Page 1 of 1
NCPA Agent Deploy to MS systems
Posted: Mon Aug 25, 2025 1:32 pm
by StevenBeauchemin
Help me understand. Why use ssh to install on MS? Is this a mistake?
I would like to deploy NCPA to my MS Servers.
Do I need to install OpenSSH first?
In my environment we have Ansible and have been using WinRM on MS deployments.
Can the Nagios deployment be changed to use WinRM instead of ssh?
The file install_agent_win.yml
Contains:
ansible_connection: ssh
Please advise.
Thanks
Steve B
Re: NCPA Agent Deploy to MS systems
Posted: Mon Aug 25, 2025 4:01 pm
by gwesterman
Hi StevenBeauchemin,
At the moment, only SSH deployment is supported from XI. I will create an internal feature request to add the option to use WinRM.
Thank you!
Re: NCPA Agent Deploy to MS systems
Posted: Wed Aug 27, 2025 12:35 pm
by StevenBeauchemin
Very nice !!
Thank You
Steve B
(please close if this is open)
Re: NCPA Agent Deploy to MS systems
Posted: Thu Aug 28, 2025 6:07 am
by AngeloMileto
Not sure if it would help you but if you can effectively have Ansible initiate a remote session, then you "may" be able to?
I use Powershell - since we don't have Ansible setup yet - and basically provide logon credentials to the remote host and then execute:
Code: Select all
$User="AdminUserName"
$Pass="UsersPassword"
$Credential=New-Object System.Management.Automation.PSCredential ($User, (ConverTo-SecureString $Pass -AsPlainText -Force))
$Session=New-PSSession -ComputerName $tmpHost -Credential $Credential
Copy-Item C:\Users\Public\Downloads\ncpa-x.x.x.exe -destination C:\Users\Public\Downloads\ -ToSession $Session
Invoke-Command -Session $Session -ScriptBlock { Start-Process C:\Users\Public\Downloads\ncpa-x.x.x.exe -ArgumentList '/S /TOKEN=ncpatoken /V/qn' -Wait }
Invoke-Command -Session $Session -ScriptBlock { Start-Service -Name 'ncpa' }
Remove-PSSession $Session
No WinRM required - although technically the Session is probably a WinRM connection in the background?
NOTE: I can't copy/paste from our production system so I had to retype this so if there is a typo, sorry.
Hope it helps.
Re: NCPA Agent Deploy to MS systems
Posted: Thu Aug 28, 2025 12:35 pm
by StevenBeauchemin
Thanks!
I'll pass this on to the person who does our non-Nagios ansible. It should give them a jump start at least.
We probably need a separate script for keeping the plugins updated. That is usually a moving target as we create plugins as needed for different applications we are watching.
Steve B