Nagiox XI - SSH Actions

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
Boune
Posts: 12
Joined: Wed Feb 14, 2018 4:15 am

Nagiox XI - SSH Actions

Post by Boune »

Hi,

Im trying to set up the SSH action wih the following nagios documentation :
https://support.nagios.com/kb/article.php?id=530

but it doesnt work for me...

nothing happen when i click "SSH access" u can check my capture:

when i run the putty_util.bat , it launch putty so the script is ok.

i try to make it works on Google Chrome on windows 10

thanks
You do not have the required permissions to view the files attached to this post.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Nagiox XI - SSH Actions

Post by scottwilkerson »

Lets verify that both these were added

Code: Select all

reg add HKEY_CLASSES_ROOT\ssh /f /ve /d "URL:ssh Protocol" 
reg add HKEY_CLASSES_ROOT\ssh /f /v "URL Protocol" /d "" 
Then also, I believe you need to restart the computer for the changes to take affect.
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Boune
Posts: 12
Joined: Wed Feb 14, 2018 4:15 am

Re: Nagiox XI - SSH Actions

Post by Boune »

Hello,

Yep , i restarted my computer after reg modification.

here my regedit
You do not have the required permissions to view the files attached to this post.
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: Nagiox XI - SSH Actions

Post by cdienger »

I believe this is caused by the browser adding a "/" at the end - at least that is what I am seeing on my system. Currently workingn through this on my end, but I'd like you to modify the batch script slightly to verify if this is the same problem you're seeing. Try:

Code: Select all

@echo on
set var=%1 
echo %var%
set extract=%var:~6,-1% 
start "" "C:\Program Files (x86)\PuTTY\putty.exe" %extract%
ping 127.0.0.1 -n 6 > nul
This will keep the command line Window open long enough to gather some details.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: Nagiox XI - SSH Actions

Post by cdienger »

Changing the extract line to:

set extract=%var:~6,-2%

Did the trick for me. There must be a hidden carriage return or something that the -1 strips off and we have to remove one more to remove the /.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Boune
Posts: 12
Joined: Wed Feb 14, 2018 4:15 am

Re: Nagiox XI - SSH Actions

Post by Boune »

Hi ,

I think i have another problem , the cmd prompt wont start... so i cant debug this with ur code...

it's like google chrome can't launch the putty_util.bat
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: Nagiox XI - SSH Actions

Post by cdienger »

Wont start as in using Win+R to open a run window and typing cmd.exe doesn't bring it up or closes it right away? If so, it sounds like you may have restrictions on the machine. Are you running with an admin account?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Locked