How to run VLC player as root user

I ran into this a while back when I needed VLC running as root on a headless server, and the usual --no-sandbox flag didn’t cut it. VLC refuses to start as root by default, which makes sense from a security standpoint but is annoying when you actually need it. The fix is brutal and hacky, but it works: sed -i 's/geteuid/getppid/' /usr/bin/vlc What’s actually happening here? VLC’s startup script checks whether the effective user ID is zero (root). If it is, it bails out. By swapping geteuid with getppid, we’re telling the script to check the parent process ID instead of the effective UID. Since getppid() returns a number way bigger than zero, the check passes and VLC starts. ...

18 May 2020 · 1 min · 168 words · Shafiq Alibhai

'How much memory is actually free?'

I keep forgetting this one, so here it is. vmstat -s -SM | grep "free memory" | awk -F" " '{print$1}' It pipes vmstat output through grep and awk to pull just the number – no units, no labels, just the gigabytes sitting there doing nothing.

10 December 2011 · 1 min · 46 words · Shafiq Alibhai
OpenSUSE installer boot menu

'OpenSUSE 11.4 -- first look'

I grabbed the openSUSE 11.4 64-bit ISO last night and spent the afternoon installing it in a VM. Here’s the full walkthrough, screenshots and all. Boot menu. Standard options – Installation, Rescue System, media check. Nothing fancy, but it gets the job done. Welcome screen. The green chameleon is back, and so is the striped wallpaper that’s become the distro’s signature look. ...

13 March 2011 · 4 min · 699 words · Shafiq Alibhai

Preserving File Permissions When Copying in Linux

Use the -p flag with cp to preserve file permissions: cp -p /aaa/bbb /ccc/ddd

14 June 2010 · 1 min · 14 words · Shafiq Alibhai
GNUSL3S LINUX OS

GNUSL3S Linux

GNUSL3S Linux is a distribution built in Goa. It bundles a wide range of pre-installed software spanning bioinformatics (EMBOSS, Primer3), security tools for penetration testing, system administration utilities, and development editors. Boot from the DVD for a graphical interface with KDE, XFce, Fluxbox, or IceWM. Based on: Slackware, SLAX, Alixe, Davix Version: 10.05.xx Architecture: i486 (32-bit) Origin: Goa, India Status: Discontinued

29 March 2010 · 1 min · 61 words · Shafiq Alibhai

Identifying Your Linux Distribution

Not sure which Linux distribution you’re running? Open a terminal and type: cat /etc/issue On Debian 4.0, for example, this outputs: Debian GNU/Linux 4.0 \n \l The \n and \l are escape sequences for the hostname and terminal device – they’re not part of the distribution name. This works on most distributions. Some also have /etc/os-release with more detail: cat /etc/os-release

23 March 2010 · 1 min · 61 words · Shafiq Alibhai

The launch of Mandriva Linux 2010

Mandriva Linux 2010 is launching on November 3rd. Highlights from the announcement: KDE 4.3.1, GNOME 2.28, kernel 2.6.31.1, and Xorg 1.6.4 RC 1 with updated Intel graphics drivers. There’s also a Moblin 2 spin for netbooks. I’ve used Mandriva off and on over the years. The Control Centre has always been one of the better configuration tools in the Linux world. Worth keeping an eye on to see how this release shapes up.

4 October 2009 · 1 min · 73 words · Shafiq Alibhai