Tim's Blog

Setup SSH security on a Linux machine

Enable key-based authentication First, enable key-based authentication. It is much more secure than using passwords. Find out how to do so here: Enabling SSH key-based authentication on a Linux machineIt is recommended to use key-based authentication over passwords. Generating a key pair on your local machine We need a public-private

Enabling SSH key-based authentication on a Linux machine

It is recommended to use key-based authentication over passwords. Generating a key pair on your local machine We need a public-private key pair to authenticate with the server. If you have one already, skip this step. If not, enter the following command to generate a key pair. ssh-keygen -t ed25519

How to disable sleep when lid closed to turn a Macbook into a server

Disable sleep when lid closed sudo pmset -a disablesleep 1 Incase you want to revert, run this command sudo pmset -a disablesleep 0 Display power settings pmset -g

How to multitask in Linux with Screen

Screen allows you to have multiple shell sessions, switch between them, as well as terminate the SSH session on a remote machine while keeping long-running tasks running, and return to the session later. Start new screen session screen screen -S session_name Detach from screen ^a + d List screens screen

How to auto-mount hard drives in Ubuntu

List partitions and note the name and UUID of the partition you want to mount sudo lsblk -o NAME,FSTYPE,UUID Sample output: NAME FSTYPE UUID sda ├─sda1 vfat 7158-C80D ├─sda2 ext4 639f097b-6b4e-4c93-b91e-29e219e5ddce └─sda3 LVM2_member mslNSe-6uVU-aw3U-Ea0a-joV6-LWuk-rBMmiP └─ubuntu--vg-ubuntu--lv ext4 3abbffb9-14b2-4fbf-8dde-3e42229703a0 sdb ├─sdb1 vfat 67E3-17E

Tim's Blog © 2026