Netgear WG311 wifi config not retained on reboot (Solved)

Booting, installing, newbie
Post Reply
Message
Author
wombat
Posts: 50
Joined: Tue 06 Sep 2005, 22:50
Location: Brisbane Australia

Netgear WG311 wifi config not retained on reboot (Solved)

#1 Post by wombat »

Hi, I have a Netgear WG311T wireless card in a P3-733 system, currently using Puppy 2.02 properly installed on a hard-drive with a gig of swap space.
I followed the ndiswrapper procedure and loaded the W-XP inf file from the cards driver CD.
I was able to get the card operating properly.
My problem is that the driver is retained but when the system reboots I have to re-run ndiswrapper, then iwconfig, then use the ethernet/network setup > wlan0 > autodhcp to reload the driver for operation.
WAG does not appear to do anything.
How do I config it to automatically load at each reboot?
It certainly works well once it is up!

Thanks for any suggestions.
wombat.

User avatar
BlackAdder
Posts: 385
Joined: Sun 22 May 2005, 23:29

#2 Post by BlackAdder »

You can add the commands to set up your wireless adapter to /etc/rc.d/rc.local. They will be excuted late in the boot sequence. Example

Code: Select all

modprobe ndiswrapper
iwconfig wlan0 essid mynet channel 6 key mykey
rm /etc/dhcpc/*.pid  # remove any leftover process id files
dhcpcd -t 10 -d wlan0
The commands could also put into a simple shell script to run when you choose.

wombat
Posts: 50
Joined: Tue 06 Sep 2005, 22:50
Location: Brisbane Australia

#3 Post by wombat »

Thankyou so much for your reply BlackAdder, I added those items to that file but still no joy.
I removed all the items apart from
modprobe ndiswrapper
iwconfig wlan0
and that allows me then to use the ethernet / networking setup wizard to simply use the "wlan0 button" and then "auto DHCP" and everything is operating properly.
Is there a simple way of adding the "auto DHCP" in a line, I feel that would fix it.
Again Thanks.
wombat.

User avatar
BlackAdder
Posts: 385
Joined: Sun 22 May 2005, 23:29

#4 Post by BlackAdder »

wombat,
The line dhcpcd -t 5 -d wlan0 should be equivalent to clicking the auto dhcp button. Does that sequence of commands work okay if used from a console window? If so, maybe the command to remove the old process id files should be:

Code: Select all

if [ -e /etc/dhcpc/*.pid ]; then
  rm /etc/dhcpc/*.pid 
fi
That simply makes the removal of any of those pesky little files conditional on there being any.

wombat
Posts: 50
Joined: Tue 06 Sep 2005, 22:50
Location: Brisbane Australia

#5 Post by wombat »

G'Day BlackAdder, well you certainly know your suff there, I applied the commands after a lot of typo errors and the wireless now works perfectly.
The eventual code now reads as ...
modprobe ndiswrapper
iwconfig wlan0
dhcpcd -t 5 -d wlan0
if [ -e /etc/dhcpc/*.pid ]; then
rm /etc/dhcpc/*.pid
fi

This really does the trick!!!
Thank you so much for your help. Blinky works overtime!
Wombat.

Garth

#6 Post by Garth »

HiWombat and BlackAdder

I (very newbie) have had the same problem until I found your topic on the forum.

Went through the same steps as Wombat but found his final text did not quite work on my machine.

I reversed the last two commands so that the entire text in /etc/rc.d/rc.local reads as follows:-

modprobe ndiswrapper
iwconfig wlan0
if [ -e /etc/dhcpc/*.pid ]; then
rm /etc/dhcpc/*.pid
fi
dhcpcd -t 5 -d wlan0


and that works perfectly for me!

Thanks guys

GuestToo
Puppy Master
Posts: 4083
Joined: Wed 04 May 2005, 18:11

#7 Post by GuestToo »

it's not important, but this line will work:

rm -f /etc/dhcpc/*.pid

(instead of
f [ -e /etc/dhcpc/*.pid ]; then
rm /etc/dhcpc/*.pid
fi )

the -f option suppresses an error message if there are no .pid files ... and it over rides -i if someone aliased rm to rm -i

so all you would need to start your connection would be:

modprobe ndiswrapper
iwconfig wlan0
rm -f /etc/dhcpc/*.pid
dhcpcd -t 5 -d wlan0

OverDrive
Posts: 178
Joined: Mon 02 Jan 2006, 05:07
Location: Cleveland, OHIO,USA

Here is what I had to do

#8 Post by OverDrive »

in /etc/rc.d/rc.local:

modprobe ndiswrapper
iwconfig wlan0
rm /etc/dhcpc/dhcpcd-wlan0.pid 2>/dev/null #if left over from last session, causes trouble.
rm /etc/dhcpc/dhcpcd-wlan0.cache 2>/dev/null #ditto
rm /etc/dhcpc/dhcpcd-wlan0.info 2>/dev/null #ditto
dhcpcd -t 5 -d wlan0

I copied the rm statements from /etc/wlan0mode

I don't profess to know why it now works. But I can say it did not work untill I rm'ed the .cache and the .info files also. Hope this helps someone else

Best Regards

Dave
Instant Puppy Fan!!!

User avatar
cruzin
Posts: 176
Joined: Thu 30 Nov 2006, 07:12

netgear wg511t with static ip

#9 Post by cruzin »

Hi, I did modprobe ath_pci and ifconfig ath0 up in the above file and that
got the network card running but I dont use dhcp but use a static ip. Is there any way to configure that at startup. I have to go into network set up and chooose wireless and set all up manually and then it works. any help will be appreciated. thanks

topaz
Posts: 132
Joined: Thu 14 Dec 2006, 20:18
Location: Northumberland UK

works for me

#10 Post by topaz »

Hi

modprobe ndiswrapper
iwconfig wlan0 essid mynet channel 6 key mykey
rm /etc/dhcpc/*.pid # remove any leftover process id files
dhcpcd -t 10 -d wlan0

in rc.local works fine for me , I used to have to load profile in WAG to pick up the key

cheers :P
Thin Client, 1gb ram, atom duel 1.7, pup precise Fruga flash drive

Post Reply