一般系统安装好后,按照自己习惯定义
#alias echo "alias cdyum=‘cd /etc/yum.repos.d/‘" >> /root/.bashrc echo "alias cdnet=‘cd /etc/sysconfig/network-scripts/‘" >> /root/.bashrc source /root/.bashrc #hosts echo ‘192.168.26.250 rhvm.rhce.cc rhvm‘ >> /etc/hosts #firewall systemctl stop firewalld systemctl disable firewalld #selinux [ `getenforce` != "Disabled" ] && setenforce 0 &> /dev/null && sed -i s/"^SELINUX=.*$"/"SELINUX=disabled"/g /etc/sysconfig/selinux #set yum repo cat << EOF > /etc/yum.repos.d/rhel.repo [rhel] name=rhel baseurl=file:///mnt enabled=1 gpgcheck=0 EOF mount /dev/cdrom /mnt yum clean all yum install vsftpd createrepo -y systemctl start vsftpd;systemctl enable vsftpd
原文:https://www.cnblogs.com/reid21/p/10630212.html