Can't update Plex on my TVS-882

Current Server Version#: 1.20.2.3402

Got a notification that there was an update to version 1.20.3.3421 and downloaded it. Went to the AppCenter and tried to do a manual install, but only received a message that it couldn’t be installed and to look in the system log for more details.

Unfortunately there are no details about the attempt to install the update. I reboot the device every Saturday morning, so figured I would wait and try again after it restarted, but with the same result. I have tried it with my normal user as well as the admin with no difference.

I did try to do an install of the current version, but receive the same error, so I am thinking that the problem is on QNAP and not the update package.

Just wondering if anyone else has seen this issue before? I am running version 4.4.3.1439 on the device, and that was installed on the 25th of September, and the current version of Plex was installed on the 3rd of October, so no changes in the OS since then, and plenty if room on the NAS volume.

TIA
Peter

TVS-882 is x86_64

If you got a corrupted download, it’s usually the browser’s (or a plug-ins) fault.
Switch to a different browser or do a direct wget of the URL.

I don’t believe the download is corrupted as I tried to reinstall the existing version with the same result.

@pvoveris

Can you upload the QPKG to a shared folder on the QNAP then:

  1. SSH into the QNAP
  2. cd into the shared folder which contains the QPKG file
  3. chmod +x name_of_qpkg_file.qpkg
  4. “execute it”. (it’s a self installing package on qnap)
  5. ./package_file_name.qpkg
  6. Copy all the output and paste back here with your reply.
1 Like

Oddly, it worked and updated the system.

[/share/pvoveris] # ./PlexMediaServer-1.20.3.3421-54b6523bd-x86_64.qpkg
Install QNAP package on TS-NAS…
./
./package_routines
./qpkg.cfg
./built_info
./qinstall.sh
4464+1 records in
4464+1 records out
110801764 bytes (105.7MB) copied, 0.257125 seconds, 411.0MB/s
108203+0 records in
108203+0 records out
110799872 bytes (105.7MB) copied, 0.257173 seconds, 410.9MB/s
PlexMediaServer 1.20.2 is already installed. Setup will now perform package upgrading.
Firmware check is fine.
Stopping Plex Media Server…
Link service start/stop script: plex.sh
Set QPKG information in /etc/config/qpkg.conf
rm: ‘/share/CACHEDEV1_DATA/.qpkg/PlexMediaServer/Library/Plex Media Server’ is a directory
ln: /share/CACHEDEV1_DATA/.qpkg/PlexMediaServer/Library/Plex Media Server/Plex Media Server: File exists
Starting Plex Media Server…

Thanks for sharing the output.

I see where I can improve that and will schedule an update to the QPKG installation scripting.

(I don’t like unwanted ‘noise’ in the scripting which is being printed out)

When I’m done, I’ll give it to Engineering for inclusion when they next update the packaging.

Still can’t install from the AppCenter though.

You need QNAP to help with the App Center portion.
I have an idea what’s happening but it is their box and I wouldn’t want to be responsible for anything if I were to give unclear instructions.

OK, I asked the same question on their forum, but I will contact their support on Monday.

Thanks for your help!

Hi Chuck, QNAP support has no idea what to do, what are your thoughts on the cause of the issue? We tried rebooting, and reinstalling the firmware, other than that they said to uninstall and reinstall Plex.

If you uninstall, QPKG will erase your installation (all your metadata).

Therefore, if we’re going to follow that method we need to make a solid backup of it

First, I’d like you to make a 100% solid backup

  1. Stop PMS
  2. SSH into it.
  3. cd /share/CA*/.qpkg/Ple*/Li*/Ple*
  4. Now we make a tar.gz of your entire installation (within Plex) and store it some place safe .
  5. tar cfz /path/to/a/safe/directory/somewhere/else/PlexBackup.tar.gz . (don’t forget the trailing dot)
  6. This will take some time
  7. When it’s done, and you can verify the backup file exists in that other location -
    tar tf /path/to/a/safe/directory/somewhere/else/PlexBackup.tar.gz
  8. This will run until the end – listing every file in the archive

If you have any errors. Do not uninstall and message me.

Presuming all is good, Uninstall PMS and restart QTS

Now comes the task of installing and recovering,

  1. Install PMS
  2. Stop PMS - no need to do anything with it. We’re going to erase this temporary install.
  3. SSH back into the box.
  4. cd /share/CA*/.qpkg/Ple*/Li*/Ple*

Now for the fun,

  1. Remove the temporary installation rm -rf .
  2. Won’t take long because this installation is empty
  3. Bring back the saved files. tar xf /path/to/a/safe/directory/somewhere/else/PlexBackup.tar.gz
  4. This will take some time to extract everything
  5. Now restart PMS.
  6. You’ll find your server is right there as if it never left

This would just be the metadata and config, not the media files, hopefully, ah yes, it is.

Also, I have two data directories which seem to be in sync, One under Plex, and one Under PlexData.

Correct. This would capture only those items in the “Plex Media Server” directory. No media would be captured unless they were items which are still queued to download and the sync directory is still in the default location.

The PlexData shared folder contains that linkage to Plex Media Server.
It’s the same place that /share/CA*/.qpkg/Ple*/Li*/Ple* would take you.

If you’re more comfortable using FileStation – Great! That’s one of the reasons I created the PlexData shared folder and “Plex Media Server” linkage. Just be certain to click into the “Plex Media Server” link and take the resultant ZIP file out of there when done because QPKG will delete it as part of uninstall.

Oh, OK, just wanted to make sure that there wasn’t a set of duplicate files out there to confuse with. I am zipping the file to my own share, so no issues there.

This is where you’ll end up ( same as clicking the link in PlexData)

[/bin] # cd /share/CA*/.qpkg/Ple*/Li*/Ple*
[/share/CACHEDEV3_DATA/.qpkg/PlexMediaServer/Library/Plex Media Server] # ls
Cache/	 Crash Reports/  Logs/	 Metadata/	      Plug-ins/		Preferences.xml
Codecs/  Diagnostics/	 Media/  plexmediaserver.pid  Plug-in Support/
[/share/CACHEDEV3_DATA/.qpkg/PlexMediaServer/Library/Plex Media Server] #

Considering the amount of time it took to do the zipping I think I may wait until the next QNAP firmware update is installed, as that will update the AppCenter as it is part of the firmware update.

If new firmware doesn’t correct the issue, then I will try the reinstall, although I doubt that doing a reinstall would do anything. Especially considering that Plex would be offline for most of the day while I did this.

You mentioned earlier that you had a thought on the problem with the AppCenter and I would be interested in hearing what that was. I also have the same issue with another program that is installed manually and has the unable to install error. I did try to install an app through their AppCenter, the Text Editor app, and it went fine.

Peter

Peter,
When I’ve encountered App Center errors in the past, the problem has been with something App Center didn’t do correctly in the QPKG configuration file (/etc/config/qpkg.conf).

This is how it should look when Plex is installed.

[PlexMediaServer]
Status = complete
Name = PlexMediaServer
Build = 20200922
Display_Name = Plex Media Server
Version = 1.20.2
Author = Plex Build Team
QPKG_File = PlexMediaServer.qpkg
Date = 2020-10-08
Shell = /share/CACHEDEV3_DATA/.qpkg/PlexMediaServer/plex.sh
Volume_Select = 3
Install_Path = /share/CACHEDEV3_DATA/.qpkg/PlexMediaServer
WebUI = /web
Web_Port = 32400
Web_SSL_Port = 32400
RC_Number = 101
Timeout = 10,30
Enable = TRUE
FW_Ver_Min = 4.3.0
FW_Ver_Max = 4.9.9

Hand editing of this file, while dangerous, does allow you to remove a package which isn’t registered correctly / is stuck after removal. Manually deleting its “block” and restarting App Center allows gives it properly defined packages to work with.

In these cases, even if a package is installed, it won’t show as installed and allow full overwrite.

There are two other files less likely to be the problem and which I’d rather not name because playing in those files can really mess up the whole NAS.

Doesn’t seem to be the case here, looks fine to me, other than version differences.

[PlexMediaServer]
Status = complete
Name = PlexMediaServer
Version = 1.20.3
Author = Plex Build Team
QPKG_File = PlexMediaServer.qpkg
Date = 2020-10-12
Shell = /share/CACHEDEV1_DATA/.qpkg/PlexMediaServer/plex.sh
Install_Path = /share/CACHEDEV1_DATA/.qpkg/PlexMediaServer
WebUI = /web
Web_Port = 32400
Web_SSL_Port = 32400
RC_Number = 101
Enable = TRUE
Visible = 2
Login_Screen = 1
Build = 20201009
Display_Name = Plex Media Server
Volume_Select = 3
Timeout = 10,30
FW_Ver_Min = 4.3.0
FW_Ver_Max = 4.9.9

Then indeed the problem is in the other files.

There is only one guaranteed solution, given that QNAP failed to remedy it,
is to copy everything off and setup it up again from factory defaults.
Reinstalling the firmware doesn’t remove any damaged user or application configuration files (App Center) is an app , with config files, but unfortunately we can’t uninstall it.

Ask QNAP what they think? Other than changing firmware version (downgrade), which I’ve done in the past successfully, I am completely out of ideas.

The thing is that nothing changed. I updated the firmware for the NAS on the 25th, no issues.

On the 3rd I updated Plex, and no issues, then on the 10th, it didn’t work, and the problem is only using the Manual Install.