Users

All Posts (9)

avatar

joffrey

Disabled

Powershell: Get-RDMSession: Connection not found

avatar
avatar
avatar
joffrey
Disabled

I tested your code (and add the Name of the current repo):

I checked all repos with the error. The Staging (it's a group) exists. Some are empty, and some not..

I don't understand

Powershell: Get-RDMSession: Connection not found

avatar
avatar
avatar
joffrey
Disabled

Hmm.. check my code. I use Set-RDMCurrentRepository

I added Update-RDMUI, no change:

 Get-RDMRepository |  ?{($_.Name -notlike '*XXX*') -and ($_.Name -notlike '*Temp*')} |% {
	Set-RDMCurrentRepository $_
	Update-RDMUI
	$s = get-RDMSession | ?{ $_.Name -like '*staging*'}
}

result:

get-RDMSession : Connection not found.
At C:\ps1\rdm_staging.ps1:7 char:7
+     $s = get-RDMSession | ?{ $_.Name -like '*staging*'}
+          ~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [Get-RDMSession], Exception
    + FullyQualifiedErrorId : 0,RemoteDesktopManager.PowerShellModule.GetRDMSessionCommand

I don't have this error on all Repo

Powershell: Get-RDMSession: Connection not found

avatar
avatar
avatar
joffrey
Disabled

Hi,

I make a simple loop :

 Get-RDMRepository |  ?{($_.Name -notlike '*XXX*') -and ($_.Name -notlike '*Temp*')} |% {
	Set-RDMCurrentRepository $_
	$s = get-RDMSession | ?{ $_.Name -like '*staging*'}
}

But, on many repository, I get this error:

Get-RDMSession : Connection not found.

Any idea please ??

Thanks you

'Joffrey

Do remote powershell using RDM as inventory source

avatar
avatar
avatar
joffrey
Disabled

Done

Powershell on Linux ?

avatar
avatar
avatar
joffrey
Disabled

Hi,

Is it possible to install RDM Powershell module on linux to use with Powershell Core to query the database ?

Do remote powershell using RDM as inventory source

avatar
avatar
avatar
joffrey
Disabled

Thanks you, but it doesn't work

This is the code :

$repo = "MyRepo"

$group = "MyGroup"

$RDMrepo = Get-RDMRepository -Name $repo

Set-RDMCurrentRepository -Repository $RDMrepo

$sessions = Get-RDMSession -Group $group | where {$_.connectionType -ne "Group"}

foreach ($s in $sessions) {

$credentials = Get-RDMSessionCredentials -PsConnection $s

Invoke-Command -ComputerName $s.Host -Credential $credentials -ComputerName $s.Host -ScriptBlock { Get-PSDrive }

}

error :

Invoke-Command : Cannot process argument transformation on parameter 'Credential'. userName

At C:\XXX\list_hosts.ps1:14 char:54

+ ... Invoke-Command -ComputerName $s.Host -Credential $credentials -Comput ...

+ ~~~~~~~~~~~~

+ CategoryInfo : InvalidData: (:) [Invoke-Command], ParameterBindingArgumentTransformationException

+ FullyQualifiedErrorId : ParameterArgumentTransformationError,Microsoft.PowerShell.Commands.InvokeCommandCommand

Do remote powershell using RDM as inventory source

avatar
avatar
avatar
joffrey
Disabled

Version 14.1.3.0

Datasource is SQL.

What is the function 'Get-Credential' about ?? Why don't write a RDM function that return a Credential object ?? We can't get the password with a credential object if you think about security

Do remote powershell using RDM as inventory source

avatar
avatar
avatar
joffrey
Disabled

Hello,

About the Get-RDMSessionPassword access denied, does the account who run the script has enough permission to view passwords?

What RDM version are you using?

What data source type are you connected to?

If it is Devolutions Password Server, what version are you using?

Best regards,

no, I can juste copy password (But I can copy un a notepad and view the password)

Do remote powershell using RDM as inventory source

avatar
avatar
avatar
joffrey
Disabled

Hi,

I want to make a simple "Get-Process" on some hosts using RDM as inventory source.

The problem is to retrieve credentials. With the GUID, I can copy username and password. With powershell, I get an access denied (get-RDMSessionPasword)

What is the good way to get login/password or credientials (the best way I think) like the Get-credential return object ?

$sessions = Get-RDMSession -Group $group | where {$_.connectionType -ne "Group"}

foreach ($h in $sessions) {

$p = Get-RDMSessionPassword $h # access denied

$c = Get-RDMSessionCredentials -PSConnection $h # return a simple string like 'privatevaultsearch', or 'inherited', or 'credentialEntry', or 'SEssionspecific'. Not a credential

}

I don't want to use the RDM agent, sorry. I'm using Remote Powershel and ansible for some tasks.

Thanks you

1 - 9 of 9 items