It’s not necessarily a common issue but it can happen under certain circumstances. The most frequent one will be a setup where 3 conditions come together:
- your server is configured to do automatic or periodic scans (
Settings>[Server Name]>Library>Scan my library automaticallyorScan my library periodically) - your server is configured to automatically empty its trash after every scan (
Settings>[Server Name]>Library>Empty trash automatically after every scan) - the drive/share with your media is occasionally not connected or takes too long to spin up when a scan happens
In such a situation Plex will update your library, clean out the “missing” media and re-catalog it during a subsequent scan (when the drives are back or spinning up fast enough). In consequence, the metadata and association to manually created collections will be deleted as well.
The basic failsafe for such a hiccup is to disable the Empty trash automatically after every scan – this way, even if a scan happens and Plex doesn’t find the media, it won’t delete the library entries. At worst they will show with an indicator that states the underlying files are not available (until you e.g. made sure the drives/shares are connected and accessible to your Plex Media Server).
With regards to your lost metadata there’s 2 considerations:
- Plex is creating regular backups of its database as part of some internal maintenance. You might be able to restore an older version/situation of your server by restoring the database from such a backup – this will require some technical tinkering though
https://support.plex.tv/articles/202485658-restore-a-database-backed-up-via-scheduled-tasks/ - If your Mac has Time Machine enabled you might be able to restore the database files from there (while the PMS is stopped!!)
While a Time Machine restore might be easier to handle, it can also restore your database in a state right from when something else was changing/updating which can result in more corruption. Therefore… if you want to go that way, I recommend to go with #1.