Ubuntu 17.04/17.10的升级和Docker安装

Ubuntu 17.04与16.04版本变化较大,容易致使升级失败。linux

下面把一些过程当中的折腾记录下来,备忘:docker

升级准备

sudo apt update && sudo apt dist-upgradeubuntu

长期支持版本默认设置为仅升级到LTS版本。 要获知有一个较新的非LTS Ubuntu版本可用,您必须使用软件更新程序工具手动设置“选择加入”:curl

  1. 打开“软件和更新”
  2. 选择“更新”选项卡
  3. 找到标题为“通知我新的Ubuntu版本”
  4. 在下拉菜单中,从“长期支持版本”切换到“任何新版本”

手动升级

sudo do-release-upgrade工具

而后,重启。就一直挂在启动界面了,再也起不来了。url

而后,作了个启动U盘,使用UltraISO作的,可是用于安装时中途出错。spa

把U盘所有分区删除,格式化一遍成NTFS。再从新作启动U盘。code

启动安装过程顺利,最后 Install  grub /dev/dm 0出错,重启失败。get

再次安装,选英文版安装(网上有人说英文版没问题),选中lvm(原来磁盘用了lvm,不知道有没有关系),成功!!!it

进去装docker、synaptic、gparted等。

安装docker CE

添加Docker’s 官方的 GPG key:

$ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -

检查下看

sudo apt-key fingerprint 0EBFCD88

添加软件源

sudo add-apt-repository \
   "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
   $(lsb_release -cs) \
   stable"

!注意:若是使用的Ubuntu 17.10,Docker  CE目前只有edge版本可用,若是安装时提示出现找不到docker-ce版本,添加源时改成以下:

sudo add-apt-repository \
   "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
   $(lsb_release -cs) \
   edge"

开始安装

sudo apt-get updatesudo apt-get install docker-ce

完整参考:

https://docs.docker.com/engine/installation/linux/docker-ce/ubuntu/#install-using-the-repository

相关文章
相关标签/搜索