IT Admin Notes
Short, practical sysadmin notes: problems I run into with Windows, Linux, Active Directory, VMware, Proxmox, Docker, MikroTik and more, and how I fixed them.
-
Copy an SSH Key to Remote Servers (Linux and Windows)
Copy your SSH public key to one or many Linux servers from Linux, macOS or Windows PowerShell, fix permissions and troubleshoot key authentication.
Read more: Copy an SSH Key to Remote Servers (Linux and Windows) -
Export CherryTree Notes to Obsidian (Python Script)
Python script that converts a CherryTree notebook (.ctb or .ctd) into Markdown files for Obsidian, keeping the node tree as folders.
Read more: Export CherryTree Notes to Obsidian (Python Script) -
Exchange Online: Enable Auto-Expanding Archive
Mailbox archive full? Enable auto-expanding archiving in Exchange Online with PowerShell for one user or the whole organization, and check its status.
Read more: Exchange Online: Enable Auto-Expanding Archive -
UFW Firewall Rules: Practical Examples
Practical UFW firewall rules for Ubuntu servers: default policies, SSH by network or IP, web, databases, port ranges, rate limiting, logs and deleting rules.
Read more: UFW Firewall Rules: Practical Examples -
Windows 11 Setup: Use a Local Account (ms-cxh:localonly)
Skip the Microsoft account sign-in during Windows 11 setup and create a local account with the ms-cxh:localonly command.
Read more: Windows 11 Setup: Use a Local Account (ms-cxh:localonly) -
PRTG: Alert on the Number of Files in a Folder
Monitor how many files are in a folder on a Windows server with the PRTG Folder sensor and alert when the count goes over a limit.
Read more: PRTG: Alert on the Number of Files in a Folder -
Limit RAM for Docker Compose Containers
Cap the memory each Docker Compose service can use with deploy resources limits and reservations, plus reference values for common monitoring containers.
Read more: Limit RAM for Docker Compose Containers -
Add a New Disk to Ubuntu Server: Partition, Format and Mount
Add a new disk to Ubuntu Server: create the partition, format it as ext4, mount it under /srv and make it permanent in fstab with its UUID.
Read more: Add a New Disk to Ubuntu Server: Partition, Format and Mount -
Proxmox VE: Remove a Dead Node and Go Back to Standalone
Remove a failed node from a Proxmox VE cluster with pvecm delnode and, if needed, dissolve the cluster to run the remaining node standalone.
Read more: Proxmox VE: Remove a Dead Node and Go Back to Standalone -
Set the Time Zone and NTP Sync on Ubuntu Server
Wrong time on Ubuntu Server? Set the correct time zone with timedatectl, enable NTP sync with systemd-timesyncd and check its status.
Read more: Set the Time Zone and NTP Sync on Ubuntu Server -
PCs Can't Log On to the Domain After Removing SMB1: Fix
Workstations lose domain logon and can't rejoin after uninstalling SMB 1.0/CIFS because the Workstation service still depends on the SMB1 driver. Fix it with sc.exe.
Read more: PCs Can't Log On to the Domain After Removing SMB1: Fix -
Windows 11 Can't Access SMB/Samba Shares: SMB Signing Fix
Windows 11 24H2 requires SMB signing and blocks some NAS and Samba shares. How to check it, the quick client-side fix and the better server-side fix.
Read more: Windows 11 Can't Access SMB/Samba Shares: SMB Signing Fix -
Shrink a Thick VMDK Disk in VMware ESXi
Reduce an oversized thick-provisioned VMDK in VMware ESXi by shrinking the Windows volume, editing the disk descriptor and cloning it with vmkfstools.
Read more: Shrink a Thick VMDK Disk in VMware ESXi -
Enable SNMPv3 on Fedora (net-snmp)
Install and configure a read-only SNMPv3 agent with authPriv on Fedora, open the firewall with firewalld and fix password mismatch problems.
Read more: Enable SNMPv3 on Fedora (net-snmp) -
SNMPv3 on Ubuntu/Debian for PRTG Monitoring
Configure a secure SNMPv3 agent (authPriv, SHA and AES) on Ubuntu or Debian and add the server to PRTG with SNMPv3 credentials.
Read more: SNMPv3 on Ubuntu/Debian for PRTG Monitoring -
Repair Windows System Files with DISM and SFC
Fix corrupted Windows system files with DISM RestoreHealth and SFC scannow, in the right order, and where to find the logs.
Read more: Repair Windows System Files with DISM and SFC -
Linux Disk Full: Find What's Using Space and Free It
Root partition at 100% on Linux? Find the folders and files using the space and free it: logs, journal, APT cache, old snaps and Docker container logs.
Read more: Linux Disk Full: Find What's Using Space and Free It -
Unattended Windows 10/11 Install with autounattend.xml
Install Windows 10 or 11 fully unattended: generate an autounattend.xml with Schneegans' generator and copy it to the root of the installation USB.
Read more: Unattended Windows 10/11 Install with autounattend.xml -
Handy Linux Terminal Tools: btop, ncdu, bat and HTTPie
Four Linux terminal tools I install on every server: btop for monitoring, ncdu for disk usage, bat as a better cat and HTTPie as a friendly HTTP client.
Read more: Handy Linux Terminal Tools: btop, ncdu, bat and HTTPie -
Update All Windows Apps Silently with winget
One winget command to update every installed Windows application silently, accept all agreements and save a log, plus how to schedule it.
Read more: Update All Windows Apps Silently with winget -
Compare GPOs with Microsoft Policy Analyzer
Use Microsoft Policy Analyzer from the Security Compliance Toolkit to compare Group Policy objects, find conflicts and check them against security baselines.
Read more: Compare GPOs with Microsoft Policy Analyzer -
MikroTik NAT Actions Explained with Examples
Quick reference of MikroTik RouterOS NAT actions (masquerade, src-nat, dst-nat, netmap, redirect and more) with a ready-to-use example for each one.
Read more: MikroTik NAT Actions Explained with Examples -
Get Your Public IP from the Linux Terminal
Find your public IP address from the Linux command line using DNS queries (dig) or HTTP services (curl), for IPv4 and IPv6.
Read more: Get Your Public IP from the Linux Terminal -
Crontab Syntax with Practical Examples
How crontab works on Linux: field syntax, practical schedule examples, logging the output and the usual reasons a cron job doesn't run.
Read more: Crontab Syntax with Practical Examples -
Kali Linux: Fix "Missing Key" Error on apt update
Fix the Kali Linux apt update error Missing key 827C8569F2518CC677FECA1AED65462EC8D5E4C5 by installing the new archive signing key.
Read more: Kali Linux: Fix "Missing Key" Error on apt update -
Install RSAT Tools with PowerShell (Windows 10/11)
Install Remote Server Administration Tools (RSAT) on Windows 10 and 11 with PowerShell: all of them or just AD, Group Policy and DNS.
Read more: Install RSAT Tools with PowerShell (Windows 10/11) -
GPO: Enable BitLocker and Store Recovery Keys in AD
Group Policy to enable BitLocker on domain computers and back up the recovery keys to Active Directory, plus the RSAT feature to view them.
Read more: GPO: Enable BitLocker and Store Recovery Keys in AD -
GPO: Enable Windows Hello (PIN and Biometrics) on Domain PCs
Group Policy settings to enable Windows Hello, PIN and biometric sign-in (face and fingerprint) on Active Directory domain-joined computers.
Read more: GPO: Enable Windows Hello (PIN and Biometrics) on Domain PCs -
Restart the Graphics Driver in Windows (Win+Ctrl+Shift+B)
Frozen or black screen but Windows is still running? Restart the graphics driver with a keyboard shortcut without rebooting or closing apps.
Read more: Restart the Graphics Driver in Windows (Win+Ctrl+Shift+B) -
See the Full PowerShell Command History (PSReadLine)
Get-History only shows the current session. Find and search the PSReadLine history file that keeps every PowerShell command you have typed.
Read more: See the Full PowerShell Command History (PSReadLine) -
Ansible with MikroTik RouterOS: Quick Start
Automate MikroTik routers with Ansible and the community.routeros collection: inventory, SSH connection settings and a playbook to back up the configuration.
Read more: Ansible with MikroTik RouterOS: Quick Start -
Extend a Disk on Ubuntu Server (VMware, LVM, ext4, XFS)
Grow a virtual disk in vCenter and extend it in Ubuntu Server: rescan, growpart, pvresize and lvextend for LVM, or resize2fs and xfs_growfs for plain disks.
Read more: Extend a Disk on Ubuntu Server (VMware, LVM, ext4, XFS) -
Ubuntu Server: SSH Key-Only Login (Disable Passwords)
Set up SSH public key authentication on Ubuntu Server and disable password logins, including the cloud-init override that often breaks it.
Read more: Ubuntu Server: SSH Key-Only Login (Disable Passwords) -
MikroTik Login with Active Directory Users via RADIUS (NPS)
Log in to MikroTik routers with your Active Directory account using RADIUS on Windows NPS: RADIUS client, connection request policy, network policy and RouterOS AAA.
Read more: MikroTik Login with Active Directory Users via RADIUS (NPS) -
Docker Compose: WordPress + MariaDB + phpMyAdmin
A ready-to-use docker-compose.yml to run WordPress with MariaDB and phpMyAdmin on your own server, with persistent volumes and an internal network.
Read more: Docker Compose: WordPress + MariaDB + phpMyAdmin -
Install Portainer CE on Docker
Deploy Portainer Community Edition as a Docker container to manage your containers, images, volumes and stacks from a web UI.
Read more: Install Portainer CE on Docker -
Install Docker Compose on Ubuntu Server
Install Docker Compose v2 on Ubuntu Server, either as the Docker CLI plugin from APT or as the standalone docker-compose binary.
Read more: Install Docker Compose on Ubuntu Server -
Install Docker Engine on Ubuntu Server
Install Docker Engine, Buildx and the Compose plugin on Ubuntu Server from Docker's official APT repository.
Read more: Install Docker Engine on Ubuntu Server -
Join Proxmox VE to Active Directory (Realm and User Sync)
Add an Active Directory realm to Proxmox VE, sync AD users and groups with a bind account and give them permissions.
Read more: Join Proxmox VE to Active Directory (Realm and User Sync) -
vSphere HA "Failover Operation in Progress" Stuck Alarm
Clear the stuck vSphere HA failover operation in progress alarm in a vCenter cluster by turning vSphere HA off and on again.
Read more: vSphere HA "Failover Operation in Progress" Stuck Alarm -
Fix winget When Running PowerShell as Administrator
winget not recognized or failing in an elevated PowerShell opened from a standard user session? Re-register the winget packages for the admin account.
Read more: Fix winget When Running PowerShell as Administrator -
Entra Password Protection for On-Premises Active Directory
Block weak and custom banned passwords in Microsoft Entra ID and on-premises Active Directory by deploying the Password Protection DC agent and proxy.
Read more: Entra Password Protection for On-Premises Active Directory -
List Disks, Partitions and Filesystems in Ubuntu
Quick commands to list disks, partitions, filesystems, sizes and mount points on Ubuntu and other Linux distributions.
Read more: List Disks, Partitions and Filesystems in Ubuntu -
Check if an Email Is Legit by Analyzing Its Headers
How to read email headers with Google's Messageheader tool to verify the real sender, SPF, DKIM and DMARC results and the servers a message went through.
Read more: Check if an Email Is Legit by Analyzing Its Headers -
Synology DSM: 2FA "Remember This Device" Not Working
Synology asks for the 2FA code every time even with Remember this device ticked? Disable the option that clears saved login sessions on restart.
Read more: Synology DSM: 2FA "Remember This Device" Not Working -
Sync Windows Time with an NTP Server (w32tm)
Configure a Windows machine to sync its clock with an NTP server using w32tm from PowerShell, force a resync and check the status.
Read more: Sync Windows Time with an NTP Server (w32tm) -
How to Size a UPS: Power (VA) and Runtime
Work out what UPS you need: estimate the load in watts, convert it to VA with the power factor and calculate the approximate battery runtime.
Read more: How to Size a UPS: Power (VA) and Runtime -
Jenkins Can't Download Plugins? Check if Your ISP Is Blocked
Jenkins plugin installs failing with timeouts? Some ISP IP ranges (for example Digi in Spain) get blocked by the Jenkins mirrors. How to diagnose it and work around it.
Read more: Jenkins Can't Download Plugins? Check if Your ISP Is Blocked -
Install SonarQube on Ubuntu 22.04 (PostgreSQL + Java 17)
Step-by-step SonarQube install on Ubuntu 22.04 with PostgreSQL 15, Java 17, kernel limits and a systemd service.
Read more: Install SonarQube on Ubuntu 22.04 (PostgreSQL + Java 17) -
Sophos Firewall (XG): Allow Blocked URLs for Specific Users
Allow some websites only for specific users on Sophos Firewall (XG) while keeping them blocked for everyone else, using a custom web category and a web policy rule.
Read more: Sophos Firewall (XG): Allow Blocked URLs for Specific Users -
Install Windows 11 Without Internet (BypassNRO)
No internet during Windows 11 setup? Use oobe\BypassNRO or its registry value to get the I don't have internet option and continue offline.
Read more: Install Windows 11 Without Internet (BypassNRO) -
Fix the CrowdStrike BSOD on Windows (July 2024)
Fix Windows machines stuck in a blue screen loop after the faulty CrowdStrike Falcon update by deleting the C-00000291*.sys channel file.
Read more: Fix the CrowdStrike BSOD on Windows (July 2024) -
Check and Force Active Directory Replication with repadmin
repadmin commands to check Active Directory replication health between domain controllers, see the queue and force a sync.
Read more: Check and Force Active Directory Replication with repadmin -
Read-Only Access to Everything in Entra ID: Global Reader
Give a user read-only access to all Microsoft Entra ID and Microsoft 365 admin settings with the Global Reader role, plus the Azure Reader role for subscriptions.
Read more: Read-Only Access to Everything in Entra ID: Global Reader -
MikroTik FastTrack: Speed Up Routing and Cut CPU Load
Enable FastTrack on a MikroTik router with two forward filter rules to speed up established connections and lower CPU usage.
Read more: MikroTik FastTrack: Speed Up Routing and Cut CPU Load -
Bypass TPM, Secure Boot and RAM Checks in Windows 11 Setup
Install Windows 11 on unsupported hardware by adding the LabConfig registry keys during setup to skip the TPM, Secure Boot and RAM checks.
Read more: Bypass TPM, Secure Boot and RAM Checks in Windows 11 Setup -
Get the MAC Address from the Command Line
Commands to get the MAC address of your network adapters from Windows CMD, PowerShell, Linux and macOS terminals.
Read more: Get the MAC Address from the Command Line -
Hide a Stuck Windows Update with wushowhide
A Windows update keeps failing and reinstalling? Hide that KB with Microsoft's official Show or Hide Updates troubleshooter (wushowhide.diagcab) or PowerShell.
Read more: Hide a Stuck Windows Update with wushowhide