美文网首页
Ubuntu Linux 安装初始化

Ubuntu Linux 安装初始化

作者: 漂泊LFF | 来源:发表于2022-02-24 09:06 被阅读0次

    ## Sources list update

    sudo cp /etc/apt/sources.list /etc/apt/sources.list_bk

    sudo echo "deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse" >> /etc/apt/sources.list

    sudo echo "deb http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse" >> /etc/apt/sources.list

    sudo echo "deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse" >> /etc/apt/sources.list

    sudo echo "deb http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse" >> /etc/apt/sources.list

    sudo echo "deb http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse" >> /etc/apt/sources.list

    sudo echo "deb-src http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse" >> /etc/apt/sources.list

    sudo echo "deb-src http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse" >> /etc/apt/sources.list

    sudo echo "deb-src http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse" >> /etc/apt/sources.list

    sudo echo "deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse" >> /etc/apt/sources.list

    sudo echo "deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse" >> /etc/apt/sources.list

    sudo apt update

    # sudo echo y | apt-get upgrade

    ## Enable the ssh service

    sudo echo "PermitRootLogin yes" >> /etc/ssh/sshd_config

    sudo /etc/init.d/ssh restart

    sudo systemctl enable ssh.service

    ## Set the Shanghai time

    sudo timedatectl set-timezone Asia/Shanghai

    ## Gateway use the default ntp service. If you want to update the time follow the

    ## special server, you can use the ntpd service to update.

    sudo timedatectl set-ntp on

    ## Install the vim

    sudo apt install vim

    sudo reboot

    相关文章

      网友评论

          本文标题:Ubuntu Linux 安装初始化

          本文链接:https://www.haomeiwen.com/subject/unczlrtx.html