我用的是perlbrew和cpanm。在执行cpanm Test::More时,我得到以下内容:
--> Working on Test::More
Fetching http://10.64.0.7:8002/authors/id/L/LO/LOCAL/Test-Simple-1.001003.tar.gz ... OK
Configuring Test-Simple-1.001003 ... OK
Building and testing Test-Simple-1.001003 ... OK
Successfully installed Test-Simple-1.001003 (upgraded from 0.98)
cannot unlink file for /home/hamid/.cpanm/work/1406642140.19670/build.log: Permission denied at /loader/0x1bdc0a8/App/cpanminus/script.pm line 99
cannot restore permissions to 0100644 for /home/hamid/.cpanm/work/1406642140.19670/build.log: Permission denied at /loader/0x1bdc0a8/App/cpanminus/script.pm line 99
cannot remove directory for /home/hamid/.cpanm/work/1406642140.19670: Directory not empty at /loader/0x1bdc0a8/App/cpanminus/script.pm line 99
1 distribution installed有人能告诉我为什么我会得到cannot unlink file, cannot restore permissions and cannot remove directory错误吗?
更改/home/hamid/.cpanm/work上的权限是否是解决该问题的明智解决方案?
谢谢
发布于 2014-08-07 09:44:25
您可能在某个时候以根用户身份运行cpanm,并通过这样做更改了本地目录中的权限。你可以通过以下方式解决这个问题:
sudo chown -R hamid:hamid ~/.cpanm那它应该又能正常工作了。
https://stackoverflow.com/questions/25179074
复制相似问题