Important commands

General help

Command

Description

command -h
command --help

Display quick help for a command

man <command>

Open manpage (exit with q)

https://manpages.debian.org/<command>

Online manpages in the browser

Users and groups

Command

Description

id

Display user/group IDs of the current user

sudo id

Check identity with root rights

passwd

Change the password of the logged-in user

Navigation, files, rights

Command

Description

pwd

Display current directory

cd /etc · cd .. · cd ~

Change directories

ls -l · ls -a

List files/directories (long/hidden)

touch ~/example.txt

Create empty file

nano ~/example.txt

Open text editor nano

cat ~/example.txt

Show file content

chmod u+x ~/example.txt

Set execution rights for owners

Systemd services

Command

Description

systemctl status <service-name>

Display the status of a unit (e.g. nftables)

sudo systemctl start|stop|restart <service-name>

Start/stop/restart service

sudo systemctl enable|disable <service-name>

Activate/deactivate automatic start

systemctl list-unit-files --no-pager

List all unit files

Logs (journald)

Command

Description

sudo journalctl --no-pager -u <service-name>

Display logs of a unit

sudo journalctl -u <service-name> -f

Track live log (Tail)

sudo journalctl -b

Logs of the current boot session

Processes and resources

Command

Description

htop

Interactive process and resource overview

Network - status, addresses, routing

Command

Description

ip --brief addr

Compact overview of IP addresses

ip addr show

Detailed interface and address information

ip link show

Link/Interface status

ip route show

Display routing table

sudo networkctl status

Overview systemd-networkd

sudo networkctl reload

Reload network configuration

ping -c 4 <IPv4_or_IPv6>

Availability test

WLAN (iwd / iwctl)

Command

Description

sudo apt install iwd

Install iwd

sudo systemctl enable --now iwd

activate and start iwd service

sudo iwctl device list

List WLAN devices

sudo iwctl station <wlx...> get-networks

Scan networks

sudo iwctl station <wlx...> connect <SSID>

Connecting with an open AP

sudo iwctl --passphrase <PWD> station <wlx...> connect <SSID>

Connecting to a WPA2-protected AP

SSH and file transfer

Command

Description

ssh Administrator@<IP_ADDRESS>

SSH login

Get-Content $env:USERPROFILE\.ssh\id_rsa.pub | ssh Administrator@<IP> "mkdir -p ~/.ssh && cat >> ~/.ssh/authorized_keys"

Send public key (PowerShell) to the IPC and insert into authorized_keys

scp -r C:\<source-path>\<folder> Administrator@<IP>:/home/Administrator/

Copy folder recursively via SCP (Windows → Linux®)

Package management (APT)

Command

Description

sudo apt update

Update package lists

sudo apt upgrade

Update installed packages

sudo apt search <term>

Search packages

sudo apt install <package>

Install packages

sudo apt remove <package>

Remove package (config remains)

sudo apt purge <package>

Remove package incl. config

sudo apt autoremove

Delete dependencies that are no longer required

Firewall (nftables)

Command

Description

systemctl status nftables

Status of the nftables service

sudo systemctl reload nftables

Reload rules

sudo systemctl restart nftables

Restart firewall service

sudo nft list ruleset

Show current rules and regulations

sudo nft flush ruleset

Delete all active rules (caution)

sudo nft -f /etc/nftables.conf.d/<file>.conf

Apply rule set from file

Host name and time

Command

Description

sudo hostnamectl hostname my-beckhoff-ipc

Set hostname

hostnamectl status

Check host name

sudo sh -c 'hostnamectl hostname "$(bhf-hostname generate)"'

Restore factory standard (BTN)

timedatectl status

Check time synchronization

TwinCAT Runtime for Linux

Command

Description

systemctl status TcSystemServiceUm

Check TwinCAT system service status

sudo systemctl stop|start TcSystemServiceUm

Stop/start TwinCAT service

sudo /usr/bin/TcSystemServiceUm -c /run/TcSystemServiceUm.pid

Put TwinCAT into Config mode

sudo /usr/bin/TcSystemServiceUm -r /run/TcSystemServiceUm.pid

Put TwinCAT into Run mode

sudo nano /etc/TwinCAT/3.1/TcRegistry.xml

Change AMS NetID / Registry (stop service first, then restart)

TwinCAT real-time Ethernet (vfio-pci)

Command

Description

sudo TcRteInstall -l

List interfaces and driver assignments

sudo systemctl stop TcSystemServiceUm

Stop TwinCAT before binding

sudo TcRteInstall --bind <PCI_ADDR>

bind vfio-pci to interface (e.g. 0000:03:00.0)

sudo systemctl start TcSystemServiceUm

Restart service

Docker® (if installed)

Command

Description

sudo systemctl status docker

Check Docker® status

sudo docker run hello-world

Execute test container

docker compose ps

Show current Compose services