dhcpcd-discuss

Problem in dhcpcd static option

Ram Kumar Koppu

Tue Mar 22 11:19:26 2011

Hi Roy,
I have problem with the dhcpcd static configuration. If use -S or --static
option dhcpcd is not assigning subnet mask to interface properly. But dhcpcd
will assign the subnet mask to interfaces without static option.
Ex:-

dhcpcd -S ip_address=10.221.38.144 -S routers=10.221.38.158 \
-S subnet_mask=255.255.255.224 CESoP0

But the ifconfig shows:
CESoP0    Link encap:Ethernet  HWaddr 00:00:DB:40:3F:AE
          inet addr:10.221.38.144  Bcast:10.255.255.255  Mask:255.0.0.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:105 errors:0 dropped:0 overruns:0 frame:0
          TX packets:34 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          RX bytes:7194 (7.0 Kb)  TX bytes:3034 (2.9 Kb)
          Base address:0x1000

I can see correct subnet mask value from the environment variable
new_subnet_mask but ifconfig shows wrong value. Looks like dhcpcd is not
bringing up interfcae properly for the static configuration. This subnet
mask also affected broadcast address in the above ifconfig display.

This problem only occuring in static configuration with the option -S or
--static. For the normal configuration (without static) it works fine. Will
you please provide me the solution for this? Thank you in advance!

-- Ram

Follow-Ups:
Re: Problem in dhcpcd static optionRoy Marples
Archive administrator: postmaster@marples.name