Systemd RestartSec/StartLimitInterval/StartLimitIntervalSec

Systemd

The default delay between executions is 100ms (RestartSec) which causes the rate limit to be reached very fast.

Just using Restart and RestartSec is not enough: systemd services have start rate limiting enabled by default. If service is started more than StartLimitBurst times in StartLimitInterval/StartLimitIntervalSec seconds is it not permitted to start any more.

Add RestartSec=5 in the service section
Add StartLimitInterval=0 in the unit section

[Unit]
Description=Linbpq
After=network.target
StartLimitInterval=0

[Service]
Type=simple
Restart=always
RestartSec=5
ExecStart=/bin/bash /home/pd9q/linbpq/runbpq
WorkingDirectory=/home/pd9q/linbpq

[Install]
WantedBy=multi-user.target
Alias=linbpq.service

Run

systemctl daemon-reload

 

 

RMSGateway New version

There is a new version of RMSGateway. This is at the moment in Beta test. See the mail of Basil N7NIX.
If you like to test the new code. Just mail N7NIX. basil (@) pacabunga.com

 

The new code (version 2.5.0) has been running on a few machines for the
last couple of days. I would like to get a few more sites to try out the
new code before it is released.

If you would like to help please contact me directly & I will give you
instructions on how to install the new code. Only the python scripts &
xml files changed to support the latest Winlink Web Services.

Thanks,
/Basil n7nix

RmsGateway Install and Update script

C. Schuman wrote a script to install and update RMS Gateway. It`s very handy now the are very busy with updating the code of RMS Gateway to handle the new demands of Winlink.

You just have to pay attention to these lines of code that you have the right version.

cd /usr/local/src/ax25
#wget -qt 3 http://k4gbb.us/docs/scripts/rmsgw-2.4.0-181.tgz || /
wget -qt 3 http://k4gbb.no-ip.info/docs/scripts/rmsgw-2.4.0-181.1.tar.bz2
#wget -qt 3 http://www.w3sg.org/RMSGW/download/rmsgw-2.4.0-181.tgz
tar xf rmsgw-2.4.0-181.1.tar.bz2

The version rmsgw-2.4.0-181.1.tar.bz2 is of 14-Sep-2018 16:41

#!/bin/bash
# Installs/Updates the Linux RMS Gateway
# Provided by C Schuman, K4GBB k4gbb1gmail.com
#	Updated 30 Oct 2014

# Color Codes
Reset='\e[0m'
Red='\e[31m'
Green='\e[32m'
Yellow='\e[33m'
Blue='\e[34m'
White='\e[37m'
BluW='\e[37;44m'

UDATE="NO"
GWOWNER="rmsgw"

# Check  User ID

    if [ $UID != 0 ]; then
	echo "You must be root User to perform installation!"
	exit 1
    fi

echo -e "${BluW}\n \t  Install/Update Linux RMS Gate \n${Yellow}\t     version 2.4.0-181  \t \n \t \n${White}  Script provided by Charles S. Schuman ( K4GBB )  \n${Red}               k4gbb1@gmail.com \n${Reset}"

echo -e "${BluW}\t Installing Support libraries \t${Reset}"
apt-get install xutils-dev libxml2 libxml2-dev python-requests -y -q
apt-get install build-essential libax25-dev libx11-dev zlib1g-dev libncurses5-dev -y -q

#  create the group for the gateway if it doesn't exist
    grep "rmsgw:" /etc/group >/dev/null 2>&1
    if [ $? -ne 0 ]; then
	echo "Creating group rmsgw..."
	groupadd rmsgw
    fi

#  create the gateway user if it doesn't exist and lock the account

    grep "rmsgw:" /etc/passwd >/dev/null 2>&1
    if [ $? -ne 0 ]; then
	#
	# create the account
	#
 	echo "Creating user rmsgw..."
 	useradd -s /bin/false -g rmsgw rmsgw
    fi

  # lock the account to prevent a potential hole, unless the
  # owner is root
    if [ "$GWOWNER" != root ]; then
	echo "Locking user account $GWOWNER..."
	passwd -l $GWOWNER >/dev/null
	# while the account is locked, make the password to
	# never expire so that cron will be happy
	chage -E-1 $GWOWNER >/dev/null
    fi

echo -e "${BluW}\t Downloading RMS Source file \t${Reset}"

cd /usr/local/src/ax25
#wget -qt 3 http://k4gbb.us/docs/scripts/rmsgw-2.4.0-181.tgz || /
wget -qt 3 http://k4gbb.no-ip.info/docs/scripts/rmsgw-2.4.0-181.1.tar.bz2
#wget -qt 3 http://www.w3sg.org/RMSGW/download/rmsgw-2.4.0-181.tgz
tar xf rmsgw-2.4.0-181.1.tar.bz2
if [ $? -ne 0 ]
   then
 echo -e "${BluW}${Red}\t RMS File not available \t${Reset}"
 exit 1
fi

echo -e "${BluW}\t Compiling RMS Source file \t${Reset}"
cd rmsgw-2.4.0-181.1
make > RMS.txt

if [ $? -ne 0 ]
   then
 echo -e "${BluW}$Red} \tCompile error${White} - check RMS.txt File \t${Reset}"
 exit 1
   else 
 rm RMS.txt
fi
make install
echo -e "${BluW}RMS Gate Installed \t${Reset}"

# Add RMS_ACI to Crontab
cat /etc/crontab|grep rmsgw || echo "#6,36 *  * * *   rmsgw    /usr/local/bin/rmsgw_aci > /dev/null 2>&1
# (End) " >> /etc/crontab

# Install Logging
if [ ! -f "/etc/rsyslog.d/60-rmsgw.conf" ]; then
echo "# RMS Gate" > /etc/rsyslog.d/60-rms.conf 
echo "        local0.info                     /var/log/rms" >> /etc/rsyslog.d/60-rms.conf 
echo "        local0.debug                    /var/log/rms.debug" >> /etc/rsyslog.d/60-rms.conf
echo "        #local0.debug                   /dev/null" >> /etc/rsyslog.d/60-rms.conf 
echo "
# (End)" >> /etc/rsyslog.d/60-rms.conf 

service restart rsyslog
fi

# Use old rmschanstat file.
if [ -f /usr/local/bin/rmschanstat.~1~ ] ; then
    cp /usr/local/bin/rmschanstat.~1~ /usr/local/bin/rmschanstat
fi

date >> /root/Changes
echo "        RMS Gate Installed - rmsgw-2.4.0-181" >> /root/Changes
echo -e "${BluW} Be Sure to Update/Edit the channels.xml and gateway.config file${Reset}"
exit 0
# (End of Script)

 

Graphic Packet 1.61b / 1.63

Who does not know it from the good old days. I have used it for many years.

Graphic Packet Dos
gp161b > gp161b.zip
gp163update > gp163upd.zip
Graphic Packet Windows
gp85v090 > gp85v090.zip
gp85v091_update > gp85v091_update.zip

Take a look in de Download section of this website for more old Software and Drivers.

Look at this website for all the tools and programs for GP.
http://dnx274.org/markus/gp/

Small BUG in uronode 2.9

Mario YO2LOJ has found a small bug in the source code of UROnode.

Thanks to Marius YO2LOJ for a patch in do_ports within command.c where there is a possibility that the interface count may return NULL and the function will generate an exception in libc for the routine causing the node to segment fault out and disconnect the user from the node.

To patch the bug you need to edit the command.c in the source code of UROnode.
On line 398 you will find this line.

   if (strcmp(ax->dest_addr, "*")!=0 && strcmp(ax25_config_get_name(ax->dev), cp)==0) n++;

You have to replace it with this.

   if (strcmp(ax->dest_addr, "*")!=0 && 
ax25_config_get_name(ax->dev) && strcmp(ax25_config_get_name(ax->dev), cp)==0) n++;

After that you can recompile the source.

Or you can download a complet command.c here.

Install and update script AX25 /tools/libs/apps

Script provided by Charles S. Schuman modified by F6BVP for updating AX.25 libraries and applications. October 22/2017 (update at Jan 13 2019)

#!/bin/bash
# script updated October-22-2017 for VE7FET new AX.25 github repository (F6BVP)
# script update January-13-2019 by VE7FET to correct error checking and update for installconf changes
# Copy this script file in /usr/local/src/ax25/updAX25.sh
# cd into /usr/local/src/ax25
# and execute command : sudo chmod a+x updAX25.sh
# execute command to run the script : ./updAX25.sh
# It will update and re-compile AX.25 libraries, AX.25 tools and AX.25 apps

LIBAX25=linuxax25-master/libax25/
TOOLS=linuxax25-master/ax25tools/
APPS=linuxax25-master/ax25apps/

# Color Codes
Reset='\e[0m'
Red='\e[31m'
Green='\e[30;42m'  # Black/Green
Yellow='\e[33m'
YelRed='\e[31;43m' #Red/Yellow
Blue='\e[34m'
White='\e[37m'
BluW='\e[37;44m'

echo -e "${BluW}\t\n\t Script provided by Charles S. Schuman modified by F6BVP for updating AX.25 libraries and applications\t\n\t\t\t ${Red} January-13-2019    \n \t\t${Yellow}       k4gbb1@gmail.com \n${Reset}"

  if ! uid=0
   then su
  fi

#if [ -f /usr/lib/libax25.a ]; then
echo -e "${Green} Removing Old Libax25 files out of the way${Reset}"
  rm -fr /usr/lib/libax25*
  rm -fr /usr/lib/libax25*.*
#fi

# Make directories if not exist
if [ -d /usr/local/src/ax25/ ]
	then echo "directory /usr/local/src/ax25 already exists"
	else 
	mkdir /usr/local/src/ax25/
fi
if ! [ -d /usr/local/etc/ax25/ ]
	then mkdir /usr/local/etc/ax25/
fi
if ! [ -d /usr/local/var/ax25/ ] 
	then 
		mkdir /usr/local/var/
		mkdir /usr/local/var/ax25
fi
#
# Download libax25 source file 
  cd /usr/local/src/ax25
  rm -fr /usr/local/src/ax25/libax25
  rm -f master.zip
  echo -e "${Green} Getting AX25 libraries, AX25 tools and AX25 apps archives${Reset}"
   wget https://github.com/ve7fet/linuxax25/archive/master.zip
  if [ $? -ne 0 ]
   then
     echo -e "${Red}\t Ax25 Source files are Missing${Reset}"
     exit 1
  fi

echo -e "${Green} Now unarchiving AX.25 files${Reset}"
  rm -fr linuxax25-master
  unzip master.zip
#Libax25 (updating configure.ac for automake > 1.12 compliance)
  cd /usr/local/src/ax25/$LIBAX25
#  
  echo -e "${Green}\t Creating Makefile(s) to prepare libraries compilation${Reset}"
  ./autogen.sh
  ./configure > liberror.txt 2>&1
  echo -e -n "\t  *"
  echo -e "${Green}\t Compiling Runtime Lib files${Reset}"

# Clean old binaries
  make clean
  if [ $? -ne 0 ]
    then
     echo -e "${Red}\t Libax25 Compile error - See liberror.txt${Reset}"
     exit 1
  fi
# Compile
  echo -n "  *"   
  make
  if [ $? -ne 0 ]
    then
     echo -e "${Red}\t Libax25 Compile error - See liberror.txt${Reset}"
     exit 1
  fi
  echo  "  *\n"
# Install
#  make install >> liberror.txt 2>&1
  make install
  if [ $? -ne 0 ]
   then
     echo -e "${Red} Libax25 Install error - See liberror.txt${Reset}"
     exit 1
   else   
     echo -e "${Green} Libax25 Installed${Reset}"
     rm liberror.txt
  fi

# AX25 libraries symbolic name needed for some applications
  cd /usr/local/lib/
  ln -s libax25.so libax25.so.0

# AX25 libraries declaration (into ld.so.conf)
  echo "/usr/local/lib" >> /etc/ld.so.conf && /sbin/ldconfig

# AX25-APPS
  cd /usr/local/src/ax25
  rm -fr /usr/local/src/ax25/ax25apps
  echo -e "${Green} AX.25 applications${Reset}"
#Libax25 (updating configure.ac for automake > 1.12 compliance)
  cd /usr/local/src/ax25/$APPS
#  
  echo -e "${Green}\t Creating Makefile(s) to prepare apps compilation${Reset}"
  ./autogen.sh
  ./configure > appserror.txt 2>&1
  echo -n -e "\t  *" 
# Clean old binaries
  make clean
  if [ $? -ne 0 ]
   then
     echo -e "${Red}\t Ax25-Apps Compile Error - see appserror.txt${Reset}"
     exit 1
  fi
# Compile Ax25-apps
  echo -n "  *" 
  echo -e "${Green}\t Compiling Ax25 apps ${Reset}"
  make
  if [ $? -ne 0 ]
   then
     echo -e "${Red}\t Ax25-Apps Compile Error - see appserror.txt${Reset}"
     exit 1
  fi
# Install Ax25-apps
  echo "  *" 
#  make  install >> appserror.txt 2>&1
  make  install
  if [ $? -ne 0 ]
  then
     echo -e "${Red} Ax25-Apps Install Error - see appserror.txt${Reset}"
     exit 1
  else
     echo -e "${Green} Ax25-apps Installed${Reset}"
     rm appserror.txt
  fi

# AX25-TOOLS
  cd /usr/local/src/ax25
  rm -fr /usr/local/src/ax25/ax25tools
  echo -e "${Green} AX.25 tools${Reset}"
  cd /usr/local/src/ax25/$TOOLS
#  
  echo -n -e "\t  *" 
  echo -e "${Green}\t Creating Makefile(s) to prepare apps compilation${Reset}"
  ./autogen.sh
  ./configure > toolserror.txt 2>&1
# Clean old binaries
  make clean
    if [ $? -ne 0 ]
      then
        echo -e "${Red}\t AX.25 tools Compile error - See toolserror.txt${Reset}"
        exit 1
    fi
# Compile Ax.25 tools
  echo -e "${Green}\t Compiling AX.25 tools${Reset}"
  echo -e "\t  *" 
  make
    if [ $? -ne 0 ]
      then
        echo -e "${Red}\t AX.25 tools Compile error - See toolserror.txt${Reset}"
        exit 1
    fi
# Install Ax.25 tools
  echo "  *" 
  make install
  if [ $? -ne 0 ]
    then
      echo -e "${Red}\t AX.25 tools Install error - See toolserror.txt${Reset}"
      exit 1
    else
      echo -e "${Green} AX.25 tools Installed${Reset}"
      rm toolserror.txt
    fi

# Set permissions for /usr/local/sbin/ and /usr/local/bin
#  cd /usr/local/sbin/
#  chmod 4775 *
#  cd /usr/local/bin/
#  chmod 4775 *
  echo -e "\t \e[030;42m   Ax.25 Libraries, applications and tools were successfully rebuilt and installed${Reset}"
  echo -e "${Green} If this is a first install of AX.25 tools or apps, sample config files were installed in the doc ${Reset}" 
  echo -e "${Green} folder on your system. This is likely something like /usr/local/share/doc or /usr/share/doc. ${Reset}"
  echo -e "${Green} Look in doc/ax25apps/conf and doc/ax25tools/conf for sample conf files, and copy them to your ${Reset}"
  echo -e "${Green} etc/ax25 folder and edit (may be /etc/ax25 or /usr/local/etc/ax25, depending on your system).${Reset}"
# (End of Script)

 

Bpq32 Log options

John G8BPQ has made it possible to move the log dir of linbpq and pilinbpq. Nice

I’ve uploaded versions of linbpq and pilinbpq to my beta download site
that allow you to move the log directory. Start with a command line
parameter of logdir=directory, eg

../pilinbpq logdir=/dev/shm

 

You can download the new version here.

http://www.cantab.net/users/john.wiseman/Documents/Downloads.html

Looking for Constibutor / Author

For the website I am looking for people who want to write and post something on the site. They can be configuration examples, an explanation of how you did something. Updates from packet software. And so on. Are there people who feel like it please let me know via the contact form or via e-mail. pd9q (@) packet-radio.net. Thanks.

O Yes, it`s a hobby, so there is no cash 🙂

LinBPQ Applications Interface.

LinBPQ has a facility to make a tcp connection from the node to an application running on the same machine. This was originally intended to connect to a shell to enable basic configuration editing, but has been generalised to allow connects to other tcp ports, thus allowing you to write your own applications to be used with LinBPQ.

Edit
Henk, pointed out that there was something missing in this story. Nowadays we mainly work with Systemd in the newer version of Linux. So the inetd (internet super server) is no longer part of this. But you can still install it. “sudo apt-get install inetutils-inetd” or the successor to inetd the Xinetd “sudo apt-get install xinetd”
Thank you Henk…

Ok, that sounds nice. Let give it a try.

Fist setup Linbpq, add de “cmdport” to the telnet port section.

PORT
 PORTNUM=4                      ; Optional but sets port number if stated
 ID=Telnet
 DRIVER=Telnet

CONFIG
 CMS=1
 CMSCALL=PI1LAP
 CMSPASS=**********
 LOGGING=1
 DisconnectOnClose=1
 CMDPORT 63000
 TCPPORT=6309
 FBBPORT=6306
 HTTPPORT=****
 LOGINPROMPT=User:
 PASSWORDPROMPT=Password:
 MAXSESSIONS=10
 CTEXT=Welcome to PI1LAP`s Telnet Server.\nPress ? For list of commands \n\n
 USER=pd9q,pass,PD9Q,,SYSOP
ENDPORT

I have add “CMDPORT 63000” but it can by any number.

Now add a Application at the end of de bpq32.cfg

APPLICATION 7,APP,C 4 HOST 0 S

Now we have to add some stuff to /etc/services and /etc/inetd.conf

/etc/services

# Local services
bpqdemo        63000/tcp   # BPQ Demo App

/etc/inetd.conf

bpqdemo    stream    tcp    nowait    pd9q  /usr/local/linbpq/testapp.pl

Now restart inetd. sudo killall -1 inetd

I have found a small script on the internet and make some adjustments.
This script is using some perl modules that has to be installed.

cpanm Linux::SysInfo
cpanm Sys::Info
cpanm Sys::Load
cpanm Sys::MemInfo
cpanm Sys::CpuLoad

The testapp.pl script. /usr/local/linbpq/testapp.pl

#!/usr/bin/perl -w -T

# Simple information script 10/2018. PD9Q/PI1LAP

use strict;
use Sys::Info;
use Sys::Info::Constants qw( :device_cpu );
use Sys::Load qw/getload uptime/;
use Sys::MemInfo qw(totalmem freemem totalswap);
use Sys::CpuLoad;

   my $info = Sys::Info->new;
   my $cpu = $info->device('CPU');
   my $os  = $info->os;

   my $old_fh = select(STDOUT);
$| = 1;
select($old_fh);

my $line = <STDIN>;

   print "Hello " . $line . "Welcome to the LinBPQ System Info App of PI1LAP.\n";
   printf "\nWe have %s ", scalar $cpu->count;
   printf "%s-bit CPU", scalar $cpu->bitness;
   printf " %s\n", scalar $cpu->identify;
   printf "The CPU speed is: %s\n\n", scalar $cpu->speed;
   print "Operating System is\n", $os->name( long => 1 );

   print "\n\nSystem load: ", (getload())[0], "\n";
   print "System uptime: ", int uptime(), "\n\n";

   print 'load average: ',
       join(',', Sys::CpuLoad::load()), "\n\n";

   print "Total memory: ".(&totalmem / 1024)."\n";
   print "Free memory:  ".(&freemem / 1024)."\n";

   print "Total swap: ".(&totalswap / 1024)."\n";
   print "Free swap:  ".(Sys::MemInfo::get("freeswap") / 1024)."\n\n";
   print "Type exit to close\n";

while( my $line = <STDIN> )
{
    $line =~ s/\r?\n$//;
    if ($line =~ /exit/)
    {
                die "shutting down, bye,bye\n";
        }

        # do your processing here!

        print "  $line\n";
}

Now we can run the script from linbpq. Let give it a try.

root@gw:/usr/local/linbpq# telnet localhost 6309
Trying ::1...
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
User:pd9q
Password:

Welcome to PI1LAP`s Telnet Server.
Press ? For list of commands

app
Connected to APP
Hello PD9Q
Welcome to the LinBPQ System Info App of PI1LAP.

We have 1 32-bit CPU Intel(R) Pentium(R) 4 CPU 3.00GHz
The CPU speed is: 2992.432

Operating System is
Debian Linux 8.10 (kernel: 3.16.0-4-686-pae)

System load: 0.07
System uptime: 1211163

load average: 0.07,0.04,0.00

Total memory: 2062392
Free memory:  440452
Total swap: 2783228
Free swap:  2745472

Type exit to close
exit
shutting down, bye,bye
Returned to Node LAPBPQ:PI1LAP-9

http://www.cantab.net/users/john.wiseman/Documents/LinBPQ%20Applications%20Interface.html

Uronode nodesearch 2.2 released

Brian N1URO has released a new version of Nodesearch 2.2

Change is that now users can search a netrom node
by alias. This idea was taken from a recent change in JNOS. Ex:

Which node are you looking for (no * please): NOS
Searching NetRom nodes for NOS …
CTJNOS:N1URO-7    DZINOS:SV1DZI-12  INNOS:N9LYA-5     MFNOS:N1URO-14
NodeSearch v2.2 by N1URO for URONode.
Goodbye.

For now it’s only on the ftp server of N1URO

ftp://n1uro.no-ip.org/pub/hamradio/packet/node-plugins/