You are not logged in.
Pages: 1
hey,
i'd like eth0 to try dhcp, and if it doesn't receive an answer within 10s or so, fall back to an address i specify! how do i do this?
(i'd like to specify something like eth0="dhcp eth0 192.168...." in rc.conf)
thanks
Offline
ifconfig reports (or not) a DHCP leased address.
A simple script could be written that retrieves the IP, if not set then the script could call ifconfig
'man bash'
'man ifconfig'
Offline
Yes, you will need to custom-make something for this - your suggested rc.conf solution will not work with our network init script. /etc/rc.local would be a good place for whatever you decide to do.
Hmm.. looking at it from a different angle, if you're happy with a static IP some of the time, why not just use a static IP all the time?
Offline
Hmm.. looking at it from a different angle, if you're happy with a static IP some of the time, why not just use a static IP all the time?
This is the obvious question really isnt it.
I mean, surely a static IP if a better solution ... after all ISPs charge for the privilage, and whats more, static ISPs make network config so simple and LAN setup + firewall admin are a breeze.
Why do you want DHCP anyway?
Offline
Pages: 1