virt-viewer的简单使用
virt-viewer
簡介:virt-viewer是一個用于顯示虛擬機的圖形控制臺的最小工具。 控制臺使用VNC或SPICE訪問協(xié)議。 可以基于其名稱,ID或UUID來引用guest虛擬機。如果客戶端尚未運行,則可以告知觀看者請等待,直到它開始,然后嘗試連接到控制臺。此查看器可以連接到遠程主機以查找控制臺信息然后也使用同一網(wǎng)絡連接到遠程控制臺。
用法:virt-viewer [OPTIONS] -- DOMAIN-NAME|ID|UUID
子命令類別
運行“virt-viewer”時,接受以下選項:
-h,-help 顯示命令行幫助摘要
-V,--version 顯示程序版本號
-v,-verbose 顯示有關連接的信息
-w, - wait 等待域啟動,然后再嘗試連接到控制臺
-r,--reconnect
如果關閉并重新啟動,則自動重新連接到域
-td PCT,-zoom = PCT
顯示窗口的縮放級別(百分比)。 范圍10-400。
-d,--direct
不要嘗試通過SSH隧道控制臺,即使主要
連接URI使用SSH。
-a,--attach
而不是直接TCP / UNIX套接字連接到遠程
顯示,要求libvirt提供一個預連接的socket
顯示。 這避免了需要與遠程驗證
顯示服務器。 此選項僅在連接時有效
到在與virt-viewer相同的主機上運行的客戶機
程序。 如果通過libvirt連接到客戶端失敗,virt-viewer
會自動回退到嘗試正常的直接TCP / UNIX
插座連接。
EXAMPLES
1:To connect to the guest called 'demo' running under Xen
# virt-viewer demo
2:To connect to the guest with ID 7 running under QEMU
#virt-viewer --connect qemu:///system 7
3:To wait for the guest with UUID 66ab33c0-6919-a3f7-e659-16c82d248521 tostartup and then connect, also reconnecting upon restart of VM
#virt-viewer --reconnect --wait 66ab33c0-6919-a3f7-e659-16c82d248521
4:To connect to a remote console using TLS
#virt-viewer --connect xen://example.org/ demo
5:To connect to a remote host using SSH, lookup the guest config and thenmake a tunnelled connection of the console
#virt-viewer --connect qemu+ssh://root@example.org/system demo
6:When using a SSH tunnel to connect to a SPICE console, it's recommended to have ssh-agent running to avoid getting multiple authenticationprompts.To connect to a remote host using SSH, lookup
the guest config and then make a direct non-tunnelled connection of the console
# virt-viewer --direct --connect xen+ssh://root@example.org/ demo
總結
以上是生活随笔為你收集整理的virt-viewer的简单使用的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 安农大计算机调剂,2020年安徽农业大学
- 下一篇: string类的相关知识及部分操作