Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

Install Plex Media Server on Ubuntu

By: a guest on Jul 30th, 2013  |  syntax: None  |  size: 4.14 KB  |  views: 5,097  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. hi,
  2.  
  3. i thought i could write a quick how to for installing pms (plex media server) on ubuntu, because many other linux guides on the internet helped me very much previously.
  4.  
  5. i used ubuntu server 12 lts, but it should work on older ubuntu versions, too.
  6.  
  7. first, you have to open a terminal window or ssh into your computer.
  8.  
  9. How to: plex media server - how to install avahi
  10. --------------------------------------------------
  11.  
  12. it is enough to copy and paste this line to install avahi:
  13.  
  14. sudo apt-get install avahi-daemon
  15.  
  16.  
  17. however you can do much more with avahi. for example advertising afp-shares. this guide covers it.
  18.  
  19. How to: plex media server - how to install plex media server
  20. -------------------------------------------------------------
  21.  
  22. sudo nano /etc/apt/sources.list
  23.  
  24.  
  25. then add "deb http://www.plexapp.com/repo lucid main" to the file.
  26. or add "deb http://www.plexapp.com/repo beta main" for the beta versions.
  27. you can put it wherever you like.
  28. use something like ctrl+x (mac-keyboard) or strg+x (windows-keyboard) to close and safe the file.
  29.  
  30. update apt-get:
  31. sudo apt-get update
  32.  
  33.  
  34. install:
  35. sudo apt-get install plexmediaserver
  36.  
  37.  
  38. how to: plex media server - access plex through a browser on the computer running plex media server
  39. -----------------------------------------------------------------------------------------------------
  40. http://localhost:32400/manage/index.html
  41. or any other computer (connected via lan)
  42. http://ip-address:32400/manage/index.html
  43.  
  44. to initially add media to your library, you can click on one of those icons on your pms website. for example movies:
  45.  
  46. then you can choose a name and directory:
  47.  
  48. the scanning will take a while, depending on how many movies or tv-shows you have.
  49. you should see the progress on the web client  
  50.  
  51.  
  52.  
  53. How to: plex media server - read this if plex does not play any files:
  54. -------------------------------------------------------------------------
  55.  
  56. if plex does not play any files, make sure your permissions are right. because plex is a new user it may not have the permissions to play your media.
  57. you can try it the easy way: add the plex-user to your group:
  58. gpasswd -a plex myuser
  59.  
  60.  
  61. or if you want to change the permissions properly (more work):
  62.  
  63. cd into your media directory, for example:
  64. cd /home/user/media
  65.  
  66.  
  67. then look up the permissions with
  68.  
  69. ls -l
  70.  
  71.  
  72. here you can see if your directory has read/write/execute for every user. its like this: (no colours in real life)
  73.  
  74. drwxrwxr-x 365 user group ---somemorestuff-- foldername
  75.  
  76. rwx indicates read/write/execute for the user.
  77. rwx indicates read/write/execute for the group
  78. r-x indicates that every other user has read/-/execute access.
  79.  
  80. i would assume the user plex only has as much access as the last three letters/hyphens (every other user).
  81. it works for me like this so the blue bit should look different in your setup.
  82. the easyiest thing you can do here is put the plex user in the group:
  83.  
  84. sudo chown youruser:plex -r /home/user/mediadirectory
  85.  
  86. this way plex will be the group and have the groups permissions (green rwx). but if there is no rwx, you will have to give it read/write/execute permissions:
  87.  
  88. sudo chmod 770 -r /home/user/mediadirectory
  89.  
  90.  
  91. the first 7 gives the user read/write/execute permissions. the second 7 is for the group. the 0 in this case gives every other user no permissions at all.
  92. the -r will change the permissions of all files in the folder.
  93.  
  94. now it should look like this: (check with ls -l again!)
  95.  
  96. rwxrwx--- 365 user plex ---somemorestuff-- foldername
  97.  
  98.  
  99. please note: this is just an option!
  100. a complete linux permissions guide would be too long for this how to. but you can find plenty good youtube videos on this topic  
  101. this might also be helpful: https://help.ubuntu....filepermissions
  102.  
  103.  
  104.  
  105. How to: plex media server - how to update plex:
  106. ---------------------------------------------------
  107.  
  108. plex updates just like most of the other linux programs. with aptitude:
  109. (every other programm will update too)
  110.  
  111. sudo aptitude update && sudo aptitude safe-upgrade
  112.  
  113. all programs mentioned here will be updated.
  114. then you have to type in y to continue.
  115. wait...
  116. that is it.