the sonyvaio in the first line is currently offline
The DHCP lease doesn't depend on the computer being connected and will be listed as "active" until the lease time expires. The "default-lease-time" in
/etc/dhcpd.conf is 24 hours and is controlled by the template-fragment
/etc/e-smith/templates/etc/dhcpd.conf/25LeaseTimeDefault. Also, the "Expiration" time listed by my script is GMT, not your local time zone - this is how dhcpd tracks leases.
the MAC address is missing and the hostname moves to the MAC-address column
Oops; I suspect my script-writing abilities are at fault here... Please run
sed -e :a -e '$!N;s/\n\ / /;ta' -e 'P;D' /var/lib/dhcp/dhcpd.leases | grep active
and post the results back here; I'll try to figure out what's up.
And there is a strange ( in the last line:
Yes, I see it. Now you know why I don't write bash scripts professionally! if you run
arp -a and post the results I'll try to fix that, too. Do you know why "localhost" is at "192.168.178.2" - this seems a bit odd to me...
Why gets the formatting always lost in a posting?
This is a feature of the forum (probably because html works this way, too...). You have to surround text with "[code]" tags to use a fixed-width font, preserve white space, and prevent automatic line wrap. I use "[code]...[/code]" tags for long lines of code or output where line wrapping would be dangerous, and "
" for short commands or references to files on the SME server.