Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
02-09-2004, 06:50 PM
|
#1
|
LQ Newbie
Registered: Feb 2004
Location: Berkeley, CA - USA
Distribution: Fedora Core
Posts: 7
Rep:
|
Booting to VGA or text mode without editing config file
I've been a Windows user for many years and decided to take a stab at Linux/Open Source. I downloaded and installed Red Hat 9.0, and am now in a dual boot configuration with Windows XP Pro and RH9.0. The problem is, it turns out I have a hardware incompatability that results in the RH boot being successful, but all I can see is a blank screen. I have an Nvidia Geforce FX5200 video card, which is not supported by RH 9.0 (I guess I should have checked that out beforehand!).
Nvidia has a driver update that I've downloaded from their website, but I cannot install it, because I can't see what I'm doing (I haven't even seen the GUI interface yet!). I think I can install the driver if I can just boot into VGA or text mode, but I'm not sure how to do this. Apparently, if I could boot into Runlevel 3, rather than 5, this will put me into text mode, but I have to edit a config file that I can't see!
Is there a keystroke or keystroke combination or something that I can press to specify the runlevel during the boot sequence, without manually editing the config file? Or is there some other option?
Thanks for any help you can provide.
|
|
|
02-09-2004, 07:20 PM
|
#2
|
LQ Guru
Registered: Feb 2003
Location: Virginia, USA
Distribution: Debian 12
Posts: 8,362
|
"Is there a keystroke or keystroke combination or something that I can press to specify the runlevel during the boot sequence, without manually editing the config file? Or is there some other option?"
One way to do this is to use a rescue CD to edit the runlevel. Boot your Red Hat install CD and go into rescue mode. Then mount your Linux / parttion with something like the following:
mkdir /canary
mount -t ext3 /dev/hda3 /canary
Then edit /canary/etc.inittab
In inittab change:
id:5:initdefault:
to:
id:3:initdefault:
Then remove the rescue CD and:
umount /canary
shutdown -r now
___________________________________
Be prepared. Create a LifeBoat CD.
http://users.rcn.com/srstites/LifeBo...home.page.html
Steve Stites
|
|
|
02-10-2004, 12:00 AM
|
#3
|
LQ Newbie
Registered: Feb 2004
Location: Berkeley, CA - USA
Distribution: Fedora Core
Posts: 7
Original Poster
Rep:
|
The rescue mode from the installation CD has allowed me to access a shell prompt and access to the file system. However, the "edit" command gives the response, "not a valid command." I can view "/etc/inittab," but I can't do anything with it.
Any suggestions?
|
|
|
02-10-2004, 12:01 AM
|
#4
|
LQ Newbie
Registered: Feb 2004
Location: Berkeley, CA - USA
Distribution: Fedora Core
Posts: 7
Original Poster
Rep:
|
Clarification:
I can see "/etc/inittab" in the file system (when I use the "dir" command in the /etc directory), but I can't do anything with it.
|
|
|
02-10-2004, 11:24 AM
|
#5
|
LQ Guru
Registered: Feb 2003
Location: Virginia, USA
Distribution: Debian 12
Posts: 8,362
|
"I can see "/etc/inittab" in the file system (when I use the "dir" command in the /etc directory), but I can't do anything with it."
You are looking at /etc/inittab on the rescue system. Since it is on a CD it is read only. You want to edit the /etc/inittab which is installed on your hard drive. So you need to know which partition is your / partition (I will assume /dev/hda3) and what type of file system / is (I will assume ext3). Then you can list your /etc/inittab like this.
mkdir /canary
mount -t ext3 /dev/hda3 /canary
less /canary/etc/inittab
You exit less by typing in q
Then you can edit /etc/inittab with vi or some other editor:
vi /canary/etc/inittab
or
ed /canary/etc/inittab
Neither vi nor ed is very user friendly. Here is a vi tutorial:
http://www.eng.hawaii.edu/Tutor/vi.html
___________________________________
Be prepared. Create a LifeBoat CD.
http://users.rcn.com/srstites/LifeBo...home.page.html
Steve Stites
Last edited by jailbait; 02-10-2004 at 11:29 AM.
|
|
|
02-10-2004, 06:02 PM
|
#6
|
LQ Newbie
Registered: Feb 2004
Location: Berkeley, CA - USA
Distribution: Fedora Core
Posts: 7
Original Poster
Rep:
|
The rescue mode I use mounts my system to /mnt/sysimage. I was able to edit "inittab" using the VI editor (thanks to Steve) in the /mnt/sysimage/etc/ directory and then used the command "chroot" to change root to /mnt/sysimage. Upon reboot, the system booted into runlevel 3.
Thanks for the help.
Just for anyone having the same difficulty, here was my process:
Boot linux into rescue mode using the installation CD and typing "linux rescue" at the "boot:" prompt.
When you get the shell prompt, navigate to "/etc/inittab" (or wherever your system has been mounted. In my case, it was mounted to "/mnt/sysimage". The rescue mode startup should tell you where it is).
Edit inittab using "vi /etc/inittab"
Change default runlevel to 3.
Reboot.
Login as root.
Do what you need to do.
You are reading this post written under my slick new Mozilla Web Browser!
|
|
|
02-10-2004, 09:36 PM
|
#7
|
Member
Registered: Feb 2004
Location: Canada
Distribution: FC2
Posts: 63
Rep:
|
If you are using grub, you can boot to text mode by clicking 'e' to edit at the grub splash screen while selecting the kernel you want to boot to.
Then with the line similar to the following highlighted, click 'e' to edit it:
kernel /vmlinuz-2.4.20-8smp ro root=LABEL=/
Change the line so it reads something like
kernel /vmlinuz-2.4.20-8smp ro root=LABEL=/ single
Then click 'b' to boot.
There is no need to change this back afterwards. Next time you boot it will go back to normal. Note that this only works for grub.
Chris DeGroot
|
|
|
All times are GMT -5. The time now is 09:43 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|