当前位置:网站首页>conda新建环境时报错NotWritableError: The current user does not have write permissions
conda新建环境时报错NotWritableError: The current user does not have write permissions
2022-08-09 22:44:00 【passion-ma】
在使用
conda create -n environment_name命令新建环境时,遇到错误:
Solving environment: failed
NotWritableError: The curren user does not have write permissions to a required path.
path: /home/user_name/.conda/pkgs/urls.txt
uid: 1021
gid: 1021If you feel that permissions on this path are set incorrectly, you can manually
change them by executing$ sudo chown 1021:1021 /home/user_name/.conda/pkgs/urls.txt
In general, it's not advisable to use 'sudo conda'.
2、问题原因
也许是安装Anaconda的时候,使用了sudo sh Ana...造成的多余问题。
安装Anaconda的时候使用了root权限,所以现在非root用户没有对anaconda3文件夹的读写权限。
3、解决方案
方案一:
'cd' 到 'annoconda3' 文件夹所在位置,运行以下命令:
sudo chown -R username anaconda3 #username为自己的用户名
方案二:
按照他给出的提示操作无果,于是使用下面的命令改变conda相关文件夹的权限,-r递归应用于子文件夹
sudo chmod 777 -R ~/anaconda3/
sudo chmod 777 -R ~/.conda/
4、测试
使用方案一对我的问题无效,但是有网友说是可行的。
方案二成功地解决了我的问题,可以新建环境了。
Solving environment: done
边栏推荐
猜你喜欢

下班后用微信处理工作时发病身亡,法院判决:工伤!
![[Interface Test] Decoding the request body string of the requests library](/img/99/82ef792dacd398a8a62dd94f235a91.png)
[Interface Test] Decoding the request body string of the requests library

如何正则匹配乱码?

In-depth understanding of multithreading (Part 1)
![[Cloud Native] This article explains how to add Tencent Crane to Kubevela addon](/img/42/384caec048e02f01461292afc931be.jpg)
[Cloud Native] This article explains how to add Tencent Crane to Kubevela addon

【云原生】一文讲透Kubevela addon如何添加腾讯Crane

高手这样看现货白银走势图

【SSL集训DAY2】有趣的数【数位DP】

防火墙之系统防护

ES6 从入门到精通 # 14:迭代器 Iterator 的用法
随机推荐
探索TiDB Lightning源码来解决发现的bug
ES6 从入门到精通 # 15:生成器 Generator 的用法
6款跨境电商常用工具汇总
《动手学深度学习》(八) -- 多尺度标检测和单发多框检测
【云原生】一文讲透Kubevela addon如何添加腾讯Crane
南大通用数据库-Gbase-8a-学习-04-部署分布式集群
[JZOF] 82 binary tree with a path of a certain value (1)
tiup cluster upgrade
Gartner全球集成系统市场数据追踪,超融合市场增速第一
后台管理实现导入导出
数据库优化 | 干货
Click: 377. Combined Sum Ⅳ
【哲理】读书的意义
LiveData : Transformations.map and Transformations.switchMap usage
【SSL集训DAY2】有趣的数【数位DP】
联盟链技术应用的难点
基于 RocksDB 实现高可靠、低时延的 MQTT 数据持久化
力扣:279.完全平方数
正则表达式的实际使用
61.【快速排序法详解】