Server Version#: 1.41.3.9314
Player Version#: N/A
Free BSD 13.4
Struggling to install plexmediaserver on my TrueNAS server.
First tried using the built-in plugin. but it’s not working at all.
Then created manually a jail. installed plexmediaserver and setup the necessary for the service to start automatically.
Service closing shortly after starting. Here are the warning/errors in the log file:
…
Feb 08, 2025 07:48:55.875 [0x806c12000] WARN - Failed to create temp dir “/tmp/pms-22708cdd-aa23-48c2-8c0e-b805ae3b57e2”: 13, Permission denied
Feb 08, 2025 07:48:55.876 [0x806c12000] ERROR - Unable to open named mutex 9334581e-7251-4ef7-a8ec-5bfe8e89ff68 with option 1: Permission denied
…
Feb 08, 2025 07:48:55.936 [0x806c12000] INFO - Analyzing database.
Feb 08, 2025 07:48:55.937 [0x806c12000] INFO - Vacuuming database.
Feb 08, 2025 07:48:55.937 [0x806c12000] ERROR - SQLITE3:0x10, 6410, statement aborts at 5: [CREATE TABLE “media_parts” (“id” INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, “media_item_id” integer, “directory_id” integer, “hash” varchar(255), “open_subtitle_hash” varchar(255), “file” varchar(255), “index” integer, “size” integer(8), “duration” integer, “created_at” dt_integer(8), “updated_at” dt_integer(8), “deleted_at” dt_integer(8), “extra_data” varchar(255))] disk I/O error
Feb 08, 2025 07:48:55.937 [0x806c12000] ERROR - SQLITE3:0x10, 10, statement aborts at 1: [VACUUM] disk I/O error
Feb 08, 2025 07:48:55.939 [0x806c12000] ERROR - Exception thrown during migrations, aborting: sqlite3_statement_backend::loadOne: disk I/O error
Feb 08, 2025 07:48:55.939 [0x806c12000] ERROR - Database corruption: sqlite3_statement_backend::loadOne: disk I/O error
–end–
did a database integrity check in SQLite on this db
“/usr/local/share/plexmediaserver/Plex SQLite” “/usr/local/plexdata/Plex Media Server/Plug-in Support/Databases/com.plexapp.plugins.library.db”
and it returned OK.
Im out of idea on what to check to resolve this issue. Any help or idea would be appreciated.
Strange that the DB would already be corrupted right after plexmediaserver installation. But, like you said, the error pretty much say that. This is a totally new clean jail running in TrueNAS. First and only thing I did in it was to install plexmediaserver and configure it to start at bootup. No movies/music/etc… in library yet.
I have download Plex DB Repair but it does not support my host. FreeBSD 13.4 running in a TrueNAS jail
When I run the DBRepair.sh script I Get this message:
root@manualPlex:~/PlexDBRepair # ./DBRepair.sh
grep: /proc/1/cgroup: No such file or directory
grep: /proc/1/cgroup: No such file or directory
grep: /proc/1/cgroup: No such file or directory
grep: /proc/1/cgroup: No such file or directory
Error: Unknown host. Current supported hosts are: QNAP, Syno, Netgear, Mac, ASUSTOR, WD (OS5), Linux wkstn/svr, SNAP
Current supported container images: Plexinc, LinuxServer, HotIO, & BINHEX
Manual host configuration is available in most use cases.
Are you trying to run the tool from outside the container environment? Manual mode is available. Please see documentation.
However, I can run it using manual host configuration with the following command:
./DBRepair.sh --sqlite [SQLitePath] --databases [PlexDBPath]
But when I search for plex db file (com.plexapp.plugins.library.db) it finds 2 occurences:
Unfortunately, I also have errors coming from the shell script. I dont know at this point how much it affect the result. I gave full control to everyone to the Databases directory.
Feb 10, 2025 18:08:31.160 [0x806c12000] WARN - Failed to create temp dir "/tmp/pms-ed72802f-e494-4be7-93cc-18d589a6a10b": 13, Permission denied
Feb 10, 2025 18:08:31.160 [0x806c12000] ERROR - Unable to open named mutex 9334581e-7251-4ef7-a8ec-5bfe8e89ff68 with option 1: Permission denied
Feb 10, 2025 18:08:32.460 [0x806c12000] ERROR - SQLITE3:0x10, 6410, statement aborts at 5: [CREATE TABLE "media_parts" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "media_item_id" integer, "directory_id" integer, "hash" varchar(255), "open_subtitle_hash" varchar(255), "file" varchar(255), "index" integer, "size" integer(8), "duration" integer, "created_at" dt_integer(8), "updated_at" dt_integer(8), "deleted_at" dt_integer(8), "extra_data" varchar(255))] disk I/O error
Feb 10, 2025 18:08:32.460 [0x806c12000] ERROR - SQLITE3:0x10, 10, statement aborts at 1: [VACUUM] disk I/O error
Feb 10, 2025 18:08:32.462 [0x806c12000] ERROR - Exception thrown during migrations, aborting: sqlite3_statement_backend::loadOne: disk I/O error
Feb 10, 2025 18:08:32.462 [0x806c12000] ERROR - Database corruption: sqlite3_statement_backend::loadOne: disk I/O error
I had already full control to everyone to the database folder and it did not work. Just gave full control to everyone to the /tmp folder and it started! thanks.