【已解决】执行conda init提示No action taken.

执行conda init报错:

复制代码
root@autodl-container:~/autodl-tmp/llm-convrec# source base
-bash: base: No such file or directory
root@autodl-container:~/autodl-tmp/llm-convrec# conda init
no change     /root/miniconda3/condabin/conda
no change     /root/miniconda3/bin/conda
no change     /root/miniconda3/bin/conda-env
no change     /root/miniconda3/bin/activate
no change     /root/miniconda3/bin/deactivate
no change     /root/miniconda3/etc/profile.d/conda.sh
no change     /root/miniconda3/etc/fish/conf.d/conda.fish
no change     /root/miniconda3/shell/condabin/Conda.psm1
no change     /root/miniconda3/shell/condabin/conda-hook.ps1
no change     /root/miniconda3/lib/python3.12/site-packages/xontrib/conda.xsh
no change     /root/miniconda3/etc/profile.d/conda.csh
no change     /root/.bashrc
No action taken.

解决办法:直接执行 Conda 自带的初始化脚本,无需重启终端即可临时激活 Conda 环境:

bash 复制代码
source /root/miniconda3/etc/profile.d/conda.sh

执行后,再次尝试激活 base 环境:

bash 复制代码
conda activate base

最后激活新建环境。

相关推荐
砍材农夫17 天前
python环境|conda安装和使用(1)
开发语言·后端·python·conda
匆匆整棹还17 天前
mamba的安装和版本对应
conda
2601_9618752418 天前
花生十三资料1200题|题库|刷题
conda·pytest·pillow·pip·web3.py·ipython·gunicorn
没有钱的钱仔18 天前
自动创建conda虚拟环境,并安装依赖包
conda
砍材农夫20 天前
python环境|pip|uv|venv|Conda区别
后端·python·conda·pip·uv
pixelpilot120 天前
Conda:跨平台的二进制包管理器
其他·conda
lg_cool_21 天前
使用conda管理python运行环境并关联vscode
vscode·python·conda
javajenius21 天前
Pixi:用 Rust 重写 Conda 体验的包管理工具
开发语言·其他·rust·conda
小白弄潮儿21 天前
Conda 使用入门指南
conda
DFT计算杂谈21 天前
WannierTools输入文件wt.in一键批量生成脚本
java·前端·chrome·python·算法·conda