Unable to resolve host hassbian

type hostname in terminal, what’s returned?

Perhaps hassbian.local will work?

If your install is anything like mine, I had the same and had to edit the /etc/hosts file and correct one of the lines. To be honest it was a little while ago when I installed and I cant remember exactly, but either the name was wrong or the IP address was wrong, once updated those messages went away for me.

I now have two IP4 entries in the hosts file :
127.0.0.1 localhost
127.0.1.1 HASS

as yours is talking about ‘hassbian’ I guess you could try:
127.0.1.1 hassbian

I need to meet the minimum characters to when I type hostname I get

hassbian

noob here: can you give me a link that would walk me through that?

Perhaps . . . .I don’t know where I would change it. I have no idea where it is getting the hostname from.

I restarted and now I am having the same problem I have had in the past. After restarting it says it can’t find the host. It asks for usr & pw then it won’t let me do anything else.

All i get is the error unable to resolve host hassbian

If I try to run anything it won’t accept my password.

Just in case anyone tried to work on this, I am reinstalling using noob instead of Hassbian. I will see if that gives me different results.

Honestly, you would just need to add:

127.0.1.1	hassbian`

To the /etc/hosts file to get rid of that. The easiest way would be to do:

sudo nano /etc/hosts

And then make the change…`

1 Like

So I tried to reinstall HA the old way and simply could not make it work. That took a really, really, long time and it did not actually work.

I reinstalled Hassbian, ioaded lots of stuff, got that error again, used the steps you posted. did them wrong at least twice, did it right, then could not get it to run.

Lots and lots of searching, went through the log file, found i had something wrong in the configuration.yaml and simply deleted the things I tried to get HA to do, and finally it works!

I even got the autostart to work. I feel accomplished even though I cant get HA to actually do anything yet. I do have it running though.

Thanks

edit: I would mark this solved, but don’t know how or if this forum uses that.

This is really all that you need to do, if you googled “Unable to resolve host” you would’ve found hundreds of results all saying the same thing as it’s nothing to do with HA itself.

I know because that’s what i did when I got it!!!

Good for you.

Lol, perhaps if you took people’s advice you wouldn’t waste yours and others time :slight_smile:

1 Like

There’s always one on a forum, guess you are it.

I originally had more than one problem. That confounded the single answer you have come with a day late.

I fixed the first problem and realized the resolve host was isolated. I could not log back into pi to fix the host file, but it took me hours to realize that.

After I reinstalled pi for the fourth time, since I have never done anything in Xnix before, I tried again and resolved the first problem but the second problem, unable to resolve host hassbian, represented it self.

I updated my original problem because I did not do anything to cause this problem and still think it might be a bug.

BendedArrow was nice enough to post a solution since I had no idea what

Please post the contents of /etc/hostname and /etc/hosts.

meant.

I had no idea how to do that. So he rescued me. Sorry that upsets you. Tell you what, I will give you a little cookie and click your heart since that seems to be what you are fishing for.

Please be nice and don’t taunt others. Your posts have been flagged by others :slight_smile:

Hi all

I too was getting the unable to resolve host issue, and I attempted to follow the advice of inserting the line

127.0.1.1 hassbian

While I was editing the hosts file my laptop froze, and killed the putty connection.

When I terminalled back in the hosts file is now blank. Can someone post what the hosts file should be for the hassbian version of homeassistant.

Thanks

This is the deafult hosts file on my hassbian install.

127.0.0.1       localhost
::1             localhost ip6-localhost ip6-loopback
ff02::1         ip6-allnodes
ff02::2         ip6-allrouters

127.0.1.1       raspberrypi

Thanks for your info

I managed to reinstate it, and then followed the advice else where in this post and changed raspberrypi to hassbian

so my config hosts file looks like

127.0.0.1       localhost
::1             localhost ip6-localhost ip6-loopback
ff02::1         ip6-allnodes
ff02::2         ip6-allrouters

127.0.1.1       hassbian

I assume that deleting raspberrypi wont cause any conflicts with anything else?

Couldn’t say. I also have a file in /etc/ called hostname and that just has hassbian in it. I’m able to resolve hassbian.local with the hosts file i posted above and that hostname file.

This was most likely caused by a mistake on my end where I forgot to change the hostname from raspberrypi to hassbian and only changed it with the avahi daemon.