Darren Reed wrote:
Darren J Moffat wrote:

Logging everything that is available from a given DHCP server is easy.

Just create an /etc/dhcp/eventhook script that grabs all the interesting things using dhcpinfo and write them out to a file format you like with appropriate time stamps.

Something based off this simple for loop should do what you want:

for option in $(nawk '/^#/ { next } /^$/ { next } {print $1}' /etc/dhcp/inittab) ; do
         value="$(/sbin/dhcpinfo $option 2> /dev/null)"
         echo "$option"="$value"
done


Unless you're proposing that this be added to Solaris for
everyone, I'd classify this as a work around for the problem.

Exactly what problem is that though ? Is it really necessary for every Solaris machine to have a log of all this info ? How do you deal with log management ? Do you intend to have tools to do something with the data or is it just paging through the raw log.

My DJMnetprof stuff (similar to Inetmenu, but simpler) logs to a file in /var/log most of this info (and some additional status info on what we did with it). Until my hard disk crash a few weeks ago I had probably 2 years worth of this log data.

Q: How often did I look at it ? Answer NEVER. Not once in debugging any problem with the tool itself or with any strange DHCP connection issues did I ever need to look at historical data. I very often ran dhcpinfo to lookup a specific value for the current connection. I just never found any historical info to be relevant.

I don't use DJMnetprof or Inetmenu anymore the current NWAM prototype combined with wificonfig profiles actually does everything I need for my laptop 99% of the time. I don't even have a DHCP eventhook script in place anymore.

Ultimately it really sounds like a debug trace for dhcpagent(1m) and I don't see how that is actually interesting to the vast majority of people who use any OpenSolaris derived OS as an end user, or in most cases even as the admin responsible for network config.

--
Darren J Moffat
_______________________________________________
networking-discuss mailing list
[email protected]

Reply via email to