您可能已经知道,带有 Mir 显示服务器的 Unity 8 桌面会话目前正在 Ubuntu 触摸设备中使用,迟早它将成为即将推出的 Ubuntu 桌面版本中带有 Mir 显示服务器的默认桌面环境。
现在,好消息是 Canonical 使得只需添加 PPA 并安装即可在所有 Ubuntu 桌面中安装和测试带有 Mir 显示服务器的最新 Unity 8 桌面。 LXC 中的 Unity 8 桌面预览是使用 LXC 容器在 Mir 显示技术上运行的新 Unity 8 桌面 shell。它只是预览版本,因为它仍处于开发阶段,尚未准备好用于生产使用。任何有兴趣在当前 Ubuntu 版本中尝试 Unity 8 桌面体验的人都可以尝试和测试。
想要尝试 Unity 8 桌面会话吗?跟我来。
在 Ubuntu 上运行 Unity 8 有两种方法。一是下载 Unity 8 桌面 ISO从这里,将其刻录到 DVD 或 USB 驱动器,然后安装。
另外,另一种简单的方法是通过 LXC Containers 添加 Canonical 开发团队开发的 PPA 并安装。
在本教程中,让我们了解如何在任何支持的 Ubuntu 操作系统中使用 Mir 显示服务器安装和测试 Unity 8 桌面预览。
运行以下命令在 Ubuntu 12.04、14.04、14.10、15.04 和 15.10 上的 LXC 中安装和测试 Unity 8 桌面(预览版)。
目前它位于 Utopic (14.10)、Vivid (15.04) 和 Wily (15.10) 的存档中,但应使用 ppa 版本来确保最新版本。
首先使用命令添加 Unity 8 PPA:
sudo apt-add-repository ppa:unity8-desktop-session-team/unity8-preview-lxc
然后,更新软件存储库列表。
sudo apt-get update sudo apt-get upgrade
现在,使用命令安装 Unity 8 桌面预览版:
sudo apt-get install unity8-lxc
上面的命令将安装稍微修改的 lightdm 版本,该版本允许 lxc 容器登录。需要重新启动才能加载升级的 LightDM。
最后,使用命令设置 Unity 8 桌面:
sudo unity8-lxc-setup
这将下载 Unity 8 桌面预览 ISO 映像并解压缩。这将需要一段时间,具体取决于您的互联网连接速度。
#################### 100.0% 166.4 kBps DONE open: No such file or directory not using seed file /var/lib/lxc/unity8-lxc/ubuntu-next.iso Read /var/lib/lxc/unity8-lxc/ubuntu-next.iso. Target 0.0% complete. No relevent local data found - I will be downloading the whole file. If that's not what you want, CTRL-C out. You should specify the local file is the old version of the file to download with -i (you might have to decompress it with gzip -d first). Or perhaps you just have no data that helps download the file downloading from https://cdimage.ubuntu.com/ubuntu-desktop-next/daily-live/current/wily-desktop-amd64.iso: -------------------- 0.0% 8.6 kBps -------------------- 0.0% 8.6 kBps -------------------- 4.6% 5.7 kBps ETA ######-------------- 34.7% 8.6 kBps ETA ########------------ 43.6% 9.6 kBps ETA ########------------ 43.6% 10.0 kBps #################### 100.0% 229.6 kBps DONE verifying download...checksum matches OK used 0 local, fetched 1086259545 Unpacking the ISO image... Configuring the Unity8 LXC... dget: retrieving https://archive.ubuntu.com/ubuntu/pool/main/u/upstart/upstart-sysv_1.13.2-0ubuntu14_amd64.deb --2015-06-04 18:36:47-- https://archive.ubuntu.com/ubuntu/pool/main/u/upstart/upstart-sysv_1.13.2-0ubuntu14_amd64.deb Resolving archive.ubuntu.com (archive.ubuntu.com)... 91.189.91.15, 91.189.92.201, 91.189.91.24, ... Connecting to archive.ubuntu.com (archive.ubuntu.com)|91.189.91.15|:80... connected. HTTP request sent, awaiting response... 200 OK Length: 40290 (39K) [application/x-debian-package] Saving to: ‘upstart-sysv_1.13.2-0ubuntu14_amd64.deb’ upstart-sysv_1.13.2-0ubuntu14_amd64.deb 100%[=======================================================================================>] 39.35K 95.4KB/s in 0.4s 2015-06-04 18:36:49 (95.4 KB/s) - ‘upstart-sysv_1.13.2-0ubuntu14_amd64.deb’ saved [40290/40290] Starting the container Switching to upstart... . . .
下载并安装后,重新启动系统。
登录 Unity 8 桌面会话
Unity 8 桌面预览 LXC 会话与您可能已安装在计算机上的任何其他桌面会话类似。您可以通过 LightDM 访问该会话。在 LightDM 登录屏幕上,为您的用户选择“Unity 8 in LXC”会话。
请注意,尚不支持访客会话。 Unity8 可能需要几秒钟的时间来加载,但最终您应该会看到熟悉的 unity8 锁屏。
要切换回之前的 Unity 会话,只需注销并选择‘Ubuntu 默认’从 LightDM 屏幕。
更新Unity 8
目前,Unity 8 会话中的更新程序无法完全更新 LXC 中的软件包。 unity8-lxc-setup 实用程序具有更新 LXC 中的软件包的功能。
要更新 LXC 的内容,请运行:
sudo unity8-lxc-setup --update-lxc
请注意,上述命令只会更新 LXC 中已有的软件包,不一定包含最新 Unity 8 桌面预览 ISO 中包含的内容。
如果您已经安装了 Unity 8 Desktop Preview ISO 并且想使用最新的 ISO,请运行:
sudo unity8-lxc-setup --rebuild-all --redownload
示例输出:
#################### 100.0% 153.9 kBps DONE reading seed file /var/lib/lxc/unity8-lxc/ubuntu-next.iso: *****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************Read /var/lib/lxc/unity8-lxc/ubuntu-next.iso. Target 100.0% complete. verifying download...checksum matches OK used 1086259200 local, fetched 0 Unpacking the ISO image... Configuring the Unity8 LXC... dget: retrieving https://archive.ubuntu.com/ubuntu/pool/main/u/upstart/upstart-sysv_1.13.2-0ubuntu14_amd64.deb --2015-06-04 19:12:36-- https://archive.ubuntu.com/ubuntu/pool/main/u/upstart/upstart-sysv_1.13.2-0ubuntu14_amd64.deb Resolving archive.ubuntu.com (archive.ubuntu.com)... 91.189.92.201, 91.189.92.200, 91.189.91.14, ... Connecting to archive.ubuntu.com (archive.ubuntu.com)|91.189.92.201|:80... connected. HTTP request sent, awaiting response... 200 OK Length: 40290 (39K) [application/x-debian-package] Saving to: ‘upstart-sysv_1.13.2-0ubuntu14_amd64.deb’ upstart-sysv_1.13.2 100%[=====================>] 39.35K 85.7KB/s in 0.5s 2015-06-04 19:12:37 (85.7 KB/s) - ‘upstart-sysv_1.13.2-0ubuntu14_amd64.deb’ saved [40290/40290] Starting the container Switching to upstart... Reading package lists... Done Building dependency tree Reading state information... Done The following packages will be REMOVED: systemd-sysv ubuntu-standard The following NEW packages will be installed: upstart-sysv 0 upgraded, 1 newly installed, 2 to remove and 0 not upgraded. Need to get 0 B/40.3 kB of archives. After this operation, 56.3 kB of additional disk space will be used. (Reading database ... 125304 files and directories currently installed.) Removing ubuntu-standard (1.334) ... dpkg: systemd-sysv: dependency problems, but removing anyway as you requested: init depends on systemd-sysv | upstart-sysv; however: Package systemd-sysv is to be removed. Package upstart-sysv is not installed. Removing systemd-sysv (219-10ubuntu1) ... Processing triggers for man-db (2.7.0.2-5) ... Selecting previously unselected package upstart-sysv. (Reading database ... 125284 files and directories currently installed.) Preparing to unpack .../upstart-sysv_1.13.2-0ubuntu14_amd64.deb ... Unpacking upstart-sysv (1.13.2-0ubuntu14) ... Processing triggers for man-db (2.7.0.2-5) ... Setting up upstart-sysv (1.13.2-0ubuntu14) ...
删除统一8
正如我上面提到的,带有 Mir 显示屏的 Unity 8尚未完全准备好。您最终可能会遇到系统损坏的情况。我强烈建议您尝试新的系统。由于它正处于繁重的开发阶段,一些专有的显示驱动程序(如 AMD 或 Nvidia)无法按预期工作。但是,不用担心,开发人员不会努力使其完美适用于所有驱动程序和设备。如果您想测试和回顾 Unity 8 堆栈在桌面体验中的工作方式,并着眼于 Ubuntu 的完全融合,请尝试一下。
如果您发现任何问题,请将错误提交给unity8-桌面会话.
要删除 Unity 8,只需运行:
sudo apt-get remove unity8-lxc
现在就这些了。我们将不时为您提供有关 Unity 8 的最新信息。在此之前,请继续关注我们并保持快乐。
干杯!






