Support Doc for Database Cache Size (MB)?

@Sittingmongoose

I don’t know how to run the service HOWEVER :wink:

kill -15 $(pidof 'Plex Media Server')

should also bring it down gracefully.

We did learn last night that the Arch linux container (Please look at the thread I split out) contains working code for Arch and should also work for all docker container implementations.

I’m working right now (semi-manually) using OMV + Docker and testing.

I’m loading up a 340K episode dummy database.

From there, I should be able to plot and determine the point of diminishing returns.
This is important for all small-memory systems because it will take from system memory. When you only have 1 GB of RAM, 200 MB is a lot)

As for this, Look around inside the container and find how the container starts plex.

It might be in the /home directory structure…
It’s going to take some investigating.

This is your opportunity to contribute to the cause :smiley: lol

If I may suggest, re-ordering the selections, so the proper sequence is … sequential…

IE, change the script order so its 1 - 2 - 3

and maybe put in a hint that vacuum is probably not needed after doing 1,2,3 (or 1,4,3 currently).

1 check > 2 repair > 3 reindex
4 vacuum (not necessary after re-index)

I realize this is an advanced tool, but you are going to get non-advanced users trying to use it… might as well make it as simple as as 1,2,3 … :slight_smile:

thank you and everyone for their efforts!

1 Like

@ChuckPa

Not sure if this has anything to do with what’s being discussed here, but I checked on the size of my databases yesterday and noticed that I now have a com.plexapp.plugins.library.db-wal file that’s larger than my current database. It was tiny just a few days ago.

This is the same thing that happened to @jaquestati in this thread Library database doubled have db-wal database of almost the same size as the regular old .db file, but for some reason I am unable to reply there.

I’ve never had a corrupt database or any issues related to database performance. What could have caused this?

WAL is the SQLite write-ahead log. In-flight transactions are written to the WAL first.

WAL files can grow for a number of reasons, and a large WAL file isn’t necessarily a sign of anything wrong. It can be but it’s not an immediate red flag.

WAL files should be removed when a database file is closed cleanly.

If you shut down Plex, are the WAL files removed?

If not, after stopping Plex, does running Plex\ SQLite com.plexapp.plugins.library.db "select count(1) from accounts" remove the WAL file?

I wonder if this should move to a different thread.


But I’ve seen something similar.

I’ve noticed that on FreeBSD, Plex doesn’t seem to shut down cleanly. Which means that WAL files aren’t deleted.

Plex on FreeBSD doesn’t shutdown with a normal kill -15. The FreeBSD port rc script even performs kill -9. That’s quite odd and I’ve been meaning to investigate.

What does the runcontrol for Plex Media Server Linux look like? How is it told to stop?

@VBB @Volts

I have a Windows VM ( :face_vomiting: )

Point me to where the default locations are please ? %APPDATA doesn’t seem to exist from the command line (or I’m driving the wrong end of the bus) nor can I find the Plex executables . LOL

I have mine in a custom place, but I think default is in %Users\AppData\Local\Plex\Data\Plex Media Server\Plug-in Support\Databases.

Welcome to Windows! :stuck_out_tongue:

Type %LOCALAPPDATA% in an Explorer location bar. There’s a Plex Media Server directory in there.

It’s usually C:\Users\[username]\AppData\Local.

Windows does this hologram insanity with Program Files vs. Program Files (x86). The amount of backwards compatibility built into Windows is really stunning. Try %ProgramFiles%.

Is this what you guys feel like when I talk Linux?

:scream:

lol

Screenshot from 2022-12-15 14-36-35

1 Like

AppData is hidden by default.

there is no %users either :stuck_out_tongue:

Typo, but you’re already in USERS :slight_smile:

Are you really entirely new to Windows?? How is that possible? lol

OK… I found the DB.

Where are the executables?

:face_with_head_bandage: :brick:

Oh boy! I mean, unless Chuck is gen Z, I cannot imagine him never having to use Windows before…

Executables would be in C:\Program Files\Plex\Plex Media Server

I predate computers. I started with punched tape, punched cards, and then upgraded to Cassette / Mag Tape storage

Think I’m a ‘Boomer’ :rofl:

2 Likes

Nothing wrong with that. I’m one gen away from you :wink:

I have one question. How are you “kids” gonna get along when we old coots are dead? Who’s gonna fix it then? :rofl:

I found the executables, Time to craft some ugliness :smiling_imp:

1 Like

Volts, to answer your question regarding shutdowns, I haven’t had a crash in a long time, so every recent shutdown has been clean, AFAIK.

Datapoints -

Nicely shutting down PMS on macOS or Windows works as expected. The -wal and -shm files are removed.

Rudely shutting down PMS on macOS or Windows also behaves as expected. The -wal and -shm files are not removed.

If you see something else, does running a query using Plex SQLite clean up those files?