[TriLUG] Problems with Fedora 7 and Hotplug

Roy Vestal rvestal at trilug.org
Tue Dec 4 12:29:03 EST 2007


Ok, I've been working on getting this stupid zaurus syncing. I have it 
"mostly" automated. I followed a few of the how tos and and setup 
/etc/hotplug/usb/usbnet as follows:

---------------<snip>---------------

#!/bin/bash
typeset -i num
num=`ifconfig | grep usb0 | wc -l`
if [ $num -eq 0 ] ; then
        ifconfig usb0 192.168.129.1 netmask 255.255.255.255 up
        route add -host 192.168.129.201 usb0
fi
iptables  -t nat -F
iptables  -t nat -A POSTROUTING -j SNAT -o eth0 --to MY_IP_ADDR 
(obscured to protect the innocent)
echo 1 > /proc/sys/net/ipv4/ip_forward
exit 0
---------------<snip>---------------

It doesn't hotplug. If I "sudo sh /etc/hotplug/usb/usbnet" then it works 
fine, QTopia Desktop works, ssh, etc. When I remove and replace, i have 
to manually run it. What am I missing. I've done the chmod +x on the 
file too.



More information about the TriLUG mailing list