


全文預(yù)覽已結(jié)束
下載本文檔
版權(quán)說(shuō)明:本文檔由用戶(hù)提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)
文檔簡(jiǎn)介
安裝完CentOS 7 minimal后,無(wú)力吐槽,變化之大,發(fā)現(xiàn)以前常用的一些命令都沒(méi)有。一、常用命令安裝查看anaconda-ks.cfg,原來(lái)是沒(méi)裝base group的包rootcentos7 # cat anaconda-ks.cfg #version=RHEL7# System authorization informationauth -enableshadow -passalgo=sha512# Use CDROM installation mediacdrom# Run the Setup Agent on first bootfirstboot -enableignoredisk -only-use=sda# Keyboard layoutskeyboard -vckeymap=us -xlayouts=us# System languagelang en_US.UTF-8 -addsupport=zh_CN.UTF-8# Network informationnetwork -bootproto=dhcp -device=eno16777736 -onboot=off -ipv6=autonetwork -hostname=localhost.localdomain# Root passwordrootpw -iscrypted $6$Zz5VMf1HPPRm0YRL$QSoaU9pAUApXMj9BXuK5qlUFGAfCv9Y/ylVGUcDYv.lrxfNodTiI/7DO1UR7carvL1EdgwQpuiwDt524f6.GR.# System timezonetimezone Asia/Chongqing -isUtc -nontp# System bootloader configurationbootloader -location=mbr -boot-drive=sdaautopart -type=lvm# Partition clearing informationclearpart -none -initlabel %packagescore # 這里只有core%endrootcentos7 # yum groupinstall base # 安裝完后ifconfig、service、chkconfig等命令就都有了二、運(yùn)行級(jí)別切換rootcentos7 # cat /etc/inittab # 系統(tǒng)運(yùn)行級(jí)別的設(shè)置方式也變化了# inittab is no longer used when using systemd.# ADDING CONFIGURATION HERE WILL HAVE NO EFFECT ON YOUR SYSTEM.# Ctrl-Alt-Delete is handled by /etc/systemd/system/ctrl-alt-del.target# systemd uses targets instead of runlevels. By default, there are two main targets:# multi-user.target: analogous to runlevel 3# graphical.target: analogous to runlevel 5# To set a default target, run:# ln -sf /lib/systemd/system/.target /etc/systemd/system/default.target這里寫(xiě)的很明白了,做個(gè)軟鏈修改默認(rèn)運(yùn)行級(jí)別rootcentos7 system# ll /lib/systemd/system/runlevel*.target # 系統(tǒng)0-6 7個(gè)運(yùn)行級(jí)別,2 3 4 運(yùn)行指向同一個(gè)文件lrwxrwxrwx 1 root root 15 Oct 11 03:51 /lib/systemd/system/runlevel0.target - poweroff.targetlrwxrwxrwx 1 root root 13 Oct 11 03:51 /lib/systemd/system/runlevel1.target - rescue.targetlrwxrwxrwx 1 root root 17 Oct 11 03:51 /lib/systemd/system/runlevel2.target - multi-user.targetlrwxrwxrwx 1 root root 17 Oct 11 03:51 /lib/systemd/system/runlevel3.target - multi-user.targetlrwxrwxrwx 1 root root 17 Oct 11 03:51 /lib/systemd/system/runlevel4.target - multi-user.targetlrwxrwxrwx 1 root root 16 Oct 11 03:51 /lib/systemd/system/runlevel5.target - graphical.targetlrwxrwxrwx 1 root root 13 Oct 11 03:51 /lib/systemd/system/runlevel6.target - reboot.target三、systemctl管理系統(tǒng)服務(wù)systemctl可以看作是service和chkconfig的組合jobchkconfig、servicesystemctl服務(wù)開(kāi)機(jī)自啟動(dòng)chkconfig -level 3 httpd onsystemctl enable httpd服務(wù)不開(kāi)機(jī)自啟動(dòng)chkconfig -level 3 httpd offsystemctl disable httpd服務(wù)狀態(tài)service httpd statussystemctl status httpd(服務(wù)詳細(xì)信息)systemctl is-active httpd(只顯示是否active)所有服務(wù)的啟動(dòng)狀態(tài)chkconfig -listsystemctl list-units -type=service啟動(dòng)服務(wù)service httpd startsystemctl start httpd停止服務(wù)service httpd stopsystemctl stop httpd重啟服務(wù)service httpd restartsystemctl restart httpdcentos 7之前的
溫馨提示
- 1. 本站所有資源如無(wú)特殊說(shuō)明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶(hù)所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁(yè)內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒(méi)有圖紙預(yù)覽就沒(méi)有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫(kù)網(wǎng)僅提供信息存儲(chǔ)空間,僅對(duì)用戶(hù)上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶(hù)上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶(hù)因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。
最新文檔
- 喀什大學(xué)晨讀活動(dòng)方案
- 品讀一本好書(shū)活動(dòng)方案
- 品鑒推廣活動(dòng)方案
- 團(tuán)日?qǐng)F(tuán)課活動(dòng)方案
- 國(guó)際幸福日系列活動(dòng)方案
- 員工子女參觀(guān)活動(dòng)方案
- 團(tuán)隊(duì)猜拳活動(dòng)方案
- 國(guó)慶旅游日活動(dòng)方案
- 商業(yè)開(kāi)業(yè)執(zhí)行活動(dòng)方案
- 國(guó)際禁毒日系列活動(dòng)方案
- 柳州某醫(yī)院空氣源熱泵熱水系統(tǒng)設(shè)計(jì)案例
- 2023-2024學(xué)年福建省泉州市小學(xué)語(yǔ)文六年級(jí)期末自測(cè)模擬試卷
- GB 29541-2013熱泵熱水機(jī)(器)能效限定值及能效等級(jí)
- 控規(guī)用地代碼
- 2023年上杭縣社區(qū)工作者招聘考試筆試題庫(kù)及答案解析
- 2021年曹楊二中自招數(shù)學(xué)試卷
- 中國(guó)近現(xiàn)代史綱要超星爾雅答案貴州大學(xué)-
- 新能源汽車(chē)底盤(pán)檢修全套課件
- 幼兒園大班數(shù)學(xué)口算練習(xí)題可打印
- 江蘇特種作業(yè)人員體檢表
- 堡壘主機(jī)用戶(hù)操作手冊(cè)運(yùn)維管理
評(píng)論
0/150
提交評(píng)論