您的位置:首页 > 运维架构 > Linux

问题集锦

2016-09-06 11:53 369 查看

问题集锦

Linux上传下载工具rzsz

# yum install –y lrzsz

# rz #导入文件
#sz #导出文件
1.虚拟机yum源问题
[root@centos ~]# yum install -y openssh-clients
Loaded plugins: fastestmirror, security
Determining fastest mirrors
Error: Cannot retrieve metalink for repository: epel. Please verify its path and try again
解决方法;
[root@centos ~]# cd /etc/yum.repos.d/
[root@centos yum.repos.d]# ls
CentOS-Base.repo CentOS-Media.repo epel-6.repo epel-testing.repo
CentOS-Debuginfo.repo CentOS-Vault.repo epel.repo
[root@centos yum.repos.d]# mv epel.repo epel.repobak
[root@centos yum.repos.d]# yum list httpd
Loaded plugins: fastestmirror, security
Loading mirror speeds from cached hostfile
* base: mirror.bit.edu.cn
* extras: mirror.bit.edu.cn
* updates: mirror.bit.edu.cn
base | 3.7 kB 00:00
base/primary_db | 4.7 MB 00:00
2.ubuntu命令
yum命令
root@shixisheng-test-1:~# apt-get install vim
Reading package lists... Done
Building dependency tree
Reading state information... Done
vim is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 57 not upgraded.
主机名命令
root@shixisheng-test-1:~# hostname
shixisheng-test-1
root@shixisheng-test-1:~# uname -n
shixisheng-test-1
主机名永久修改/etc/hostname
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  linux基础