Linux
Remote command
ssh user@server 'command arguments'
Interactive remote command
ssh -t user@server 'command arguments'
ls -l | head -n 1 | xargs gwenview
Copy to /usr/share/fonts/ or ~/.local/share/fonts/ and then run:
fc-cache -fv #for ~/.local/share/fonts sudo fc-cache -fv #for /usr/share/fonts/ chmod 755 /usr/share/fonts/dir chmod 644 /usr/share/fonts/dir/*.ttf
Umax boot: Esc
pacman-key --populate archlinux
gpg --edit-key 3E80... trust 5 y save
gpg --verify archlinux-2025.11.01-x86_64.iso.sig archlinux-2025.11.01-x86_64.iso
dd bs=4M if=path/to/archlinux-version-x86_64.iso of=/dev/disk/by-id/usb-My_flash_drive conv=fsync oflag=direct status=progress
free -h
ip link ip -s link nmcli device status enthtool enp0s3
ip addr show ip -brief addr show ip route get 192.168.1.9 ip route arping 192.168.1.8 ip neighbour show
ping -M do server.example.com -s 1500 tracepath server.example.com tcpdump -i enp0s3 'icmp6 or icmp' iptables -t mangle -A FORWARD -p tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu nft add rule ip filter forward tcp flags syn tcp option maxseg size set rt mtu
ss -tulpn bat /etc/resolve.conf
https://www.joindns4.eu/for-public#resolver-options DNS4EU:
86.54.11.11 86.54.11.211 2a13:1001::86:54:11:11 2a13:1001::86:54:11:211
ss -tulpn | grep 53 nslookup www.example.com
dig www.example.com @1.1.1.1 dig +cd www.rhybar.cz
tcpdump -i enp0s3 -vvv 'port 67 or port 68' dhclient -v -1
mtr server.example.com iperf3 -c ping.online.net -u -b 10M -t 20 speedtest-cli
for file in *.pdf
magick $file $(basename $file .pdf).png
end
fd pattern
fd pattern -t d #directories
fd pattern -t f #files
fd pattern -x command {} # execute command for each file
fd pattern -X command # execute command for all files
fd . /srv/filmy -t d
fd . /srv/filmy -t d -x chmod 755 {}
fd . /srv/filmy/ -t f -x chmod 644 {}
bluetoothctl
if bluetooth headphones disconnect, run pavucontrol
ls -l /dev/ttyUSB0 sudo usermod -aG uucp $USER reboot groups
gsettings set org.gnome.desktop.wm.keybindings switch-input-source "['<Alt>Shift_L', '<Super>space', 'XF86Keyboard']" gsettings set org.gnome.desktop.wm.keybindings close "['<Super><Shift>Q', '<Alt>F4']" gsettings set org.gnome.desktop.wm.keybindings toggle-maximized "['<Super>F', '<Alt>F10']"
seq -w
cat /etc/passwd | grep "/\*/\*sh" awk -F: '($3 == 0) {print}' /etc/passwd sudo cat /root/.bash_history
for user in \((cut -f1 -d: /etc/passwd); do crontab -u \)user -l 2>/dev/null; done sudo cat /etc/crontab sudo ls -al /etc/cron.\/\
systemctl list-units --type=service --state=running ps aux --sort=-%mem | head -n 10 grep -r LD_PRELOAD /etc/profile /etc/bash* ~/.bashrc ~/.profile
sudo ss -tuln sudo netstat -tulnp
List of ports: Wikipedia
ls -la /home/*/.ssh/authorized_keys grep -r "" /root/.ssh/authorized_keys /home/*/.ssh/authorized_keys 2>/dev/null cat /etc/ssh/sshd_config | grep -E 'PermitRootLogin|PasswordAuthentication'
vim /etc/login.defs UMASK 027
lsmod
rsync -avzh /source/path/ /destination/path/
rsync -avzh --exclude 'temp/' /source/ /destination/
Identifying which process is using a specific port 8080 lsof -i :8080
lsof | grep deleted
git-delta package
delta file1 file2
find /var/www -type f -name "*.log" -mtime +30 -delete
find /etc -type f -exec chmod 644 {} \;
dust ncdu
Add the shell to /etc/shells with:
echo /usr/local/bin/fish | sudo tee -a /etc/shells
Change your default shell with:
chsh -s /usr/local/bin/fish
Again, substitute the path to fish for /usr/local/bin/fish - see command -s fish inside fish. To change it back to another shell, just substitute /usr/local/bin/fish with /bin/bash, /bin/tcsh or /bin/zsh as appropriate in the steps above.
# file.timer # Copy this file to ~/.config/systemd/user/ [Unit] Description=Run my-service.py script [Timer] OnBootSec=15min OnCalendar=*-*-* 18:00:00 [Install] WantedBy=timers.target
# Change the path for the script in ExecStart [Unit] Description=Run my-service.py script [Service] Type=simple Restart=always ExecStart=/usr/bin/env python3 /home/user/.local/bin/my-service.py
systemctl --user daemon-reload systemctl --user start my-service.timer systemctl --user --all list-timers
libdvdread libdvdcss libdvdnav sudo pacman -S libdvdread libdvdnav libdvdcss
sudo systemctl enable iwd sudo systemctl start iwd sudo systemctl enable systemd-resolved sudo systemctl start systemd-resolved
ln -sf /run/systemd/resolve/stub-resolv.conf /etc/resolv.conf
vim /etc/iwd/main.conf EnableNetworkConfiguration=true
resolvectl status
pacstrap -K /mnt base linux linux-firmware arch-chroot /mnt pacman -S grub efibootmgr intel-ucode iwd vim man-db man-pages texinfo
pdfimages -all input.pdf output