`juju deploy $LOCAL_CHARM` is very slow on arm64

Bug #1991967 reported by Simon Déziel
This bug report is a duplicate of:  Bug #1987684: juju deploy is too slow. Edit Remove
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Canonical Juju
New
Undecided
Unassigned

Bug Description

Back in August 2022, I reported that `juju deploy`'ing a local charm was slow:

```
$ ll -h lxd-cloud-cell_ubuntu-22.04-amd64.charm lxd-cloud-cell_0+git.d27fa0c_amd64.snap
-rw-rw-r-- 1 sdeziel sdeziel 20M Aug 2 22:02 lxd-cloud-cell_0+git.d27fa0c_amd64.snap
-rw-r--r-- 1 sdeziel sdeziel 5.8M Aug 17 19:17 lxd-cloud-cell_ubuntu-22.04-amd64.charm

$ time juju deploy ./lxd-cloud-cell_ubuntu-22.04-amd64.charm cell-b --resource snap=lxd-cloud-cell_0+git.d27fa0c_amd64.snap -n 3 --to 22,23,24
Located local charm "lxd-cloud-cell", revision 10
Deploying "cell-b" from local charm "lxd-cloud-cell", revision 10 on jammy

real 1m31.175s
user 0m3.435s
sys 0m5.517s
```

I don't know which Juju version that was but now with Juju 2.9.34, this is way worse even with a smaller charm not using any resource:

```
sdeziel@shell01:~$ ls -lh ./lxd_ubuntu-20.04-amd64.charm && time juju deploy --debug -m test ./lxd_ubuntu-20.04-amd64.charm
-rw-r--r-- 1 sdeziel sdeziel 11M Oct 5 21:00 ./lxd_ubuntu-20.04-amd64.charm

14:46:34 INFO juju.cmd supercommand.go:56 running juju [2.9.34 20b8212e62c5d122e63141825a7733bf66c4c5a9 gc go1.18.5]
14:46:34 DEBUG juju.cmd supercommand.go:57 args: []string{"/snap/juju/20511/bin/juju", "deploy", "--debug", "-m", "test", "./lxd_ubuntu-20.04-amd64.charm"}
14:46:34 INFO juju.juju api.go:78 connecting to API addresses: [172.17.40.60:17070]
14:46:34 DEBUG juju.api apiclient.go:1153 successfully dialed "wss://172.17.40.60:17070/api"
14:46:34 INFO juju.api apiclient.go:688 connection established to "wss://172.17.40.60:17070/api"
14:46:34 INFO juju.juju api.go:78 connecting to API addresses: [172.17.40.60:17070]
14:46:34 DEBUG juju.api apiclient.go:1153 successfully dialed "wss://172.17.40.60:17070/model/bab6b8e8-3e8c-40e0-8eec-118ea6a15196/api"
14:46:34 INFO juju.api apiclient.go:688 connection established to "wss://172.17.40.60:17070/model/bab6b8e8-3e8c-40e0-8eec-118ea6a15196/api"
14:46:34 DEBUG juju.core.charm computedseries.go:27 series "focal" for charm "lxd" with format 2, Kubernetes false
14:46:34 DEBUG juju.core.charm computedseries.go:27 series "focal" for charm "lxd" with format 2, Kubernetes false
14:46:34 INFO cmd charm.go:384 Preparing to deploy local charm: "lxd_ubuntu-20.04-amd64.charm"
14:53:43 INFO cmd charm.go:406 Located local charm "lxd", revision 4
14:53:47 INFO cmd charm.go:236 Deploying "lxd" from local charm "lxd", revision 4 on focal
14:53:55 DEBUG juju.api monitor.go:35 RPC connection died
14:53:55 DEBUG juju.api monitor.go:35 RPC connection died
14:53:55 INFO cmd supercommand.go:544 command finished

real 7m22.082s
user 0m0.501s
sys 0m0.414s
```

In both cases, the Juju controller is a local LXD container so the network upload of the charm shouldn't be the source of the slowness.

*Important note*: the slowness is only observed on an arm64 controller deploying to amd64 machines. The same deployment from an amd64 controller is way faster (~1 minute).

Tags: lxd-cloud
Simon Déziel (sdeziel)
description: updated
summary: - `juju deploy $LOCAL_CHARM` is very slow
+ `juju deploy $LOCAL_CHARM` is very slow on arm64
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.