LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-09-2003, 07:29 PM   #1
morrolan
Member
 
Registered: Sep 2003
Location: Manchester UK
Posts: 264

Rep: Reputation: 30
Unable to disable X from loading at statup


Hi, I'm quite new to Linux, got so annoyed at microsoft that I'm now exploring alternatives.

I want Debian to boot to the command line, but each time the machine is powered up, it goes straight to Debain's X login screen, and from there into KDE.

I've been working on this for days, I've read what I can find on google, I've changed the default runlevel in inittab to 3 (everywhere says change it from 5 to 3, my default was 2 , but each time the system is turned on, it loads into the GUI.

I've looked at the Xsession file (didn't understand much), but I don't know what processes run or where the programs to launch at startup are listed.



Is there such a thing as a "startup" script, which lists what to run and in what order at boot?
 
Old 09-09-2003, 08:03 PM   #2
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Linux Mint 17, Debian 8
Posts: 7,863

Rep: Reputation: 311Reputation: 311Reputation: 311Reputation: 311
"(everywhere says change it from 5 to 3"

Debian is the oddball. It uses a different runlevel scheme from the other distributions. 2 was probably GUI and I would guess that 1 is command line in Debian. Anyway look in the comments in /etc/inittab to see if you can figure out what Debian does with runlevels.

"Is there such a thing as a "startup" script, which lists what to run and in what order at boot?"

There are several large sets of startup scripts located in /etc/init.d
The runlevel setting determines which set of startup scripts are run.
You can also edit and change the startup scripts any way that you want.

Last edited by jailbait; 09-09-2003 at 08:06 PM.
 
Old 09-09-2003, 08:29 PM   #3
morrolan
Member
 
Registered: Sep 2003
Location: Manchester UK
Posts: 264

Original Poster
Rep: Reputation: 30
0 is listed as halt
1 single-user
2-5 multiple users
6 is reboot

Where can I find definitions of what each runlevel consists of?

 
Old 09-09-2003, 09:02 PM   #4
wr3ck3d
Member
 
Registered: Dec 2002
Location: IL
Distribution: NetBSD, Slackware, Gentoo, Debian, FreeBSD
Posts: 444

Rep: Reputation: 31
I dont use debian. Found this though. Not sure if is correct so be careful

Quote:
Q: How can I make debian not boot into X?
A: First of all, the answer is *not* changing your default runlevel
like in RedHat, Debian uses a different approach and configures
runlevels differently, i.e. it makes by default no difference between
the multi-user runlevels 2 [default runlevel], 3, 4 and 5 and lets
the system administrator customize them. Read
http://www.debian.org/doc/debian-pol...sys#s-sysvinit for more
informations. Your graphical login thing, called a 'display manager'
is started like any other service with a script in /etc/init.d/ and a
symlink pointing to that in /etc/rc?.d/. If you want to get rid of it,
you have two possibilities:
1) remove the offending package, most likely one from xdm, kdm, wdm,
gdm or login.app (note: you can have more than one installed, but only
one is used by default). If your system wants to remove the packages
x-window-system, kde or gnome, dont't worry, they are only useful for
installation and not needed afterwards.
2) remove the symlink from one or all of the runlevels. This can be
solved with Debian's update-rc.d command (e.g. update-rc.d -f xdm remove).
This will remove xdm from all multi-user runlevels. You can also
use rm to delele the symlink in your default runlevel, but not in the
others in order to be able to boot into a 'X runlevel' and a 'non-X
runlevel', like RedHat does it.
 
Old 09-09-2003, 09:28 PM   #5
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Linux Mint 17, Debian 8
Posts: 7,863

Rep: Reputation: 311Reputation: 311Reputation: 311Reputation: 311
Halt means stop the computer
reboot means reboot the computer

single user mode means run with only one user, i.e. like the old DOS system

According to this link Debian sets runlevels 2-5 to be exactly the same:
http://www.togaware.com/linux/survivor/Other_Run.html

This baffles me as no other distribution is set up like this.

On Debian the run level number is used to start the script:
/etc/init.d/rcS#

So setting the runlevel to 3 will run script /etc/init.d/rcS3

That's all I can tell you. So either we need a Debian expert in here to help on this question or you could follow the scripts /etc/init.d/rcS# and see what they do.

If they are truly all the same then you could borrow one and set up your own private startup script to experiment with.
 
Old 09-09-2003, 09:48 PM   #6
morrolan
Member
 
Registered: Sep 2003
Location: Manchester UK
Posts: 264

Original Poster
Rep: Reputation: 30
Thumbs up

wr3ck3d,
that worked wonders, I ran "update-rc.d -f xdm remove" as root, and rebooted - voila! Booted straight to the command prompt. Next thing, it tried to boot into gdm, so I removed that too.

Thanks very much.


"There is no substitute for good manners - except fast reflexes."
 
Old 09-09-2003, 09:55 PM   #7
morrolan
Member
 
Registered: Sep 2003
Location: Manchester UK
Posts: 264

Original Poster
Rep: Reputation: 30
Jailbait, that link you gave http://www.togaware.com/linux/survivor/Other_Run.html is the more surgical removal approach.

quote:
To stop xdm, for example, from starting up by default on boot, simply remove the symbolic link of the corresponding `S' script from /etc/rc?.d/S*xdm.

it goes into detail about removing the xdm entry in the particular run level script, rather than the kitchen-knife approach (which works great nonetheless) as used by "update-rc.d -f xdm remove".

Thanks again for the help guys!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Unable to Disable TAPPING javb Linux - Newbie 1 03-11-2005 08:40 PM
Apache 2 Modules which I can disable loading.. latino Linux - Networking 2 10-16-2004 04:14 AM
How do I Disable Firewire from loading in Suse 9.1 Pro. rentz Linux - Laptop and Netbook 6 06-18-2004 07:09 AM
disable modules from loading on boot spyderusa11 Fedora 1 05-23-2004 06:58 PM
how to disable old module loading... bit7 Linux - Hardware 2 11-25-2003 03:59 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:25 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration