Long application names cause error starting jujuc

Bug #1855603 reported by Adam Israel
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical Juju
Triaged
Low
Unassigned

Bug Description

Version:2.7.0-disco-amd64

Long application names (greater than 50 characters) are accepted by `juju deploy` but lead to errors in various stages of a charm's lifecycle.

If an application name exceeds 67 characters, the debug-log shows the following failure:

unit-app-vnf-efa45f19-3bd7-z4129-b60e-9e3229146f92-vdu-ubuntuvdu1-cnt-z0-0: 13:38:43 ERROR juju.worker.uniter.operation hook "install" failed: starting jujuc server: listening to jujuc socket: listen unix @/var/lib/juju/agents/unit-app-vnf-efa45f19-3bd7-z4129-b60e-9e3229146f92-vdu-ubuntuvdu1-cnt-z0-0/agent.socket: bind: invalid argument

Under 67 characters, but greater than 51 characters, the install hook succeeds but the collect-metrics hook fails:

unit-app-vnf-efa45f19-3bd7-z4129-b60e-9e3229146f92-vdu01-0: 11:23:32 ERROR juju.worker.dependency "metric-collect" manifold worker returned unexpected error: error running 'collect-metrics' hook: starting jujuc
server: listening to jujuc socket: listen unix @/var/lib/juju/agents/unit-app-vnf-efa45f19-3bd7-z4129-b60e-9e3229146f92-vdu01-0/metrics-collect-agent.socket: bind: invalid argument

Expected behavior:

Either the `juju deploy mycharm mycharmhasalongname-b68c67e9-229d-z4040-86c5-f4054f81dce9` should fail fast, or the hooks in question should work with the longer name.

Changed in juju:
status: New → Triaged
importance: Undecided → High
importance: High → Medium
importance: Medium → High
Revision history for this message
Yoshi Kadokawa (yoshikadokawa) wrote :

I am seeing a little bit different issue, but probably still the same cause(long application name)
I noticed this when rebooting the machine.
After the reboot, jujud unit could not start and got stuck in "agent initializing".
The following error was seen in /var/log/juju/machine-x.log

2020-07-08 10:23:01 ERROR juju.worker.dependency engine.go:663 "broker-tracker" manifold worker returned unexpected error: cannot create instance broker: creating LXD container manager: Get http://unix.socket/1.0: EOF
2020-07-08 10:23:03 ERROR juju.worker.dependency engine.go:663 "unit-agent-deployer" manifold worker returned unexpected error: remove /var/lib/juju/tools/unit-ubuntu-aaaaa-bbbbb-ccccc-ddddd-eeeee-fdcbf0ee8-0: no such file or directory

In my case, I'm seeing this when the application name is longer than 39 characters.
And here is the steps how I reproduced.

Using juju v2.7.7
1. bootstrap juju
juju bootstrap localhost
2. deploy an application with longer than 39 characters
juju deploy ubuntu ubuntu-aaaaa-bbbbb-ccccc-ddddd-eeeee-ff
3. after the deploy is completed, reboot the unit
juju run --unit ubuntu-aaaaa-bbbbb-ccccc-ddddd-eeeee-ff/0 -- sudo reboot

It looks like the systemd service name is created wrong.
$ systemctl list-unit-files | grep jujud
jujud-machine-0.service enabled
jujud-unit-ubuntu-aaa…bbbb-ccccc-ddddd-eeeee-fdcbf0ee8-0.service enabled

Revision history for this message
Canonical Juju QA Bot (juju-qa-bot) wrote :

This bug has not been updated in 2 years, so we're marking it Low importance. If you believe this is incorrect, please update the importance.

Changed in juju:
importance: High → Low
tags: added: expirebugs-bot
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.