# Setting up DHCP leases for static IPs

**URL:** <https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514>\
**Category:** Help\
**Tags:** dhcp\
**Created:** [July 8, 2019, 9:24am UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514 "2019-07-08T09:24:39Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![alec](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/alec/32/8771_2.png) [@alec](https://discourse.pi-hole.net/u/alec)\
**Post date:** [July 8, 2019, 9:24am UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/1 "2019-07-08T09:24:39Z")

</div>

I have an Orbi router which I use to set up various static IPs for devices on my local network. It has an address reservation table looking something like this:

| IP Address | Device Name | MAC Address |
| --- | --- | --- |
| 192.168.1.56 | HUE-BRIDGE | 01:17:66:70:GE:99 |
| 192.168.1.18 | ROKU-STICK | F6:3A:6B:A3:73:G1 |

I've now set up Pi-hole as my DNS and DHCP server. It looks like some of these mappings have been carried across to Pi-hole's "Currently active DHCP leases" table, but have been assigned different IPs based on the range. I also see the "Static DHCP leases configuration" table below seems to be separate and empty.

**After Pi-hole setup these local devices with their static IPs are no longer accessible on my network. What should I be doing here to fix these devices, keeping the original IP address set on them if possible?**

- Should I be removing these address reservations in Orbi and use only Pi-hole's "Static DHCP leases configuration" table for this instead?
- Should I change the IP range in the DHCP settings to exclude, or include these previously set up devices? Devices don't seem to get reassigned IPs after I change this range.

Any insight on what I should be doing here to fix my static IPs is appreciated!

---

<div class="post-metadata">

**Author:** ![Mcat12](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/mcat12/32/20_2.png) [@Mcat12](https://discourse.pi-hole.net/u/Mcat12)\
**Post date:** [July 10, 2019, 2:24am UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/2 "2019-07-10T02:24:14Z")

</div>

Make sure you are only running one DHCP server. Pi-hole has no knowledge of the router's DHCP reservations, so it will assign new ones. Usually you need to restart the device or its networking to have it renew its DHCP lease (get new DHCP info).

---

<div class="post-metadata">

**Author:** ![alec](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/alec/32/8771_2.png) [@alec](https://discourse.pi-hole.net/u/alec)\
**Post date:** [July 10, 2019, 11:02am UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/3 "2019-07-10T11:02:50Z")

</div>

@Mcat12 thanks for your reply. My understanding is I need one DHCP reservation on the router for the Pi (`192.168.1.2`) to prevent this IP from changing.

What I've ended up doing here (based on [this comment](https://www.reddit.com/r/pihole/comments/9r91rc/how_to_set_a_static_ip_for_the_pihole/e8ff80b/)) is keeping the router's DHCP server enabled, but to a range of just one address `192.168.1.2`. This same address is set up in the router as an address reservation.

 ![screenshot](https://discourse.pi-hole.net/uploads/default/original/3X/e/3/e399da3442d43da3310b9a82d23d396e75799e68.png)

The router's DNS server is also set to `192.168.1.2`:

 ![screenshot](https://discourse.pi-hole.net/uploads/default/original/3X/0/7/071b72df04ce806a52eb5d4347e1ac4b9daa85a7.png)

As for Pi-hole, I've set the available address range outside of this to prevent any clashing:

 ![screenshot](https://discourse.pi-hole.net/uploads/default/original/3X/6/9/69bd61222bb436539aca3ea129200e52b0a9140e.png)

All other static IP address reservations I've set up within Pi-hole:

 ![screenshot](https://discourse.pi-hole.net/uploads/default/original/3X/d/6/d6fc25a6c158e94c11731c124314aa4273286582.png)

Does this sound like an appropriate setup to you?

---

<div class="post-metadata">

**Author:** ![Mcat12](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/mcat12/32/20_2.png) [@Mcat12](https://discourse.pi-hole.net/u/Mcat12)\
**Post date:** [July 11, 2019, 4:13am UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/4 "2019-07-11T04:13:30Z")

</div>

You do not need to run DHCP on the router if you are running it on Pi-hole.

---

<div class="post-metadata">

**Author:** ![alec](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/alec/32/8771_2.png) [@alec](https://discourse.pi-hole.net/u/alec)\
**Post date:** [July 11, 2019, 8:09am UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/5 "2019-07-11T08:09:56Z")

</div>

@Mcat12 but don't I need a fixed IP for the Pi itself that's running Pi-hole?

Are you suggesting I set this up as a DHCP lease within Pi-hole? Disabling the router's DHCP server (which is only using one address like I say) makes my devices unavailable on the network.

---

<div class="post-metadata">

**Author:** ![Mcat12](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/mcat12/32/20_2.png) [@Mcat12](https://discourse.pi-hole.net/u/Mcat12)\
**Post date:** [July 12, 2019, 3:16am UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/6 "2019-07-12T03:16:48Z")

</div>

You do not need a DHCP lease, as Pi-hole is already set up with a static address. A static address is different than a static lease.

---

<div class="post-metadata">

**Author:** ![alec](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/alec/32/8771_2.png) [@alec](https://discourse.pi-hole.net/u/alec)\
**Post date:** [July 12, 2019, 8:05am UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/7 "2019-07-12T08:05:28Z")

</div>

I see, thank you @Mcat12. I have now disabled DHCP on the router.

Just as a final clarification (sorry!) although DHCP is disabled, the address reservation on the router setting the IP for the Pi as `192.196.1.2` should remain?

 ![screenshot](https://discourse.pi-hole.net/uploads/default/original/3X/c/0/c06fdce7ae90978b4232c595077420bd0c04f9c1.png)

---

<div class="post-metadata">

**Author:** ![Mcat12](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/mcat12/32/20_2.png) [@Mcat12](https://discourse.pi-hole.net/u/Mcat12)\
**Post date:** [July 13, 2019, 2:23am UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/8 "2019-07-13T02:23:26Z")

</div>

As DHCP is disabled, the address reservation is also disabled.

---

<div class="post-metadata">

**Author:** ![alec](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/alec/32/8771_2.png) [@alec](https://discourse.pi-hole.net/u/alec)\
**Post date:** [July 15, 2019, 1:34pm UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/9 "2019-07-15T13:34:49Z")

</div>

Fair enough, but then how do I set the IP address of the Pi to `192.168.1.2`? This is outside the range in the Pi-hole settings, so it can't be set there?

Slightly off topic, but I'm currently running Pi-hole as [a Home Assistant addon](https://github.com/hassio-addons/addon-pi-hole). After running well for a day or so I come home to the internet connection being down (Orbi shows purple light ring). Resetting the router to factory defaults and re-setting up Pi-hole gets me going again but only until it happens again. The most recent time this happened the Pi simply won't show up on my network after power cycles - I assume my SD card is blown.

Pi-hole seems important enough to run on a dedicated Pi, but in the meantime this behaviour is disconcerting.

---

<div class="post-metadata">

**Author:** ![DanSchaper](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/danschaper/32/91_2.png) [@DanSchaper](https://discourse.pi-hole.net/u/DanSchaper)\
**Post date:** [July 15, 2019, 3:20pm UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/10 "2019-07-15T15:20:07Z")

</div>

For the first, see `/etc/network/interfaces` for static IP addressing. If it's a Raspberry Pi and Raspbian then you'll have to read the instructions in that file. Normally we set the IP as static with our installation script.

As for running as an addon, that's not a supported running configuration that we are able to assist with. You'll have to ask the person that wrote it for support, as they modify our work.

---

<div class="post-metadata">

**Author:** ![alec](https://discourse-cdn.pi-hole.net/user_avatar/discourse.pi-hole.net/alec/32/8771_2.png) [@alec](https://discourse.pi-hole.net/u/alec)\
**Post date:** [July 15, 2019, 4:17pm UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/11 "2019-07-15T16:17:34Z")

</div>

Thank you for the replies, that has cleared some things up for me.

---

<div class="post-metadata">

**Author:** ![system](https://discourse.pi-hole.net/uploads/default/original/3X/7/c/7c8792f649eeb921c5d2b4c41564ffa873d9a2b8.png) [@system](https://discourse.pi-hole.net/u/system)\
**Post date:** [August 5, 2019, 4:17pm UTC](https://discourse.pi-hole.net/t/setting-up-dhcp-leases-for-static-ips/21514/12 "2019-08-05T16:17:37Z")

</div>

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.
