udhcpc doesn't assign ip address

Posted by Diab on Super User See other posts from Super User or by Diab
Published on 2012-10-23T10:48:33Z Indexed on 2012/10/23 11:04 UTC
Read the original article Hit count: 292



i have a board running linux 2.6.28 and i have one Ethernet interface (eth0)

i want dhcp to assign dynamic ip to this interface. i have busybox with udhcpc in the file system and the kernel has the "Pack Socket" enabled

so i copied the scripts from "busybox-1.14.1/examples/udhcp" to my board on "/etc/udhcpc/"

(i created this directory) and when i run :

ifconfig eth0 up


the interface is up but without ip address, then running

udhcpc -i eth0 -s /etc/udhcpc/sample.script

i get the following: note : sample.script contains : "exec /etc/udhcpc/sample.$1"

# udhcpc -i eth0 -s /etc/udhcpc/sample.script

udhcpc (v1.14.1) started

Sending discover...

Sending select for 192.168.10.198...

Lease of 192.168.10.198 obtained, lease time 691200


but when i check with ifconfig i can see that it didn't assign the ip address to eth0. anyone have an idea why udhcpc didn't assign the ip ?

Thanx

© Super User or respective owner

Related posts about linux

Related posts about networking