Error: Unable to set up server: basic_string::_S_create

server-synology

#4

Thank you! I stand corrected!


#5

Is there anything I can do to help diagnose the problem ?

In DSM5 I had the problem when PMS was started with other packages during boot. but manual start always worked. Now with DSM6 it's a bit random, even with the NAS at 5% utilization sometimes I receive the error.


#6

If you can reproduce every time, then a stack trace would be helpful here


#7

@moody_blue have you made the following changes at all and does it make a difference?

cd "/var/packages/Plex Media Server/scripts"

vi start-stop-status

Changes are highlighted bold:

start_plex ()
{
PLEX_PATH=$(/usr/syno/sbin/synoshare --get Plex | grep Path | awk -F[ '{print $2}' | awk -F] '{print $1}') sleep 30
su plex -s /bin/sh -c "export LD_LIBRARY_PATH='$PLEX_DIR';export PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS=$PROCS; export PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR='$PLEX_LIBRARY_PATH';export TMPDIR=$PLEX_PATH/tmp_transcoding;ulimit -s 3000;sleep 15;/var/packages/Plex\ Media\ Server/target/Plex\ Media\ Server &"

counter=20


#8

@dane22 How can I produce a stack trace ?

@trumpy81 I will test your suggestion tomorrow


#9

No problem moody, I was thinking you had already made that change, but hold off on that until you can possibly get a stack trace. I have no idea how to grab that on Synology, sorry.


#10

I'm digging in the tool chains now how to get the trace.

Just to be upfront... I want to add that if the change does prevent failure at startup, it still doesn't address where it's happening and we won't know until we catch the failure while tracing. All this does is let some other library (?) get into memory fully (which shouldn't happen if Linux is working right) before starting Plex.

In a word, and I'm not being skeptical or nay-sayer. but this is a "band-aid".

However, if it's going to be added, how about putting it where it belongs?

start)
    sleep 30
    echo Starting Plex ...
    start_plex
    exit $?
    ;;

#11

A console log should also be grabbed


#12

There is no 'console' on synology. Best that can be captured is stdout & stderr from when the script runs


#13

Yes, you are absolutely correct Chuck, it is a bandaid, but it has helped some folks before. I did not come up with that either, I think it was suggested by another user in the forums quite some time ago.


#14

ok.. just being communicative. I have the DSM 5 toolchain working (after hacking it) in DSM 6. It has the tools we need. I'm getting the other sources & building binaries for synology I think we'll need as well.


#15

I have the same problem all the time. changing the sleep duration in the script does not work/fix it


#16

@zeltum said:
I have the same problem all the time. changing the sleep duration in the script does not work/fix it

Is the error repeatable every time and, if so, what are the conditions / apps you also have running? We see it and then it goes away before anyone can reproduce it.


#17

Which version of PMS are you running?


#18

OK, this is happening ever time for me. I can't use PMS at all until it's resolved. I tried the band-aid fix above with no luck.

Please let me know what else you need from me to fix this. My configurations is: Intel(R) Atom(TM) CPU C2538 @ 2.40GHz running DSM 6.0.1-7393 Update 1.


#19

@grlucas said:
OK, this is happening ever time for me. I can't use PMS at all until it's resolved. I tried the band-aid fix above with no luck.

Please let me know what else you need from me to fix this. My configurations is: Intel(R) Atom(TM) CPU C2538 @ 2.40GHz running DSM 6.0.1-7393 Update 1.

You've stopped / uninstalled Video Station?

Did you try to uninstall PMS, restart, then reinstall it? For reasons we do not understand, that has actually corrected something in DSM.


#20

Not able to start Plex Media server no more. In Package Center I go to Plex Media Server > Action > Run. Status goes to 'Starting' but after a few seconds it goes back to 'Stopped'
I have uninstalled the application, restarted the NAS, reinstalled the application but still won't start up.

Configuration:
Synology DS1515+
DSM 6.0.1-7393 Update 1
w/3 x 4TB Toshiba MD04ACA400

Log:
Jul 15, 2016 19:38:57 [0xf2d11b40] INFO - Plex Media Server v0.9.16.3.1840-cece46d - synology DiskStation i686 - build: linux-synology-i686 synology
Jul 15, 2016 19:38:57 [0xf2d11b40] INFO - Linux version: 3.10.77 (#7393 SMP Thu Jun 2 19:50:12 CST 2016)
Jul 15, 2016 19:38:57 [0xf2d11b40] INFO - Processor Intel(R) Atom(TM) CPU C2538 @ 2.40GHz
Jul 15, 2016 19:38:58 [0xf386d780] ERROR - CERT: Found a user-provided certificate, but couldn't install it.
Jul 15, 2016 19:38:58 [0xf386d780] ERROR - Error: Unable to set up server: basic_string::_S_create

Thanks


#21

You are seeing the problems with DSM 6 we all see.

Uninstall PMS, restart, install again, Start PMS

You should also consider upgrading to something newer. I maintain 0.9.16.6 as my emergency fallback. Synology's Package Center version is very old by comparison.


#22

Is there a proper fix or Plex software update on the Package Centre that fixes the problem? Why can't the latest version be on the Package Centre anyway?

I have the same problem.


#23

Package Center only has 0.9.16.3. Synology does things at 'their' pace.

IF we could ever get a machine / situation which reproduced it every time, we could figure a way around it but to date there have been no instances.