天天看點

ubuntu server 18.04 上安裝 GNOME gnome-core 圖形桌面

#/bin/bash
# ubuntu 其他版本軟體倉庫: https://developer.aliyun.com/mirror/ubuntu?spm=a2c6h.13651102.0.0.3e221b11Lyoail
# ubuntu18 阿裡雲倉庫源 配置案例:
echo "
deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse
" >>  /etc/apt/sources.list
# 寫入軟體倉庫配置檔案
sudo rm /var/lib/dpkg/updates/*
sudo apt-get update                       
# 更新軟體倉庫,否則無法安裝出現問題:
# E: dpkg uas interrupted, you nus tn an ually run 'dpkg --com figure-a' to correct the proble n. -+a:7k-11m7uAo..L.o..f..7.~m m一 -11 
# E: dpkg 被中斷,您必須手工運作 sudo dpkg –configure -a 解決此問題。

apt-get install x-window-system-core
apt-get install gnome-core
# 安裝GNOME桌面環境。

startx
# 執行以下指令,啟動圖形化桌面。
           

繼續閱讀