LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
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


Reply
  Search this Thread
Old 06-25-2004, 10:36 PM   #1
crazibri
Member
 
Registered: Mar 2004
Location: Orange County, CA
Distribution: OS X, SuSE, RH, Debian, XP
Posts: 377

Rep: Reputation: 31
Stop Suse boot.local in Grub


Hi,
I'm fairly new to Linux but know the basic way around. This might sound like a dumb question but I recently added a command to boot.local in Suse9.1 and since it relates to my wireless card it keep waiting for my wireless card to be initalized but its not until after boot.local so basically I'm in a loop.

How do I stop boot.local from being accessed at boot for Suse? I've got Grub bootloader installed.
Thanks!
 
Old 06-25-2004, 11:41 PM   #2
bruno buys
Senior Member
 
Registered: Sep 2003
Location: Rio
Distribution: Debian
Posts: 1,509

Rep: Reputation: 46
boot-local is accessed very early in the boot process. Your wireless shouldn't have loaded modules, yet.

I don't know how you can prevent from boot.local being accessed, but another way is to edit boot.local and remove the line, reverting the file to the previous state.

Once you did this, you can start your wireless with a script, which is easier to insert in the boot process, and you can control when is it loaded with the runlevel editor.
Post again if you choose this way and if you need help.

Last edited by bruno buys; 06-25-2004 at 11:42 PM.
 
Old 06-26-2004, 12:35 AM   #3
crazibri
Member
 
Registered: Mar 2004
Location: Orange County, CA
Distribution: OS X, SuSE, RH, Debian, XP
Posts: 377

Original Poster
Rep: Reputation: 31
Thank you for helping!

Well see thats the thing, the command in boot.local is for wpa support and the program is waiting for wireless modules to be loaded but it wont go onto the next part of the boot process until the program can see wlan0 up and running.

So my problem is that I need to stop that command from happening in boot.local during the boot process so that Suse will actually boot. It doesnt move past it.

If there's some way I can get to a command line to edit boot.local and then boot it or if there's an option like F8 in windows where I can tell it what to load and not load.

Once I can get rid of this command in boot.local or if there's a way to bypass that one command then I can fix my problem and put the command somewhere else in the level editor.

Any more input would be much appreciated. Thanks!

 
Old 06-26-2004, 12:56 AM   #4
bruno buys
Senior Member
 
Registered: Sep 2003
Location: Rio
Distribution: Debian
Posts: 1,509

Rep: Reputation: 46
Yes, there is. But you don't have to boot the installed suse, in order to edit this file. The easiest way is to load a system from the cd, with some sort of live cd.

You can run the first cd from the 5 cd's set used to install suse, and ask to repair an installation. Or you can run a suse live cd, from 9.1 or even a 9.0. They are freely available to download.

Personally, I would run a live cd, as it will give you a kde environment, with a bit more support than just the command line in init 3.

Once you are in, just mount the drive where is the file you wanna edit, do the changes, save and reboot:

- su to root, then do something like:

mount the drive where boot.local is written:
mount /dev/??? /
In the above line you should change ??? by the partition where the file is. The mount point I'm guessing it's /.

kwrite /etc/boot.local
it will open the file. Edit, save and close.

Remove the cd from the drive and reboot.

If you can manage to go through these steps without error, let me know, and we'll set your wireless, in the next.

Last edited by bruno buys; 06-26-2004 at 01:00 AM.
 
Old 06-26-2004, 01:54 AM   #5
crazibri
Member
 
Registered: Mar 2004
Location: Orange County, CA
Distribution: OS X, SuSE, RH, Debian, XP
Posts: 377

Original Poster
Rep: Reputation: 31
Very good idea! I'm back on Suse right now online posting this.

I'm using WPA encryption already but I just kinda srewed myself by putting it in wrong on the boot.local.

So basically where should I put this command?
It basically runs the WPA program so that when my wireless starts up it gets its IP assigned. The problem I'm currently having with where I put the boot.local is that when I look at the boot process while booting up it assigns my IP like a regular ethernet does, but when I get into KDE, Suse isnt resolving my DNS and host names. I go into Control Panel and look at DNS and Host names and everything is checked off appropriately bu it just doesnt resolve it unless I uncheck the box, update, then go back into it and check the box and update it. Then Suse reecognizes the DNS and starts resolving host names and thus I can get online.

Any clues?
Thanks again!
 
Old 06-26-2004, 10:29 AM   #6
bruno buys
Senior Member
 
Registered: Sep 2003
Location: Rio
Distribution: Debian
Posts: 1,509

Rep: Reputation: 46
Hmmm... Well, first things first.
Could you edit the boot.local to its original state? Live cds, etc... everything ok?

There are different approaches to what you might want to do to fix this. That's the nice thing about linux. I'll tell you what I did to insert my scripts in the boot process, but there can be other - even more efficient - ways to do the same thing.

1. Create a shell script to run the command you need:

- Open your text editor of choice and write

#! /bin/sh

# Command to up the wireless, by crazibri jun-2004 (or some header like this)

command

# Additionally, you may want to put a line that creates an empty file here, just to ease the
# verification of success. This file will be created with 0 bytes and owner root/root. Then you
# can remove it, no problem. If you wish not to put it, remove both this comment and the
# command.

touch /home/crazibri/wireless-ok

# Also optional

echo "Wireless done!"

EOF

- Save it as root/root in /etc/init.d

- Give it execute permission, by clicking in the "execute" bit in the properties dialog in a graphical env.

2. Now, open yast2 > system > Runlevel editor. Choose expert mode.

You'll see all the scripts listed there, and also the one you just created. Now, all you have to do is set it to run at, say, level 5 (which is multiuser/graphical env). In this point it comes up the doubt about the correct point to up the wireless. I guess runlevel 5 is a safe mode to operate.
You can also test if suse can run the script well, by trying to run now, with the Enable button.

After all this, just save and reboot.

Post again if you get stuck.
 
Old 06-26-2004, 12:31 PM   #7
crazibri
Member
 
Registered: Mar 2004
Location: Orange County, CA
Distribution: OS X, SuSE, RH, Debian, XP
Posts: 377

Original Poster
Rep: Reputation: 31
Ok, that worked. I was able to set it up as run level 5 and it starts up as I need it to.

The only problem I'm having now is with DNS and Host name resolving.
When I get into Suse and start Mozilla it cant resolve hostnames.

I find that I can manually fix this if go into Control Center, Yast Modules, Network Services, DNS and Host Names and then either uncheck or check the box that says Update DNS from DHCP. I hit finish and it updates DNS and then it works. Its very odd. Its almost as if DNS isnt being resolved at bootup or wherever it does that.

Any suggestions?
 
Old 06-26-2004, 01:54 PM   #8
bruno buys
Senior Member
 
Registered: Sep 2003
Location: Rio
Distribution: Debian
Posts: 1,509

Rep: Reputation: 46
*******
I find that I can manually fix this if go into Control Center, Yast Modules, Network Services, DNS and Host Names and then either uncheck or check the box that says Update DNS from DHCP
*******

So, you're not using your isp's dns server? Does this wireless connection supply a dns server?
You see, the dns server in a "mainstream" eth connection is supplied by the dhcp - or other connection method used. What you have to do is figure out how your isp works, and have suse benefit on it.
Another approach would be to run a dns daemon locally. To do this, I guess you have to up the "named" daemon, in - again - runlevel editor. Just open it and check, at level 5, the "named" box.
But please check this info. I'm not very sure about it.
 
Old 06-27-2004, 01:13 PM   #9
crazibri
Member
 
Registered: Mar 2004
Location: Orange County, CA
Distribution: OS X, SuSE, RH, Debian, XP
Posts: 377

Original Poster
Rep: Reputation: 31
Well the way it works with my ISP is that it assigns me IP and DNS via DHCP.
For whatever reason, my computer isnt picking up on the DNS and I have to go in and refresh it for some reason. I see my IP assigned so thats not an issue. Anyway, I'll have to email linuxant and see if they can tell me anything about it.
Thanks for you help! I really appreciate it.
 
Old 06-29-2004, 04:22 PM   #10
Mad_C
Member
 
Registered: Dec 2002
Location: Austria
Distribution: Slax, ccux-Linux, coLinux
Posts: 49

Rep: Reputation: 15
Thumbs up Thanks Bruno!

Quote:
Originally posted by bruno buys

1. Create a shell script to run the command you need:

- Open your text editor of choice and write

#! /bin/sh

# Command to up the wireless, by crazibri jun-2004 (or some header like this)

command

# Additionally, you may want to put a line that creates an empty file here, just to ease the
# verification of success. This file will be created with 0 bytes and owner root/root. Then you
# can remove it, no problem. If you wish not to put it, remove both this comment and the
# command.

touch /home/crazibri/wireless-ok

# Also optional

echo "Wireless done!"

EOF

- Save it as root/root in /etc/init.d

- Give it execute permission, by clicking in the "execute" bit in the properties dialog in a graphical env.

2. Now, open yast2 > system > Runlevel editor. Choose expert mode.

You'll see all the scripts listed there, and also the one you just created. Now, all you have to do is set it to run at, say, level 5 (which is multiuser/graphical env). In this point it comes up the doubt about the correct point to up the wireless. I guess runlevel 5 is a safe mode to operate.
You can also test if suse can run the script well, by trying to run now, with the Enable button.

After all this, just save and reboot.

Post again if you get stuck.
Thanx again, I thought I would never figure out how to autoload modules in SuSE 9.1!
I think I should switch to a leaner distro soon

Mad_C
 
Old 06-29-2004, 05:17 PM   #11
bruno buys
Senior Member
 
Registered: Sep 2003
Location: Rio
Distribution: Debian
Posts: 1,509

Rep: Reputation: 46
did it work ok?
 
Old 06-30-2004, 01:49 AM   #12
Mad_C
Member
 
Registered: Dec 2002
Location: Austria
Distribution: Slax, ccux-Linux, coLinux
Posts: 49

Rep: Reputation: 15
>did it work ok?


Yes, indeed it does work fine. Now, since you are a SuSE 9.1 wiz, maybe you can help me some more:

For one machine I need to start my application at the end of the boot process (runlevel 3) without prompting the user to log in.
The app needs to run as root since so far I have not succeded yet to tweak SuSE to allow a DirectFB program to run as normal user.
After my program is terminated, I do want the login prompt.

How can I accomplish this?
 
Old 06-30-2004, 08:40 AM   #13
bruno buys
Senior Member
 
Registered: Sep 2003
Location: Rio
Distribution: Debian
Posts: 1,509

Rep: Reputation: 46
" Yes, indeed it does work fine. Now, since you are a SuSE 9.1 wiz"

Wow! That´s the first time someone calls me like that. Kinda scaring... i don´t feel like it, yet...


"For one machine I need to start my application at the end of the boot process (runlevel 3) without prompting the user to log in. The app needs to run as root since so far I have not succeded yet to tweak SuSE to allow a DirectFB program to run as normal user.
After my program is terminated, I do want the login prompt."


So, if I got it well, you normally boot to runlevel 3, only? I mean, by default, suse installs a boot process to runlevel 5, and only then prompts the user to log in.

Try to use the same approach as before. The app must be owned by root/root (owner/group). If it is located in some non-default dir, you may want to write the whole path in your command, like, say, /usr/bin/myapp.
Then, write the incredibly simple script to load it, give exec perm, own it to root/root, save in /etc/init.d
Open runlevel editor, tick the script to run at runlevel 3, as desired. Also, in this editor, there´s a menu for choosing the level in which you want the system to load at boot time. I guess that´s what you need to choose, right?

Post again if it fails.





Last edited by bruno buys; 06-30-2004 at 08:42 AM.
 
Old 06-30-2004, 09:17 AM   #14
Mad_C
Member
 
Registered: Dec 2002
Location: Austria
Distribution: Slax, ccux-Linux, coLinux
Posts: 49

Rep: Reputation: 15
>So, if I got it well, you normally boot to runlevel 3, only?

Yes, it's a DirectFB app that doesn't need X and must start after power on without user intervention.

>Try to use the same approach as before.

How do I make sure it's the last script run just before the login prompt?
 
Old 06-30-2004, 09:32 AM   #15
bruno buys
Senior Member
 
Registered: Sep 2003
Location: Rio
Distribution: Debian
Posts: 1,509

Rep: Reputation: 46
Hmmm... Got it.

I am not in my suse comp right now (damn win98 station at work). But in a few hours I´ll be in it, and I´ll search for an answer.

Keep the faith!
 
  


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
use suse/grub to boot slackware ? muddywaters SUSE / openSUSE 2 08-18-2005 01:10 PM
Blank Screen after Suse Boot - HowTo boot from grub to command line benco420 Linux - Newbie 3 02-13-2005 05:50 AM
Dual boot issues… Not SuSE, but Grub… LinuxHawk Linux - General 1 11-06-2004 10:41 PM
boot.local failed (suse 9.1) Big Money Linux - Software 10 08-06-2004 09:59 PM
SuSE boot problem grub and 2.6.3 deuce868 Linux - General 1 03-01-2004 03:44 AM


All times are GMT -5. The time now is 01:00 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