You are not logged in.
Pages: 1
Hello.
I was wondering if there are plans for adding support for different runlevels in Arch.
In case there aren't, I was thinking about prefixing the daemons in the daemons array, with the runlevels at which they are intended to run. For example, if I want to have kdm running only at runlevel 5, my daemons array would look like this:
DAEMONS=(... 5kdm)Any input would be appreciated.
Some PKGBUILDs: http://members.lycos.co.uk/sweiss3
Offline
Arch does have support for different runlevels, have you taken a look at /etc/inittab ?
Also, check out this wiki article, for running kdm on another runlevel -> http://wiki.archlinux.org/index.php/Login_manager
Offline
This is what I am using now, but it is fairly limited. You cannot have different services running for different runlevels using the current rc.conf structure (correct me if I'm wrong).
Some PKGBUILDs: http://members.lycos.co.uk/sweiss3
Offline
The lack of extra runlevels seems to be a source of pride for Arch, in keeping with the KISS principle, as per the Wiki. (I personally have no need of setting runlevels- mainly because I don't fully understand their significance.)
What are the advantages and disadvantages of having more runlevels? Is it just another level of control over one's system?
Offline
you could make a change for his very simply:
cp /etc/rc.multi /etc/rc.multi5
sed -i "s/DAEMONS/DAEMONS5/g" /etc/rc.multi5in /etc/inittab, change:
rm:2345:wait:/etc/rc.multito
rm:2345:wait:/etc/rc.multi
rm:5:wait:/etc/rc.multi5then put your daemons in DAEMONS5=() in rc.conf
5's probably a shitty prefix for this, but that's just an example, swap it for whatever you like. You'd also need to cut a bit of /etc/rc.shutdown, just the daemon stopping part to a seperate file, and add that to the inittab on shutdown. Seperate file will stop it being clobbered by updates, rather than editing /etc/rc.shutdown.
I don't see much hope of this being merged, but this *is* a clean way you could implement it if you need it, and would not be clobbered by any system updates.
James
Last edited by iphitus (2007-04-28 23:09:50)
Offline
The lack of extra runlevels seems to be a source of pride for Arch, in keeping with the KISS principle, as per the Wiki. (I personally have no need of setting runlevels- mainly because I don't fully understand their significance.)
What are the advantages and disadvantages of having more runlevels? Is it just another level of control over one's system?
With runlevels you can keep several 'configurations' for the same system. For example, using and X server and not using it.
/etc/inittab is a bit limited at that. Sure, you can handle starting and stopping a display manager there, but what if you have daemons that need X? For example, if you are not using X right now, you probably don't need to have the keytouch daemon running either.
I bet there are people who can put it to better use.
As for being against KISS - I think the term is being misused. I do not believe the meaning of KISS is to be less functional - It is about keeping a simple implementation of things. Pacman is by no means a simple package manager - It has plenty of features, but the way you use them is fairly simple. This is what makes it KISS.
@iphitus:
Thanks for the tip. I do believe however that it is a useful feature, and it gives you an extra sysv feature, without complicating its management that much.
Some PKGBUILDs: http://members.lycos.co.uk/sweiss3
Offline
I too don't really see the value in this myself - I never bothered with them in RedHat either.
My laptop currently offers me 10 profiles on boot, each unique, without the need for runlevels.
I personally appreciate their absence. I tried to think of a real use for them but failed. Just my opinion of course.
iphitus: You should wikify that gem ![]()
Last edited by lefallen (2007-04-28 13:59:04)
JABBER: krayon -A-T- chat.qdnx.org
E-MAIL: archlinuxforums -A-T- quadronyx.org
WEB: http://www.qdnx.org/krayon/
~o~
Offline
I'm not 100% sure, but when changing /etc/inittab, make sure it's added to /etc/pacman.conf as NoUpgrade.
I noticed it wasn't after I saw pacman was going to upgrade initscripts and quickly stopped it... not sure what would have happened if I hadn't.
Offline
As for being against KISS - I think the term is being misused. I do not believe the meaning of KISS is to be less functional - It is about keeping a simple implementation of things.
Yea, but I think different runlevels don't need any special implementation in the default setup (yes, I'm no dev, so my opinion is not very important
. There's only that many people that actually need to use it, and those could follow iphitus' hint (or come up with a similar solution themselves). I think filling up the default setup with all the possibilities what some people might use IS against KISS. The system works as it should, and if you need something extra (like runlevels), edit these 3 files.
I really enjoy this approach, since to make a modification, I need to understand how the system works (in this case, how the initscripts start up the system). Then if something breaks, I can figure out the problem much more quicky. I come from the gentoo world, where the initscripts are more complicated; you only edit some conf files; doing some change that is not predicted by the devs is somewhat difficult; the next update breaks it; and you still have no clue how the things are actually done.
Offline
Well, someone take Iphitus' suggestion and put it in the Wiki under "Runlevels"! ![]()
Offline
my implementation is simple enough that someone could take the runlevel files and make a package and aur it, call it 'runlevels' or something....
inittab doesnt need to be in NoUpgrade, it's marked as backup=() in the PKGBUILD.
wikified: http://wiki.archlinux.org/index.php/Adding_Runlevels
Like I said, I don't see much chance of this being merged, just because we don't need it, and there aren't many uses, but given it's simplicity, it could easily be introduced as an addon package.
James
Last edited by iphitus (2007-04-28 23:10:49)
Offline
rm:2345:wait:/etc/rc.multi rm:5:wait:/etc/rc.multi5James
Shouldn't it be:
rm: --> 234 <--:wait:/etc/rc.multi
rm:5:wait:/etc/rc.multi5? (Minus the arrows obviously) I'm no expert; I could be wrong.
Last edited by Weeks (2007-04-28 23:23:07)
Offline
Hi guys!
I added a simpler approach to add runlevels in Arch.
Check it out in the wiki page above.
Greetins by the Shogun.
Have fun and enjoy your life!
Offline
Pages: 1