Solved

Edit boot grub

Posted on 2011-09-03
11
381 Views
Last Modified: 2012-05-12
Hi,

I want to edit the grub.cfg file in boot so that it is in text mode. Which line do i edit ?

To physically do it, I press 'e', write text to the line and then ctr-x. But how do i do it from the grub.conf? Is it similar ?

Thanks.



0
Comment
Question by:zizi21
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
  • 2
11 Comments
 
LVL 21

Expert Comment

by:Papertrip
ID: 36479231
To make this permanent, you need to edit /etc/inittab

Find the line with "initdefault", and change the digit in that line to "3" for run-level 3.
0
 
LVL 78

Expert Comment

by:arnold
ID: 36479270
Which linux version do you have?
Debian/ubuntu have a different mechanism than the one papertrip reference. It uses the telinit <run_level> mechanism.
telinit 3
Running runlevel in the shell should tell you which runlevel it is in.
chkconfig gdm off
http://www.cyberciti.biz/faq/prevent-xorg-from-starting-in-linux/
0
 
LVL 21

Expert Comment

by:Papertrip
ID: 36479286
I had thought the grub.cfg (instead of .conf) was just a typo, but after your reply I realize that it's not a typo if the distro is Ubuntu (or possibly some other Debian variant).

Guess I won't get my first points from this one heh.
0
More Than Just A Video Library

Train for your certification. Learn the latest DevOps tools. Grow your skillset to do better work.

At Linux Academy, we release new training modules every week so you'll always be up to date on the latest tech.

 
LVL 78

Expert Comment

by:arnold
ID: 36479292
You very well should get some points since the asker was not specific in their question and it is a valid answer to the question.
0
 

Author Comment

by:zizi21
ID: 36479299
I am using Ubuntu 10.04.2 LTS.

I did try changing the run level but i can't restart the computer after that..Someone told him they have changed the linux distrubtion, so, the run level would not work.
0
 

Author Comment

by:zizi21
ID: 36479301
I prefer using grub as I could the variables anytime i want to..i don't want it to be permanent..
0
 

Author Comment

by:zizi21
ID: 36479303
Any help is appreciated. Thanks.
0
 
LVL 78

Expert Comment

by:arnold
ID: 36479312
e
single
to boot in single user mode at which point you can use telinit to reset to level 3/2. Or revert the changes you made.

I do not know whether using e and then putting 2 will let you boot the system or whether Single is the only parameter (special Case)

0
 

Author Comment

by:zizi21
ID: 36479328
I am able to log into the computer now after installing linux again (sometime back). That's the reason I am hesitating to change the run level..Can I do it with boot grub ? I am able to do it when I am physically at the computer. But, I want to change the script so that I don't need to physcially be at the computer. I could ssh anywhere and change it..
0
 
LVL 78

Accepted Solution

by:
arnold earned 500 total points
ID: 36479330
disable  GDM (/sbin/chkconfig GDM off) which is the Gnome Desktop Manager.

When the system boots normally, what is the output from running /sbin/runlevel?
N 3, N 4, N 5?

Disabling the GDM service as outlined above, will maintain the same runlevel, but without starting the graphical display which is what you want.


0
 

Author Comment

by:zizi21
ID: 36480115
Thanks. I am trying it now.
0

Featured Post

[Webinar] How Hackers Steal Your Credentials

Do You Know How Hackers Steal Your Credentials? Join us and Skyport Systems to learn how hackers steal your credentials and why Active Directory must be secure to stop them. Thursday, July 13, 2017 10:00 A.M. PDT

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Network Interface Card (NIC) bonding, also known as link aggregation, NIC teaming and trunking, is an important concept to understand and implement in any environment where high availability is of concern. Using this feature, a server administrator …
If you have a server on collocation with the super-fast CPU, that doesn't mean that you get it running at full power. Here is a preamble. When doing inventory of Linux servers, that I'm administering, I've found that some of them are running on l…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question