Hubitat Hub Static IP option and setting

No need to apologize. We are the same age, so I understand. We all started out asking questions, regardless of our age. Continue to ask, someone with an answer should respond.

6 Likes

I’d say it’s also usually a good sign when we keep asking questions, regardless of age :wink:.

6 Likes

Hi Bravenel
On this threat I suggest something but I never get response from you or other staff member:

In a C4, Is it possible to add a option on Settings to state a Delay before the hub get IP?

I have a lot of blackouts here and for some reason my HE is always getting ip BEFORE my router start.... the only solution is to unplug power and after some time plug it again, then it get IP correctly. In the meantime can't access the hub and it is annoying at the minimun, if I'm out of home then I lose access to my home until I return and do that.

I'm not asking for static IP as you explained the C4 do not have a button to reset and I'm agree with that... I'm just asking to be able to select a delay before the hub get ip or start.

Tagging @gopher.ny

Can I suggest putting your Hubitat on a UPS if it isn't already on one?

2 Likes

It is but battery is dead....why? because in where I live there are not on the stores.. amazing but true.
I can't use amazon either or similar online stores..... but that's a complete book to explain Ambassador... is complicated to live here... that's why I selected HE and all its offline features

1 Like

There's no such option available on C4. There's no static IP setting, either. Implementing it will require a non-trivial effort and is not considered at this time.

1 Like

Would it be possible to detect a bad/missing IP address at start-up, then invoke a rule that will do a "reboot" after a bit when things are hopefully happy?

image

If you install the "Hub Information" (user) device driver then reference the virtual device it uses to read the IP address:

image

You can test that for a sensible value...then, use the Hubitat Hub Controller device (another user device driver) to force a reboot after a delay.

image

You can find the user apps in the Hubitat Package Manager (also a user app--if you aren't using it, search the forum for install location)...

Hub Information Driver:

Hubitat Hub Controller:
image

1 Like

The problem with that, and with using Hub Information driver, is that you might get into a reboot loop. On my C-7, Hub Info gets bad data on its first poll after reboot. And I would expect that the hub sends out an ARP packet upon each reboot so that it can get its reserved IP, so the approach of doing a reboot if the IP is in the 169.254.x.x range might be made to work by an appropriate systemStart rule, but that could also put you into a reboot loop if the hub were to be booted with the Ethernet cable disconnected, etc.

A better approach might be to put the hub on a receptacle that has a pre-set turn-on delay, and plug that receptacle and the switch/router into the same source. I believe that such receptacles exist, our lab used to use them to sequence the turn-on of equipment. That would provide a delay before the hub boots.

2 Likes

I believe variables are saved across reboots--so, you could track your reboots via a variable so you didn't reboot more than 1-2 times.

You could also begin with a delay as well to help.

But, yeah, also, some sort of "delayed power on" device could do the trick as well if you can find one.

1 Like

I wrote a Hub Info addon a while back that among other things will send out a notificiation if the IP Address changes

Would be an easy for me to include a reboot option if you’d like…

4 Likes

Your hub info app works great to keep track of my ip address for me! Many thanks!!

3 Likes

Hi gopher.ny
I know that and that's why I'm asking for this feature.
I think it will be very easy to do and very useful and the same time.

Another users below are giving me good solutions but to buy a hardware with a timer is complicated here and I don't think is a good idea to make routines on the start process if this is something HE programmer can solve easily.

All that can be a solution .. it will make HE start double of the time needed but its a solution.
But I will preffer something implemented on the Hub core software.....it will be easier, faster, and less complicated for normal users.

You are right I thouth about it inmediately (I'm electric engineer so that's was my first choice) but telling you the truth we haven't those receptacles here....I can figure out how to make myself something like that with some circuits made by my own but too much trouble for something the HE programmers can solve easily. Don't you think?

No, I don’t think that’s necessarily true. Realize that the Hubitat platform is layered on top of a standard OS that Hubitat didn’t write. The network stack that does the ARP on boot to get an IP is buried in the networking stack initialize routines. Having done OS development, including a Unix 4.2BSD port to a new architecture back in the 1980s, I’m not going to speculate on the amount of effort that would be required, other than to comment that it would seem desirable that Hubitat run on top of as close-to-standard OS so that maintenance efforts would not be expended on such things.

But I would guess that, regardless of the amount of effort required, it’s near the bottom of the Hubitat priorities. And, also, realize that you seem to be running a C-4, no longer sold, which does not have the same underlying OS as the current C-7 product. Any effort spent doing this for the C-4 would take away from product development on the current and future product line. Doesn’t seem to make business sense to me.

3 Likes

You might prefer it, but you very much have an "edge case" unique to your situation.

That makes it unlikely to happen

Thus, you need to consider realistic alternatives, such as what I suggested--else you'll likely end up with only a wish. As was just noted by others, a native HE solution just for you isn't likely.

2 Likes

Thinking in what you say it makes sense... I'm agree with you.

So.. I have to buy a new hub even when this one is ok or I have to implement solutions suggested here....good point from you, never thought "Hubitat platform is layered on top of a standard OS that Hubitat didn’t write", that's make things complicated.

1 Like

Agreed with you,.... I will try to implement your suggestions

2 Likes

I have added this option to Hub Monitor ​if IP = 169.254.x.x, requires Hub Information driver ≥ 2.6.15

2 Likes