Multipass authentication preventing snap building

Hi all, I am trying to update my snap with snapcraft, however it seems there is a problem with Multipass. I have no idea what is going on here - I don’t know what Multipass is or why it is important, and what the error messages mean.

Up to now I have not had to locally authenticate with anything whilst making my snap.

All help gratefully received!

cheers Alan

 snapcraft --debug
Snapping photonotebook
Launching a VM.
Build environment is in unknown state, cleaning first.
ERROR: ld.so: object 'libgtk3-nocsd.so.0' from LD_PRELOAD cannot be preloaded (failed to map segment from shared object): ignored.
info failed: The client is not authenticated with the Multipass service.
Please use 'multipass authenticate' before proceeding.
ERROR: ld.so: object 'libgtk3-nocsd.so.0' from LD_PRELOAD cannot be preloaded (failed to map segment from shared object): ignored.
launch failed: The client is not authenticated with the Multipass service.      
Please use 'multipass authenticate' before proceeding.
An error occurred with the instance when trying to launch with 'multipass': returned exit code 2.
Ensure that 'multipass' is setup correctly and try again.

I have the same issue, it is not ideal, but as a workaround I just launch an instance manualy in another window with the command below, then I run the snapcraft command in a different window and it does not throw the error.

multipass launch --name foo

I hope this helps.

@townsend looks like LD_PRELOAD is messing up. I wonder if snap-confine should clear this envvar, @mvo?

Hey All,

It looks like the Multipass client cert is messed up. Please try following the directions at https://discourse.ubuntu.com/t/unable-to-authorize-the-client-and-cannot-set-a-passphrase-workaround/28321 to hopefully work around this issue.

Thanks!

Also, if snapcraft is running under a different user than you normally use Multipass with, then you need to set a passphrase via:

$ multipass set local.passphrase

and then with the user that is running a client that is not authenticated, run:

$ multipass authenticate

and provide the passphrase you just set.

Hi, tried that earlier and again just now at your suggestions. No change, so I got rid of multipass and gotthe latest stable version installed, and all so far ok.

Lets see if it still works after shutdown / re-boot!

I still get multiple LD_PRELOAD errors, but they do not seem to interfere with the building of the snap.

cheers and thanks

Alan