Can't install or refresh snaps on Arch Linux


Perhaps that’s a case of buggy package purge in older version of the package. I think there was such a bug at some point, snap-mgmt --purge would remove stuff under /var/lib/snapd/ but state.json was left behind. That was a bunch of releases back though.

Would manually clearing device-serial in state.json unblock it?


@mborzecki I think the easiest workaround would be:

snap ack “the generic model assertion”


@_tim Can you try that?


Yes, I’d like to, but I don’t know what “the generic model assertion” is…



$ snap known --remote model model=generic-classic series=16 brand-id=generic > assertion
$ sudo snap ack assertion


Ok, did that.
Now I get:

➜  ~ sudo snap refresh 
error: cannot perform the following tasks:
- Download snap "core" (5897) from channel "stable" (no device serial yet)


Seems like there is no easy way out. Please see the output of snap changes to snap changes to check if Initialize device change appears.

If it does not then, try this:

$ systemctl stop snapd
$ sudo cat /var/lib/snapd/state.json | \
    jq 'delpaths([["data", "auth", "device"]])' > state.json-new
$ sudo cp state.json-new /var/lib/snapd/state.json
$ sudo systemctl start snapd

After a while you should see this:

$ snap changes
ID   Status  Spawn               Ready               Summary
19   Done    today at 18:29 CET  today at 18:29 CET  Initialize device


That solved the problem for me! Thanks a lot!


I see this for RPi ubuntu-core core18

“type”: “model”,
“authority-id”: “xxx”,
“brand-id”: “xxx”,
“series”: “16”,
“model”: “my-pi3”,
“architecture”: “armhf”,
“base”: “core18”,
“gadget”: “pi=18-pi3”,
“kernel”: “pi-kernel=18-pi3”,
“timestamp”: “2019-01-19T00:32:25+00:00”