Logging date of DHCP transactions ?
James Jalbert
jjalbert at rsu39.org
Fri May 23 16:23:12 UTC 2014
I use the following script to create a csv file, then I import it into my database I have setup. I am using Ubuntu for dhcp, but I assume it should be the same for all flavors
tail -n 2000 /var/log/dhcp.log | awk '/DHCPACK on/ {print $1" "$2" "$3","$8","$10}' > /home/netop/IPLog.csv
James Jalbert
Network Administrator
Eastern Aroostook RSU #39
Phone: 207-493-4246
E-Mail: jjalbert at rsu39.org
>>> "Mike." <the.lists at mgm51.com> 5/23/2014 12:04 PM >>>
On 5/23/2014 at 4:20 PM BONNET, Frank wrote:
|hello
|
|I'm running isc-dhcpd on a FreeBSD 10 machine it works well
|but I've been requested to log dates of all DHCP transactions
|in /var/log/dhcpd.log I've googled a bit but did not find useful
|informations ...
|
|Any info welcome , thank you
=============
According to the man page, dhcpd(8),
http://www.freebsd.org/cgi/man.cgi?query=dhcpd&apropos=0&sektion=0&man
path=FreeBSD+9.2-RELEASE+and+Ports&arch=default&format=html
"...Normally, dhcpd will log all output using the syslog(3) function
with the log facility set to LOG_DAEMON.
..."
You can direct that output to a specific file by adding something
like:
daemon.info /var/log/daemon
to your /etc/syslog.conf file, and then touching /var/log/daemon to
assure the file exists. You may also want to add that log to the
/etc/newsyslog.conf file so it gets rotated.
Hope this helps.
_______________________________________________
dhcp-users mailing list
dhcp-users at lists.isc.org
https://lists.isc.org/mailman/listinfo/dhcp-users
More information about the dhcp-users
mailing list