服务器安装Ubuntu的那些坑
2018-03-15 17:58 迷 阅读(1570) 评论(0) 编辑 收藏 举报1. 虽然简体中文很亲切,但请选择English,否则极有可能安装途中报错
2. 安装完各种系统文件后,请注意选择启动Disk,一不小心跳过了貌似只好重装
3. 进入后无法使用apt-get,总提示需要cdrom请按以下步骤解决:
sudo vim /etc/apt/sources.list
注释掉cdrom,添加:deb http://cn.archive.ubuntu.com/ubuntu/ xenial main restricted universe multiverse
4. 更新源参考:http://wiki.ubuntu.org.cn/模板:16.04source
deb http://mirrors.aliyun.com/ubuntu/ xenial main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ xenial-proposed main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ xenial main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ xenial-proposed main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse deb http://cn.archive.ubuntu.com/ubuntu/ xenial main restricted universe multiverse deb http://cn.archive.ubuntu.com/ubuntu/ xenial-security main restricted universe multiverse deb http://cn.archive.ubuntu.com/ubuntu/ xenial-updates main restricted universe multiverse deb http://cn.archive.ubuntu.com/ubuntu/ xenial-backports main restricted universe multiverse deb http://cn.archive.ubuntu.com/ubuntu/ xenial-proposed main restricted universe multiverse deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial main restricted universe multiverse deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial-security main restricted universe multiverse deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial-updates main restricted universe multiverse deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial-backports main restricted universe multiverse deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial-proposed main restricted universe multiverse deb http://mirrors.163.com/ubuntu/ xenial main restricted universe multiverse deb http://mirrors.163.com/ubuntu/ xenial-security main restricted universe multiverse deb http://mirrors.163.com/ubuntu/ xenial-updates main restricted universe multiverse deb http://mirrors.163.com/ubuntu/ xenial-proposed main restricted universe multiverse deb http://mirrors.163.com/ubuntu/ xenial-backports main restricted universe multiverse deb-src http://mirrors.163.com/ubuntu/ xenial main restricted universe multiverse deb-src http://mirrors.163.com/ubuntu/ xenial-security main restricted universe multiverse deb-src http://mirrors.163.com/ubuntu/ xenial-updates main restricted universe multiverse deb-src http://mirrors.163.com/ubuntu/ xenial-proposed main restricted universe multiverse deb-src http://mirrors.163.com/ubuntu/ xenial-backports main restricted universe multiverse
5. 设置静态IP,注意设置DNS
sudo vim /etc/network/interfaces
auto enp2s0 iface enp2s0 inet static address 192.168.10.225 netmask 255.255.255.0 gateway 192.168.10.1 dns-nameserver 223.5.5.5 223.6.6.6
【推荐】还在用 ECharts 开发大屏?试试这款永久免费的开源 BI 工具!
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步