Hi,
Is there a macro/tool or just a good way within RDM to easily query your list of servers for information about the OS hardware etc? For instance running an msinfo32 on a Windows servers returns a quick glance of the server stats.
Just a quick way to click and find out what OS, memory disk space etc it has? For Linux as well?
thanks,
Clarifying "information tab", it's the properties of the connection, Information.
Hi,
We have that on our todo list but it's not implemented yet.
David Hervieux
this would be a great addition really.
This is what I use for now.
This should look correct once copied and pasted into PowerShell
# First, this worked for me, my hope is you will find it helpful.
# I called this my RDM_MetaData_Updater.ps1
# Remote Desktop Manager (RDM) Version 2020.1.20.0 64-bit Enterprise Edition
# Using a SQL Server 2016 DB
# I am running this in PowerShell version 5.1.18362.752 as an administrator on my local desktop.
# RDM is running on this same desktop as my regular user account.
Clear-Host
Import-Module "C:\Program Files (x86)\Devolutions\Remote Desktop Manager\RemoteDesktopManager.PowerShellModule.psd1"
# Set your DS (Data Source), mine is on our SQL server
# You can find your data source under in your RDM under File/Data Sources
$DS = Get-RDMDataSource -Name MySQLServerName
# Next, I get all of the sessions under my group name.
# This grabs everything, including folders, etc.
$Sessions = Get-RDMSession -GroupName "Michael" -IncludeSubFolders
# Next, for testing, I wanted to update the IP Address on a single server
# in the RDM.
ForEach ($Session in $Sessions)
{
# So, if the Host name matched the server I was looking for then I would run my script.
# For me, if I wanted to run through all my servers I would change the IF line to:
# If($Session.ConnectionType -eq "RDPConfigured")
# You can get as creative as you'd like.
If($Session.Host -eq "NameOfServerToUpdate")
{
# I just wanted to see it found the correct host.
$Session.Host
$IPv4Address = (Get-ADComputer -Identity $Session.Host -Properties IPv4Address).IPv4Address
# And here I just wanted to what IPAddress was found.
$IPv4Address
Set-RDMSessionProperty -ID $Session.ID -Path "MetaInformation" -Property "IP" -Value $IPv4Address
# Do not forget to do a refresh on your RDM console to see the updated information.
}
}
@michael47 - that is a great script, thank you for sharing. Probably also more supported than directly injecting that data into SQL db ;-)
Is there any documentation on MetaInformation? Where can I find List of "all" Properties in Metainformation (powershell command isnt very helpfull with output)
Hello,
There is no documentation available with all properties of the MetaInformation property. It is possible to get the properties list from any entry in PowerShell like the following command. Please note that the list of MetaInformation properties is a bit longer than what you see in this picture!
Best regards,
Érica Poirier
Exactly what I was looking for, thank you very much!
Best regards,
Rok
Sorry for a subquestion:
And I guess CustomFields are not extandable? And fixed Properties are not renamable (to change displayname of the Property same as in CustomFields)?
Best regards,
RokB
Hello,
That's right, fixed properties cannot be renamed. It is only possible to rename Custom Fields.
This is possible to extend Custom Fields in RDM.
With PowerShell, you can create a new custom field like the following.
$session = Get-RDMSession -Name MyCredential $NewCustomField = New-Object Devolutions.RemoteDesktopManager.Business.CustomFieldEntity $NewCustomField.CustomFieldTitle = "My new custom" $NewCustomField.CustomFieldValue = "This is my new custom field" $session.MetaInformation.CustomFieldEntities += $NewCustomField Set-RDMSession $session -Refresh
Best regards,
Érica Poirier
Perfect, thank you so much, especially for PS part ;-)
Best regards,
Rok