rc腳本的位置不同:
redhat : /etc/rc.d/rc
ubuntu:/etc/init.d/rc作者: wangkj 時(shí)間: 2009-11-10 14:41
還有就是ubuntu特有的/etc/rcS.d
我從rc文件中,沒(méi)有找到關(guān)于這個(gè)必須執行的操作,但是
網(wǎng)上提到:
*運行等級 S:開(kāi)機進(jìn)程中的第一個(gè)運行等級。若/etc/rcS.d 下的鏈接文件開(kāi)頭子母是大寫(xiě)的,那么它鏈接的在 /etc/init.d 下的對應腳本將被調用并開(kāi)啟,該進(jìn)程將被執行。
運行等級 S 就是指的這個(gè)這個(gè)目錄中的文件,
如果相信了解這些啟動(dòng)步驟,請讀/sbin/init的源碼,這個(gè)俺懶得讀了。
從我的實(shí)驗來(lái)看,確實(shí)是先執行rcS.d然后在執行rc的。
linux的啟動(dòng)過(guò)程簡(jiǎn)介:
bios啟動(dòng)第一個(gè)可啟動(dòng)設備
啟動(dòng)grub
啟動(dòng)內核,加載root分區
內核讀取/bin/init /sbin/init /usr/bin/init //usr/sbin/init ,這四個(gè)文件前面優(yōu)先,有前面的后面就不管了
所以詳細的真是啟動(dòng)過(guò)程,應該從init文件讀取。
這個(gè)文件可以是可執行文件,也可以是shell腳本。當然,從這個(gè)文件進(jìn)一步調用其他可執行文件或者腳本再正常不過(guò)了。作者: wangkj 時(shí)間: 2009-11-10 14:42
所以,估計rcS.d可能就是init讀取的執行文件,當然你想修改init強制讀取其他文件也沒(méi)有問(wèn)題;蛘邚娭撇蛔x取某些文件也沒(méi)問(wèn)題。作者: lelee007 時(shí)間: 2009-11-10 17:23
會(huì )計什么意思?想表達什么?作者: linux_Ultra 時(shí)間: 2009-11-10 22:01
ubuntu 不守規范,亂搞,要用正統的發(fā)行版,debian作者: wangkj 時(shí)間: 2009-11-11 13:05 標題: apt-get 錯誤的解決:用這個(gè)文件替換/etc/apt/sources.list #deb cdrom:[Ubuntu 9.04 _Jaunty Jackalope_ - Release i386 (20090420.1)]/ jaunty main restricted# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to# newer versions of the distribution.deb http://hk.archive.ubuntu.com/ubuntu/ jaunty main restricteddeb-src http://hk.archive.ubuntu.com/ubuntu/ jaunty main restricted## Major bug fix updates produced after the final release of the## distribution.deb http://hk.archive.ubuntu.com/ubuntu/ jaunty-updates main restricteddeb-src http://hk.archive.ubuntu.com/ubuntu/ jaunty-updates main restricted## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu## team. Also, please note that software in universe WILL NOT receive any## review or updates from the Ubuntu security team.deb http://hk.archive.ubuntu.com/ubuntu/ jaunty universedeb-src http://hk.archive.ubuntu.com/ubuntu/ jaunty universedeb http://hk.archive.ubuntu.com/ubuntu/ jaunty-updates universedeb-src http://hk.archive.ubuntu.com/ubuntu/ jaunty-updates universe## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu## team, and may not be under a free licence. Please satisfy yourself as to## your rights to use the software. Also, please note that software in## multiverse WILL NOT receive any review or updates from the Ubuntu## security team.deb http://hk.archive.ubuntu.com/ubuntu/ jaunty multiversedeb-src http://hk.archive.ubuntu.com/ubuntu/ jaunty multiversedeb http://hk.archive.ubuntu.com/ubuntu/ jaunty-updates multiversedeb-src http://hk.archive.ubuntu.com/ubuntu/ jaunty-updates multiverse## Uncomment the following two lines to add software from the 'backports'## repository.## N.B. software from this repository may not have been tested as## extensively as that contained in the main release, although it includes## newer versions of some applications which may provide useful features.## Also, please note that software in backports WILL NOT receive any review## or updates from the Ubuntu security team.# deb http://hk.archive.ubuntu.com/ubuntu/ jaunty-backports main restricted universe multiverse# deb-src http://hk.archive.ubuntu.com/ubuntu/ jaunty-backports main restricted universe multiverse## Uncomment the following two lines to add software from Canonical's## 'partner' repository.## This software is not part of Ubuntu, but is offered by Canonical and the## respective vendors as a service to Ubuntu users.# deb http://archive.canonical.com/ubuntu jaunty partner# deb-src http://archive.canonical.com/ubuntu jaunty partnerdeb http://security.ubuntu.com/ubuntu jaunty-security main restricteddeb-src http://security.ubuntu.com/ubuntu jaunty-security main restricteddeb http://security.ubuntu.com/ubuntu jaunty-security universedeb-src http://security.ubuntu.com/ubuntu jaunty-security universedeb http://security.ubuntu.com/ubuntu jaunty-security multiversedeb-src http://security.ubuntu.com/ubuntu jaunty-security multiverse作者: wangkj 時(shí)間: 2009-11-11 13:05
cn.ubuntun.com有問(wèn)題。經(jīng)常連不上,不知道是不是被河蟹了。作者: f.luo 時(shí)間: 2009-11-11 13:09
會(huì )計也用ubuntu了?作者: 一朝成名 時(shí)間: 2009-11-11 20:21
裝了一個(gè)Ubuntu,一直還沒(méi)用過(guò)~作者: f.luo 時(shí)間: 2009-11-11 20:26
現在的源用的是163的,速度還不錯。作者: wangkj 時(shí)間: 2009-11-11 21:37
地址,給個(gè)具體地址。作者: linux_Ultra 時(shí)間: 2009-11-11 21:53
163 , 臺灣的都不錯。作者: f.luo 時(shí)間: 2009-11-11 22:19
163的源:
deb http://mirrors.163.com/ubuntu/ karmic main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ karmic-security main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ karmic-updates main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ karmic-proposed main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ karmic-backports main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ karmic main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ karmic-security main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ karmic-updates main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ karmic-proposed main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ karmic-backports main restricted universe multiverse作者: linux_Ultra 時(shí)間: 2009-11-11 22:19
安裝剛發(fā)行的ubuntu,一般就看看速配指南就行了 http://wiki.ubuntu.org.cn/Qref/Source#.E6.BA.90.E5.88.97.E8.A1.A8作者: f.luo 時(shí)間: 2009-11-11 22:19
sohu的源:
deb http://mirrors.sohu.com/ubuntu/ karmic main restricted universe multiverse
deb http://mirrors.sohu.com/ubuntu/ karmic-security main restricted universe multiverse
deb http://mirrors.sohu.com/ubuntu/ karmic-updates main restricted universe multiverse
deb http://mirrors.sohu.com/ubuntu/ karmic-proposed main restricted universe multiverse
deb http://mirrors.sohu.com/ubuntu/ karmic-backports main restricted universe multiverse
deb-src http://mirrors.sohu.com/ubuntu/ karmic main restricted universe multiverse
deb-src http://mirrors.sohu.com/ubuntu/ karmic-security main restricted universe multiverse
deb-src http://mirrors.sohu.com/ubuntu/ karmic-updates main restricted universe multiverse
deb-src http://mirrors.sohu.com/ubuntu/ karmic-proposed main restricted universe multiverse
deb-src http://mirrors.sohu.com/ubuntu/ karmic-backports main restricted universe multiverse作者: 一朝成名 時(shí)間: 2009-11-12 11:34
看來(lái)我要順應潮流換ubuntu了~~~作者: linux_Ultra 時(shí)間: 2009-11-12 22:27
linuxsir 那邊的老鳥(niǎo)都玩gentoo和archlinux。。。
還記得上課時(shí)老師對我們說(shuō):你們現在還太粉了所以在玩 linux,和我當年一樣,高手玩的是 FreeBSD和OpenBSD...作者: f.luo 時(shí)間: 2009-11-12 22:38
學(xué)到詞了,粉……作者: wangkj 時(shí)間: 2009-11-13 15:22
ubuntu 啟動(dòng)調用的不是inittab,而是/ectc/event.d/rc-default !
可能是修改了init文件吧。沒(méi)看源碼。
花了不少功夫才發(fā)現的。