mirror of
https://github.com/kvcache-ai/AgentENV.git
synced 2026-11-05 01:17:36 +00:00
[GH-ISSUE #319] bug(tools-image): guest hostname instance does not resolve locally #82
Labels
No labels
bug
documentation
enhancement
enhancement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
kvcache-ai/AgentENV#82
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @LSX-s-Software on GitHub (Sep 25, 2026).
Original GitHub issue: https://github.com/kvcache-ai/AgentENV/issues/319
Affected component
Firecracker runtime / guest bootstrap (
tools-image/pivot-init)AgentENV version
725810de2d925d7908d44f18521ff3496e9360a1(the relevant code is also present on currentmain)0.1.1Host environment
docker.io/library/eclipse-temurin:17-jdk-jammy(any image without aninstanceentry in/etc/hostscan expose the same problem).Operation and configuration
Cold-start a sandbox from the public OCI image, using the default guest network and tools drive. No custom hostname or DNS settings are required.
Steps to reproduce
Cold-start a sandbox from
docker.io/library/eclipse-temurin:17-jdk-jammy.In the guest, run:
In the same guest, run a Java self-lookup:
Expected behavior
The hostname assigned to the guest should resolve to a valid local address without relying on an external DNS server. Java's
InetAddress.getLocalHost()should succeed.Actual behavior
The guest hostname is
instance, butinstanceis absent from the guest's local hosts mappings. A files-only lookup fails, and Java self-lookup can fail with:The kernel boot argument sets the hostname to
instance. The guest bootstrap writes onlylocalhostentries when/etc/hostsis missing or empty, and leaves a non-empty file untouched. Neither path ensures thatinstanceresolves.Logs and diagnostics
The observed exception is shown above. The files-only
getentprobe distinguishes local hosts configuration from a DNS answer for the same name. No host networking failure is required.Reproduction frequency
Always when the guest image does not already map
instancelocally and DNS does not provide that mapping. Whether ordinary lookups happen to succeed can otherwise depend on external DNS behavior.Regression information
Additional context
#268 addressed missing or empty
/etc/hostsforlocalhost, and the earlier #55 proposed a relatedlocalhostrepair. Neither adds a mapping for the guest's own hostname. A fix should preserve image-provided entries and remain correct across cold starts and snapshot restores, where a slot IP may change.Pre-submission checklist