纯小白新手嫩芽刚刚接触LINUX,处女地首先探索ubuntu,version:21,最新版,跟着老师学习SSH链接,做远程操作时发现问题,现在解决问题过程如下。
1.putty链接出现--network error connection refusesed
2.~$sudo apt-get install openssh-server
3.出现错误
4.~$sudo apt-get install yum
5.出现错误
6.~$sudo vim /etc/apt/sources.list
7.i插入模式-粘贴最下方,删除多余字符和横线,esc,:wq
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security multiverse
8.~$sudo apt-get update
9.~$sudo apt-get install mlocate
10.~$sudo apt-get install openssh-server
11.可以连了