ok its working but not always, I have two separate networks, maybe that's causing problems, when my PC is connected to the hub and to the one of networks, script is working, and when it's boot I can see IP address for a second, when my PC is connected to the other network, when it boot I see quick message "sending discover" or "waiting for IP 60", after this putty fails to load session, and its taking about 30-60 seconds network to start working.
Here my bootlocal.sh script:
#!/bin/sh
~ put other system startup commands here
/opt/eth0.sh &
SEC=60
while [ $SEC -gt 0 ] ; do
ifconfig | grep -q "Bcast" && break || sleep 1
echo -ne "Waiting for IP $((SEC--)) \r"
done
echo
and putty.sh in .X.d folder
#!/bin/sh
putty -load SessionName