VLC is a free and open source cross-platform multimedia player, encoder and streamer that works. It is a very popular (and possibly the most used) media player out there.

Some of its notable features include support for almost all (if not most) multimedia files, it also supports Audio CDs, VCDs, and DVDs. Additionally, VLC supports various streaming protocols enabling users to stream content over a network.

Suggested Read: 10 Best Open Source Media Players for Linux

In this article, we will show you a simple hack that will enable you to run VLC media player as root user in Linux.

Note: There is a reason why VLC won’t run in a root account (or can’t be run as root), so because the root account is for system maintenance only, not for everyday activities.

Install VLC Player in Linux


Installing VLC is so easy, it is available in official repositories of mainstream Linux distros, just run the following command on your respective Linux distribution.

$ sudo apt install vlc #Debain/Ubuntu
$ sudo yum install vlc #RHEL/CentOS
$ sudo dnf install vlc #Fedora 22+

If you are running your Linux system as root, for example Kali Linux, you’ll get the error below when you try to run VLC.

"VLC is not supposed to be run as root. Sorry. If you need to use real-time priorities and/or privileged TCP ports you can use vlc-wrapper (make sure it is Set-UID root and cannot be run by non-trusted users first)."

Alternative Ways to Run VLC as Root User

Run the sed command below to make changes in the VLC binary file, it will replace the geteuid variable (which determines the effective user ID of the calling process) with getppid (which will determine the parent process ID of the calling process).

In this command, ‘s/geteuid/getppid/‘ (regexp=geteuid, replacement=getppid) does the magic.

$ sudo sed -i 's/geteuid/getppid/' /usr/bin/vlc

Alternatively, edit the VLC binary file using a hex-editor such as bless, hexeditor. Then search for geteuid string and replace it with getppid, save the file and exit.

Yet again, another way around this is to download and compile the VLC source code by passing the --enable-run-as-root flag to ./configure and VLC should be able to run as root.

That’s all! You should now run VLC as root user in Linux. To share any thoughts, use the feedback form below.

Facebook Comments

More Stuff

Emblematic Group and Mozilla Team Up to Showcase Next Generation o... Everything you share on the internet is a story. You read blog posts and watch videos that make you feel connected to people across the world. Virtual...
Latest Firefox Release is Faster than Ever With the introduction of the new Firefox Quantum browser in 2017 we changed the look, feel, and performance of our core product. Since then we have la...
Competing without a Marketing Budget: When All You Have is a Produ... This is a story about the power of a good landing page, PR efforts, and marketing strategy. The refreshing twist here is that instead of explaining ho...
The Ongoing Fiasco and Mysterious Afterlife of QuadrigaCX I’d say you were a little late to the cryptocurrency party if you haven’t heard about the ongoing catastrophe that’s been QuadrigaCX these past six ...
Spread the love

Posted by News Monkey