Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I have installed a vlc in centos 6.5. I want to run it as root. But I get the following error,

"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)."

share|improve this question
Out of curiosity, what would be the reason to do this ? –  kursus Apr 19 at 14:09
So use vlc-wrapper like it says? –  Kevin Apr 19 at 20:41
Pro-tip: Do not do this. –  HalosGhost Jun 30 at 22:14
Pro-er retort: Please explain why. –  Christian Jul 30 at 10:57

2 Answers 2

The only way around this is recompiling. Pass the --enable-run-as-root flag to ./configure and vlc should be able to run as root. The above answer is from here.

share|improve this answer
recompiling is not the only way, just change the call to geteuid to deliver 1. I describe this at linuxintro.org/wiki/Run_vlc_as_root –  Thorsten Staerk Oct 29 at 6:56
@ThorstenStaerk, thanks for providing me the information. –  Ramesh Oct 29 at 16:42
Could you please mark the question as answered? –  Thorsten Staerk Oct 31 at 8:49

See http://www.linuxintro.org/wiki/Run_vlc_as_root:

  • backup vlc

    # cp /usr/bin/vlc /usr/bin/vlc-backup

  • find the call to geteuid inside the vlc binary:

    # needle=$(objdump -d /usr/bin/vlc | grep euid | tail -1 | awk '{print "\x"$2"\x"$3"\x"$4"\x"$5"\x"$6;}')

  • replace the call to just deliver 01:

    # sed -ir "s/$needle/\xb8\x01\x00\x00\x00/" /usr/bin/vlc

  • test it. vlc should now run under the root user!

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.