#从本地上传文件到服务器
scp -r .\name_gene.csv root@122.23.344..324:/home/data
#用key无密码登录服务器
第一步:在本地机器上使用ssh-keygen产生公钥私钥对
$ ssh-keygen
第二步:用ssh-copy-id将公钥复制到远程机器中
$ ssh-copy-id -i .ssh/id_rsa.pub 用户名字@192.168.x.xxx
注意: ssh-copy-id 将key写到远程机器的 ~/ .ssh/authorized_key.文件中
第三步: 登录到远程机器不用输入密码
$ ssh 用户名字@192.168.x.xxx
Last login: Sun Nov 16 17:22:33 2008 from 192.168.1.2
常见问题:
ssh-copy-id -u eucalyptus -i ~eucalyptus/.ssh/id_rsa.pub ssh 用户名字@192.168.x.xxx
第一次需要密码登录
function ssh-copy-id([string]$userAtMachine, $args){
$publicKey = "$ENV:USERPROFILE" + "/.ssh/id_rsa.pub"
if (!(Test-Path "$publicKey")){
Write-Error "ERROR: failed to open ID file '$publicKey': No such file"
}
else {
& cat "$publicKey" | ssh $args $userAtMachine "umask 077; test -d .ssh || mkdir .ssh ; cat >> .ssh/authorized_keys || exit 1"
}
}
linux安装minconda
下载安装包并安装
wget https://mirrors.bfsu.edu.cn/anaconda/miniconda/Miniconda3-py37_4.8.3-Linux-x86_64.sh
sh Miniconda3-py37_4.8.3-Linux-x86_64.sh
https://repo.anaconda.com/miniconda/Miniconda3-py311_23.5.2-0-Linux-x86_64.sh
按照提示完成安装
添加北外源
conda config --add channels https://mirrors.bfsu.edu.cn/anaconda/pkgs/free/
conda config --add channels https://mirrors.bfsu.edu.cn/anaconda/cloud/bioconda/
conda config --add channels https://mirrors.bfsu.edu.cn/anaconda/cloud/msys2/
conda config --add channels https://mirrors.bfsu.edu.cn/anaconda/cloud/menpo/
conda config --add channels https://mirrors.bfsu.edu.cn/anaconda/cloud/peterjc123/
conda config --add channels https://mirrors.bfsu.edu.cn/anaconda/pkgs/main/
conda config --add channels https://mirrors.bfsu.edu.cn/anaconda/cloud/conda-forge/
conda config --add channels https://mirrors.bfsu.edu.cn/anaconda/cloud/pytorch/
conda config --add channels https://mirrors.bfsu.edu.cn/anaconda/pkgs/r/
conda config --set show_channel_urls yes
安装一些python常用的包
conda install matplotlib numpy seaborn xlsxwriter mysql-connector-python xlwt gxx_linux-64 mysql pysam
nano ~/.bashrc
export PATH="$HOME/miniconda3/bin:$PATH"
ctrll+x y
source ~/.bashrc
sudo adduser <username>
sudo cat /etc/passwd