Common Tasks :Connecting to a Specified Host
2012-10-19 11:15
369 查看
Connecting to a Specified Host
This allows you to access any networked host machine that is running VMware Server from a single client machine. If the host is running VMware Workstation, you must use the procedure Connectingto the Local Host as the Current User.
For clients connecting through a firewall, open ports 8222 and 8333 for VMware Server on Windows, or ports 80 and 443 for VMware Server on Linux, in addition to default port 902. This is assuming vmware-hostd listens on the default ports. If you changed
ports at installation time or with vmware-config.pl, open those ports instead.
Example 3-1.
C code below.
#include "vix.h" int main(int argc, char * argv[]) { VixHandle hostHandle = VIX_INVALID_HANDLE; VixHandle jobHandle = VIX_INVALID_HANDLE; VixError err; // Connect to specified host. jobHandle = VixHost_Connect(VIX_API_VERSION, VIX_SERVICEPROVIDER_VMWARE_SERVER, argv[1], // hostName 0, // hostPort argv[2], // userName argv[3], // password, 0, // options VIX_INVALID_HANDLE, // propertyListHandle NULL, // callbackProc NULL); // clientData err = VixJob_Wait(jobHandle, VIX_PROPERTY_JOB_RESULT_HANDLE, &hostHandle, VIX_PROPERTY_NONE); if (VIX_OK != err) { // Handle the error... goto abort; } Vix_ReleaseHandle(jobHandle); jobHandle = VIX_INVALID_HANDLE; // Other code goes here... abort: VixHost_Disconnect(hostHandle); }
If you specify the host when you connect to VMware Server, you can also choose to specify the port number. The port number defaults to 902, which is correct for most installations
of VMware Server. Some installations might be configured to use a different port number, if port 902 is already in use on the host.
相关文章推荐
- Common Tasks :Connecting to the Local Host as a Specified User
- Common Tasks :Connecting to the Local Host as the Current User
- nginx connect() failed (113: No route to host) while connecting to upstream
- mpich2 error while connecting to host 由于目标计算机积极拒绝,无法连接。 (10061)
- connecting to host: cephm resulted in errors: IOError cannot send (already closed?)[ceph-deploy部署报错]
- mpich2 error while connecting to host 由于目标计算机积极拒绝,无法连接。 (10061)
- the specified license key not be verified as belonging to this host
- How to create a VM on a specified host with openstack
- Unable to connect to specified host. 错误
- httclient caught when connecting to the target host:Address already in use
- Common Tasks :Connecting to a Host
- DOS cmd - how to ping a remote host with specified port
- Are you sure you want to continue connecting etc ssh ssh_config StrictHostKeyChecking no
- DOS cmd - how to ping a remote host with specified port
- Connecting Windows Mobile device emulators to the Internet without ActiveSync
- ssh: connect to host your.remote.host.ip port 22: Connection refused
- Failed to connect the specified server.Server library could not be loaded
- Linux下SUDO出现Unable to resolve host XXX解决方法
- 数据库--异常--java.net.NoRouteToHostException: Cannot assign requested address
- git clone时失败提示:Connection to bitbucket.org closed by remote host..00 KiB/s