spice在桌面虛擬化中的應用系列之二(Linux平臺spice客戶端的編譯安裝,支持USB映射)

1.系統環境

1.1 測試環境

centos6.4最小化安裝(centos6.x桌面版也適用)windows

使用yum源爲163源加EPEL源centos

1.2 spice客戶端介紹

spice做爲遠程鏈接工具,能夠支持遠程桌面顯示,鼠標拖拽,自適應分辨率,spice應用在桌面雲中,主要是鏈接windows桌面,其支持的USB映射能夠使在終端插入的U盤映射到雲端的windows系統中,其效果就至關於在遠端的windows系統上插入U盤工具

在windows平臺下的spice客戶端爲virt-viewer,其不支持usb映射,若須要添加usb映射功能,則須要從新編譯客戶端,加入usb映射功能,對於非開發人員來講,其編譯至關複雜測試

在centos6.x平臺下能夠使用yum安裝virt-viewer,其也不支持usb轉發,下面就是編譯centos6.x下的spice客戶端的具體過程字體

2 下載spice所需軟件

2.1 安裝編譯工具

yum groupinstall "Development tools"
2.2 下載軟件包
#usbredir支持usb映射
wget
http://www.spice-space.org/download/usbredir/usbredir-0.7.tar.bz2 #spice-gtk
wget http://www.spice-space.org/download/gtk/spice-gtk-0.28.tar.bz2
#spice客戶端
wget http://virt-manager.org/download/sources/virt-viewer/virt-viewer-2.0.tar.gz

 

3 編譯安裝usbredir

3.1 依賴包
yum install libusb*
3.2 安裝
./configure --prefix=/usr/local/remote-viewer
make
make install

 

4 編譯安裝spice-gtk

4.1 依賴包
yum install pixman*
yum install openssl*
yum install gtk2-devel
yum install pulseaudio
yum install pulseaudio-devel
yum install pulseaudio-libs-devel
yum install libjpeg*
yum install libusb*
yum install usbredir*
yum install *gudev*
4.2 安裝spice-gtk
./configure --prefix=/usr/local/remote-viewer --enable-usbredir=yes --enable-smartcard=no --with-gtk=2.0
make
make install

 

5 安裝spice客戶端

5.1 依賴包
yum install libxml*
yum install spice-gtk*
5.2 安裝spice客戶端
./configure --prefix=/usr/local/remote-viewer --with-gtk=2.0 --with-spice-gtk
make
make install

 

6 spice客戶端字體沒法顯示解決

因爲測試機使用的是最小化安裝,因此會形成spice客戶端圖形界面下字體沒法顯示,若是你使用centos桌面版編譯安裝這個客戶端,就不會存在這個問題,解決辦法是安裝下面軟件包spa

yum install xorg-x11-fonts-Type1.noarch
相關文章
相關標籤/搜索