Click to See Complete Forum and Search --> : ifup and ifdown


orufet
11-23-2004, 11:59 AM
If I use

ifdown eth0

and

ifup eth0

it seems to release and to renew my ip address. However, it's always the same...shouldn't it be different? I'm on a cable connection, and trying to get a new ip. How is this done?

ph34r
11-23-2004, 12:07 PM
Well, the dhcp server keeps track of your mac address, and either allows for a lease of X amount of time and will keep giving you the same IP if you request a new one during that time, OR the dhcp server has been told to always assign your mac address the same ip always. A long lease time will have the same effect...

orufet
11-23-2004, 07:22 PM
so is there no way to get a new ip?

glasdave
11-23-2004, 07:39 PM
You might want to try powering down your moden for 10 or 15 mins, and see what happens then.

soulestream
11-24-2004, 01:18 AM
on a cable modem, i have had them change my IP for punishment, i think, but ive been on cable for 4 years and have kept the same IP for months sometimes...


why do you need a new IP?


soule

rocketpcguy
11-24-2004, 01:24 AM
he was doing naughty things, i guess

jumpedintothefire
11-24-2004, 11:57 PM
If its a mac address issue, that can be overridden by the kernel using the MACADDR= variable in the config file for the interface.

[root@CD223978-A /]# cat /sbin/ifup | grep MACADDR
if [ -n "$MACADDR" ]; then
ifconfig ${DEVICE} hw ether ${MACADDR}
[root@CD223978-A network-scripts]#

same for dhcp hostname issues

[root@CD223978-A /]# cat /sbin/ifup | grep DHCP_HOSTNAME
if [ -n "$DHCP_HOSTNAME" ]; then
PUMPARGS="-h $DHCP_HOSTNAME"
[root@CD223978-A /]#