Long SSH Login: pam_systemd 25s Delay

Long SSH Login What is PAM Pluggable Authentication Modules (PAM) is a middleware layer between applications (sshd, su, login, sudo) and authentication logic. Programs link against libpam.so and delegate authentication to it. Every login goes through a stack of modules defined in /etc/pam.d/. Why Login is Slow PAM runs modules sequentially on every login. If one module hangs, your login waits. Common suspects include pam_motd.so, pam_lastlog.so, and pam_env.so. In constrained deployments, the main offender is often:...

June 4, 2026 · 2 min

How to safely copy files to a flash drive on Linux

If you copy files to a USB flash drive and remove it right after cp finishes, data may still be in the kernel write cache. That means copy command is done, but device writes are not fully done yet. The safe approach is simple: Copy files Force data to disk Unmount device Remove flash drive Basic safe flow cp -r ./my-folder /mnt/usb/ sync umount /mnt/usb Linux vs Windows write cache behavior On Linux, if you run umount without sync first, umount may take a while....

May 17, 2026 · 1 min

Hello World Without Libc: A Deep Dive into How Programs Really Work

Introduction Most programmers start with a simple “Hello World” program like this: #include <stdio.h> int main(void) { printf("hello world\n"); return 0; } But have you ever wondered what really happens under the hood? What is printf doing? Where does main come from? What happens before main is called? How does the program actually communicate with the operating system to display text on the screen? In this article, we’re going to build a “Hello World” program in C that requires no standard library (no libc)....

May 11, 2026 · 32 min