Ok I think I'm done for the night

This commit is contained in:
Hibby 2024-07-17 01:31:30 +01:00
parent 7335d94ad9
commit 8c81240e8a
Signed by: hibby
SSH Key Fingerprint: SHA256:Y6XbnzN0FEB1R/exPF5hUbHUgE/Nn7M1uT566fxo6pE
5 changed files with 184 additions and 61 deletions

View File

@ -2,7 +2,14 @@
For Debian-alikes, see [installation instructions](../install/linux.md). For Debian-alikes, see [installation instructions](../install/linux.md).
Each of the below components are required to make the complete node, but they are (generally) not all interdependent, and most of the unique components will work to make a stripped down version. Each of the below components are required to make the complete node, but they
are (generally) not all interdependent, and most of the unique components will
work to make a stripped down version.
!!! warning
It can be assumed that most of this is not for the Linux newbie, and
that commands here are to be run as
[root](../linux.md/#users-permissions-and-sudo), exercise good judgement!
## axports ## axports
@ -10,13 +17,16 @@ Setting up basic AX.25 on Debian is relatively simple - the key file to edit her
GB7HIB currently runs the following below config. Each port has been given an internal reference, I like to detail what connection they are providing. Other people map them out by number or other methods, but I find having a pretty consistent set of references to the radio/interface I'm using keeps my brain in check. GB7HIB currently runs the following below config. Each port has been given an internal reference, I like to detail what connection they are providing. Other people map them out by number or other methods, but I find having a pretty consistent set of references to the radio/interface I'm using keeps my brain in check.
The callsign&SSID is, in this case, the physical address for the port, akin to a MAC address on ethernet. It shows under `ifconfig` as a mac address for the link. The callsign&SSID is, in this case, the physical address for the port, akin to a MAC address on Ethernet. It shows under `ifconfig` as a mac address for the link.
Speed is the speed of the serial port on the interface. In the case of the NinoTNC, this is 57600. Speed is the speed of the serial port on the interface. In the case of the NinoTNC, this is 57600.
Paclen is the packet length - for V/UHF links, 255 bytes is a nice length. For HF, 60-80 is more common. It means for shorter packets that aren't as likely to be impacted by changes in propagation. Paclen is the packet length - for V/UHF links, 255 bytes is a nice length. For HF, 60-80 is more common. It means for shorter packets that aren't as likely to be impacted by changes in propagation.
Window is the number of packets that can be sent in one burst. The more reliable the link,the higher the number. This is limited by the version of ax25 you're running - 2.0 has a lower window than 2.0. If you're running Linux, at the moment you're on ax25 2.0. Window is the number of packets that can be sent in one burst. The more reliable
the link,the higher the number. This is limited by the version of ax25 you're
running - 2.0 has a lower window than 2.2. If you're running Linux, at the
moment you're on ax25 2.0.
``` ```
hibby@raspberrypi:~ $ cat /etc/ax25/axports hibby@raspberrypi:~ $ cat /etc/ax25/axports
@ -35,7 +45,8 @@ ip GB7HIB-11 115200 255 7 IP
`kissattach` binds the axport to a physical kiss device. `kissattach` binds the axport to a physical kiss device.
I attach my UHF port to my NinoTNC with: I attach my UHF port to my NinoTNC with:
`kissattach /dev/ttyACM0 uhf` !!! note "Terminal Command"
`kissattach /dev/ttyACM0 uhf`
### axcall ### axcall
@ -61,9 +72,11 @@ We create a virtual modem with `ax25ipd`, a virtual pipe with `socat` that lets
I create a socket pair to connect `ax25ipd` and `kissattach` to connect the `ip` ax25 port to the axudp tunnel. I create a socket pair to connect `ax25ipd` and `kissattach` to connect the `ip` ax25 port to the axudp tunnel.
The command I run for this is: The command I run for this is:
```socat -d -d -ly pty,raw,echo=0,link=/var/ax25/pty/axip1 pty,raw,echo=0,link=/var/ax25/pty/axip2``` !!! note "Terminal Command"
`socat -d -d -ly pty,raw,echo=0,link=/var/ax25/pty/axip1 pty,raw,echo=0,link=/var/ax25/pty/axip2`
If you are copying this, you might need to make the `/var/ax25/pty` - `mkdir -p /var/ax25/pty` !!! tip
If you are copying this, you might need to make the `/var/ax25/pty` - `mkdir -p /var/ax25/pty`
This is brought up at boottime by systemd: This is brought up at boottime by systemd:
@ -107,29 +120,29 @@ route MM3NDH 10.13.37.2 bd
### Running ax25ipd ### Running ax25ipd
This is run from the command line as follows: This is run from the command line as follows:
!!! note "Terminal Command"
`ax25ipd` `ax25ipd`
### kissattach ### kissattach
We need to attach the axip port to the virtual modem we've created with ax25ipd once it's running, and this is a simple case of: We need to attach the axip port to the virtual modem we've created with ax25ipd once it's running, and this is a simple case of:
!!! note Terminal Command
`kissattach /var/ax25/pty/axip2 axip` `kissattach /var/ax25/pty/axip2 axip`
## NET/ROM ## NET/ROM
NET/ROM covers functionality analogous to OSI layer3/layer 4. NET/ROM covers functionality analogous to OSI layer3/layer 4.
What it means in reality is that my node has a knowledge of its neighbours and what their neighbours are, and automates routing calls. To use the earlier example, I can call directly to gm0cqv and my machine will know the best path - What it means in reality is that my node has a knowledge of its neighbours and what their neighbours are, and automates routing calls. To use the earlier example, I can call directly to gm0cqv and my machine will know the best path -
!!! note "Terminal Command"
`axcall nrnod GM0CQV-7` `axcall nrnod GM0CQV-7`
Each NET/ROM sends a 'NODES' broadcast periodically. This details what systems it can hear, what the gateway to the remote nodes is and a 'quality' value. Each NET/ROM sends a 'NODES' broadcast periodically. This details what systems it can hear, what the gateway to the remote nodes is and a 'quality' value.
Nodes on the network can have an alias too - GM0CQV's node on -7 above is PTRNOD, so I can do the following - Nodes on the network can have an alias too - GM0CQV's node on -7 above is
PTRNOD, so I can do the following to end up at the same location -
`axcall nrnod PTRNOD` !!! note "Terminal Command"
`axcall nrnod PTRNOD`
and end up at the same location.
NET/ROM ports are largely independent of ax25 ports in that a user can call any given nrport without going through a specific axport. You can essentially define per-application nrports, and as many as you wish (assuming you have free unique SSIDs to offer them as mac addresses). NET/ROM ports are largely independent of ax25 ports in that a user can call any given nrport without going through a specific axport. You can essentially define per-application nrports, and as many as you wish (assuming you have free unique SSIDs to offer them as mac addresses).
@ -151,15 +164,21 @@ nrnod GB7HIB-1 HIBNOD 235 Netrom node Port
nrbbs GB7HIB-2 HIBBBS 235 Netrom BBS Port nrbbs GB7HIB-2 HIBBBS 235 Netrom BBS Port
``` ```
I have a port for my service, the callsign and port, and an up to 6 letter alias for the service. The packet length is 20 bytes shorter than the ax25 packet to account for overheads, and then there's a wee description. I have a port for my service, the callsign and port, and an up to 6 letter alias
for the service. The packet length is 20 bytes shorter than the ax25 packet to
account for overheads, and then there's a wee description.
### nrbroadcast ### nrbroadcast
`/etc/ax25/nrbroadcast` defines how often `netromd` sends a NODES broadcast and what port it sends them over. `/etc/ax25/nrbroadcast` defines how often `netromd` sends a NODES broadcast and
what port it sends them over.
It also defines the default quality of stations received directly over that port, the worst quality it will broadcast, how long without hearing a nodes broadcast the station will remain in your routing table. It also defines the default quality of stations received directly over that
port, the worst quality it will broadcast, how long without hearing a nodes
broadcast the station will remain in your routing table.
I have set some sensible defaults, things that come over the ip link are quite high, but I limit the worst quality so that my NODES table isn't too big. I have set some sensible defaults, things that come over the ip link are quite
high, but I limit the worst quality so that my NODES table isn't too big.
``` ```
hibby@raspberrypi:~ $ cat /etc/ax25/nrbroadcast hibby@raspberrypi:~ $ cat /etc/ax25/nrbroadcast
@ -178,8 +197,8 @@ ip 3 200 130 1
Like AX.25, we need to attach the port to a device - our tool for this is `nrattach`. Like AX.25, we need to attach the port to a device - our tool for this is `nrattach`.
`nrattach` is simple - you nrattach a port and that's it. `nrattach` is simple - you nrattach a port and that's it.
!!! note "Terminal Command"
`nrattach nrnod` `nrattach nrnod`
### netromd ### netromd
@ -187,23 +206,39 @@ Like AX.25, we need to attach the port to a device - our tool for this is `nratt
I should really make this systemd unit come up after nrattach. I should really make this systemd unit come up after nrattach.
I run it as `netromd -i -l -d -t 30`, which broadcasts almost immidiately, creates debug logs and broadcasts every 30 minutes. I run it as below:
!!! note "Terminal Command"
`netromd -i -l -d -t 30`
This broadcasts almost immediately, creates debug logs and broadcasts every 30 minutes.
## ax25d ## ax25d
ax25d is the Daemon that routes incoming connection requests and spins up a process for the caller. ax25d is the Daemon that routes incoming connection requests and spins up a
process for the caller.
Interestingly, it isn't tied to the incoming port that the call is coming through, so you can have any port or interface handle calls to any callsign, alias or other word. Interestingly, it isn't tied to the incoming port that the call is coming
through, so you can have any port or interface handle calls to any callsign,
alias or other word.
`/etc/ax25/ax25d.conf` is the config file that controls this, and it handles ax25 ports and netrom ports slightly differently. The default config we ship with debian is full of great examples, see online [here](https://salsa.debian.org/debian-hamradio-team/ax25-tools/-/blob/master/ax25/ax25d.conf.in?ref_type=heads) - mine is configured as below. `/etc/ax25/ax25d.conf` is the config file that controls this, and it handles
ax25 ports and netrom ports slightly differently. The default config we ship
with debian is full of great examples, see online
[here](https://salsa.debian.org/debian-hamradio-team/ax25-tools/-/blob/master/ax25/ax25d.conf.in?ref_type=heads)
- mine is configured as below.
Reading it, you can see that GB7HIB is in [] and nrnod is in <>. They define the type of port. Reading it, you can see that GB7HIB is in [] and nrnod is in <>. They define the
This means if you connect to GB7HIB over ax25, you get uronode. type of port. This means if you connect to GB7HIB over ax25, you get uronode.
If you connect to HIBNOD, or GB7HIB-1 over netrom, you get uronode! If you connect to HIBNOD, or GB7HIB-1 over netrom, you get uronode!
I am really interested in exploring some other applications, including `axspawn`, which lets you spawn a bash (or other) shell and effectively gives shell access over ax25/netrom to a user. I am really interested in exploring some other applications, including
`axspawn`, which lets you spawn a bash (or other) shell and effectively gives
shell access over ax25/netrom to a user.
There's lots of options here, and it's an incredibly flexible piece of software and is the core of why the Linux stack is so interesting to me. You can present any binary on your system to a connecting user! There's lots of options here, and it's an incredibly flexible piece of software
and is the core of why the Linux stack is so interesting to me. You can present
any binary on your system to a connecting user!
``` ```
hibby@raspberrypi:~ $ cat /etc/ax25/ax25d.conf hibby@raspberrypi:~ $ cat /etc/ax25/ax25d.conf
@ -231,20 +266,26 @@ default * * * * * * - root /usr/sbin/uronode uronode
### Running ax25d ### Running ax25d
This is an easy one to start - This is an easy one to start -
!!! note "Terminal Command"
`ax25d` `ax25d`
## Uronode Frontend ## Uronode Frontend
I use uronode both as a frontend for users connecting and for me connecting to the node and to neighbouring stations, essentially over telnet. When someone connects to my system, Uronode generates the menu that they see. I use uronode both as a frontend for users connecting and for me connecting to
the node and to neighbouring stations, essentially over telnet. When someone
connects to my system, Uronode generates the menu that they see.
I also have it configured as my local client - i can run `uronode` in a terminal and be presented with a helpful control interface. I also have it configured as my local client - i can run `uronode` in a terminal
and be presented with a helpful control interface.
### uronode.conf ### uronode.conf
This is the core config file for uronode that details what uronode can do. I'm running mine very stripped back, and have cut a lot of the defaults out: This is the core config file for uronode that details what uronode can do. I'm
running mine very stripped back, and have cut a lot of the defaults out:
You can see the BBS command is just a uronode call out to GB7HIB-2 over netrom, and there are external commands for netstat and the 'nodesearch' program I quite like. You can see the BBS command is just a uronode call out to GB7HIB-2 over netrom,
and there are external commands for netstat and the 'nodesearch' program I quite
like.
The rest is pretty much default. The rest is pretty much default.
@ -336,16 +377,22 @@ This defines shell access for me as a sysop. I've never actually spawned a shell
### Uronode as a local interface ### Uronode as a local interface
I use uronode as my local packet radio terminal - instead of turning on and typing `axcall nrnod salbbs` to get to gm0nrt, I log in, type uronode, feed it my callsign and I am met with the uronode command interface, from which I can type `c salbbs`. It's a much nicer place to be! I use uronode as my local packet radio terminal - instead of turning on and
typing `axcall nrnod salbbs` to get to gm0nrt, I log in, type uronode, feed it
my callsign and I am met with the uronode command interface, from which I can
type `c salbbs`. It's a much nicer place to be!
This required `xinetd` for me to set up easily. This required `xinetd` for me to set up easily - you'll need to install it.
#### xinetd config #### xinetd config
I think the below two config files are the only things required to make uronode listen on port 3964 - I think the below two config files are the only things required to make uronode
listen on port 3964 . `xinetd` must be enabled and started by systemd to be listening
`xinetd` must be enabled and started by systemd to be listening (`systemctl enable xinetd`, `systemctl start xinetd`) !!! note "Terminal Command"
`systemctl enable xinetd`, `systemctl start xinetd`
There is probably a systemd native way of doing this, but I couldn't see that in the docs. There is probably a systemd native way of doing this, but I couldn't see that in
the docs.
``` ```
hibby@raspberrypi:~ $ cat /etc/xinetd.d/uronode hibby@raspberrypi:~ $ cat /etc/xinetd.d/uronode
@ -368,15 +415,22 @@ uronode 3694/tcp # Uronode
## FBB BBS ## FBB BBS
`fbb` is my BBS software of choice! It is an oddity in that it binds directly to the ports you tell it exist, so it's listening on my ax25 and netrom ports without an entry in `ax25d.conf`. This mostly seems like magic to me and I am happy to let it run this way! `fbb` is my BBS software of choice! It is an oddity in that it binds directly to
the ports you tell it exist, so it's listening on my ax25 and netrom ports
without an entry in `ax25d.conf`. This mostly seems like magic to me and I am
happy to let it run this way!
It has a few config files - fbb.conf, which is populated by the first run, `ports.sys` which defines the ports available and then `bbs.sys` and `forward.sys` which defines how you route to the outside world. It has a few config files - fbb.conf, which is populated by the first run,
`ports.sys` which defines the ports available and then `bbs.sys` and
`forward.sys` which defines how you route to the outside world.
### ports.sys ### ports.sys
My reference for this file was [this website](https://www.febo.com/packet/linux-ax25/fbb-config.html), which was a helpful resource! My reference for this file was [this website](https://www.febo.com/packet/linux-ax25/fbb-config.html), which was a
helpful resource!
I have incremented the number of TNCs where appropriate and added my ports as 1,2,3. I have left the COM 1 Interface 9 etc alone. I have incremented the number of TNCs where appropriate and added my ports as
1,2,3. I have left the COM 1 Interface 9 etc alone.
``` ```
hibby@raspberrypi:~ $ cat /etc/ax25/fbb/port.sys hibby@raspberrypi:~ $ cat /etc/ax25/fbb/port.sys

View File

@ -119,4 +119,4 @@ This will tell the system you want to start the `linbpq` service. Navigate to
[http://127.0.0.1:8008](http://127.0.0.1:8008) if you are on the systme you've [http://127.0.0.1:8008](http://127.0.0.1:8008) if you are on the systme you've
performed the install on and you should see a webpage like below: performed the install on and you should see a webpage like below:
![bpq welcome page](../static/img/bpq_login.png)) ![bpq welcome page](../static/img/node-main.png)

View File

@ -1,24 +1,31 @@
# Linux Native Stack # Linux Native Stack
The linux native stack is highly configurable and can be easily installed on all Debian distros. The linux native stack is highly configurable and can be easily installed on
all Debian distros. Beware! Most of the tooling is for the command line.
More detailed configuration instructions and explanations can be found [here](../config/linux.md) More detailed configuration instructions and explanations can be found
[here](../config/linux.md).
## Install ## Install
To get a basic node setup, the minimum viable software is: To get a basic node setup, the minimum viable software is:
`apt install libax25 ax25-tools ax25-apps uronode` !!! note "Terminal Command"
`apt install libax25 ax25-tools ax25-apps uronode`
### BBS ### BBS
To set up a BBS install fbb To set up a BBS install fbb
!!! note "Terminal Command"
`apt install fbb` `apt install fbb`
## Basic Config ## Basic Config
We shall set up a single AX.25 port to receive calls and display Uronode to calling stations. We shall set up a single AX.25 port to receive calls and display Uronode to
calling stations.
Setting up and attaching a port is a prerequisite to monitoring, sending calls
and receiving calls.
### ax25 ports ### ax25 ports
@ -38,14 +45,39 @@ uhf UR0CAL-10 57600 255 2 UHF 9600bd
Modify the callsign to your own or your station's call. Modify the callsign to your own or your station's call.
This has to be attached as to the modem, in effect telling the computer to This has to be attached as to the modem, in effect telling the computer to
listen to the modem's output. Run the below as root: listen to the modem's output. Run the below:
!!! note "Terminal Command"
`sudo kissattach /dev/ttyACM0 uhf`
`kissattach /dev/ttyACM0 uhf` ## Monitoring Traffic
### ax25d The application that will show traffic picked up by your port is `axlisten`.
ax25d (ax25 daemon) listens to incoming data and directs calling stations to the application you want them to use. !!! note "Terminal Command"
It can present different applications based on any combination of the callsign calling you, the callsign and SSID the calling station is calling and the port they are calling to. `axlisten -ac`
Running the above will show in the terminal all traffic successfully decoded by
your modem, and everything you're trying to send to the outside world.
`axlisten` can be run beside the below commands - just open a new terminal for them!
## Outbound Calls
You can call another station by running `axcall` in the terminal:
!!! note "Terminal Command"
`axcall <port> <remote station>`
In the case of calling my station from the port we configured above, this would be
!!! note "Terminal Command"
`axcall uhf GB7HIB`
## Inbound Calls
ax25d (ax25 daemon) listens to incoming data and directs calling stations to
the application you want them to use. It can present different applications
based on any combination of the callsign calling you, the callsign and SSID the
calling station is calling and the port they are calling to.
ax25d is controlled by `/etc/ax25/ax25d.conf` ax25d is controlled by `/etc/ax25/ax25d.conf`
@ -61,10 +93,14 @@ NOCALL * * * * * * L
default * * * * * * - root /usr/sbin/uronode uronode default * * * * * * - root /usr/sbin/uronode uronode
``` ```
Note the callsign, SSID and port are aligned with the axport in this example. Similar to axports, modify UR0CAL to our own callsign or your station's callsign. Note the callsign, SSID and port are aligned with the axport in this example.
Similar to axports, modify UR0CAL to our own callsign or your station's
callsign.
ax25d is started by running the below as root: ax25d is started by running the below:
`ax25d` !!! note "Terminal Command"
`sudo ax25d`
Stations should be able to call uronode on your system using AX.25. Stations should be able to call uronode on your system using AX.25 and be
presented with the basic uronode.

View File

@ -231,6 +231,18 @@ This effectively translates to 'add <username> to <groupname>. Get rid of the
brackets and add the user and group you're trying for! See [Permissions and brackets and add the user and group you're trying for! See [Permissions and
Groups](#Permissions-and-Groups) for an example. Groups](#Permissions-and-Groups) for an example.
### Running Command Line Programs as Root
We prefix a command with `sudo` if we want it to be run as root and we know
we're in the right group!
!!! note "Terminal Command"
`nano /etc/bpq32.cfg`
becomes
`sudo nano /etc/bpq32.cfg`
### Editing text as root ### Editing text as root
The path of least resistance for many is to use the command line - if you know The path of least resistance for many is to use the command line - if you know

View File

@ -18,6 +18,12 @@ For details on how to use it:
* Configuration can be found [here](config/bpq.md). * Configuration can be found [here](config/bpq.md).
* The project website can be found [here](https://www.cantab.net/users/john.wiseman/Documents/) * The project website can be found [here](https://www.cantab.net/users/john.wiseman/Documents/)
!!! info
BPQ has a good community, plenty of features and is well supported
within the UK Packet Radio Network. It is a good starting point for
beginners and old hands alike! It is available in the repo and kept up
to date for you by me!
## XROUTER ## XROUTER
XROUTER is written by Paula G8PZT and allows a computer to act as a node in a NET/ROM and AX.25 network. XROUTER is written by Paula G8PZT and allows a computer to act as a node in a NET/ROM and AX.25 network.
@ -35,6 +41,13 @@ For details on how to use it:
* Configuration can be found [here](config/xrouter.md). * Configuration can be found [here](config/xrouter.md).
* The project website can be found [here](https://groups.io/g/xrouter/topics) * The project website can be found [here](https://groups.io/g/xrouter/topics)
!!! info
XROUTER has a good community, plenty of features and is well supported
with an active groups.io. It has an excellent user interface and is
quick to get up and running with! It is a good starting point for
beginners and old hands alike! It is not available in the repo and you
will need to remember to update it periodically.
## Linux Native Stack ## Linux Native Stack
The Linux native AX.25 stack has been authored by many over the years, and is shipped as a standard part of Debian. The Linux native AX.25 stack has been authored by many over the years, and is shipped as a standard part of Debian.
@ -53,3 +66,11 @@ For details on how to use it:
* Installation information can be found [here](install/linux.md). * Installation information can be found [here](install/linux.md).
* Configuration can be found [here](config/linux.md). * Configuration can be found [here](config/linux.md).
!!! info
The Linux stack is deep and powerful in its featureset and nearly
infinitely configurable, but this is both a blessing and a curse.
It has less community than the others and is harder to get support for.
It has been known to have bugs that cause issues with stability which
might impact your neighbours. It is probably worth avoiding if you're a
beginner and only exploring if you're a keen experimenter!