Home

Hello Guruplug You Jerk @ 2010-05-17 23:16:53.858363
Filed under: Linux  Tech  Frustration 
So you bought a Guruplug. You've waited and waited and now it's at your front door taunting you. You rip open the packaging and find a place in your networking closet to plug it in. Ethernet cord plugged in you plug the Guruplug in and watch your router logs. Nothing. Restart the plug and watch logs. Nothing. Change ethernet ports, reboot and watch logs. Nothing. Nothing. Nothing. ARRGGGG!

Don't fear -- here is some help. Before I start please note most of this information came from the forums at plugcomputer.org. Also note I am tired and cranky.

First, unplug the Guruplug and unplug the ethernet cord from the device. Before an ethernet connection will work you will need to ensure that your router/switch is 10/100 and not a gigabit router/switch. This may seem odd but many people have found plugging into gigabit devices (even those which can sense and fail downwards) causes the Guruplug to plainly not work. Go find an old router/switch and patch it in to your modern gigabit switch and then plug the guru plug in through there. While it shouldn't matter (at least I don't *think* it should matter) which ethernet jack you use note I have only tested it with the top one (the one closest to the logo and lights).

Lookie there! You see the Guruplug in your router logs now with an IP address. Great! ssh on over with the root user and the default password of nosoup4u (yeah -- really, that is it). Before you do anything else, STOP! Do you need the wifi device running? Anyone is able to join the network and use your connection! Even if you are going to be using the wifi in the Guruplug in your project you probably do not need it running at this point, so let's turn it off temporarily by running "uaputl sys_cfg_radio_ctl off". Use your desktop/laptop and check to make sure that you can no longer see the GuruPlug SSID (it may take a minute or two you to see). If you know you are not going to be using the Wifi for a while you can turn it off by editing /root/init_setup.sh and comment out everything from "rm -f /etc/wlanclient.mode" up to and including "/usr/bin/uaputl bss_start". The file should now look like this:

# We always bootup in AP mode. Delete any stale files
#rm -f /etc/wlanclient.mode
#SSID=Plug2-uAP-`ifconfig eth0 | awk -F ":" '/HWaddr/ {print $6$7}'`
#
#insmod /root/uap8xxx.ko
#ifconfig uap0 192.168.1.1 up
#/usr/bin/uaputl sys_cfg_ssid $SSID
#/usr/bin/uaputl bss_start
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE
echo 1 > /proc/sys/net/ipv4/ip_forward
/etc/init.d/udhcpd start
/etc/init.d/dnsmasq start
iptables -A INPUT -i uap0 -p tcp -m tcp --dport 80 -j ACCEPT

# Re-enable bluetooth. In the earlier case, it didn't find the firmware.
#rmmod libertas_sdio libertas btmrvl_sdio btmrvl bluetooth 2>/dev/null
rmmod btmrvl_sdio btmrvl
/etc/init.d/bluetooth start

modprobe btmrvl_sdio
hciconfig hci0 up
hciconfig hci0 piscan
/usr/bin/mute-agent &

# Set leds
echo 1 > `eval ls /sys/class/leds/*plug*\:green\:health/brightness`
echo 1 > `eval ls /sys/class/leds/*plug*\:green\:wmode/brightness`

Now let's get that root password changed! We don't want someone iPhoning us! All you need to do is run "passwd". You will be prompted for your new password two times. Now the root password is no longer nosoup4u, it is what you just set it to. Don't forget it.

As any good engineer you just tried to update the system (you are a good engineer aren't you?). The problem here is that, well, it didn't work.

Err http://10.82.108.51 binary/ Release.gpg    
  Could not connect to 10.82.108.51:80 (10.82.108.51). - connect (110 Connection timed out)
Err http://10.82.108.51 binary/ Translation-en_US
  Could not connect to 10.82.108.51:80 (10.82.108.51). - connect (110 Connection timed out)
Ign http://10.82.108.51 binary/ Release        
Ign http://10.82.108.51 binary/ Packages/DiffIndex
Ign http://10.82.108.51 binary/ Packages       
Err http://10.82.108.51 binary/ Packages       
  Could not connect to 10.82.108.51:80 (10.82.108.51). - connect (110 Connection timed out)
W: Failed to fetch http://10.82.108.51/kedars/sheevaplug_wifi/builds/packages/binary/Release.gpg  
Could not connect to 10.82.108.51:80 (10.82.108.51). - connect (110 Connection timed out)

W: Failed to fetch http://10.82.108.51/kedars/sheevaplug_wifi/builds/packages/binary/en_US.gz 
 Could not connect to 10.82.108.51:80 (10.82.108.51). - connect (110 Connection timed out)

W: Failed to fetch http://10.82.108.51/kedars/sheevaplug_wifi/builds/packages/binary/Packages  
Could not connect to 10.82.108.51:80 (10.82.108.51). - connect (110 Connection timed out)

E: Some index files failed to download, they have been ignored, or old ones used instead.
E: dpkg was interrupted, you must manually run 'dpkg --configure -a' to correct the problem. 

As the error states, go ahead and run "dpkg --configure -a". Then edit /etc/apt/sources.list and comment out the silly internal to the manufacturers network IP address so the file looks like this:

deb http://ftp.us.debian.org/debian/ lenny main contrib non-free
deb http://http.us.debian.org/debian stable main contrib non-free
deb http://security.debian.org lenny/updates main contrib non-free
deb http://www.backports.org/debian lenny-backports main contrib non-free
#deb http://10.82.108.51/kedars/sheevaplug_wifi/builds/packages/ binary/

Now run "apt-get update && apt-get upgrade" to get that system updated. This will take a bit of time. While that runs go learn about Mentally Ill Gangsters


OK, now we see all those stupid messages saying we are getting stuff from the future. That is cool and all but we don't need to hear about time traveling code over and over. Let's fix it using date. You will need to run date like so 'date -s "+Mon May 17 22:50:00 EST 2010"'. Now you will need to really set the timezone (assuming you are not in UTC). To do this replacing EST with your correct timzeone: "cd /etc/; mv localtime localtime.old; ln -s /usr/share/zoneinfo/EST localtime".

Now is the moment of truth. Reboot the plug by running "reboot". It will probably come back up with the same IP address (punch a tree in the face), but if you can't get to the plug check your routers logs to see if it got assigned another address. Everything should be great and you should be off to the races. YES DICE! Now I need sleep. I have no more caffeine powering my madness.

 digg it   seed it   del.icio.us   ma.gnolia
Tags:       Log in to post comments.


 
A Django joint.
© 2007-2009 Steve 'Ashcrow' Milner | Studio7designs | Arbutus Photography