ssh_tunnel statistics: rlarsen to zippy

Time: 2022-Aug-16 13:43:05 Tue

Current tunnel state: disabled          Current tunnel condition: DOWN

loader stats

------ loader (pid: 1451 ) ------------ (v3.26 2006/04/15) ----- State: disabled UP
Time:                2022-Aug-16 09:51:36 Tue
client:              rlarsen
server:              zippy
client heartbeat:    Tue Aug 16 09:47:42 EDT 2022
server heartbeat:    Tue Aug 16 09:47:42 EDT 2022
server heartbeat 1:  Tue Aug 16 09:47:42 EDT 2022
server heartbeat 2:  Tue Aug 16 09:43:44 EDT 2022
server heartbeat 3:  Server Heartbeat 1
server heartbeat 4:  Server Heartbeat 2
Sleep time:          238
loader loop counter: 3
bad port tests:      0     last: none yet
failed file updates: 0     last: none yet
tunnels killed:      2     last: 2022-Aug-16 09:51:06 Tue
emails sent:         3     last: 2022-Aug-16 09:51:06 Tue
email addresses:     john@larsen-family.us
loader started:      2022-Aug-16 09:43:06 Tue
debug flags:         0x0

tunnel stats

------ tunnel (pid: 1513 ) ------------ (v3.26 2006/04/15) ----- State: enabled UP
Time:                2022-Aug-16 09:47:43 Tue
client:              rlarsen
server:              zippy
client heartbeat:    Tue Aug 16 09:47:42 EDT 2022
server heartbeat:    Tue Aug 16 09:43:44 EDT 2022
Sleep time:          238
tunnel loop counter: 2
bad port tests:      0     last: none yet
emails sent:         1     last: 2022-Aug-16 09:43:12 Tue
email addresses:     john@larsen-family.us
tunnel started:      2022-Aug-16 09:43:43 Tue
debug flags:         0x0

Current users, uptime, and load average

 13:43:05 up 8 days,  2:35,  0 users,  load average: 0.00, 0.00, 0.00
USER     TTY        LOGIN@   IDLE   JCPU   PCPU WHAT

Current processes

UID        PID  PPID  C STIME TTY          TIME CMD
cyg_ser+   522     1  0 Aug08 ?        00:00:00 /usr/bin/cygrunsrv
Admin     3197   521  0 Aug08 ?        00:00:00 /usr/sbin/cron -n
Admin     3213     1  0 Aug08 ?        00:00:00 /usr/bin/perl -w /home/Admin/ssh_tunnel/zippy/ssh_tunnel.pl
cyg_ser+   523   522  0 Aug08 ?        00:00:00 /usr/sbin/sshd -D
Admin     3218  3213  0 Aug08 ?        00:00:00 /usr/bin/procps -edf
Admin      521   520  0 Aug08 ?        00:00:00 /usr/sbin/cron -n
Admin      520     1  0 Aug08 ?        00:00:00 /usr/bin/cygrunsrv

Current netstat


Active Connections

  Proto  Local Address          Foreign Address        State
  TCP    10.0.0.65:61437        173-14-166-6-NewEngland:ssh  TIME_WAIT
  TCP    127.0.0.1:5905         June-PC:49155          ESTABLISHED
  TCP    127.0.0.1:5905         June-PC:49156          ESTABLISHED
  TCP    127.0.0.1:5905         June-PC:49157          ESTABLISHED
  TCP    127.0.0.1:5905         June-PC:49158          ESTABLISHED
  TCP    127.0.0.1:5905         June-PC:49159          ESTABLISHED
  TCP    127.0.0.1:5905         June-PC:49160          ESTABLISHED
  TCP    127.0.0.1:5905         June-PC:49161          ESTABLISHED
  TCP    127.0.0.1:5905         June-PC:49162          ESTABLISHED
  TCP    127.0.0.1:5905         June-PC:49163          ESTABLISHED
  TCP    127.0.0.1:5905         June-PC:49164          ESTABLISHED
  TCP    127.0.0.1:49155        June-PC:5905           ESTABLISHED
  TCP    127.0.0.1:49156        June-PC:5905           ESTABLISHED
  TCP    127.0.0.1:49157        June-PC:5905           ESTABLISHED
  TCP    127.0.0.1:49158        June-PC:5905           ESTABLISHED
  TCP    127.0.0.1:49159        June-PC:5905           ESTABLISHED
  TCP    127.0.0.1:49160        June-PC:5905           ESTABLISHED
  TCP    127.0.0.1:49161        June-PC:5905           ESTABLISHED
  TCP    127.0.0.1:49162        June-PC:5905           ESTABLISHED
  TCP    127.0.0.1:49163        June-PC:5905           ESTABLISHED
  TCP    127.0.0.1:49164        June-PC:5905           ESTABLISHED

crontab file

# DO NOT EDIT THIS FILE - edit the master and reinstall.
# (/tmp/crontab.q5SHPLUqO6 installed on Sun Apr 14 22:26:25 2019)
# (Cron version V5.0 -- $Id: crontab.c,v 1.12 2004/01/23 18:56:42 vixie Exp $)
# m h  dom mon dow   command
MAILTO=john@larsen-family.us
#* * * * * echo "`date`: Crontab test" > /tmp/crontab_test.txt; echo "`date`: Crontab test"

# Perform the nightly backup --------------------------------------
2 3 * * * /home/Admin/backup/backup.cron
3 3 * * * /home/Admin/backup/backup.cron
#40 19 * * * /home/Admin/backup/backup.cron

# Perform periodic speedtest --------------------------------------
#0,15,30,45 * * * * /home/Admin/speedtest/speedtest.sh
0,5,10,15,20,25,30,35,40,45,50,55 * * * * /home/Admin/speedtest/speedtest.sh
#* * * * * /home/Admin/speedtest/speedtest.sh

# Maintain ssh tunnel ----------------------------------------------
3,13,23,33,43,53 * * * * /home/Admin/ssh_tunnel/zippy/ssh_tunnel.pl

loader.conf file

# Filename:  loader.conf
# Description:  This is the configuration file for the loader portion of the 
# ssh_tunnel program.  The contents of this file never change.  This insures
# that the loader will always operate.  It is important not to change the 
# formatting of this file because it is read by the ssh_tunnel and processed 
# using perl which is expecting things to be in certain locations.
#
# loader.conf has two sections:
# 1. Configuration information such as the names of the ssh and sshd
#    hosts, the working directories on each host, and other data as needed.
# 2. The ssh host configuration for the loader program is in this file.
#    That configuration should never change.  It needs to be at the end
#    of the file because ssh uses everything between "Host" entries as
#    configuration.  There is only one Host section in this file.
#
########################################################################
# The following section contains host information 
# SSH_CLIENT      rlarsen
# SSH_CLIENT_DIR  /home/Admin/ssh_tunnel/zippy
# SSH_SERVER      zippy
# SSH_SERVER_DIR  /home/tunnels/ssh_tunnel/rlarsen
#
########################################################################
# The following section is the ssh config file for the loader program.
# IMPORTANT!  The path on the client MUST have the SSH_SERVER name in
# it.  The script uses this name is search strings and it MUST be there.
Host loader
HostName sml.dnsalias.org
Port = 22
UserKnownHostsFile = /home/Admin/ssh_tunnel/zippy/known_hosts
User = tunnels
IdentityFile = /home/Admin/ssh_tunnel/zippy/id_rsa.rlarsen

tunnel.conf file

# Filename:  tunnel.conf
#
# Description:  This is the configuration file for the tunnel portion of the 
# ssh_tunnel program.  The contents of this file can be changed during program execution.
# It is important not to change the formatting of the file because it is read by the
# tunnel program and processed using awk which is expecting things to be in certain
# locations.
#
# tunnel.conf has three sections:
# 1. Configuration information such as email addresses and thresholds.
# 2. The ssh host configuration for the tunnel.  This consists of two
#    host definitions, tunnel and heartbeat.  The tunnel is the permanent
#    connection and defines port forwarding.  The heartbeat uses one of 
#    the forwarded ports to write and copy heartbeat files between the
#    ssh client and the ssh server.  Changing heartbeats indicate that the
#    tunnel is functioning.
# 3. The webpage configuration section as described below.  This has the
#    ssh host configuration for updating a webpage on a webserver.
#
################################################################################
# The following section contains configuration information
#
# The tunnel is either "enabled" or "disabled" based on the value given
# below.  If disabled, then no processes are running on either the
# client or the server.  A cron job on the client runs ssh_tunnel.pl periodically
# to check if tunnel.conf has changed on the server.  If a change is detected
# then the new tunnel.conf file is transfered over.  If the tunnel state
# becomes "enabled" then the tunnel is activated.
# TUNNEL_STATE disabled
#
# The email addresses below receive diagnostic messages.  Separate
# multiple addresses with commas and no white space.  The word "none"
# turns off email sending and is the default.  The same email address
# is used by cron, loader, tunnel, and pulse.
# EMAIL_ADDRESS     john@larsen-family.us
#
# The threshold defined below is how many port failures are required
# before an email is sent.  Set this to "none" to turn this off.  If
# the ssh_server's ssh port isn't accessible then the loader kills 
# the tunnel.  This periodic email serves as a reminder that the tunnel
# is down.
# EMAIL_THRESHOLD   50
#
# The loader, tunnel, and pulse programs all have the same sleep value.
# The sleep time can be changed here.  It should be in the range of
# 60 to 3600 seconds.  Shorter sleep times increase system loading.
# The sleep time must be less than half the crontab time for ssh_tunnel.pl.
# SLEEP_TIME        238
#
#
################################################################################
# The following section is the ssh config file for the tunnel program.
# IMPORTANT!  The path on the client MUST have the SSH_SERVER name in
# it.  The script uses this name is search strings and it MUST be there.
#
# Important info about port numbers used in the "ssh_tunnel" and "heartbeat"
# sections below.  The "heartbeat" Port number must be the same as the last
# two port numbers in the "ssh_tunnel" section.  In this example 50022 is
# used.  The port number used must be unused by anything else on the two
# machines.  If you have multiple tunnels connecting to a single ssh_server
# be sure to use different port numbers.  
#
# Another requirement is that the ssh_server must be configured to
# allow remote port forwarding.  This is normally off by default in the 
# ssh_server's sshd_config file.  Set "GatewayPorts yes" in sshd_config.
#
Host tunnel
HostName sml.dnsalias.org
Port = 22
UserKnownHostsFile = /home/Admin/ssh_tunnel/zippy/known_hosts
User = tunnels
IdentityFile = /home/Admin/ssh_tunnel/zippy/id_rsa.rlarsen
Compression = yes
RemoteForward = 43980 192.168.1.1:80
RemoteForward = 43443 192.168.1.1:443
RemoteForward = 43999 localhost:5900
RemoteForward = 43222 localhost:22
RemoteForward = 43022 localhost:22
LocalForward = 43022 localhost:22

################################################################################
Host heartbeat
HostName localhost
Port = 43022
UserKnownHostsFile = /home/Admin/ssh_tunnel/zippy/known_hosts
User = tunnels
IdentityFile = /home/Admin/ssh_tunnel/zippy/id_rsa.rlarsen

################################################################################
Host pulse
HostName localhost
Port = 43022
UserKnownHostsFile = /home/tunnels/ssh_tunnel/rlarsen/known_hosts
User = Admin
IdentityFile = /home/tunnels/ssh_tunnel/rlarsen/id_rsa.rlarsen

################################################################################
# Note: This section must be last in tunnel.conf.
# A webpage will be copied to the directory set by WEBSERVER_DIR below.  The
# default value "none" turns this feature off.  Change "none" to the directory
# path where the webpage should be copied.  The "webpage" host information 
# below must also be changed to valid values to make this work.
# WEBSERVER_DIR     /home/tunnels/ssh_tunnel_html
#
# The filename of the webpage copied to the webserver defaults to
# SSH_CLIENT_to_SSH_SERVER.html.  To choose a different name replace the
# word "default" on the line below with the desired name.
# WEBPAGE_FILENAME  default
#
# A copy of the webpage can be put in the directory define by WEBPAGE_LOCAL_DIR.
# Change "none" to a valid directory to enable this feature.
# WEBPAGE_LOCAL_DIR  none
#
# The webpage update rate defaults to once per sleep time. Change the value below
# to select a different rate.  The update rate is the number of times through the
# loader while loop before updating the webpage.  This value is ignored when events
# occur such as the tunnel going down or during startup.  The webpage is updated
# for all non normal runtime events.
# WEBPAGE_UPDATE_RATE   1
#
Host webpage
HostName sml.dnsalias.org
Port = 22
UserKnownHostsFile = /home/Admin/ssh_tunnel/zippy/known_hosts
User = tunnels
IdentityFile = /home/Admin/ssh_tunnel/zippy/id_rsa.rlarsen