题记
VNC是OpenStack的Nova默认的连接协议,面对一些简单的管理工作表现也不错,但是如果用户经常使用Windows桌面,VNC就显得能力不足。一般情况下,使用Spice协议来代替VNC。
VNC
VNC (Virtual Network Computing)是虚拟网络计算机的缩写。VNC 是一款优秀的远程控制工具软件,由著名的 AT&T 的欧洲研究实验室开发的。VNC 是在基于 UNIX 和 Linux 操作系统的免费的开源软件,远程控制能力强大,高效实用,其性能可以和 Windows 和 MAC 中的任何远程控制软件媲美。 在 Linux 中,VNC 包括以下四个命令:vncserver,vncviewer,vncpasswd,和 vncconnect。大多数情况下我只需要其中的两个命令:vncserver 和 vncviewer。
Spice已经支持和即将支持的功能
当前支持功能:
• 图形界面 - processes and transmits 2D graphic commands
• 视频流 - heuristically identifies video streams and transmits M-JPEG video streams
• 图片压缩 - offers verios compression algorithm that were built specifically for Spice, including QUIC (based on SFALIC), LZ, GLZ (history-based global dictionary), and auto (heuristic compression choice per image)
• 硬件鼠标- processes and transmits cursor-specific commands
• 图像,颜色,鼠标缓存 - manages client caches to reduce bandwidth requirements
• 在线切换 - supports clients while migrating Spice servers to new hosts, thus avoiding interruptions
• Windows 驱动 - Windows drivers for QXL display device and VDI-port
• 多监视器
• 客户端支持linux和windows - can be easily ported to additional platforms.
• 立体声音频 - supports audio playback and captures; audio data stream is optionally compressed using CELT
• 加密 - using OpenSSL
• 两种鼠标模式- provides client (more user-friendly) and server (increased accuracy and fully synchronized) modes
• 音频视频同步 - synchronizes video streams with audio clocks
• Spice 代理 - running on the guest and performs tasks for the client
• 剪切板共享 - allows copy paste between clients and the virtual machine
未来将支持的新功能:
• 网络隧道 (in progress) - using virtual network interface to enable sharing of network resources. Currently the focus is on printer sharing but is not limited to that.
• Off-screen surfaces (in progress) - supports off-screen surfaces as infrastructure for future DirectDraw, video acceleration and 3D acceleration. GDI and X11 will also benefit from this feature. It will also lay foundation for multi-head support
• 共享usb (in progress) - allows clients to share their USB devices with Spice servers
• Direct Draw
• 客户端GUI - Enables user-friendly configuration
• 屏幕管理 - add support for enabling selection of the screen used by the client
• 配置文件 - enables persistent user and administrative settings
• 共享光驱 - share your CD with Spice server
• 视频加速
• 3D加速
• 支持Aero
• Linux features parity
• OSX client
• Simultaneous clients connection
OpenStack启用Spice协议
测试环境:Ubuntu14.04 icehouse
控制节点
1、安装软件
apt-get install nova-spiceproxy spice-html5 spice-vdagent
2、修改控制节点的Nova.conf
注释掉所有跟vnc相关的内容,然后添加如下内容