无法创建快照,快照命令失败

问题描述

我正在尝试构建一个 snap,我已经使用 Flutter 来构建应用程序。在创建 snap 包时出现错误

Staging Flutter-extension 
+ snapcraftctl stage
Staging gnome-3-28-extension 
+ snapcraftctl stage
Staging system-information 
+ snapcraftctl stage
Priming Flutter-extension 
+ snapcraftctl prime
Priming gnome-3-28-extension 
+ snapcraftctl prime
Priming system-information 
+ snapcraftctl prime
The command 'system_information' for 'system_information' was resolved to 'bin/system_information'.
The command 'system_information' has been changed to 'bin/system_information'.
Snapping |                                                                                                   
Failed to create snap,snap command Failed:
stdout:

stderr:
error: cannot pack "/root/prime": mksquashfs call Failed: Could not create destination file: Operation not permitted

We would appreciate it if you anonymously reported this issue.
No other data than the traceback and the version of snapcraft in use will be sent.
Would you like to send this error data? (Yes/No/Always/View) [no]: no
snapcraft-system-information # 

我已经尝试过 snapcraft clean 但它没有解决问题。

解决方法

删除构建目录并重新构建。

按照这个github链接了解详细信息 https://github.com/EOSIO/eos/issues/4885

,

实际上,错误是由我用来构建 snap 包的 multipass 产生的。我尝试删除 /build 并再次构建,但没有奏效。

我找到了另一种使用 lxd 构建快照的方法