How many DHCP bindings are in use?

Reply
Highlighted
L3 Networker

How many DHCP bindings are in use?

All,

I've been digging around and as far as I can tell there isn't a way to just show me how many DHCP bindings are currently in use, is there?

I have interfaces that are serving up /21's of addresses and I'd love to be able to just run a quick command telling me: There are 567 addresses in use out of 2000 or a % or something. As far as I can tell the only thing you can do is just show me a HUGE list of all the IPs which is pretty useless besides knowing a lot of people have addresses..

Thanks!

Tags (3)
L7 Applicator

Re: How many DHCP bindings are in use?

Hello,

> show dhcp server lease all | match pool

This will output the leases, but only match lines with "pool" in the name. A sample output is:

> show dhcp server lease all | match pool

Allocated IPs: 0, Total number of IPs in pool: 26. 0.0000% used

Allocated IPs: 7, Total number of IPs in pool: 21. 33.3333% used

Hope this helps,

Greg

L3 Networker

Re: How many DHCP bindings are in use?

Hmmmm.. Is this maybe a 5.1 or 6.0 feature? We're currently running 5.0.6 and if I just run the command:

show dhcp server lease all

I get a listing of bindings, however I don't see anything that says 'pool' so if I run the full command:

show dhcp server lease all | match pool

It matches nothing so it doesn't show me anything..

Thanks!

L7 Applicator

Re: How many DHCP bindings are in use?

Sorry about that, my firewall is running 6.0.1 and I assumed it would be the same on a 5.0 box as well. It looks like the 'pool' output was added to the 6.0 version, so that's a new feature. There is no feature in 5.0 that would give you a summary from what I could find.

Your best bet would be to turn on logging in your SSH program, turn off CLI paging (set cli pager off), then do a grep -c or something similar to count the number of lines you got that match your /21 (cat output.txt | grep -c 172.16.).

Once you're ready to upgrade to 6.0, you can use the other command I gave before.

Cheers,

Greg

L4 Transporter

Re: How many DHCP bindings are in use?

Hi

On 5.0.9 You can use:

admin@PA-200> show dhcp server lease ethernet1/4.31 | match committed

My question is - is it possible to monitor by SNMP? (on 5.x or 6.x)?

Regards

Slawek

Like what you see?

Show your appreciation!

Click Like if a post is helpful to you or if you just want to show your support.

Click Accept as Solution to acknowledge that the answer to your question has been provided.

The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!

These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the Live Community as a whole!

The Live Community thanks you for your participation!