Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 11-10-2003, 06:09 AM   #1
Registered: Aug 2003
Posts: 36

Rep: Reputation: 15
Bash scripting

I have a ADSL USB modem installed on my Debian3.0 computer. I want this computer to [list=1][*]Start uploading the firmware to my USB modem(and wait 20 seconds, because the uploading takes this long)[*]Start PPPd (the actual connection)[*]After succesfull PPPd start & login into the network (20 seconds wait) I want the PC to start services like Eggdrop, Bouncer etc. (internet services)[/list=1]
Can anyone give me tips/hints how to write this as a nice script?
Or does anyone have a better idea how to do this?

Can I add the script (using Webmin) to boot at startup, but as the last possible script? (because the devUSBfs etc. must have loaded already)

Old 11-10-2003, 07:00 AM   #2
Senior Member
Registered: Sep 2003
Location: Sweden
Distribution: Debian
Posts: 3,032

Rep: Reputation: 58
It sounds like a pretty straightforward script and it should be very easy to implement. For reference, download the Advanced Bash Scripting Guide (scroll down a little bit and it's there), it's very useful.
<commands for uploading the firmware>
sleep 20
/etc/init.d/pppd start # Or whatever the PPPd script is called
I don't think you would need to use a "sleep 20" line after the firmware is uploaded - the script executes one line at a time so PPPd won't be launched until the prior command (the upload) is done. You could also some simple error checking and reporting with the script.

Old 11-11-2003, 04:21 AM   #3
Registered: Aug 2003
Posts: 36

Original Poster
Rep: Reputation: 15
Hmm... thnx dude, I'll try it.


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
Bash scripting help (su ...) shwong Linux - General 1 11-02-2005 01:26 PM
Bash scripting pete1234 Programming 1 09-27-2005 02:48 AM
bash scripting vadon Linux - Newbie 6 05-10-2005 05:07 AM
need help with bash scripting rich2oo1 Programming 2 12-17-2003 01:50 PM
HELP with BASH scripting atwah Linux - Newbie 6 09-09-2003 02:10 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:55 PM.

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