dhcpcd on startup

What features/apps/bugfixes needed in a future Puppy
Post Reply
Message
Author
User avatar
jcoder24
Posts: 604
Joined: Fri 06 May 2005, 12:33
Location: Barbados

dhcpcd on startup

#1 Post by jcoder24 »

I think the following modification should be added to one of puppy's startup scripts.

if [ -f /etc/dhcpc/dhcpcd-ethX.pid ]
then
rm /etc/dhcpc/dhcpcd-ethX.pid
dhcpcd ethX
fi

where X is the interface number 0,1,2....

I think it is safe to assume that if the file exists that dhcp is being used.

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#2 Post by Flash »

Um, why? :)

User avatar
jcoder24
Posts: 604
Joined: Fri 06 May 2005, 12:33
Location: Barbados

#3 Post by jcoder24 »

That way if you're running dhcp you won't have to remove the .pid file and manually start dhcpcd each time you reboot.

Guest

#4 Post by Guest »

/etc/rc.d/rc.network:

Code: Select all

echo "Trying to get IP address from DHCP server (60sec timeout)..."
rm /etc/dhcpc/dhcpcd-eth0.pid 2>/dev/null #if left over from last session, causes trouble.
rm /etc/dhcpc/dhcpcd-eth0.cache 2>/dev/null #ditto
rm /etc/dhcpc/dhcpcd-eth0.info 2>/dev/null #ditto

Code: Select all

cho "Trying to get IP address from DHCP server (60sec timeout)..."
rm /etc/dhcpc/dhcpcd-eth1.pid 2>/dev/null #if left over from last session, causes trouble.
rm /etc/dhcpc/dhcpcd-eth1.cache 2>/dev/null #ditto
rm /etc/dhcpc/dhcpcd-eth1.info 2>/dev/null #ditto

Post Reply