LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Making USB Internet Connection Permanent (https://www.linuxquestions.org/questions/linux-newbie-8/making-usb-internet-connection-permanent-106266/)

Luddite 10-20-2003 08:41 AM

Making USB Internet Connection Permanent
 
Hi all,

following the advice given in the following excellent thread:

ww.linuxquestions.org/quest...&threadid=77412 ...

... I have managed to get my MDK 9.0 system installed and my NTL Cable modem is working (get in!!). The only problem is I have to open a console and type in a script every time I reboot - the thread advises modifying the text in the USB List of file /etc/rc.d/rc.modules, but that file doesn't have any USB List in it - on my system, it contains only the following:

#!/bin/sh
# (c) MandrakeSoft, Chmouel Boudjnah <chmouel@mandrakesoft.com>
# $Id: rc.modules,v 1.1.1.1 2000/07/30 05:07:38 chmouel Exp $
# description: launch modules specified in /etc/modules inspired by a
# Debian idea.

[ -f /etc/modules ] || exit 0

# Loop over every line in /etc/modules.
(cat /etc/modules; echo) | while read module args
do
case "$module" in
\#*|"") continue ;;
esac
initlog -s "Loading module: $module"
modprobe $module $args >/dev/null 2>&1
done

I am not blessed with the greatest mind in computin and no doubt I'm missing something obvious but any advice appreciated!

Cheers,
The Luddite.

Caysho 10-20-2003 09:19 AM

I'm guessing the script you run inserts modules ?

I just had a look at the thread you refer to
http://www.linuxquestions.org/questi...threadid=77412

and the way the /etc/rc.modules is described, each module is explicitly added in the script.

in your's, it's looping through rc.modules (a cleaner approach), which I think is where you'll need to add them - my rc.modules is like that too, and my /etc/modules only has 'scsi_hostadapter' on it's own line (it's the only uncommented line in the file).

I don't know what else you're doing in it, so I can't give any additional advice.

Luddite 10-20-2003 09:29 AM

Cheers Caysho.

Gotta be honest, I don't know! The script I'm typing in Xterm as root is:

rmmod acm
modprobe CECEther
ifconfig -a

...await output, then:

dhcpcd
ifconfig

...this allows me to access the web but I have to do the same thing every time I load up. My knowledge of Linux is practically zero - I really need to know specifically what I need to add/amend in the rc.modules file and whereabouts in the text to add it - don't want much, I know...

Caysho 10-20-2003 09:38 AM

ok, you're doing more than just adding a module...

I would recommend that you put the contents of that script you're running into the script that is run when the user logs in. I can never remember what it is though, so you'll have to search/ask around.

it might not be the best or smartest way to do it, but it's the only easy way I can think of.

wuck 10-20-2003 12:03 PM

If you put the script you have to enter everytime in /etc/rc.local, it will be executed every time you boot.

Luddite 10-27-2003 09:55 AM

Cheers Wuck.

Have tried this but seems to be to no avail - is there a standard syntax I need to follow (i.e. do I need to put some sort of punctuation mark at the beginning/end of each line etc. etc.)?

Cheers again all - am starting to really like the Linux environment!

samwwwblack 10-27-2003 12:42 PM

Save a copy of the /etc/rc.local just in case i screw up the syntax

at the end of /etc/rc.local, type the following

/sbin/rmmod acm
/sbin/modprobe CDCEther
/sbin/ifconfig -a
/sbin/dhcpcd
/sbin/ifconfig

reboot and see if it works, im guessing you'll get a load of ifconfig output as before when doing it manually.

regards,

sam black

Luddite 10-28-2003 06:24 AM

Thank you all and thanks Sam - your tip works a treat and I don't get any console output - KDE loads as before but I can access t'internet straight away.

Cheers, I really appreciate the advice.

The Luddite.


All times are GMT -5. The time now is 03:11 PM.