# Reverse SSH Verification

##### Logs

- /var/log/pulse/xmpp-agent-relay.log
- /var/log/mmc/master-mast.log
- C:\\Program Files\\Medulla\\var\\log\\xmpp-agent-machine.log

##### Debugging operations

<div id="bkmrk-sur-le-client">**On the client**</div><div id="bkmrk-l%27%C3%A9tablissement-du-r">Reverse SSH connections from clients are established via the following scripts</div>- Linux: /var/lib/pulse2/reversessh.sh
- Windows: c:\\Program Files\\Medulla\\bin\\reversessh.ps1

<div id="bkmrk-sur-linux%2C-il-est-po">On Linux, you can run these scripts manually to test the tunnel setup. Refer to these scripts to find the port number being used. e.g.:</div>```
/usr/bin/ssh -t -t -R <strong>51891</strong>:localhost:22 -o StrictHostKeyChecking=no -i "/var/li
b/pulse2/.ssh/id_rsa" -l reversessh 192.168.2.15 -p 22
```

<div id="bkmrk-sur-windows%2C-il-faut">On Windows, you must use the MMC console to enable debugging during deployment. To do this, stop the OpenSSH service from an XMPP console to force the reverse SSH connection:</div>```
sc stop sshdaemon
```

[![image (10).png](https://docs.medulla-tech.io/uploads/images/gallery/2026-01/scaled-1680-/gpea54rxjPat4PvG-image-10.png)](https://docs.medulla-tech.io/uploads/images/gallery/2026-01/gpea54rxjPat4PvG-image-10.png)

Start a deployment. In the audit view, the result of the reverse SSH connection will be displayed:

[![image (11).png](https://docs.medulla-tech.io/uploads/images/gallery/2026-01/scaled-1680-/oJ456tnlibEHmwft-image-11.png)](https://docs.medulla-tech.io/uploads/images/gallery/2026-01/oJ456tnlibEHmwft-image-11.png)

<span style="text-decoration:underline;"><span style="color:rgb(0,0,0);text-decoration:underline;">**If the tunnel does not establish, it is either a port issue or a key issue**</span></span>

<div id="bkmrk-sur-le-relais">**On the relay**</div><div id="bkmrk-le-script-suivant-pe">The following script allows you to test the establishment of the reverse connection on the ARSs on the defined port (see above):</div>```
#!/bin/bash
echo "port $1"
echo "reverse exists"
netstat -an | egrep "tcp.*:$1.*LISTEN"
echo "reverse in use"
netstat -an | egrep "tcp.*:$1.*ESTABLISHED"
echo "reverse PID"
lsof -t -i :$1 -s tcp:LISTEN
```

<div id="bkmrk-on-peut-voir-les-pro">You can view the reverse SSH processes with:</div>```
ps aux | grep ssh
```

<div id="bkmrk-root%C2%A0-%C2%A0-%C2%A0-2267%C2%A0-0.0%C2%A0">root 2267 0.0 0.1 95184 6860 ? Ss 15:26 0:00 sshd: reversessh [priv]  
reverse+ 2280 0.0 0.0 95184 3868 ? S 15:26 0:00 sshd: reversessh@pts/7  
  
on Windows:</div>```
tasklist | findstr ssh
```

<div id="bkmrk--2"></div>