rm:无法删除“.vscode-server/bin/xxxxxx/.nfs000000000xxxxxxxxxxxx":设备或资源繁忙 [英] rm: cannot remove ‘.vscode-server/bin/xxxxxx/.nfs000000000xxxxxxxxxxxx’: Device or resource busy

查看:159
本文介绍了rm:无法删除“.vscode-server/bin/xxxxxx/.nfs000000000xxxxxxxxxxxx":设备或资源繁忙的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

从客户端删除visual code studio(vscode)远程ssh后出现问题.通过卸载远程 SSH 尝试释放主机上占用的内存.

解决方案

我了解到 .vscode_server/下的文件夹有两个子文件夹,我想删除该文件夹,因为某些扩展占用了太多空间,这是

><块引用>

rm -rf .vscode-server/

rm:无法删除‘.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs000000000428ac6a000005ce’:设备或资源繁忙rm:无法删除.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs0000000006b42642000005f6":设备或资源繁忙rm:无法删除.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs0000000006c122f3000005fe":设备或资源繁忙rm:无法删除.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs000000000609731e00000607":设备或资源繁忙rm:无法删除.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs000000000154ec5400000623":设备或资源繁忙rm:无法删除.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs00000000015e1f560000062d":设备或资源繁忙rm:无法删除.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs0000000007fa221c00000632":设备或资源繁忙rm:无法删除.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs00000000011f979d00000643":设备或资源繁忙

...这里有很多行...

<块引用>

cd .vscode-server/

<块引用>

ls

<块引用>

bin/扩展/

<块引用>

CD 扩展

<块引用>

ls

<块引用>

ms-vscode.cpptools-0.26.3

<块引用>

cd ms-vscode.cpptools-0.26.3

<块引用>

ls

<块引用>

bin

<块引用>

ls

<块引用>

.nfs0000000005615fa900000b1b* .nfs0000000005615faa00000b1c*

<块引用>

rm -rf .nfs0000000005615fa900000b1b

rm:无法删除‘.nfs0000000005615fa900000b1b’:设备或资源繁忙

<块引用>

lsof .nfs0000000005615fa900000b1b**

命令 PID 用户 FD 类型设备大小/关闭节点名称

Microsoft 966 xxxxxx txt REG 0,40 14250189 90267561 .nfs0000000005615fa900000b1b

Microsoft 1145 xxxxxx txt REG 0,40 14250189 90267561 .nfs0000000005615fa900000b1b

Microsoft 1642 xxxxxx txt REG 0,40 14250189 90267561 .nfs0000000005615fa900000b1b

.... 这里有很多行....

这里我用notepad++杀掉了所有正在运行的子进程

<块引用>

杀死 -9 966

<块引用>

杀死 -9 1145

<块引用>

杀死 -9 1642

...等

所以最后删除了 .nfs0000000005615fa900000b1b 进程

您需要对所有流程都这样做,但要从子流程开始.我相信一些天才会有效而快速地做到这一点.但我很高兴我终于可以摆脱 .vscode-server 文件夹.

希望这对您有所帮助!

the problem occurred after removing visual code studio (vscode) remote ssh from the client. By uninstalling Remote SSH in an attempt was done to free up memory taken on host computer.

解决方案

I learnt that the folder under .vscode_server/ have two subfolder and I wanted to remove the folder since the some extentions was taking too much space, it was

rm -rf .vscode-server/

rm: cannot remove ‘.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs000000000428ac6a000005ce’: Device or resource busy rm: cannot remove ‘.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs0000000006b42642000005f6’: Device or resource busy rm: cannot remove ‘.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs0000000006c122f3000005fe’: Device or resource busy rm: cannot remove ‘.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs000000000609731e00000607’: Device or resource busy rm: cannot remove ‘.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs000000000154ec5400000623’: Device or resource busy rm: cannot remove ‘.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs00000000015e1f560000062d’: Device or resource busy rm: cannot remove ‘.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs0000000007fa221c00000632’: Device or resource busy rm: cannot remove ‘.vscode-server/bin/c47d83b293181d9be64f27ff093689e8e7aed054/.nfs00000000011f979d00000643’: Device or resource busy

... many lines here ...

cd .vscode-server/

ls

bin/ extensions/

cd extensions

ls

ms-vscode.cpptools-0.26.3

cd ms-vscode.cpptools-0.26.3

ls

bin

ls

.nfs0000000005615fa900000b1b* .nfs0000000005615faa00000b1c*

rm -rf .nfs0000000005615fa900000b1b

rm: cannot remove ‘.nfs0000000005615fa900000b1b’: Device or resource busy

lsof .nfs0000000005615fa900000b1b**

COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME

Microsoft 966 xxxxxx txt REG 0,40 14250189 90267561 .nfs0000000005615fa900000b1b

Microsoft 1145 xxxxxx txt REG 0,40 14250189 90267561 .nfs0000000005615fa900000b1b

Microsoft 1642 xxxxxx txt REG 0,40 14250189 90267561 .nfs0000000005615fa900000b1b

.... many line here ....

Here I used notepad++ to kill all sub-process running

kill -9 966

kill -9 1145

kill -9 1642

... etc

so finally the process .nfs0000000005615fa900000b1b was removed

you need to that for all process but start from the subprocesses. I am sure some genius will do this effectively and fast. But I was happy that I finally could get rid of .vscode-server folder.

Hope this was helpful!

这篇关于rm:无法删除“.vscode-server/bin/xxxxxx/.nfs000000000xxxxxxxxxxxx":设备或资源繁忙的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆