在CentOS6.5上的安装Anaconda3

1、下载Anaconda

版本Anaconda3-5.2.0
https://mirrors.tuna.tsinghua.edu.cn/anaconda/archive/Anaconda3-5.2.0-Linux-x86_64.sh

2、添加可执行权限

# 添加权限的命令
chmod +x Anaconda3-5.2.0-Linux-x86_64.sh

3、安装

# 安装
./Anaconda3-5.2.0-Linux-x86_64.sh -u
或者 bash Anaconda3-5.2.0-Linux-x86_64.sh -u

# -u:为了后续更改安装目录,如果不添加“-u”,则会出现“ERROR: File or directory already exists: '/usr/local/anaconda3'
# If you want to update an existing installation, use the -u option.”问题

4、同意条款

(1)首先提示查看条款“In order to continue the installation process, please review the license
agreement. Please, press ENTER to continue”,点击Enter;
(2)查看条款后,提示“Do you accept the license terms? [yes|no]”,
输入:yes,进入下一步。

5、修改自定义目录

修改自定义目录之前提示"
Anaconda3 will now be installed into this location:
/root/anaconda3
  - Press ENTER to confirm the location
  - Press CTRL-C to abort the installation
  - Or specify a different location below
 "
# 修改自定义目录
[/root/anaconda3] >>> /usr/local/anaconda3

6、设置配置路径

“Do you wish the installer to prepend the Anaconda3 install location
to PATH in your /root/.bashrc ?”
输入:yes

7、设置环境变量

1)在"/etc/profile"中的最后一行添加环境变量
# Anaconda3
export PATH=$PATH:/etc/usr/local/anaconda3/bin

# 使Python3生效
source /etc/profile

2)可以不配置环境变量,在/usr/bin下添加软连接
# ln -s 源文件/目录 目标文件/目录
ln -s /usr/local/anaconda3/bin/python3 /usr/bin/python3

8、测试

# 测试,默认是python2,使用python3
python3

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值