Blocking waiting for file lock on the registry index 问题解决

问题表现:

cargo build时一直卡在Blocking waiting for file lock on the registry index。

解决方法:

1、之前在linux下出现过一次,采用这种方法解决了:rust - Cargo build hangs with " Blocking waiting for file lock on the registry index" after building parity from source - Stack Overflow

复制代码
rm -rf ~/.cargo/registry/index/* ~/.cargo/.package-cache

2、这次出现在windows上,按道理删除对应的文件夹也能解决。

但是想到既然显示的文件锁被占用,肯定是被其他进程占了,只需要把对应进程杀掉就好。

首先找到被占用的文件夹:

然后查找是谁占用它的

把这些进程都杀掉,问题解决!

相关推荐
xjz18421 天前
Rust 用 `&&`、`||`、`!` 把条件组合起来
rust
不积跬步无以至千里mmbb261 天前
Rust三大核心:Trait Crate Mod详解
linux·rust
SomeOtherTime1 天前
第 2 讲:借用检查器(Borrow Checker)的数学本质——读写锁的编译期化、非词法生命周期(NLL)与重借用(Reborrowing)
rust
xjz18422 天前
Rust 的else:把「做不做」升级成「二选一」
rust
喵个咪2 天前
RushWind Admin — update_mask 写面:字段级白名单、显式清除与点路径合并
后端·rust
喵个咪2 天前
RushWind Admin — 多租户行级隔离与租户回收站:Viewer 三态、repo_shell! 与全域级联清除
后端·rust
喵个咪2 天前
RushWind CMS — 三服务拓扑:core 领域层、双 BFF 薄代理与一份契约的双面输出
后端·rust
不积跬步无以至千里mmbb262 天前
Rust内核开发核心入口解析
linux·rust
wflynn3 天前
GitHub 今日推荐|rust-anything:录制真实输入输出,渐进式重写热点函数到 Rust
rust·开源·github·cli·claude-code·agent-skills
风笙9784 天前
[Rust] String 与 &str 详解
rust