幫助中心
這里有最新的使用文檔和教程
< 返回
Centos8 提示需要把cockpit服務(wù)設(shè)置開機(jī)自啟
2023-05-30 10:12 作者:31IDC 閱讀量:3383 所屬分類:Linux系統(tǒng)Centos8 Stream終端登錄后提示需要把cockpit服務(wù)設(shè)置開機(jī)自啟
CentOS8已經(jīng)出很久了,今天想裝下看看有哪些變化,安裝完登錄就發(fā)現(xiàn)不一樣了,登錄后提示Activate the web console with: systemctl enable --now cockpit.socket 是什么意思
一登錄 centos8, 就提示信息 “Activate the web console with: systemctl enable --now cockpit.socket”
Connecting to 192.168.8.191:22...
Connection established.
To escape to local shell, press 'Ctrl+Alt+]'.
Activate the web console with: systemctl enable --now cockpit.socket
Last login: Sun Mar 15 02:43:19 2020 from 192.168.8.151
這個(gè)是什么意思呢? 其實(shí)這個(gè)就是想讓你開啟cockpit服務(wù)。這條命令就是要把cockpit設(shè)置為開機(jī)自啟動(dòng)并且立刻運(yùn)行起來,Cockpit 是紅帽開發(fā)的網(wǎng)頁版圖像化服務(wù)管理工具,官方是說“Cockpit 是一個(gè)交互式 Linux 服務(wù)器管理接口。”,說白了就是給你提供個(gè)web頁面來管理cneots8服務(wù)器,聽說這個(gè)服務(wù)還是非常好用的,后面會(huì)更新看下這個(gè)服務(wù)的具體使用。
按照提示把相關(guān)服務(wù)器開啟后,終端登錄服務(wù)器后,會(huì)有以下提示:
- 開啟cockpit服務(wù)器:
sudo systemctl enable --now cockpit.socket
[leiakun@centos8 ~]$ sudo systemctl enable --now cockpit.socket
[sudo] leiakun 的密碼:
Created symlink /etc/systemd/system/sockets.target.wants/cockpit.socket → /usr/lib/systemd/system/cockpit.socket.
[leiakun@centos8 ~]$
- 重新登錄終端驗(yàn)證,提示
Web console: https://centos8:9090/ or https://192.168.8.191:9090/
Connecting to 192.168.8.191:22...
Connection established.
To escape to local shell, press 'Ctrl+Alt+]'.
Web console: https://centos8:9090/ or https://192.168.8.191:9090/
Last login: Sun Mar 15 02:44:44 2020 from 192.168.8.151
- 查看服務(wù)在防火墻中是否啟用
sudo firewall-cmd --get-services |grep cockpit
[leiakun@centos8 ~]$ sudo firewall-cmd --get-services |grep cockpit
RH-Satellite-6 amanda-client amanda-k5-client amqp amqps apcupsd audit bacula bacula-client bb bgp bitcoin bitcoin-rpc bitcoin-testnet bitcoin-testnet-rpc bittorrent-lsd ceph ceph-mon cfengine cockpit condor-collector ctdb dhcp dhcpv6 dhcpv6-client distcc dns dns-over-tls docker-registry docker-swarm dropbox-lansync elasticsearch etcd-client etcd-server finger freeipa-4 freeipa-ldap freeipa-ldaps freeipa-replication freeipa-trust ftp ganglia-client ganglia-master git grafana gre high-availability http https imap imaps ipp ipp-client ipsec irc ircs iscsi-target isns jenkins kadmin kdeconnect kerberos kibana klogin kpasswd kprop kshell ldap ldaps libvirt libvirt-tls lightning-network llmnr managesieve matrix mdns memcache minidlna mongodb mosh mountd mqtt mqtt-tls ms-wbt mssql murmur mysql nfs nfs3 nmea-0183 nrpe ntp nut openvpn ovirt-imageio ovirt-storageconsole ovirt-vmconsole plex pmcd pmproxy pmwebapi pmwebapis pop3 pop3s postgresql privoxy prometheus proxy-dhcp ptp pulseaudio puppetmaster quassel radius rdp redis redis-sentinel rpc-bind rsh rsyncd rtsp salt-master samba samba-client samba-dc sane sip sips slp smtp smtp-submission smtps snmp snmptrap spideroak-lansync spotify-sync squid ssdp ssh steam-streaming svdrp svn syncthing syncthing-gui synergy syslog syslog-tls telnet tentacle tftp tftp-client tile38 tinc tor-socks transmission-client upnp-client vdsm vnc-server wbem-http wbem-https wsman wsmans xdmcp xmpp-bosh xmpp-client xmpp-local xmpp-server zabbix-agent zabbix-server
- 如有啟用則不用執(zhí)行如下操作,如果防火墻沒有開通對(duì)應(yīng)的服務(wù)器,需要執(zhí)行以下操作。
- 因?yàn)镃ockpit默認(rèn)是使用9090進(jìn)行Web管理,CentOS8默認(rèn)又自帶了Firewall防火墻,所以還需要放行對(duì)應(yīng)的端口,命令如下:
sudo firewall-cmd --add-service=cockpit --permanent
sudo firewall-cmd --reload
防火墻打開后就可以通過瀏覽器打開對(duì)應(yīng)的管理界面,用戶名密碼就是系統(tǒng)登錄的用戶名和密碼。以下是登錄首頁和內(nèi)部頁面情況。