Can I delete the -tmp database files?

I’m running out of space on the system disk, and I notice there are a large number of tmp files in this folder:

var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-in Support/Databases

eg
com.plexapp.plugins.library.db-2017-08-07-tmp
com.plexapp.plugins.library.db-2018-03-23-tmp
etc

What’s the impact to deleting all of these with the -tmp suffix to free up space? If it’s safe to do so, can I set PMS to clean these up automatically, or am I looking at a cron job?

I did search but could not find a specific answer, so apologies if this has already been asked before.

Thanks

Asking again…

@nickdspencer said:
Asking again…

Backup, then delete to see if any harm done.

I’d only delete them while Plex server is shut down.
Normally, those should get deleted automatically. So there might be something not right abotu your server.

Ok, thank you. Could you please elaborate on ‘something not right about your server’ - under the Server Settings - Scheduled Tasks, I have everything checked. Is there something else that needs to be configured?

I don’t think this has somethign to do with configuration within Plex. It might be rather something about your particular machine.
But I am not a linux person. Maybe @ChuckPA can shed some light.

Sorry for the delay.

They’re usually ok to delete. Strange that they didn’t get cleaned up during normal processing. Keep an eye on that.

  1. Stop PMS (makes certain the files are closed)
  2. Delete the tmp files . Do not delete the wal or shm files
  3. Start PMS

Just in case anyone else comes across this, in my case it was related to write permissions on the backup directory.

Check the Scheduled Tasks screen in your server config, and look for the Backup directory option. Verify that folder has write permissions for the plex user.

I was using cifs to mount a Windows share, and did not set the user so it was a root mount. This worked for most things, because it was world-readable, but saving to the share was not allowed. I changed the /etc/fstab configuration to add uid and gid for the plex user, and now it’s able to complete the backup task properly and clean out the *-tmp files.

So ive just noticed im in the same boat!

As long as i dont delete the main .DB files can i delete the .TMP and non tmp files? (This is the start of a VERY VERY long list
-rw-r–r-- 1 plex plex 5798912 May 24 12:22 com.plexapp.plugins.library.blobs.db
-rw-r–r-- 1 plex plex 303104 Nov 26 2017 com.plexapp.plugins.library.blobs.db-2017-11-26
-rw-r–r-- 1 plex plex 303104 Nov 29 2017 com.plexapp.plugins.library.blobs.db-2017-11-29
-rw-r–r-- 1 plex plex 303104 Nov 30 2017 com.plexapp.plugins.library.blobs.db-2017-11-30
-rw-r–r-- 1 plex plex 303104 Dec 9 2017 com.plexapp.plugins.library.blobs.db-2017-12-09-tmp
-rw-r–r-- 1 plex plex 303104 Dec 12 2017 com.plexapp.plugins.library.blobs.db-2017-12-12-tmp
-rw-r–r-- 1 plex plex 303104 Dec 15 2017 com.plexapp.plugins.library.blobs.db-2017-12-15-tmp
-rw-r–r-- 1 plex plex 303104 Dec 18 2017 com.plexapp.plugins.library.blobs.db-2017-12-18-tmp
-rw-r–r-- 1 plex plex 303104 Dec 21 2017 com.plexapp.plugins.library.blobs.db-2017-12-21-tmp