 |
 |
 |
 |
| Using Fedora General support for current versions. Ask questions about Fedora and it's software that do not belong in any other forum. |

31st July 2012, 11:41 AM
|
|
Registered User
|
|
Join Date: Jul 2012
Location: Oregon
Posts: 4

|
|
|
Change default run level to 3?
I would like to force my system to boot in run level 3. How would I go about doing this?
I couldn't find info about how to do this in F17.
also, if I edit my bootup options in GRUB at startup my computer freezes for whatever reason.
|

31st July 2012, 12:55 PM
|
|
Registered User
|
|
Join Date: Jan 2010
Posts: 4,979

|
|
|
Re: Change default run level to 3?
# ln -sf /usr/lib/systemd/system/multi-user.target /etc/systemd/system/default.target
Found by googling the terms systemd change runlevel
and the first hit was http://www.freedesktop.org/wiki/Soft...AskedQuestions
For what it's worth, I find that if I do a minimal installation, then later install X (though I don't install a destkop environment like Gnome, KDE, XFCE or LXDE, but only window managers, like openbox or dwm), it will continue to start with a text boot.
As for your other issue, you might want to start a separate thread, as it is probably a different issue. It will also help if you mention what sort of changes you make and how the computer freezes, as well as whether or not you ran grub2-mkconfig - /boot/grub2/grub.cfg afterwards. Regardless you won't change run level in grub (and indeed, didn't change it in grub in the old days either.)
Last edited by smr54; 31st July 2012 at 12:58 PM.
|

1st August 2012, 05:54 PM
|
|
Registered User
|
|
Join Date: Oct 2009
Posts: 824

|
|
|
Re: Change default run level to 3?
Edit the file /etc/default/grub
At the end of the line starting with "GRUB_CMDLINE_LINUX", add " 3" (within the quotes).
Then run "grub2-mkconfig -o /boot/grub2/grub.cfg"
That is, IMO, the easiest way to override the default runlevel without having to mess with things like systemd.
As for the grub2 freezup problem, check what you're doing when editing the options, are you, by any chance, pressing the "enter" key after making your changes? Blank lines WILL freeze up your boot. Make your edits, and press... F10(???) to boot. DO NOT PRESS ENTER.
|

4th August 2012, 09:15 AM
|
|
Registered User
|
|
Join Date: Jul 2012
Location: Oregon
Posts: 4

|
|
|
Re: Change default run level to 3?
Sorry I couldn't reply back sooner, been busy with work.
@droidhacker - Yes, that is the problem. Stupid Ubuntu has me programmed to press enter after editing grub boot options. I regret ever using Ubuntu.
Thank you both! I will see if I can get one of them to work.
---------- Post added at 08:15 AM ---------- Previous post was at 07:56 AM ----------
Quote:
Originally Posted by droidhacker
Edit the file /etc/default/grub
At the end of the line starting with "GRUB_CMDLINE_LINUX", add " 3" (within the quotes).
Then run "grub2-mkconfig -o /boot/grub2/grub.cfg"
That is, IMO, the easiest way to override the default runlevel without having to mess with things like systemd.
As for the grub2 freezup problem, check what you're doing when editing the options, are you, by any chance, pressing the "enter" key after making your changes? Blank lines WILL freeze up your boot. Make your edits, and press... F10(???) to boot. DO NOT PRESS ENTER.
|
Yes. This was exactly what I was looking for. Thank you so much
|

4th August 2012, 04:14 PM
|
 |
Registered User
|
|
Join Date: Mar 2009
Location: Norway
Posts: 134

|
|
|
Grub should not be edited. You can instead change your inittab setting in inittab from 5 to 3.. (/etc/inittab)
Sent from my HTC Incredible S using Tapatalk 2
|

4th August 2012, 04:48 PM
|
|
Registered User
|
|
Join Date: Jun 2006
Posts: 121

|
|
|
Re: Change default run level to 3?
Fedora no longer really has runlevels. However, systemd has some support that tries to do something sensible when someone asks it to do something with runlevels.
So far, I think the suggestion provided by smr54 is quite close to how "switching to runlevel 3" is done in Fedora >= 15.
Recently, in my experience, this would also work:
Code:
systemctl enable multi-user.target
For targets, "enable" seems to result in replacing the default target.
|

4th August 2012, 11:31 PM
|
 |
Administrator
|
|
Join Date: Aug 2009
Posts: 6,612

|
|
|
Re: Change default run level to 3?
With systemd, to switch runlevels:
Code:
systemctl isolate multi-user.target
or
systemctl isolate graphical.target
To change the default runlevel:
Code:
rm /etc/systemd/system/default.target
ln -sf /lib/systemd/system/multi-user.target /etc/systemd/system/default.target
or
ln -sf /lib/systemd/system/graphical.target /etc/systemd/system/default.target
systemd does not even use the /etc/inittab So changing it in there doesn't work anymore.
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
Current GMT-time: 21:03 (Wednesday, 22-05-2013)
|
|
 |
 |
 |
 |
|
|