是否可以在 google colab 的 VM 中挂载 squashfs 文件?

Is it possible to mount a squashfs file in google colab's VM?

在 Google Colab Notebook 中,您可以执行任意 bash 命令,方法是在行前加上 ! 前缀或在块开头加上 %%shell。在 Ubuntu 18.04 VM 运行 notebook 中,您有相当大的自由权限可以做任何您想做的事情,允许您下载和安装不同的程序。

我想创建并挂载一个 squashfs 文件,但是挂载它给我一个 operation not permitted.

%%shell
apt-get update && apt-get install -y squashfs-tools
mksquashfs sample_data sample_data.sqsh
mount sample_data.sqsh /root/content/using_sqsh -t squashfs -o loop

我可以做些什么来提升我的权限吗?或者在他们的基础设施上根本不允许安装?我如何检查确切地不允许知道是否可以可以

备注:

您可以使用 cat /proc/1/cgroup to confirm that the Colab VM is a docker container, docker containers are not able to mount anything in unprivileged mode (the default), and running in privileged mode would be a security issue.

因此,无法在 Google Colab VM 中挂载 squashfs 文件(或其他任何文件)。