VirtualBox

source: vbox/trunk/doc/manual/en_US/dita/topics/guestadd-guestprops.dita

最後變更 在這個檔案是 107390,由 vboxsync 提交於 8 週 前

Docs: bugref:10705. bugref: 10829. The docs build has been modified to split generated refentry dita files and the user manual files and the following commits from doc's team git repo has been applied:

0946136c74dda0483704db891345cb39548b4e28 Started consolidating known issues and troubleshooting information
845b847e6a8e778b38a57867e25ee5e086a73800 Added individual topics for list of known issues, integrated into Troubleshooting section.
bb574836aac775889bd61e4a72f489617fcb7d18 Removed EFI firmware from experimental features for 7.2
6d2e68b244869991e713d170ecd239739d99ba56 Moved known issues into Known Issues section
e2630c896561587718b5c3197c384a38d07014d5 Merge branch 'VBP-1461_experimental-features' into 'main'
0512e2cce51f49ccdc56f3381a2a0c924f2bd278 Feedback on known issues
a77d6c980f6ff5cad9d32b2fb9290990093a03fa Restructured host and guest OS topics
988af5cc9628f5de0806531bc98686f691a911fd Updates with feedbback from Jacob
982a61c9f25b22b745ec483e763e3d88efe59c40 Included feedback from Jacob
93181c8c6cc2d9a26bcccb1145cb0423c0d9f4c9 Updated known issues with feedback from Klaus
8bc369561c383f09b409fe5e44f507440b3735fb Created Legacy Guest OS section
d7932f55accdab7a03666302d58b8c941cd48be2 Moved known issues to more appropriate places for the info
2a4aa094ba8a7ac6894d2a777316eabf41746580 Further moving of known issues
baeabd5308c5519a4dc26b4197be9b00e419a85a Updated links to cli_topics

  • 屬性 svn:eol-style 設為 native
  • 屬性 svn:keywords 設為 Author Date Id Revision
檔案大小: 7.4 KB
 
1<?xml version='1.0' encoding='UTF-8'?>
2<!DOCTYPE topic PUBLIC "-//OASIS//DTD DITA Topic//EN" "topic.dtd">
3<topic xml:lang="en-us" id="guestadd-guestprops">
4 <title>Guest Properties</title>
5
6 <body>
7 <p>
8 <ph conkeyref="vbox-conkeyref-phrases/product-name"/> enables requests of some properties from a running
9 guest, provided that the <ph conkeyref="vbox-conkeyref-phrases/product-name"/> Guest Additions are
10 installed and the VM is running. This provides the following
11 advantages:
12 </p>
13 <ul>
14 <li>
15 <p>
16 A number of predefined VM characteristics are automatically
17 maintained by <ph conkeyref="vbox-conkeyref-phrases/product-name"/> and can be retrieved on the host.
18 For example, to monitor VM performance and statistics.
19 </p>
20 </li>
21 <li>
22 <p>
23 Arbitrary string data can be exchanged between guest and host.
24 This works in both directions.
25 </p>
26 </li>
27 </ul>
28 <p>
29 To accomplish this, <ph conkeyref="vbox-conkeyref-phrases/product-name"/> establishes a private
30 communication channel between the <ph conkeyref="vbox-conkeyref-phrases/product-name"/> Guest Additions
31 and the host, and software on both sides can use this channel to
32 exchange string data for arbitrary purposes. Guest properties are
33 simply string keys to which a value is attached. They can be set,
34 or written to, by either the host and the guest. They can also be
35 read from both sides.
36 </p>
37 <p>
38 In addition to establishing the general mechanism of reading and
39 writing values, a set of predefined guest properties is
40 automatically maintained by the <ph conkeyref="vbox-conkeyref-phrases/product-name"/> Guest Additions to
41 allow for retrieving interesting guest data such as the guest's
42 exact operating system and service pack level, the installed
43 version of the Guest Additions, users that are currently logged
44 into the guest OS, network statistics and more. These predefined
45 properties are all prefixed with <codeph>/VirtualBox/</codeph>
46 and organized into a hierarchical tree of keys.
47 </p>
48 <p>
49 Some of this runtime information is shown when you select
50 <b outputclass="bold">Session Information Dialog</b> from a
51 virtual machine's <b outputclass="bold">Machine</b> menu.
52 </p>
53 <p> A more flexible way to use this channel is with the <userinput>VBoxManage guestproperty</userinput> command. See <xref href="../cli_topics/vboxmanage-guestproperty.dita"/>. For example, to have <i>all</i> the available guest properties for a given running VM listed with their respective values, use this command: </p>
54 <pre xml:space="preserve">$ VBoxManage guestproperty enumerate "Windows Vista III"
55VirtualBox Command Line Management Interface Version <varname>version-number</varname>
56Copyright (C) 2005-2022 Oracle and/or its affiliates
57
58Name: /VirtualBox/GuestInfo/OS/Product, value: Windows Vista Business Edition,
59 timestamp: 1229098278843087000, flags:
60Name: /VirtualBox/GuestInfo/OS/Release, value: 6.0.6001,
61 timestamp: 1229098278950553000, flags:
62Name: /VirtualBox/GuestInfo/OS/ServicePack, value: 1,
63 timestamp: 1229098279122627000, flags:
64Name: /VirtualBox/GuestAdd/InstallDir,
65 value: C:/Program Files/Oracle/VirtualBox
66 Guest Additions, timestamp: 1229098279269739000, flags:
67Name: /VirtualBox/GuestAdd/Revision, value: 40720,
68 timestamp: 1229098279345664000, flags:
69Name: /VirtualBox/GuestAdd/Version, value: <varname>version-number</varname>,
70 timestamp: 1229098279479515000, flags:
71Name: /VirtualBox/GuestAdd/Components/VBoxControl.exe, value: <varname>version-number</varname>r40720,
72 timestamp: 1229098279651731000, flags:
73Name: /VirtualBox/GuestAdd/Components/VBoxHook.dll, value: <varname>version-number</varname>r40720,
74 timestamp: 1229098279804835000, flags:
75Name: /VirtualBox/GuestAdd/Components/VBoxDisp.dll, value: <varname>version-number</varname>r40720,
76 timestamp: 1229098279880611000, flags:
77Name: /VirtualBox/GuestAdd/Components/VBoxMRXNP.dll, value: <varname>version-number</varname>r40720,
78 timestamp: 1229098279882618000, flags:
79Name: /VirtualBox/GuestAdd/Components/VBoxService.exe, value: <varname>version-number</varname>r40720,
80 timestamp: 1229098279883195000, flags:
81Name: /VirtualBox/GuestAdd/Components/VBoxTray.exe, value: <varname>version-number</varname>r40720,
82 timestamp: 1229098279885027000, flags:
83Name: /VirtualBox/GuestAdd/Components/VBoxGuest.sys, value: <varname>version-number</varname>r40720,
84 timestamp: 1229098279886838000, flags:
85Name: /VirtualBox/GuestAdd/Components/VBoxMouse.sys, value: <varname>version-number</varname>r40720,
86 timestamp: 1229098279890600000, flags:
87Name: /VirtualBox/GuestAdd/Components/VBoxSF.sys, value: <varname>version-number</varname>r40720,
88 timestamp: 1229098279893056000, flags:
89Name: /VirtualBox/GuestAdd/Components/VBoxVideo.sys, value: <varname>version-number</varname>r40720,
90 timestamp: 1229098279895767000, flags:
91Name: /VirtualBox/GuestInfo/OS/LoggedInUsers, value: 1,
92 timestamp: 1229099826317660000, flags:
93Name: /VirtualBox/GuestInfo/OS/NoLoggedInUsers, value: false,
94 timestamp: 1229098455580553000, flags:
95Name: /VirtualBox/GuestInfo/Net/Count, value: 1,
96 timestamp: 1229099826299785000, flags:
97Name: /VirtualBox/HostInfo/GUI/LanguageID, value: C,
98 timestamp: 1229098151272771000, flags:
99Name: /VirtualBox/GuestInfo/Net/0/V4/IP, value: 192.168.2.102,
100 timestamp: 1229099826300088000, flags:
101Name: /VirtualBox/GuestInfo/Net/0/V4/Broadcast, value: 255.255.255.255,
102 timestamp: 1229099826300220000, flags:
103Name: /VirtualBox/GuestInfo/Net/0/V4/Netmask, value: 255.255.255.0,
104 timestamp: 1229099826300350000, flags:
105Name: /VirtualBox/GuestInfo/Net/0/Status, value: Up,
106 timestamp: 1229099826300524000, flags:
107Name: /VirtualBox/GuestInfo/OS/LoggedInUsersList, value: username,
108 timestamp: 1229099826317386000, flags:</pre>
109 <p>
110 To query the value of a single property, use the
111 <userinput>get</userinput> subcommand as follows:
112 </p>
113 <pre xml:space="preserve">$ VBoxManage guestproperty get "Windows Vista III" "/VirtualBox/GuestInfo/OS/Product"
114VirtualBox Command Line Management Interface Version <varname>version-number</varname>
115Copyright (C) 2005-2022 Oracle and/or its affiliates
116
117Value: Windows Vista Business Edition</pre>
118 <p>
119 To add or change guest properties from the guest, use the tool
120 <userinput>VBoxControl</userinput>. This tool is included in the Guest
121 Additions. When started from a Linux guest, this tool requires
122 root privileges for security reasons.
123 </p>
124 <pre xml:space="preserve">$ sudo VBoxControl guestproperty enumerate
125VirtualBox Guest Additions Command Line Management Interface Version <varname>version-number</varname>
126Copyright (C) 2005-2022 Oracle and/or its affiliates
127
128Name: /VirtualBox/GuestInfo/OS/Release, value: 2.6.28-18-generic,
129 timestamp: 1265813265835667000, flags: &lt;NULL&gt;
130Name: /VirtualBox/GuestInfo/OS/Version, value: #59-Ubuntu SMP Thu Jan 28 01:23:03 UTC 2010,
131 timestamp: 1265813265836305000, flags: &lt;NULL&gt;
132 ...</pre>
133 <p>
134 For more complex needs, you can use the <ph conkeyref="vbox-conkeyref-phrases/product-name"/> programming
135 interfaces. See <xref href="VirtualBoxAPI.dita"><ph conkeyref="vbox-conkeyref-phrases/product-name"/> Programming Interfaces</xref>.
136 </p>
137 </body>
138</topic>
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette