Linux related stuff
Useful console programs
- bwm-ng - Bandwidth Monitor NG (Next Generation), a live bandwidth monitor for network and disk io
- iftop - display bandwidth usage on an interface by host
- nethogs - Net top tool grouping bandwidth per process
- nload - displays the current network usage
To install them all:
sudo apt install bwm-ng iftop nethogs nload
Useful gui programs
SSH load key error in libcrypto
Occasionally on Ubuntu 22.04 I've experienced the error message shown below when trying to connect to a server using an ssh key:
$ ssh email@example.com -i ~/.ssh/id_ed25519 Load key "id_ed25519": error in libcrypto
I finally realized the problem was the presence of DOS style CRLF end of line designators. Using dos2unix to convert the end of line designators resolved the issue.
$ dos2unix ~/.ssh/id_ed25519
Useful system commands
# Show maximum capacity and number of RAM slots sudo dmidecode -t 16 # Show information on RAM in slots sudo dmidecode -t 17 # Shows all memory related information in the system. Slow as it polls all hardware first. sudo lshw -class memory
VBAN for Linux
I've used Voicemeeter Banana and Potato for a long time to do advanced audio management on my various computers, including streaming audio from various computers in the house to my laptop and vice versa.
VBAN for Linux allows me to incorporate some older laptops (that have trouble running Windows but no problem running Ubuntu Desktop) into my various setups. Primarily I use a second laptop to stream Youtube or Udemy videos while I'm using my primary Windows laptop. Bluetooth headset is connected to the primary laptop and all other audio sources are sinked to it. 👍
Configuring Ubuntu 20.04 to sink audio and use vban_emitter to stream to a VBAN receiver
#!/bin/bash pactl load-module module-null-sink sink_name=vbanmix # use "pactl info" or "pactl list" to find the proper alsa_output interface pactl load-module module-combine-sink channels=2 slaves=vbanmix,alsa_output.pci-0000_00_1b.0.analog-stereo pactl set-default-source vbanmix.monitor
#!/bin/bash IPADDR=10.10.10.10 UDPPORT=6980 STREAMNAME=Linux_Laptop SAMPLERATE=48000 AUDIOBACKEND=pulseaudio vban_emitter --ipaddress=$IPADDR --port=$UDPPORT --streamname=$STREAMNAME --backend=$AUDIOBACKEND --rate=$SAMPLERATE
Running on a headless system
After banging my head against the wall for weeks trying to figure out how to get vban_emitter working on a Raspberry Pi and an f80a, here's what I found.
By default, Pulseaudio only works with a user logged in directly to the system. After trying to get Pulseaudio setup to run in system mode, I realized it's much easier to just leverage ALSA directly.
The default ALSA configuration is set to use CARD 0. When using USB devices, these are inserted as CARD 1. In order to use this, you need to either update or create the /etc/asound.conf file with the information below:
# /etc/asound.conf defaults.pcm.card 1 defaults.ctl.card 1
Here's the vban_emitter command to use:
vban_emitter -i IP_ADDRESS -p 6789 -s STREAM_NAME -b alsa