Assign Static IP Address without USB Config file

Hi everybody !

I installed Hassio using the VMDK provided on the website. My Hassio instance got an IP from my DHCP server. After that, I tried to set a static IP using the following documentation on https://github.com/home-assistant/hassos/blob/rel-1/Documentation/network.md

I put a my-network file both in /etc/network and in /config/network containing the following lines:

[connection]
id=hassos-network
uuid=a98ff096-050a-472c-9f30-267804b2802f
type=802-3-ethernet

[ipv4]
method=manual
address1=192.168.1.30/24,192.168.1.1
dns=8.8.8.8;192.168.1.1;

[ipv6]
addr-gen-mode=stable-privacy
method=auto

I restarted my Hass.io instance, and it doesn’t seem to work.

I’ve since then assigned a static lease on this Hassio instance, but since I have a 1 day lease time, I’d like to speed up the process a little bit, and use the static IP I want.

I’m starting to think that I have to use a USB key with the my-network file…

Is there something I’m not doing correctly ?

Thanks in advance for your answers.

Reserve the IP address in your router for that MAC address…

Thanks for your answer ! I’ve done that, but it doesn’t seem to get the good IP address (I’m thinking it’s because of the lease time of 1 day, maybe it won’t work until that lease time has expired). That’s why I wanted to force it…

I have never touched the lan config in HA. Maybe you should set the IPv4 address to auto not manual… Also make sure you have the right MAC address reserved. I have never ever had an issue with a router reserving an IP address for a client unless some other device has/is using it and then you remove that device from the network and fix the reservation in the router (deleting the other device) and then restarting the device(s).

I don’t understand why you are having a problem.

Well thanks for your help, I managed to solve my problem by disconnecting the network adapter in esxi, booting again, stopping again, and connecting the network adapter. I now have the ip I set in the static ip section on my router.

Thanks again

1 Like