Wednesday, February 9, 2022

Export Your PLEX server library media names in Linux or Windows

LINUX

Make yourself the ROOT user

sudo -i

Verify the location of the "Plex Media Scanner" location.  Depends on the flavor of linux, but usually in in:

/usr/lib/plexmediaserver/

but use this command if you cant find it find / -name "Plex Media Scanner"

Update the path to allow the scanner access to related files.

export PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR="/var/lib/plexmediaserver/Library/Application Support"

Now we are ready to run the scanner.  This command will give you the libraries you can export:

/usr/lib/plexmediaserver/Plex\ Media\ Scanner --list

This will list of your Libraries, each assigned with a number. something like this as an example:

1: Movies   
2: TV Shows 
3: Music
4: Videos

This example is "Movies", so a "1" will be used for the "--section" argument in the next line

/usr/lib/plexmediaserver/Plex\ Media\ Scanner --list --section 1

You'll get a list of movies and folders it has and you can copy /paste it.  
If you want to output it to a file you can use a command like this:

/usr/lib/plexmediaserver/Plex\ Media\ Scanner --list -section 1 > plexlist.txt


WINDOWS

You can also do this from windows if you do the following:

  1. Goto the default plex directory from a command prompt
    "C:\Program Files (x86)\Plex\Plex Media Server"

  2. Enter in the command"
    "Plex Media Scanner.exe" --list

  3. You'll get a  list of available libraries.
    "Plex Media Scanner.exe" --list -section 1

  4. You can print it to the cmd interface, or you can print it to a directory
    "Plex Media Scanner.exe" --list -section 1 > plexlist.txt

No comments:

Post a Comment