Centos更换yum源,安装ssh server


先连上网,然后更换yum源

1. 新建的用户没有sudo权限,所以首先切换到root用户
su -
输入密码

2. 备份之前的yum源
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup

3. 下载yum源centos6
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo

4. 清理并生成缓存
yum clean all
yum makecache

 

安装ssh server

$ yum search ssh
$ yum install openssh-server
$ chkconfig --list sshd
sshd      0:off    1:off    2:on    3:on    4:on    5:on    6:off

  


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM