Category: Bash / Terminal / Scripts

GNU Linux bash – script to generate thumbnails
02.12.2021

# requirements su – root apt update # has the convert command apt install imagemagick vim /scripts/create_thumbs.sh #!/bin/bash THUMBS_FOLDER=/path/to/images/thumbnails for file in /path/to/images/* do # next line checks the mime-type of the file IMAGE_TYPE=`file –mime-type -b “$file” | awk -F’/’ […]

06.03.2020

hostnamectl; # tested on Icon name: computer-desktop Chassis: desktop Operating System: Debian GNU/Linux 10 (buster) Kernel: Linux 4.19.0-8-amd64 Architecture: x86-64 su – root; # become root apt update apt install rfkill rfkill list all 0: phy0: Wireless LAN Soft blocked: […]

gnu linux bash – ssh login as different user
12.01.2020

situation: one is userA but wants to ssh login to server with ipv4: 123.123.123.123 via userB (dedicated user for that server/task). so what one does is: make sure one can login as userB than as userA: userA: ssh -v -i […]

10.01.2020

mdadm -E /dev/sd[a-z] # -E, –examine # Print contents of the metadata stored on the named device(s). # Note the contrast between –examine and –detail. # –examine applies to devices which are components of an array, while # –detail applies […]

09.09.2019

yum install ascii # or apt install ascii ascii Usage: ascii [-dxohv] [-t] [char-alias…] -t = one-line output -d = Decimal table -o = octal table -x = hex table -h = This help screen -v = version information Prints […]

29.08.2019

update: safety first! when it comes to important files: safety comes first thus recommend to the user that wants to go pro the following backup system: have two complete backups at two different places: backupA: at the company, USB 3.0 […]

05.06.2019

WARNING! BE VERY VERY CAREFUL! YOU CAN DESTROY YOUR SYSTEM! so better use a system that is not production important/not a live server. use a laptop that has NOTHING ATTACHED TO IT! (unplug all USB Sticks and external USB Drives) […]