Forums

Bill
Bill
Offline
Resolved
0 votes
Hello,

Through the admin I went to access the plex media server and I got this message:

Ooooops: /bin/ls: cannot access /var/run/PlexMediaServer.pid: No such file or directory

I did some research and and file in question is PlexMediaServer.pid.

I did try :

1) I putty in and deleted the file.

2) started the service with no error messages through the command line service plexmediaserver start.

3) The file was created , but still non usable.

I have uninstalled, restarted the server and then re-installed and I am still getting the same error.

Any help is greatly appreciated!.

Thank you in advance!

Bill
Tuesday, March 11 2014, 11:10 PM
Share this post:
Responses (19)
  • Accepted Answer

    fikse
    fikse
    Offline
    Saturday, September 27 2014, 12:30 PM - #Permalink
    Resolved
    0 votes
    Dave Loper wrote:
    Even though the process is dead, stop the service. This will clear the pid file properly:

    /etc/init.d/plexmediaserver stop


    Then start the service:

    /etc/init.d/plexmediaserver start


    I had suddenly and out-of-the-air the identical fault as Bill. I did as You suggested here, and when it started it said something like
    Starting PlexMediaServer:                                  [  OK  ]
    ln: creating symbolic link `/var/run/PlexMediaServer.pid': File exists


    Brilliant. Stuff is working as it should. B)
    The reply is currently minimized Show
  • Accepted Answer

    Sunday, April 27 2014, 09:58 AM - #Permalink
    Resolved
    0 votes
    Great you have it working! ClearOS with Plex Media Server really rocks.

    I have experienced this problem one time. I just deleted the PID file and haven't had any issues any more.
    The reply is currently minimized Show
  • Accepted Answer

    Bill
    Bill
    Offline
    Saturday, April 26 2014, 08:36 PM - #Permalink
    Resolved
    0 votes
    Hello Helpful People,

    The issue for me has been resolved. I got frustrated so, since I back up all the files for the web, I attempted a clean install.

    When I zeroed out my hard drive with active kill. When I went to do the install the hard drive had a complete failure.

    After installing a new hard drive and clean install everything is functioning perfectly.

    I especially want to thank Tim and Nick, for all there help. I think ClearOs is a great server.!

    Thank you every one!

    Bill
    The reply is currently minimized Show
  • Accepted Answer

    Saturday, April 26 2014, 07:25 AM - #Permalink
    Resolved
    0 votes
    I installed the Plex Media server via the Marketplace and also got this error, I rebooted my ClearOS server and Plex now works .....
    The reply is currently minimized Show
  • Accepted Answer

    Friday, April 25 2014, 09:57 PM - #Permalink
    Resolved
    0 votes
    Even though the process is dead, stop the service. This will clear the pid file properly:

    /etc/init.d/plexmediaserver stop


    Then start the service:

    /etc/init.d/plexmediaserver start
    The reply is currently minimized Show
  • Accepted Answer

    Thursday, April 03 2014, 10:07 AM - #Permalink
    Resolved
    0 votes
    try "service plexmediaserver start"
    The reply is currently minimized Show
  • Accepted Answer

    Bill
    Bill
    Offline
    Friday, March 14 2014, 11:18 PM - #Permalink
    Resolved
    0 votes
    Hi Tim,

    here is what I am getting from the log;


    Mar 13, 2014 18:26:48 [0xb77046d0] INFO - Plex Media Server v0.9.9.5.411-da1d892 - ubuntu PC i686

    Mar 13, 2014 18:26:48 [0xb77046d0] DEBUG - Opening 10 database sessions to library, SQLite 3.8.0.2,threadsafe=1

    Mar 13, 2014 18:26:48 [0xb77046d0] INFO - SQLITE3:a, 283, recovered 48 frames from WAL file /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-in Support/Databases/com.plexapp.plugins.library.db-wal

    Mar 13, 2014 18:26:48 [0xb77046d0] DEBUG - Running migrations.

    Mar 13, 2014 18:26:48 [0xb77046d0] ERROR - Error: Unable to set up server: bind: Address already in use

    I am wondering if I able to clear out the bind address? And possibly that would fix it?


    OK I did
    cat Preferences.xml 
    Inside of Plex Media Server this is what I got

    <?xml version="1.0" encoding="utf-8"?>
    <Preferences MachineIdentifier="a659b7f5-13fe-4ad4-bbb7-c76c1aaf2f16" ProcessedMachineIdentifier="33705e1e4e56ab8bd3f4d35e1704256e02c1c960 " AcceptedEULA="1" PlexOnlineMail="XXXX67" PlexOnlineToken="5PXwWom4rkpgzUBcc1HT" PlexOnlineUsername="XXXX67" PublishServerOnPlexOnlin eKey="1" FirstRun="0" FriendlyName="myplex.SOMETHING.net" collectUsageData="0" ManualPortMappingMode="1" FSEventLibraryUpdatesEnabled= "1"/>


    xxxx67 is my user name

    myplex.SOMETHING.net is the plex server

    Do you think it would be safe to clear this out and would I use nano to set these to nothing?

    _______________________________________________________________________________________________
    UPDATE:

    1) I have renamed the Preferences.xml
    2) uninstalled plex
    3) Removed symbolic link
    4) Re-installed Plex
    5) This created a new Preference.xml and the errant symbolic link
    6) In the clearOS Plex link I got the server stopped warning and I got another message that I was already logged in.

    Based what I am observing, even though Plex is being uninstalled, there is user data that isn't being deleted. I just haven't found the the last piece(s) as of yet.

    Thank you guys for your help!

    Bill
    The reply is currently minimized Show
  • Accepted Answer

    Friday, March 14 2014, 01:09 PM - #Permalink
    Resolved
    0 votes
    Plex handles it's own PID file at /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/plexmediaserver.pid

    When the service starts (when called by the 'service plexmediaserver restart' command) it creates the file and populates it based on the running process ID. A symlink is created from /var/run/PlexMediaServer.pid to this location. If it's red it means that it doesn't exist

    What often happens with processes that die without notice is that the subsys remains locked i.e. a stale 'lock' file exists, preventing it from restarting. Usually a simple 'service plexmediaserver restart' is all that's required and it will remove the stale lock file and recreate the PID, but it sounds like yours is bailing. You should find further clues in the LOGS
    tail /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Logs/Plex\ Media\ Server.log


    P.S Annoying spaces in their directory structure!
    The reply is currently minimized Show
  • Accepted Answer

    Friday, March 14 2014, 08:30 AM - #Permalink
    Resolved
    0 votes
    I am afraid you're beyond where I can try and help.

    I know you say the symlink is errant, but it could be a problem with the symlink target. What is the output of:
    ls -l /var/run/P*
    I get:
    lrwxrwxrwx 1 root root 90 Mar 10 21:55 /var/run/PlexMediaServer.pid -> /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/plexmediaserver.pid
    I suspect it is more likely the target is incorrrect. With Plex running, what is the output of:
    ls -l "/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/plexmediaserver.pid"
    Note I had to use quotes round the file name because of the spaces in the path.
    The reply is currently minimized Show
  • Accepted Answer

    Bill
    Bill
    Offline
    Thursday, March 13 2014, 10:39 PM - #Permalink
    Resolved
    0 votes
    Hi Nick,

    Thank you for the help! The issue is still not resolved. Here is what I do know;

    The issue appeared to happen right after I was forced to purchase the Plex channel on my roku.

    Once I disconnected from the server thru roku, then in the clearOS web admin I could access the Plex server page with the server stopped.

    Once I start the service, the plex server dies and I get the same error referencing the symbolic link. Thereby preventing me from accessing the Plex server page through the web admin.

    I have uninstalled and re-installed with restarts, the plex server. So, It really comes down to the server when started creates the errant symbolic link and then dies. Plus I can only start the server from the CL when I start from the web admin it basically just sits there spinning its wheels, stuck in the process of starting up.

    What I have learned is that maybe roku users should disconnect from the server before purchasing the channel. Then after the purchase start the server back up and re-connect.

    Bill
    The reply is currently minimized Show
  • Accepted Answer

    Thursday, March 13 2014, 12:37 PM - #Permalink
    Resolved
    0 votes
    I am generally reluctant to advise on app removal in case of unwanted side effects. I know that the plex web config also pulls in another couple of dependencies and plex iself brings in ffmpeg. If we ignore those, you can try removing the core plex apps with:
    rpm -e plex* app-plex* --nodeps
    The if you do an "updatedb && locate plex" that should show residual files with plex in the name. Don't worry about rpmsave files. They are just your old config files. To do a reinstall you should just be able to then do a:
    yum install app-plex
    The reply is currently minimized Show
  • Accepted Answer

    Bill
    Bill
    Offline
    Thursday, March 13 2014, 03:31 AM - #Permalink
    Resolved
    0 votes
    The reply is currently minimized Show
  • Accepted Answer

    Bill
    Bill
    Offline
    Wednesday, March 12 2014, 09:43 PM - #Permalink
    Resolved
    0 votes
    Ok this is what I did;

    1) I ran the command suggested and got this:
    11439 0.0 0.0 4356 740 pts/0 S+ 16:20 0:00 grep plex

    2) I renamed the suggest file and I renamed the file PlexMediaServer.pid

    The service started with no messages. When I attempted Servers --> Plex media Server I still get
    Ooooops: /bin/ls: cannot access /var/run/PlexMediaServer.pid: No such file or directory

    I am wondering if you might know what files or folders that I could CL remove after I un install the Plex server and then attempt to re-install. it all comes back to the symbolic Link of PlexMediaServer.pid . Is this file suppose to hold the proccess id of the Plex Server. The reason why I ask is because when I start the service it checks if the file exists and if doesn't creates the file. Also in that directory there are other pid files with a grey color, this is more of a redish color.
    The reply is currently minimized Show
  • Accepted Answer

    Wednesday, March 12 2014, 09:17 PM - #Permalink
    Resolved
    0 votes
    Check if plex is running with a "ps aux | grep plex". If it is not, try deleting (or, safer, renaming) /var/lock/subsys/PlexMediaServer and restarting plex.
    The reply is currently minimized Show
  • Accepted Answer

    Bill
    Bill
    Offline
    Wednesday, March 12 2014, 08:13 PM - #Permalink
    Resolved
    0 votes
    On the service plexmediaserver status I get

    PlexMediaServer dead but subsys locked

    I don't think that sounds good for me, lol.

    Thanks Nick.
    The reply is currently minimized Show
  • Accepted Answer

    Wednesday, March 12 2014, 08:04 PM - #Permalink
    Resolved
    0 votes
    The yellow icon just means the webconfig item was updated in the last 24 hours. Nothing to worry about. Can you try dropping to the command line then doing a:
    service plexmediaserver restart
    service plexmediaserver status
    From memory one of these created the symlink for me.
    The reply is currently minimized Show
  • Accepted Answer

    Bill
    Bill
    Offline
    Wednesday, March 12 2014, 07:29 PM - #Permalink
    Resolved
    0 votes
    Hi Nick,

    Everytime I attempt to access the Plex Media server, which has a yellow error icon next to it, I get this message:

    Ooooops: /bin/ls: cannot access /var/run/PlexMediaServer.pid: No such file or directory

    So, I am looking for a solution to get the plex media server going again.

    I have uninstalled the server, restarted, and re-installed with no luck.

    Thanks for your help,

    Bill
    The reply is currently minimized Show
  • Accepted Answer

    Wednesday, March 12 2014, 07:22 PM - #Permalink
    Resolved
    0 votes
    OL. The symlink points to /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/plexmediaserver.pid and it contains the process ID od one of the plex processes ("ps aux | grep plex"). What are you trying to do with the file?
    The reply is currently minimized Show
  • Accepted Answer

    Wednesday, March 12 2014, 12:31 PM - #Permalink
    Resolved
    0 votes
    Bill,
    From memory, the file itself is not a file but a symlink to another file elsewhere. I believe the init script creates the symlink when you start the service or or do a "service plexmediaserver status". It may do it whenever you use the "service plexmediaserver" command, but I'd need to check the init script to confirm that,
    I'll need to check the Webconfig when I'm home to see if I observe the same, but note there was an app-plex* update yesterday so things may have changed since you made your observation.
    The reply is currently minimized Show
Your Reply