我尝试通过以下方式停止所有Docker容器:
docker stop $(docker ps -q)
但是,这是输出:
docker ps -q: command not found
docker stop : command not found
同样适用于:
docker rm $(docker ps -aq)
输出如下:
docker ps -aq: command not found
docker rm : command not found
This论坛答案概述了apt-get更新和apt-get安装过程可以帮助使其正常运行。但是,这导致以下错误消息:
E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied)
E: Unable to lock directory /var/lib/apt/lists/
W: Problem unlinking the file /var/cache/apt/pkgcache.bin - RemoveCaches (13: Permission denied)
W: Problem unlinking the file /var/cache/apt/srcpkgcache.bin - RemoveCaches (13: Permission denied)
我正在使用Linux的Windows子系统,并在Visual Studio Code中执行它。 谢谢您的帮助!