Thursday, February 10, 2022

How to Install Asterisk 18 and FreePBX 16 on Raspberry Pi OS Bullseye (64-bit & 32-bit)

Deploying Asterisk 18 LTS alongside the modern FreePBX 16 administrative interface on Raspberry Pi OS (Debian 11 Bullseye) enables a carrier-grade VoIP telephony platform on energy-efficient ARM hardware. This guide provides the complete setup for both 64-bit (aarch64) and 32-bit (armhf) architectures.

OS: Raspberry Pi OS Bullseye • Components: Asterisk 18.x, FreePBX 16, Node.js 14, MariaDB 10.5, Apache 2.4

1. Installing System Packages & PHP 7.4

sudo apt-get update && sudo apt-get upgrade -y
sudo apt-get install -y build-essential libssl-dev libncurses5-dev libnewt-dev   libxml2-dev libsqlite3-dev uuid-dev mariadb-server mariadb-client   libjansson-dev libedit-dev sox libsox-fmt-all git curl subversion

# Install PHP 7.4 modules required by FreePBX 16
sudo apt-get install -y apache2 php php-cli php-mysql php-pear php-gd php-mbstring   php-intl php-xml php-curl php-zip

2. Building Asterisk 18 LTS

cd /usr/src
sudo wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-18-current.tar.gz
sudo tar -zxf asterisk-18-current.tar.gz
cd asterisk-18.*

sudo contrib/scripts/get_mp3_source.sh
sudo contrib/scripts/install_prereq install

sudo ./configure --with-pjproject-bundled --with-jansson-bundled
sudo make menuselect.makeopts
sudo menuselect/menuselect --enable format_mp3 menuselect.makeopts
sudo make -j$(nproc)
sudo make install
sudo make config
sudo ldconfig

3. Installing FreePBX 16

cd /usr/src
sudo wget http://mirror.freepbx.org/modules/packages/freepbx/freepbx-16.0-latest.tgz
sudo tar -zxf freepbx-16.0-latest.tgz
cd freepbx
sudo ./install -n

Monday, February 7, 2022

How to Set Up a Samba Network Storage Drive on Raspberry Pi for Hikvision IP Cameras

Hikvision value IP cameras (such as the IPC-B120, IPC-B121H, and IPC-B120-D-W) feature onboard motion detection, infrared night vision, and H.265+ compression, but lack internal hard drives. Rather than purchasing an expensive commercial NVR, you can attach an external USB hard disk to a Raspberry Pi configured as an SMB/CIFS Network Attached Storage (NAS) target for continuous or motion-triggered video archiving.

Stack: Raspberry Pi 4 • External USB HDD (ext4) • Samba Server (SMBv2/v3) • Hikvision Storage Management

1. Installing and Configuring Samba on the Raspberry Pi

sudo apt-get update
sudo apt-get install samba samba-common-bin -y

# Create recording directory on mounted external drive
sudo mkdir -p /media/cctv_storage/hikvision
sudo chown -R nobody:nogroup /media/cctv_storage/hikvision
sudo chmod -R 0777 /media/cctv_storage/hikvision

2. Samba Share Definition (/etc/samba/smb.conf)

Hikvision firmware requires specific Samba dialect and locking settings to format network drives successfully:

[hikvision]
   comment = Hikvision CCTV Storage
   path = /media/cctv_storage/hikvision
   browseable = yes
   writeable = yes
   guest ok = yes
   read only = no
   create mask = 0777
   directory mask = 0777
   force user = nobody

Restart Samba:

sudo systemctl restart smbd

3. Mounting the Drive in Hikvision Web GUI

  1. Log into your camera's web interface → Configuration → Storage → Storage Management → Net HDD.
  2. Set Type to NAS / SMB/CIFS, enter the Raspberry Pi's IP address, set File Path to /hikvision, and save.
  3. Under HDD Management, select the newly added network disk and click Format / Init. Once status changes to Normal, motion recordings will save directly to your Pi.

How Google Antigravity Solved the Mysterious NVIDIA Sleep Reboot on My Dell Inspiron 7567 (Ubuntu Linux)

If you run modern Ubuntu or Linux on a Dell Inspiron 15 Gaming (7567) or a similar 7th-gen Intel laptop paired with an NVIDIA GeForce GTX ...