{"id":11719,"date":"2019-03-16T00:01:19","date_gmt":"2019-03-16T00:01:19","guid":{"rendered":"http:\/\/www.appservgrid.com\/paw92\/?p=11719"},"modified":"2019-03-16T00:01:19","modified_gmt":"2019-03-16T00:01:19","slug":"how-to-install-and-run-vlc-media-player-as-root-in-linux","status":"publish","type":"post","link":"https:\/\/www.appservgrid.com\/paw92\/index.php\/2019\/03\/16\/how-to-install-and-run-vlc-media-player-as-root-in-linux\/","title":{"rendered":"How to Install and Run VLC Media Player as Root in Linux"},"content":{"rendered":"<p><strong>VLC<\/strong>\u00a0is a free and\u00a0<a href=\"https:\/\/www.tecmint.com\/10-best-open-source-video-players-for-linux-in-2015\/\" target=\"_blank\" rel=\"noopener\">open source cross-platform multimedia player<\/a>, encoder and streamer that works. It is a very popular (and possibly the most used) media player out there.<\/p>\n<p>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.<\/p>\n<p><b>Suggested Read:<\/b>\u00a0<a href=\"https:\/\/www.tecmint.com\/10-best-open-source-video-players-for-linux-in-2015\/\" target=\"_blank\" rel=\"noopener\">10 Best Open Source Media Players for Linux<\/a><\/p>\n<p>In this article, we will show you a simple hack that will enable you to run VLC media player as root user in Linux.<\/p>\n<p><strong>Note<\/strong>: There is a reason why VLC won\u2019t run in a root account (or can\u2019t be run as root), so because the root account is for system maintenance only, not for everyday activities.<\/p>\n<h3>Install VLC Player in Linux<\/h3>\n<p>Installing\u00a0<strong>VLC<\/strong>\u00a0is so easy, it is available in official repositories of mainstream Linux distros, just run the following command on your respective Linux distribution.<\/p>\n<pre>$ sudo apt install vlc   \t #Debain\/Ubuntu\r\n$ sudo yum install vlc \t         #RHEL\/CentOS\r\n$ sudo dnf install vlc   \t #Fedora 22+\r\n<\/pre>\n<p>If you are running your Linux system as root, for example Kali Linux, you\u2019ll get the error below when you try to run VLC.<\/p>\n<pre>\"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).\"\r\n<\/pre>\n<h4>Alternative Ways to Run VLC as Root User<\/h4>\n<p>Run the\u00a0<a href=\"https:\/\/www.tecmint.com\/linux-sed-command-tips-tricks\/\" target=\"_blank\" rel=\"noopener noreferrer\">sed command<\/a>\u00a0below to make changes in the VLC binary file, it will replace the\u00a0<strong>geteuid<\/strong>\u00a0variable (which determines the effective user ID of the calling process) with\u00a0<strong>getppid<\/strong>\u00a0(which will determine the parent process ID of the calling process).<\/p>\n<p>In this command, \u2018<strong>s\/geteuid\/getppid\/<\/strong>\u2018 (<strong>regexp=geteuid, replacement=getppid<\/strong>) does the magic.<\/p>\n<pre>$ sudo sed -i 's\/geteuid\/getppid\/' \/usr\/bin\/vlc\r\n<\/pre>\n<p>Alternatively, edit the VLC binary file using a hex-editor such as\u00a0<strong>bless<\/strong>,\u00a0<strong>hexeditor<\/strong>. Then search for\u00a0<strong>geteuid<\/strong>\u00a0string and replace it with\u00a0<strong>getppid<\/strong>, save the file and exit.<\/p>\n<p>Yet again, another way around this is to download and compile the VLC source code by passing the\u00a0<code>--enable-run-as-root<\/code>\u00a0flag to\u00a0<code>.\/configure<\/code>\u00a0and VLC should be able to run as root.<\/p>\n<p>That\u2019s all! You should now run VLC as root user in Linux. To share any thoughts, use the feedback form below.<\/p>\n<p><a href=\"https:\/\/www.tecmint.com\/run-vlc-media-player-as-root-in-linux\/\" target=\"_blank\" rel=\"noopener\">Source<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>VLC\u00a0is a free and\u00a0open 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 &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.appservgrid.com\/paw92\/index.php\/2019\/03\/16\/how-to-install-and-run-vlc-media-player-as-root-in-linux\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;How to Install and Run VLC Media Player as Root in Linux&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-11719","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/11719","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/comments?post=11719"}],"version-history":[{"count":1,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/11719\/revisions"}],"predecessor-version":[{"id":11721,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/11719\/revisions\/11721"}],"wp:attachment":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/media?parent=11719"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/categories?post=11719"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/tags?post=11719"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}