今天也是记流水账的一天,下载安装了 conda ,了解了一下 conda 环境,今天的任务还挺轻松的,但是让我对linux服务器上的软件安装好像认识得更直观了一点点。不过还是不完全明白,我们在服务器上能调用哪些范围内的软件?比如一个组每个同学有自己的账号,但是大家的目录都在课题组目录下,组里别的同学下载安装的软件我也能用,这是为什么呢,我们能调用到哪个层级的目录下的软件是取决于什么呀?
- 登录服务器,查看服务器是多少位的,
bio04@VM-0-6-ubuntu:~$ uname -a Linux VM-0-6-ubuntu 4.15.0-118-generic #119-Ubuntu SMP Tue Sep 8 12:30:01 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
- 看样子是 64 位的,然后去找miniconda for Linux 64的最新版本,顺利下载到了 biosoft 目录下
bio04@VM-0-6-ubuntu:~/biosoft$ wget https://mirrors.tuna.tsinghua.edu.cn/anaconda/miniconda/Miniconda3-latest-Linux-x86_64.sh --2022-05-11 17:50:14-- https://mirrors.tuna.tsinghua.edu.cn/anaconda/miniconda/Miniconda3-latest-Linux-x86_64.sh Resolving mirrors.tuna.tsinghua.edu.cn (mirrors.tuna.tsinghua.edu.cn)... 101.6.15.130, 2402:f000:1:400::2 Connecting to mirrors.tuna.tsinghua.edu.cn (mirrors.tuna.tsinghua.edu.cn)|101.6.15.130|:443... connected. HTTP request sent, awaiting response... 200 OK Length: 75660608 (72M) [application/octet-stream] Saving to: ‘Miniconda3-latest-Linux-x86_64.sh’ Miniconda3-latest-Linux-x86_64.sh 100%[==================================================================================>] 72.16M 1.19MB/s in 70s 2022-05-11 17:51:25 (1.03 MB/s) - ‘Miniconda3-latest-Linux-x86_64.sh’ saved [75660608/75660608]
- 重要步骤之安装
输入bash Miniconda3-latest-Linux-x86_64.sh
之后enter了超多遍过了很多条款,终于到了Do you accept the license terms? [yes|no]
,yes
了两下,成功安装!==> For changes to take effect, close and re-open your current shell. <== If you'd prefer that conda's base environment not be activated on startup, set the auto_activate_base parameter to false: conda config --set auto_activate_base false Thank you for installing Miniconda3! ```
- 重要步骤之激活
听话地关闭了 Xshell 重新打开,结果发现没注意把conda3 安装到 biosoft 下,一不小心直接安装到了自己的主目录下。问题不大,继续激活。直接在主目录下输入source ~/.bashrc
,之后在随便哪个文件夹下输入conda都能出来conda的基本信息,不太懂它的作用范围,查了一下安装路径,是在conda里面,所以是在我的主目录下都可以调用的意思吗?(base) bio04@VM-0-6-ubuntu:~/tmp$ whereis conda conda: /home/bio04/miniconda3/bin/conda /home/bio04/miniconda3/condabin/conda
- 添加镜像:输入后没有什么反馈,应该就没事了吧
- 正式使用conda:
试了不加-y
直接conda install fastqc
,结果就是自己输了一个y
,别的似乎没啥,试了一些fastqc -help
能看到帮助文档,到这里就安装好 fastqc 啦,也顺便看了看它安装到了哪里(base) bio04@VM-0-6-ubuntu:~$ whereis fastqc fastqc: /home/bio04/miniconda3/bin/fastqc
- conda环境
(base) bio04@VM-0-6-ubuntu:~$ conda info --envs # conda environments: # base * /home/bio04/miniconda3 (base) bio04@VM-0-6-ubuntu:~$ conda create -n rna-seq python=3 fastqc trimmomatic -y (base) bio04@VM-0-6-ubuntu:~$ conda info --envs # conda environments: # base * /home/bio04/miniconda3 rna-seq /home/bio04/miniconda3/envs/rna-seq (base) bio04@VM-0-6-ubuntu:~$ conda activate rna-seq (rna-seq) bio04@VM-0-6-ubuntu:~$ conda info --envs # conda environments: # base /home/bio04/miniconda3 rna-seq * /home/bio04/miniconda3/envs/rna-seq
- 见识了一次掉线)
Socket error Event: 32 Error: 10053. Connection closing...Socket close. Connection closed by foreign host. Disconnected from remote host(linux) at 19:58:12. Type `help' to learn how to use Xshell prompt. [D:\~]$
那就到这里吧~
网友评论