Comment 15 for bug 39249

Revision history for this message
Jaakko Heinonen (jheinonen) wrote : Re: (Dapper) can't create /var/lib/dhcp3/dhclient.eth0.leases: Permission denied

dhcp3-server init script has these lines:

                chown dhcpd:dhcpd /var/lib/dhcp3 /var/lib/dhcp3/dhcpd.leases
                if [ -e /var/lib/dhcp3/dhcpd.leases~ ]; then
                    chown dhcpd:dhcpd /var/lib/dhcp3/dhcpd.leases~
                fi

However if you don't have dhcp3-server installed /var/lib/dhcp3 permissions are following:

$ ls -ld /var/lib/dhcp3
drwxr-xr-x 2 root root 4096 2007-05-01 11:37 /var/lib/dhcp3

This prevents dhclient to update leases file after dropping the privileges.

Proposed fix attached.