I am trying to catch up on creating snaps during my summer vacation and have run into a bit of trouble. I run Windows 10 and use the Quick Create images for Hyper-V for both 18.04.2 LTS and 19.04. Clean default installation with the only change is to use Swedish keyboard and timezone set to “Stockholm”.
In both versions, when the first login wizard is done, I open the application store and try to install the “Visual Studio Code” snap. In both cases it fails with the message “error: too early for operation, device not yet seeded or device model not acknowledged”.
Any tries to use “sudo snap install” from the terminal fails with the same message.
Doing a “sudo apt purge snapd” followed by a “sudo apt install snapd” solves this issue in both cases.
The problem is that I am trying to learn using Ubuntu Core and baking my own images, and the Ubuntu Core image is creating using this guide:
The Ubuntu Core installation created is having the exact same problem, so required snaps in the image is not being installed and further snaps can’t be installed through ssh.
Something seems to be bricked with default installation and snapd.
have you tried with an existing ubuntu core image yet ? in general these are well tested (though typically used on embedded devices and IoT gateways, i doubt many people actually use them in a VM in production)
When you tell the tools to create an image with pre-installed (seeded) snaps, you need to specify all the dependencies by hand. Otherwise the resulting seed.yaml will be invalid and snapd won’t be able to start up.
Edit to add: for example, if you specify kanagram as an additional snap, you need to also ask for kde-frameworks-5-core18 and core18.
I just followed the guide and the only slaps added to the Ubuntu Core image is “hello” and “hello-world” as by the example. I can’t see that there is any dependencies that could cause such a problem.
well, typically seeding snaps in core images happens through the required-snaps: entry in the model assertion, it is pretty rare that you have actual dependencies beyond core or core18 itself here … (no graphical env on core makes most framework snaps moot)
but if you seed a snap using core on a core18 image you need to also seed core in required-snaps. i assume this is the issue here.
That worked! Thanx @ogra. Those issues with Hyper-V just had me going it was the same issue with the Core image. Now I can get around it on the Hyper-V images by purging and the Core image is built and up and working and I can move forward and try to get my own snap into it.
Many thanx! Too many landmines being a newbie on this. I wouldn’t have solved it by myself without someone removing the blindfold from my eyes.
I just encountered that error a few moments ago on my garuda linux - arch based distro uh… and these comments were for ubuntu and debian i tried to figure it out by myself and this is what worked for me :
sudo systemctl status snapd.seeded.service, it should give u this
○ snapd.seeded.service - Wait until snapd is fully seeded
Loaded: loaded (/usr/lib/systemd/system/snapd.seeded.service; disabled; preset: disabled)
Active: inactive (dead)
even if u get something different its ok this next command wont give out harm to snap…
sudo systemctl restart snapd.seeded.service and
sudo systemctl restart snapd.service
Perfect! Tried several things before, but the restart of the snapd.seeded.service I think did the trick for me. Ubuntu 23.10, fresh snapd 16-2.60.4 install from apt.