← Back to issue list

Snapcraft produces too long instance name, instance launch fails

View original Launchpad issue

Metadata

Project
snapcraft (launchpad)
Number
#1981205
Type
issue
State
closed
Author
~fnordahl
Labels
craft-1194
Created
Updated
Closed

Current evaluation

LXC's 63-character instance-name limit blocked snapcraft pack; no fix was recorded, and the dormant report was closed as stale.

Resolution: closed stale

Reason: No merged PR, commit, superseding work, or maintainer explanation was recorded. The sole comment, from ~mr-cal on 2022-07-15, linked charmcraft#629 and was followed by 1,492 days without activity.

Evaluated by: mr-cal-bot

No scores available.

Issue body

$ snap info snapcraft|grep ^installed installed: 7.0.11.post26+gita61c6032 (7943) 65MB classic $ snapcraft pack Failed to launch instance 'snapcraft-octavia-diskimage-retrofit-on-amd64-for-amd64-12194235'. * Command that failed: "lxc --project snapcraft launch craft-com.ubuntu.cloud-buildd:core22 local:snapcraft-octavia-diskimage-retrofit-on-amd64-for-amd64-12194235 --config 'raw.idmap=both 1000 0' --config security.syscalls.intercept.mknod=true" * Command exit code: 1 * Command output: b'Creating snapcraft-octavia-diskimage-retrofit-on-amd64-for-amd64-12194235\n' * Command standard error output: b'Error: Failed instance creation: Invalid instance name: Name must be 1-63 characters long\n' If you remove the snap name altogether the base name of the instance is: snapcraft--on-amd64-for-amd64-12194235 $ echo -n"snapcraft--on-amd64-for-amd64-12194235"|wc 1 1 41 Which leaves 22 characters for the snap name in this case, or 20 if the inode number nears the max value. Would you think this is sufficient? What about using a hashed instance name instead?

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed stale LXC's 63-character instance-name limit blocked snapcraft pack; no fix was recorded, and the dormant report was closed as stale.
stealth/space-bunny-alpha — closed stale Closed as stale after inactivity; no fixing PR or commit is linked. The only follow-up identified the same instance-name length failure in Charmcraft #629.
stealth/space-bunny-alpha — closed stale Closed without a recorded Snapcraft fix; matching LaunchPad #1981205 was abandoned. Craft-providers PR #134 independently added hashed, 63-character-safe LXD names.
qwen/qwen3.6-35b-a3b — — Abandoned. The LXC instance name length violation was not addressed, and the proposed hashed naming approach was not implemented.
qwen/qwen3.6-35b-a3b — — Abandoned without resolution. Snapcraft generated LXC instance names exceeding the 63-character limit, causing launch failures. The suggested hashed naming approach was not implemented.
qwen/qwen3.6-35b-a3b — — Closed without resolution. Snapcraft generated LXC instance names exceeding the 63-character limit, causing pack failures. A hashed naming solution was suggested but never implemented. The report was abandoned due to inactivity.
qwen3.6-35b-a3b-mtp-q6 — — Closed without resolution. Snapcraft generated LXC instance names exceeding the 63-character limit, causing pack failures. The author suggested hashing names, but no fix was implemented.

Update history

Date Change
created

Related work

  • Related To: canonical/charmcraft#629 (confidence 100%)

    The sole comment explicitly identifies it as the same issue in Charmcraft.

Related issues

Issue Project State Summary Similarity
#1999321 Snapcraft is stuck on "launching instance..." indefinitely snapcraft (launchpad) open Endless LXD startup on failed container DNS now times out via craft-providers; Snapcraft 7.5.4 is recorded as fixing the wait. Multipass arm64 and Docker diagnostics remain separately tracked.
75%
#1590620 snapcraft can generage snaps with a name longer than 107 characters snapcraft (launchpad) open Snapcraft still accepts overlong snap names during project validation, allowing builds that the Store later rejects; the maintainer discussed shorter limits, but global enforcement is absent.
75%