1. 把用户添加到 sudoers 中
/etc/sudoers
2. 更改 yum 源
-
备份自带的yum源
[root@localhost ~]# mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
-
下载阿里云的 yum 源
[root@localhost ~]# wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
-
生成缓存
[root@localhost ~]# yum makecache
-
更新(更改很多软件, 需要比较长的时间)
[root@localhost ~]# yum -y update
3. 小火车
sudo wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
rpm -ivh epel-release-6-8.noarch.rpm
4. 更改网络地址
DEVICE=eth0
HWADDR=00:0C:29:5C:D8:A7
TYPE=Ethernet
UUID=96e08d83-ce04-41b2-899d-d741d58d05e8
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=static
IPADDR=192.168.2.101
GATEWAY=192.168.2.2
DNS1=192.168.2.2
5. 安装 zsh 和 oh-my-zsh
// 安装zsh
sudo yum install -y zsh
// 切换到zsh
sudo chsh -s /bin/zsh
//检查当前的shell
echo $SHELL
// 安装 oh-my-zsh
//先安装git 因为 oh-my-zsh需要git
sudo yum install -y git
wget https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O - | sh
配置 ~/.zshrc
# export PATH=$HOME/bin:/usr/local/bin:$PATH
# Path to your oh-my-zsh installation.
export ZSH=~/.oh-my-zsh
# Set name of the theme to load. Optionally, if you set this to "random"
# it'll load a random theme each time that oh-my-zsh is loaded.
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
ZSH_THEME="af-magic"
# Uncomment the following line to use case-sensitive completion.
# CASE_SENSITIVE="true"
# Uncomment the following line to use hyphen-insensitive completion. Case
# sensit