In this article, I will explain how to easily try "Cockpit", which is software for managing Linux with GUI, on a learning service called "Katacoda".
https://cockpit-project.org/running.html
This time, we are focusing on the procedure to easily implement the same function on Katacoda, so please check separately what you can do with Cockpit and how to use it.
Select "Learn CentOS" in the middle.
Select "Playground" on the left.
On the next page, click "Start" and the CLI screen will appear as shown below. First, set the root administrator password here.
passwd
The warning is due to the use of weak security strings. This time it's for learning purposes, so you can set a temporary one that is easy for you to understand.
yum install cockpit (User manually approves Yes response to installation)
Or
yum -y install cokpit (Automatically responds Yes to the installation)
The installation was completed in a few seconds.
#Check the startup status of the cockpit service systemctl status cockpit
Active was confirmed in green letters. Cockpit is now working.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/680306/daefc4ca-8411-8d29-d84a-0e2accde9b84.png)
Originally, it is also necessary to open the firewall port here. For Cockpit, TCP 9090 must be Open.
However, since firewalld is not running in the Katakoda environment, it is possible to use Cockpit without setting it.
If you want to check the procedure for opening the firewall port, refer to the [Cokpit](https://cockpit-project.org/running.html) page for the firewall port opening command for each distribution. Please give me.
<H2> 5. Use a browser to access CentOS and log in </ H2>
There is a "+" icon at the top of the CLI screen in Katacoda.
Click here to display a menu that allows you to access the Linux.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/680306/dc351cc0-b105-5aaf-2837-487e7858309f.png)
Select the third "Select port to view on Host 1" from the top.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/680306/0fa404ab-ed67-1a88-6b12-f5a57c73b138.png)
Enter the default port number 9090 used by Cockpit in the port specification field below, and then click "Display Port".
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/680306/61172eb0-0c99-6790-1107-a54b305f10e9.png)
I was able to start Cockpit on the browser.
Enter the following information to log in. (User name root / password value set earlier)
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/680306/5176f191-e9e1-078e-8bc7-8a6e1879bad0.png)
After logging in, you can check the information about the Linux OS graphically as follows.
Performance charts Graphs also move in real time, which is interesting.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/680306/eefe34a8-d567-e173-c6cd-a1fa71bd0191.png)
<H2> Bonus: Log collection is also possible on katacoda </ H2>
#Install Sosreport(Be sure to carry out because it is not installed on CentOS on Katacoda environment) yum install sos
After performing the above work, you can get the log from the log collection tab.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/680306/387a41f0-4b73-63c6-d895-b403df04d6ee.png)
I was able to get the file in tar.xz format from CentOS in Katacoda. Of course, it can be decompressed.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/680306/1a1996bf-4e46-c915-2146-87b94478d172.png)
Recommended Posts