Opened 9 years ago
Closed 9 years ago
#12260 closed bug (fixed)
system/settings/network/hosts missing resulting in non-resolving localhost
Reported by: | waddlesplash | Owned by: | axeld |
---|---|---|---|
Priority: | normal | Milestone: | Unscheduled |
Component: | Servers/net_server | Version: | R1/Development |
Keywords: | Cc: | ||
Blocked By: | Blocking: | #12364 | |
Platform: | All |
Description (last modified by )
NetResolv assumes that "localhost" actually exists, but in some instances it doesn't (it can't be resolved -- 127.0.0.1 exists, though).
This could be part of the issue with our DHCP issues in #12208, however it isn't the sole reason as adding a localhost line to hosts doesn't fix the DHCP issue.
Change History (11)
comment:1 by , 9 years ago
comment:2 by , 9 years ago
Description: | modified (diff) |
---|
comment:3 by , 9 years ago
Description: | modified (diff) |
---|
comment:4 by , 9 years ago
Description: | modified (diff) |
---|---|
Summary: | [net_server?] "localhost" is not garunteed to be created before some services → system/settings/network/hosts missing resulting in non-resolving localhost |
comment:5 by , 9 years ago
I might be dumb, but netresolv should be the one to provide "localhost" in the first place, no? It's the only name resolution entity out there (in Haiku) after all.
How about reverting the netresolv change, and go with FreeBSD's solution next time?
comment:6 by , 9 years ago
localhost and the loopback interface are working fine here, without the need for an "hosts" file.
comment:7 by , 9 years ago
Blocking: | 12364 added |
---|
comment:8 by , 9 years ago
I did some digging, netresolv does provide localhost... by parsing the /etc/hosts like on most platforms :-). There could be edge cases of users wanting to modify where localhost points so setting it in a static way is really not ideal. As all the platforms I know of define localhost in some etc-hosts way, i'm going that route.
Fix on it's way.
comment:9 by , 9 years ago
As with the services, I could imagine that I hard-coded that into the former libbind solution in case there was no /etc/hosts file. It would probably make sense to look into that.
Strike that. In some instances,
localhost
isn't even created at all -- it doesn't exist on my system (!)