Is there a way to monitor the status of SSH tunnel?
Clash Royale CLAN TAG#URR8PPP
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty margin-bottom:0;
up vote
0
down vote
favorite
I work as a system administrator in a Datacentre and as part of my daily routine work, I mostly need to establish a SSH tunnel to access certain critical services to work on. But sometimes the tunnel dies due to network drop. I would like to check whether is there a way to have some SSH tunnel monitor program to check the live status of the tunnel.
For example:
- Green indication when the connection is active and red indication when the tunnel is not active and to which server the tunnel has got established etc..
ssh ssh-tunneling
add a comment |Â
up vote
0
down vote
favorite
I work as a system administrator in a Datacentre and as part of my daily routine work, I mostly need to establish a SSH tunnel to access certain critical services to work on. But sometimes the tunnel dies due to network drop. I would like to check whether is there a way to have some SSH tunnel monitor program to check the live status of the tunnel.
For example:
- Green indication when the connection is active and red indication when the tunnel is not active and to which server the tunnel has got established etc..
ssh ssh-tunneling
2
The only reliable way I've found is to test it periodically,tcping
would be one way to do such tests.. have you tried autossh?
â Jasen
Jul 29 at 4:34
2
everythingcli.org/ssh-tunnelling-for-fun-and-profit-autossh & harding.motd.ca/autossh. Usingautossh
is exactly what I do as well.
â slmâ¦
Jul 29 at 4:36
2
Shows how to make it into a systemd - gist.github.com/thomasfr/9707568.
â slmâ¦
Jul 29 at 4:39
1
Another approach is shown here usinglsof
- superuser.com/questions/248389/list-open-ssh-tunnels.
â slmâ¦
Jul 29 at 7:29
It depends how the tunnel is started but if one ssh connection is used only for that, if the tunnel closes then it means ssh is stopped. So you just need to check if ssh is running or not.
â Patrick Mevzek
Jul 30 at 13:22
add a comment |Â
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I work as a system administrator in a Datacentre and as part of my daily routine work, I mostly need to establish a SSH tunnel to access certain critical services to work on. But sometimes the tunnel dies due to network drop. I would like to check whether is there a way to have some SSH tunnel monitor program to check the live status of the tunnel.
For example:
- Green indication when the connection is active and red indication when the tunnel is not active and to which server the tunnel has got established etc..
ssh ssh-tunneling
I work as a system administrator in a Datacentre and as part of my daily routine work, I mostly need to establish a SSH tunnel to access certain critical services to work on. But sometimes the tunnel dies due to network drop. I would like to check whether is there a way to have some SSH tunnel monitor program to check the live status of the tunnel.
For example:
- Green indication when the connection is active and red indication when the tunnel is not active and to which server the tunnel has got established etc..
ssh ssh-tunneling
asked Jul 29 at 4:24
Gokulnath Kumar
558
558
2
The only reliable way I've found is to test it periodically,tcping
would be one way to do such tests.. have you tried autossh?
â Jasen
Jul 29 at 4:34
2
everythingcli.org/ssh-tunnelling-for-fun-and-profit-autossh & harding.motd.ca/autossh. Usingautossh
is exactly what I do as well.
â slmâ¦
Jul 29 at 4:36
2
Shows how to make it into a systemd - gist.github.com/thomasfr/9707568.
â slmâ¦
Jul 29 at 4:39
1
Another approach is shown here usinglsof
- superuser.com/questions/248389/list-open-ssh-tunnels.
â slmâ¦
Jul 29 at 7:29
It depends how the tunnel is started but if one ssh connection is used only for that, if the tunnel closes then it means ssh is stopped. So you just need to check if ssh is running or not.
â Patrick Mevzek
Jul 30 at 13:22
add a comment |Â
2
The only reliable way I've found is to test it periodically,tcping
would be one way to do such tests.. have you tried autossh?
â Jasen
Jul 29 at 4:34
2
everythingcli.org/ssh-tunnelling-for-fun-and-profit-autossh & harding.motd.ca/autossh. Usingautossh
is exactly what I do as well.
â slmâ¦
Jul 29 at 4:36
2
Shows how to make it into a systemd - gist.github.com/thomasfr/9707568.
â slmâ¦
Jul 29 at 4:39
1
Another approach is shown here usinglsof
- superuser.com/questions/248389/list-open-ssh-tunnels.
â slmâ¦
Jul 29 at 7:29
It depends how the tunnel is started but if one ssh connection is used only for that, if the tunnel closes then it means ssh is stopped. So you just need to check if ssh is running or not.
â Patrick Mevzek
Jul 30 at 13:22
2
2
The only reliable way I've found is to test it periodically,
tcping
would be one way to do such tests.. have you tried autossh?â Jasen
Jul 29 at 4:34
The only reliable way I've found is to test it periodically,
tcping
would be one way to do such tests.. have you tried autossh?â Jasen
Jul 29 at 4:34
2
2
everythingcli.org/ssh-tunnelling-for-fun-and-profit-autossh & harding.motd.ca/autossh. Using
autossh
is exactly what I do as well.â slmâ¦
Jul 29 at 4:36
everythingcli.org/ssh-tunnelling-for-fun-and-profit-autossh & harding.motd.ca/autossh. Using
autossh
is exactly what I do as well.â slmâ¦
Jul 29 at 4:36
2
2
Shows how to make it into a systemd - gist.github.com/thomasfr/9707568.
â slmâ¦
Jul 29 at 4:39
Shows how to make it into a systemd - gist.github.com/thomasfr/9707568.
â slmâ¦
Jul 29 at 4:39
1
1
Another approach is shown here using
lsof
- superuser.com/questions/248389/list-open-ssh-tunnels.â slmâ¦
Jul 29 at 7:29
Another approach is shown here using
lsof
- superuser.com/questions/248389/list-open-ssh-tunnels.â slmâ¦
Jul 29 at 7:29
It depends how the tunnel is started but if one ssh connection is used only for that, if the tunnel closes then it means ssh is stopped. So you just need to check if ssh is running or not.
â Patrick Mevzek
Jul 30 at 13:22
It depends how the tunnel is started but if one ssh connection is used only for that, if the tunnel closes then it means ssh is stopped. So you just need to check if ssh is running or not.
â Patrick Mevzek
Jul 30 at 13:22
add a comment |Â
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f459125%2fis-there-a-way-to-monitor-the-status-of-ssh-tunnel%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
2
The only reliable way I've found is to test it periodically,
tcping
would be one way to do such tests.. have you tried autossh?â Jasen
Jul 29 at 4:34
2
everythingcli.org/ssh-tunnelling-for-fun-and-profit-autossh & harding.motd.ca/autossh. Using
autossh
is exactly what I do as well.â slmâ¦
Jul 29 at 4:36
2
Shows how to make it into a systemd - gist.github.com/thomasfr/9707568.
â slmâ¦
Jul 29 at 4:39
1
Another approach is shown here using
lsof
- superuser.com/questions/248389/list-open-ssh-tunnels.â slmâ¦
Jul 29 at 7:29
It depends how the tunnel is started but if one ssh connection is used only for that, if the tunnel closes then it means ssh is stopped. So you just need to check if ssh is running or not.
â Patrick Mevzek
Jul 30 at 13:22