How to query for available / used ip

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

How to query for available / used ip

Leandro
Hello Guys , I would like to plot the function of my dhcpd server on
cacti graph.
I want to know ir is there any recommended way to ask a running dhcp
server how many ips were granted and how many are available ?
Regards ,
Leandro.

_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: How to query for available / used ip

Gero Palacio
Hi Leandro,

You'll probably want an answer with someone with more experience but I'm inclined to think that the only way to do this is by parsing the contents of the dhcpd.leases file. I don't think you could do it using the omshell, but I might be a good idea to check out omapi.

Good luck,
Geronimo.

_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: How to query for available / used ip

Simon Hobson
In reply to this post by Leandro
Leandro <[hidden email]> wrote:

> Hello Guys , I would like to plot the function of my dhcpd server on cacti graph.
> I want to know ir is there any recommended way to ask a running dhcp server how many ips were granted and how many are available ?

Check out dhcp-pool
As well as a command line tool, it has a munin plugin component. In principle it shouldn't be too hard to get it to update an RRD but I haven't got that far yet. As a command line tool it will give you information like this :

Subnet 192.168.7.0/24
--------------------------------------------------

  1. Pool "WiFi":

     Monitoring:      ON
     Warning limit:   75%
     Critical limit:  90%
     Active leases:   22/91 (24.2%)

While the Munin plugin will give you output like this :

$ dhcpd-munin_192.168.7.0_24_1
active.value 22
warning.value 68.2
critical.value 81.9
max.value 91

I figure the latter should be parseable into something that can be fed into Nagios and Cacti

_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

RE: How to query for available / used ip

Dmitry Vayntrub
You might also look at dhcpd-pools
http://dhcpd-pools.sourceforge.net/

It is really fast (written in C ), and the output is easy to parse, as well as present as a web page if you would like to.
Here is an example of the text mode output:
[root@ns1 dhcp]# dhcpd-pools
Ranges:
shared net name     first ip           last ip            max   cur    percent  touch   t+c  t+c perc     bu  bu perc
sfs-wifi-dhcp-10_143_010.143.0.16          - 10.143.15.254     4079    16      0.392    860   876    21.476   2037   49.939
sfs-wifi-dhcp-10_143_1610.143.16.16     - 10.143.31.254     4079    17      0.417    934   951    23.315   2034   49.865
sfs-wifi-dhcp-10_143_3210.143.32.16     - 10.143.47.254     4079    18      0.441    830   848    20.789   2033   49.841
sfs-wifi-dhcp-10_143_4810.143.48.16     - 10.143.63.254     4079    21      0.515    934   955    23.413   2034   49.865
sfs-wifi-dhcp-10_143_6410.143.64.16     - 10.143.79.254     4079    27      0.662    876   903    22.138   2031   49.792
sfs-wifi-dhcp-10_143_8010.143.80.16     - 10.143.95.254     4079    17      0.417    906   923    22.628   2038   49.963
sfs-wifi-dhcp-10_143_9610.143.96.16     - 10.143.111.254    4079    17      0.417    922   939    23.020   2037   49.939
sfs-wifi-dhcp-10_143_11210.143.112.16    - 10.143.127.254    4079    17      0.417    922   939    23.020   1578   38.686
sfs-wifi-dhcp-10_143_12810.143.128.16    - 10.143.143.254    4079    17      0.417    923   940    23.045      0    0.000
sfs-wifi-dhcp-10_143_14410.143.144.16    - 10.143.159.254    4079    22      0.539    944   966    23.682      0    0.000
sfs-wifi-dhcp-10_143_16010.143.160.16    - 10.143.175.254    4079    19      0.466    910   929    22.775      0    0.000
sfs-wifi-dhcp-10_143_17610.143.176.16    - 10.143.191.254    4079    23      0.564    930   953    23.364      0    0.000
sfs-wifi-dhcp-10_143_19210.143.192.16    - 10.143.207.254    4079    20      0.490    888   908    22.260      0    0.000
sfs-wifi-dhcp-10_143_20810.143.208.16    - 10.143.223.254    4079    16      0.392    883   899    22.040      0    0.000
sfs-wifi-dhcp-10_143_22410.143.224.16    - 10.143.239.254    4079    18      0.441   1085  1103    27.041      0    0.000
sfs-wifi-dhcp-10_143_24010.143.240.16    - 10.143.255.254    4079    18      0.441    882   900    22.064      0    0.000

Shared networks:
name                   max   cur     percent  touch    t+c  t+c perc     bu  bu perc
sfs-wifi-dhcp-10_143_0  4079    16      0.392     860    876    21.476   2037   49.939
sfs-wifi-dhcp-10_143_16  4079    17      0.417     934    951    23.315   2034   49.865
sfs-wifi-dhcp-10_143_32  4079    18      0.441     830    848    20.789   2033   49.841
sfs-wifi-dhcp-10_143_48  4079    21      0.515     934    955    23.413   2034   49.865
sfs-wifi-dhcp-10_143_64  4079    27      0.662     876    903    22.138   2031   49.792
sfs-wifi-dhcp-10_143_80  4079    17      0.417     906    923    22.628   2038   49.963
sfs-wifi-dhcp-10_143_96  4079    17      0.417     922    939    23.020   2037   49.939
sfs-wifi-dhcp-10_143_112  4079    17      0.417     922    939    23.020   1578   38.686
sfs-wifi-dhcp-10_143_128  4079    17      0.417     923    940    23.045      0    0.000
sfs-wifi-dhcp-10_143_144  4079    22      0.539     944    966    23.682      0    0.000
sfs-wifi-dhcp-10_143_160  4079    19      0.466     910    929    22.775      0    0.000
sfs-wifi-dhcp-10_143_176  4079    23      0.564     930    953    23.364      0    0.000
sfs-wifi-dhcp-10_143_192  4079    20      0.490     888    908    22.260      0    0.000
sfs-wifi-dhcp-10_143_208  4079    16      0.392     883    899    22.040      0    0.000
sfs-wifi-dhcp-10_143_224  4079    18      0.441    1085   1103    27.041      0    0.000
sfs-wifi-dhcp-10_143_240  4079    18      0.441     882    900    22.064      0    0.000

[root@ns1 dhcp]# dhcpd-pools -help
Usage: dhcpd-pools [OPTIONS]
This is ISC dhcpd pools usage analyzer.

  -c --config   file    path to the dhcpd.conf file
  -l --leases   file    path to the dhcpd.leases file
  -f --format   [thc]   output format
                          t for text
                          h for html table
                          H for full html page
                          c for comma separated values
  -s --sort [nimcptTe]  sort ranges by
                          n name
                          i IP
                          m maxium
                          c current
                          p percent
                          t touched
                          T t+c
                          e t+c perc
  -r --reverse          reverse order sort
  -o --output   file    output into a file
  -L --limit    nr      output limit mask 77 - 00
  -v --version          version information
  -h --help             this screen

Report bugs to <[hidden email]>

Thanks,
Dmitry Vayntrub
Systems Coordinator
Information Technology Services
San Francisco State University
(415)338-1909

-----Original Message-----
From: [hidden email] [mailto:[hidden email]] On Behalf Of Simon Hobson
Sent: Saturday, June 20, 2015 5:07 AM
To: Users of ISC DHCP
Subject: Re: How to query for available / used ip

Leandro <[hidden email]> wrote:

> Hello Guys , I would like to plot the function of my dhcpd server on cacti graph.
> I want to know ir is there any recommended way to ask a running dhcp server how many ips were granted and how many are available ?

Check out dhcp-pool
As well as a command line tool, it has a munin plugin component. In principle it shouldn't be too hard to get it to update an RRD but I haven't got that far yet. As a command line tool it will give you information like this :

Subnet 192.168.7.0/24
--------------------------------------------------

  1. Pool "WiFi":

     Monitoring:      ON
     Warning limit:   75%
     Critical limit:  90%
     Active leases:   22/91 (24.2%)

While the Munin plugin will give you output like this :

$ dhcpd-munin_192.168.7.0_24_1
active.value 22
warning.value 68.2
critical.value 81.9
max.value 91

I figure the latter should be parseable into something that can be fed into Nagios and Cacti

_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: How to query for available / used ip

Leandro
In reply to this post by Gero Palacio
Hello , Gero , thanks for your answer, could you please explain "check out omapi" I understand that omapi is the proprietary protocol for isc dhcp server clustering.
Does it have any framework or usefull tool ?
Thanks.
Leandro.
 

On 19/06/15 20:10, Gero Palacio wrote:
Hi Leandro,

You'll probably want an answer with someone with more experience but I'm inclined to think that the only way to do this is by parsing the contents of the dhcpd.leases file. I don't think you could do it using the omshell, but I might be a good idea to check out omapi.

Good luck,
Geronimo.


_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users


_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: How to query for available / used ip

Gero Palacio
Hi Leandro,

Actually OMAPI, as the name suggests, it's an API not a protocol. I thought you could use that API to query the servers but that's not the case. The only interactive way of querying the servers is using OMSHELL which is a shell for OMAPI.

Nevertheless it seems you already have the answer you were looking for.

Good luck!
Gerónimo. 





On Mon, Jun 22, 2015 at 11:32 AM, Leandro <[hidden email]> wrote:
Hello , Gero , thanks for your answer, could you please explain "check out omapi" I understand that omapi is the proprietary protocol for isc dhcp server clustering.
Does it have any framework or usefull tool ?
Thanks.
Leandro.

 

On 19/06/15 20:10, Gero Palacio wrote:
Hi Leandro,

You'll probably want an answer with someone with more experience but I'm inclined to think that the only way to do this is by parsing the contents of the dhcpd.leases file. I don't think you could do it using the omshell, but I might be a good idea to check out omapi.

Good luck,
Geronimo.


_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users


_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users


_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: How to query for available / used ip

Leandro
In reply to this post by Dmitry Vayntrub
Dear Dmitry:
After you suggest to try dhcpd-pools I have been trying to compile it
but could not success.
Im having problems after running ./configure.
It seems to be a problem finding uthash.h header.
I already download the package but I dont know what to do with it.
Can you help me?
Im using Centos 6.6 i386.

Leandro.

On 20/06/15 13:23, Dmitry Vayntrub wrote:

> You might also look at dhcpd-pools
> http://dhcpd-pools.sourceforge.net/
>
> It is really fast (written in C ), and the output is easy to parse, as well as present as a web page if you would like to.
> Here is an example of the text mode output:
> [root@ns1 dhcp]# dhcpd-pools
> Ranges:
> shared net name     first ip           last ip            max   cur    percent  touch   t+c  t+c perc     bu  bu perc
> sfs-wifi-dhcp-10_143_010.143.0.16          - 10.143.15.254     4079    16      0.392    860   876    21.476   2037   49.939
> sfs-wifi-dhcp-10_143_1610.143.16.16     - 10.143.31.254     4079    17      0.417    934   951    23.315   2034   49.865
> sfs-wifi-dhcp-10_143_3210.143.32.16     - 10.143.47.254     4079    18      0.441    830   848    20.789   2033   49.841
> sfs-wifi-dhcp-10_143_4810.143.48.16     - 10.143.63.254     4079    21      0.515    934   955    23.413   2034   49.865
> sfs-wifi-dhcp-10_143_6410.143.64.16     - 10.143.79.254     4079    27      0.662    876   903    22.138   2031   49.792
> sfs-wifi-dhcp-10_143_8010.143.80.16     - 10.143.95.254     4079    17      0.417    906   923    22.628   2038   49.963
> sfs-wifi-dhcp-10_143_9610.143.96.16     - 10.143.111.254    4079    17      0.417    922   939    23.020   2037   49.939
> sfs-wifi-dhcp-10_143_11210.143.112.16    - 10.143.127.254    4079    17      0.417    922   939    23.020   1578   38.686
> sfs-wifi-dhcp-10_143_12810.143.128.16    - 10.143.143.254    4079    17      0.417    923   940    23.045      0    0.000
> sfs-wifi-dhcp-10_143_14410.143.144.16    - 10.143.159.254    4079    22      0.539    944   966    23.682      0    0.000
> sfs-wifi-dhcp-10_143_16010.143.160.16    - 10.143.175.254    4079    19      0.466    910   929    22.775      0    0.000
> sfs-wifi-dhcp-10_143_17610.143.176.16    - 10.143.191.254    4079    23      0.564    930   953    23.364      0    0.000
> sfs-wifi-dhcp-10_143_19210.143.192.16    - 10.143.207.254    4079    20      0.490    888   908    22.260      0    0.000
> sfs-wifi-dhcp-10_143_20810.143.208.16    - 10.143.223.254    4079    16      0.392    883   899    22.040      0    0.000
> sfs-wifi-dhcp-10_143_22410.143.224.16    - 10.143.239.254    4079    18      0.441   1085  1103    27.041      0    0.000
> sfs-wifi-dhcp-10_143_24010.143.240.16    - 10.143.255.254    4079    18      0.441    882   900    22.064      0    0.000
>
> Shared networks:
> name                   max   cur     percent  touch    t+c  t+c perc     bu  bu perc
> sfs-wifi-dhcp-10_143_0  4079    16      0.392     860    876    21.476   2037   49.939
> sfs-wifi-dhcp-10_143_16  4079    17      0.417     934    951    23.315   2034   49.865
> sfs-wifi-dhcp-10_143_32  4079    18      0.441     830    848    20.789   2033   49.841
> sfs-wifi-dhcp-10_143_48  4079    21      0.515     934    955    23.413   2034   49.865
> sfs-wifi-dhcp-10_143_64  4079    27      0.662     876    903    22.138   2031   49.792
> sfs-wifi-dhcp-10_143_80  4079    17      0.417     906    923    22.628   2038   49.963
> sfs-wifi-dhcp-10_143_96  4079    17      0.417     922    939    23.020   2037   49.939
> sfs-wifi-dhcp-10_143_112  4079    17      0.417     922    939    23.020   1578   38.686
> sfs-wifi-dhcp-10_143_128  4079    17      0.417     923    940    23.045      0    0.000
> sfs-wifi-dhcp-10_143_144  4079    22      0.539     944    966    23.682      0    0.000
> sfs-wifi-dhcp-10_143_160  4079    19      0.466     910    929    22.775      0    0.000
> sfs-wifi-dhcp-10_143_176  4079    23      0.564     930    953    23.364      0    0.000
> sfs-wifi-dhcp-10_143_192  4079    20      0.490     888    908    22.260      0    0.000
> sfs-wifi-dhcp-10_143_208  4079    16      0.392     883    899    22.040      0    0.000
> sfs-wifi-dhcp-10_143_224  4079    18      0.441    1085   1103    27.041      0    0.000
> sfs-wifi-dhcp-10_143_240  4079    18      0.441     882    900    22.064      0    0.000
>
> [root@ns1 dhcp]# dhcpd-pools -help
> Usage: dhcpd-pools [OPTIONS]
> This is ISC dhcpd pools usage analyzer.
>
>    -c --config   file    path to the dhcpd.conf file
>    -l --leases   file    path to the dhcpd.leases file
>    -f --format   [thc]   output format
>                            t for text
>                            h for html table
>                            H for full html page
>                            c for comma separated values
>    -s --sort [nimcptTe]  sort ranges by
>                            n name
>                            i IP
>                            m maxium
>                            c current
>                            p percent
>                            t touched
>                            T t+c
>                            e t+c perc
>    -r --reverse          reverse order sort
>    -o --output   file    output into a file
>    -L --limit    nr      output limit mask 77 - 00
>    -v --version          version information
>    -h --help             this screen
>
> Report bugs to <[hidden email]>
>
> Thanks,
> Dmitry Vayntrub
> Systems Coordinator
> Information Technology Services
> San Francisco State University
> (415)338-1909
>
> -----Original Message-----
> From: [hidden email] [mailto:[hidden email]] On Behalf Of Simon Hobson
> Sent: Saturday, June 20, 2015 5:07 AM
> To: Users of ISC DHCP
> Subject: Re: How to query for available / used ip
>
> Leandro <[hidden email]> wrote:
>
>> Hello Guys , I would like to plot the function of my dhcpd server on cacti graph.
>> I want to know ir is there any recommended way to ask a running dhcp server how many ips were granted and how many are available ?
> Check out dhcp-pool
> As well as a command line tool, it has a munin plugin component. In principle it shouldn't be too hard to get it to update an RRD but I haven't got that far yet. As a command line tool it will give you information like this :
>
> Subnet 192.168.7.0/24
> --------------------------------------------------
>
>    1. Pool "WiFi":
>
>       Monitoring:      ON
>       Warning limit:   75%
>       Critical limit:  90%
>       Active leases:   22/91 (24.2%)
>
> While the Munin plugin will give you output like this :
>
> $ dhcpd-munin_192.168.7.0_24_1
> active.value 22
> warning.value 68.2
> critical.value 81.9
> max.value 91
>
> I figure the latter should be parseable into something that can be fed into Nagios and Cacti
>
> _______________________________________________
> dhcp-users mailing list
> [hidden email]
> https://lists.isc.org/mailman/listinfo/dhcp-users
> _______________________________________________
> dhcp-users mailing list
> [hidden email]
> https://lists.isc.org/mailman/listinfo/dhcp-users

_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

RE: How to query for available / used ip

Dmitry Vayntrub
Get the 4 header files from the page below and put in one directory.
https://github.com/troydhanson/uthash/tree/master/src

Specify the directory path when running configure with "--with-uthash". Here is as an example of what I ran., and the uthash header files were under /root/dhcp/dhcpd-pools-2.26/contrib/uthash/src/

./configure --with-uthash=/root/dhcp/dhcpd-pools-2.26/contrib/uthash/src/ --with-dhcpd-conf=/etc/dhcpd.conf --with-dhcpd-leases=/var/lib/dhcpd/dhcpd.leases

Thanks,
Dmitry Vayntrub
Systems Coordinator
Information Technology Services
San Francisco State University
(415)338-1909

> -----Original Message-----
> From: [hidden email] [mailto:dhcp-users-
> [hidden email]] On Behalf Of Leandro
> Sent: Friday, June 26, 2015 12:46 PM
> To: Users of ISC DHCP
> Subject: Re: How to query for available / used ip
>
> Dear Dmitry:
> After you suggest to try dhcpd-pools I have been trying to compile it but could
> not success.
> Im having problems after running ./configure.
> It seems to be a problem finding uthash.h header.
> I already download the package but I dont know what to do with it.
> Can you help me?
> Im using Centos 6.6 i386.
>
> Leandro.
>
> On 20/06/15 13:23, Dmitry Vayntrub wrote:
> > You might also look at dhcpd-pools
> > http://dhcpd-pools.sourceforge.net/
> >
> > It is really fast (written in C ), and the output is easy to parse, as well as present
> as a web page if you would like to.
> > Here is an example of the text mode output:
> > [root@ns1 dhcp]# dhcpd-pools
> > Ranges:
> > shared net name     first ip           last ip            max   cur    percent
> touch   t+c  t+c perc     bu  bu perc
> > sfs-wifi-dhcp-10_143_010.143.0.16          - 10.143.15.254     4079    16      0.392
> 860   876    21.476   2037   49.939
> > sfs-wifi-dhcp-10_143_1610.143.16.16     - 10.143.31.254     4079    17      0.417
> 934   951    23.315   2034   49.865
> > sfs-wifi-dhcp-10_143_3210.143.32.16     - 10.143.47.254     4079    18      0.441
> 830   848    20.789   2033   49.841
> > sfs-wifi-dhcp-10_143_4810.143.48.16     - 10.143.63.254     4079    21      0.515
> 934   955    23.413   2034   49.865
> > sfs-wifi-dhcp-10_143_6410.143.64.16     - 10.143.79.254     4079    27      0.662
> 876   903    22.138   2031   49.792
> > sfs-wifi-dhcp-10_143_8010.143.80.16     - 10.143.95.254     4079    17      0.417
> 906   923    22.628   2038   49.963
> > sfs-wifi-dhcp-10_143_9610.143.96.16     - 10.143.111.254    4079    17      0.417
> 922   939    23.020   2037   49.939
> > sfs-wifi-dhcp-10_143_11210.143.112.16    - 10.143.127.254    4079    17
> 0.417    922   939    23.020   1578   38.686
> > sfs-wifi-dhcp-10_143_12810.143.128.16    - 10.143.143.254    4079    17
> 0.417    923   940    23.045      0    0.000
> > sfs-wifi-dhcp-10_143_14410.143.144.16    - 10.143.159.254    4079    22
> 0.539    944   966    23.682      0    0.000
> > sfs-wifi-dhcp-10_143_16010.143.160.16    - 10.143.175.254    4079    19
> 0.466    910   929    22.775      0    0.000
> > sfs-wifi-dhcp-10_143_17610.143.176.16    - 10.143.191.254    4079    23
> 0.564    930   953    23.364      0    0.000
> > sfs-wifi-dhcp-10_143_19210.143.192.16    - 10.143.207.254    4079    20
> 0.490    888   908    22.260      0    0.000
> > sfs-wifi-dhcp-10_143_20810.143.208.16    - 10.143.223.254    4079    16
> 0.392    883   899    22.040      0    0.000
> > sfs-wifi-dhcp-10_143_22410.143.224.16    - 10.143.239.254    4079    18
> 0.441   1085  1103    27.041      0    0.000
> > sfs-wifi-dhcp-10_143_24010.143.240.16    - 10.143.255.254    4079    18
> 0.441    882   900    22.064      0    0.000
> >
> > Shared networks:
> > name                   max   cur     percent  touch    t+c  t+c perc     bu  bu perc
> > sfs-wifi-dhcp-10_143_0  4079    16      0.392     860    876    21.476   2037
> 49.939
> > sfs-wifi-dhcp-10_143_16  4079    17      0.417     934    951    23.315   2034
> 49.865
> > sfs-wifi-dhcp-10_143_32  4079    18      0.441     830    848    20.789   2033
> 49.841
> > sfs-wifi-dhcp-10_143_48  4079    21      0.515     934    955    23.413   2034
> 49.865
> > sfs-wifi-dhcp-10_143_64  4079    27      0.662     876    903    22.138   2031
> 49.792
> > sfs-wifi-dhcp-10_143_80  4079    17      0.417     906    923    22.628   2038
> 49.963
> > sfs-wifi-dhcp-10_143_96  4079    17      0.417     922    939    23.020   2037
> 49.939
> > sfs-wifi-dhcp-10_143_112  4079    17      0.417     922    939    23.020   1578
> 38.686
> > sfs-wifi-dhcp-10_143_128  4079    17      0.417     923    940    23.045      0
> 0.000
> > sfs-wifi-dhcp-10_143_144  4079    22      0.539     944    966    23.682      0
> 0.000
> > sfs-wifi-dhcp-10_143_160  4079    19      0.466     910    929    22.775      0
> 0.000
> > sfs-wifi-dhcp-10_143_176  4079    23      0.564     930    953    23.364      0
> 0.000
> > sfs-wifi-dhcp-10_143_192  4079    20      0.490     888    908    22.260      0
> 0.000
> > sfs-wifi-dhcp-10_143_208  4079    16      0.392     883    899    22.040      0
> 0.000
> > sfs-wifi-dhcp-10_143_224  4079    18      0.441    1085   1103    27.041      0
> 0.000
> > sfs-wifi-dhcp-10_143_240  4079    18      0.441     882    900    22.064      0
> 0.000
> >
> > [root@ns1 dhcp]# dhcpd-pools -help
> > Usage: dhcpd-pools [OPTIONS]
> > This is ISC dhcpd pools usage analyzer.
> >
> >    -c --config   file    path to the dhcpd.conf file
> >    -l --leases   file    path to the dhcpd.leases file
> >    -f --format   [thc]   output format
> >                            t for text
> >                            h for html table
> >                            H for full html page
> >                            c for comma separated values
> >    -s --sort [nimcptTe]  sort ranges by
> >                            n name
> >                            i IP
> >                            m maxium
> >                            c current
> >                            p percent
> >                            t touched
> >                            T t+c
> >                            e t+c perc
> >    -r --reverse          reverse order sort
> >    -o --output   file    output into a file
> >    -L --limit    nr      output limit mask 77 - 00
> >    -v --version          version information
> >    -h --help             this screen
> >
> > Report bugs to <[hidden email]>
> >
> > Thanks,
> > Dmitry Vayntrub
> > Systems Coordinator
> > Information Technology Services
> > San Francisco State University
> > (415)338-1909
> >
> > -----Original Message-----
> > From: [hidden email]
> > [mailto:[hidden email]] On Behalf Of Simon Hobson
> > Sent: Saturday, June 20, 2015 5:07 AM
> > To: Users of ISC DHCP
> > Subject: Re: How to query for available / used ip
> >
> > Leandro <[hidden email]> wrote:
> >
> >> Hello Guys , I would like to plot the function of my dhcpd server on cacti
> graph.
> >> I want to know ir is there any recommended way to ask a running dhcp server
> how many ips were granted and how many are available ?
> > Check out dhcp-pool
> > As well as a command line tool, it has a munin plugin component. In principle it
> shouldn't be too hard to get it to update an RRD but I haven't got that far yet. As
> a command line tool it will give you information like this :
> >
> > Subnet 192.168.7.0/24
> > --------------------------------------------------
> >
> >    1. Pool "WiFi":
> >
> >       Monitoring:      ON
> >       Warning limit:   75%
> >       Critical limit:  90%
> >       Active leases:   22/91 (24.2%)
> >
> > While the Munin plugin will give you output like this :
> >
> > $ dhcpd-munin_192.168.7.0_24_1
> > active.value 22
> > warning.value 68.2
> > critical.value 81.9
> > max.value 91
> >
> > I figure the latter should be parseable into something that can be fed
> > into Nagios and Cacti
> >
> > _______________________________________________
> > dhcp-users mailing list
> > [hidden email]
> > https://lists.isc.org/mailman/listinfo/dhcp-users
> > _______________________________________________
> > dhcp-users mailing list
> > [hidden email]
> > https://lists.isc.org/mailman/listinfo/dhcp-users
>
> _______________________________________________
> dhcp-users mailing list
> [hidden email]
> https://lists.isc.org/mailman/listinfo/dhcp-users
_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users