Hello,
How to create a shorcut to a VM in an ESX which opens with VMRC?
You don't need the SDK per se--you can get all the information you need to create the URL via the vSphere/ESXi/etc. managed object browser (MOB), ex. https://<your_server>/mob
, but you'll have to automate it yourself:
The simplest VMRC URL is just your sever and MOID which on connect you can validate with your username and password, ex. vmrc://<your_server>/?moid=<your_moid>
There is no KB for this now but the VMRC team intends to post one.
---
Update: PowerCLI 6.5, announced on the PowerCLI blog 2016-11-17, installs VMRC and launches it with the Open-VMConsoleWindow command, ex.
Get-VM -Name VM-name | Open-VMConsoleWindow
To display the URL instead of launching VMRC, add the -UrlOnly parameter on the end. This URL includes a single-use expiring clone ticket which will log you in automatically. If you reuse the URL after the ticket has expired, or remove the ticket, VMRC will prompt you for credentials.
Check if helps: How to Generate VM Remote Console URL for vSphere 5.x Web Client | virtuallyGhetto
The previous reply links to a 2011 virtuallyGhetto article which describes generating https:// URLs for the plugin VMRC, versions 5.5 and earlier. Standalone VMRC, versions 7 and later, are launched via vmrc:// URLs. These virtuallyGhetto articles reference the new URL scheme (and the comments there have more details):
VMware should have a KB document to describe this.
Hello,
For virtual ghetto, I understand it takes SDK. Is this possible without ?
Also, you mention a KB . What is his link?
You don't need the SDK per se--you can get all the information you need to create the URL via the vSphere/ESXi/etc. managed object browser (MOB), ex. https://<your_server>/mob
, but you'll have to automate it yourself:
The simplest VMRC URL is just your sever and MOID which on connect you can validate with your username and password, ex. vmrc://<your_server>/?moid=<your_moid>
There is no KB for this now but the VMRC team intends to post one.
---
Update: PowerCLI 6.5, announced on the PowerCLI blog 2016-11-17, installs VMRC and launches it with the Open-VMConsoleWindow command, ex.
Get-VM -Name VM-name | Open-VMConsoleWindow
To display the URL instead of launching VMRC, add the -UrlOnly parameter on the end. This URL includes a single-use expiring clone ticket which will log you in automatically. If you reuse the URL after the ticket has expired, or remove the ticket, VMRC will prompt you for credentials.
OK but i don't know <your moid>.
Is it possible with the DataStore Path?
I try that but it doesn't work :
vmrc://vmer68vcenter.intranet.local/?moid=[LOCAL_ESX01_DS1] MP_v7/MP_v7.vmx
I Enter user name and password but after i have the message :
You must have the MOID to connect this way. Some other ways to find MOIDs:
Here's a simple example in PowerCLI for connecting to an ESXi-hosted VM by name. Replace the items in bold with your specifics:
Add-PSSnapin VMware.VimAutomation.Core
Connect-VIServer <your_server>
$sessionMgr = Get-View $DefaultViserver.ExtensionData.Client.ServiceContent.SessionManager
$vm = Get-VM -Name "<vm_name>"
$url = "vmrc://clone:{0}@{1}/?moid={2}" -f $sessionMgr.AcquireCloneTicket(), $DefaultVIServer.serviceuri.Host, $vm.ExtensionData.moref.value
Start-Process $url
I created this shortcut and it worked
"C:\Program Files (x86)\VMware\VMware Remote Console\vmrc.exe" vmrc://DomainName\UserName@vCenterName/?moid=vm-VmNumber. I found the VM number with the RVTools utility.