Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system. |
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.
|
 |
01-18-2004, 06:18 PM
|
#1
|
Senior Member
Registered: Aug 2003
Location: Birkenhead/Britain
Distribution: Linux From Scratch
Posts: 2,073
Rep:
|
Bootscripts - pause at init 3?
Hello people. I'm very pleased with myself as I've recently done LF Scratch. It's been a lot of hard work but it's been very rewarding as I've learnt an enormous amount and I've done it all myself (well, Google helped a fair bit), this is the first time I've asked for help. The thing is, the driver for my modem, an Alcatel Speedtouch, works as a Kernel module which loads at boot. The problem is, the Nvidia module seems to put it of it's stride. If I boot to init 5, the Nvidia module stops the modem connecting to my ISP and I have to unplug it and plug it in again, the hotplug script notices it and it then connects. I don't like doing that though so what I do is boot to init 3, type root, password, init 5 and by the time I've done that the modem has done it's thing and the GDM takes me to my Gnome desktop.
So what I'd like to know, is it possible to make the boot scripts pause for about 10 seconds at init 3 to let the modem draw breath? On Mandrake it pauses for about 30 seconds during the boot process to let the modem connect and then moves on. I will study the way they do it but I would be grateful for any assistance, if someone could give me a few tips and point me in the right direction.
|
|
|
01-19-2004, 03:41 AM
|
#2
|
Member
Registered: Nov 2002
Location: Melbourne, Australia
Distribution: (C)LFS (x86_64, ix86, sparcv9, ppc)
Posts: 122
Rep:
|
Re: Bootscripts - pause at init 3?
sleep 10
will cause a script to sleep for 10 seconds.
|
|
|
01-19-2004, 09:55 AM
|
#3
|
Senior Member
Registered: Aug 2003
Location: Birkenhead/Britain
Distribution: Linux From Scratch
Posts: 2,073
Original Poster
Rep:
|
Thanks, but I did know that. I was hoping someone would be able to point me towards a script I could put it in.
|
|
|
01-19-2004, 01:48 PM
|
#4
|
Member
Registered: Nov 2002
Location: Melbourne, Australia
Distribution: (C)LFS (x86_64, ix86, sparcv9, ppc)
Posts: 122
Rep:
|
If all you want to do is pause for 10 seconds at the end of runlevel 3,
just create a script in /etc/rc.d/init.d as say "pause", should only be
#!/bin/sh
sleep 10
Then just create a symlink under rc3.d pointing to it to as S99pause .
Ugly hack of a workaround to your issue, but hey, it'll do the job till you
come up with something better...
|
|
|
01-19-2004, 02:44 PM
|
#5
|
Senior Member
Registered: Aug 2003
Location: Birkenhead/Britain
Distribution: Linux From Scratch
Posts: 2,073
Original Poster
Rep:
|
Sadly it doesn't work (yes, I did remember to chmod 755). The script runs if I open it in a terminal but if I run it during boot as you described, there is no pause. Presumably the script is still running in the background somewhere, meanwhile the boot process is busy starting Gnome and...no internet. Thanks for your time.
|
|
|
01-28-2004, 06:20 PM
|
#6
|
Senior Member
Registered: Aug 2003
Location: Birkenhead/Britain
Distribution: Linux From Scratch
Posts: 2,073
Original Poster
Rep:
|
Yay! It works! The answer was so obvious I'm ashamed it took so long for the penny to drop. All it needed was
Code:
#!/bin/bash
sleep 20
init 5
The pause script sleeps in the background for 20 second while the modem settles down and then takes me into Gnome without typing a thing. Thanks for your help mdh. Sorry for being so thick.
|
|
|
01-28-2004, 08:00 PM
|
#7
|
Member
Registered: Nov 2002
Location: Melbourne, Australia
Distribution: (C)LFS (x86_64, ix86, sparcv9, ppc)
Posts: 122
Rep:
|
Don't mention it :-)
It's an interesting issue you have, if you feel the need to you may want to
make note of it on lfs-support, you won't be the only one that runs into
this... and we may come up with a better way. (note I'm not on that list,
only really lfs-dev and lfs-hackers).
Good luck with your LFS'ing mate
[R]
|
|
|
All times are GMT -5. The time now is 01:31 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
|
|