# Plex media server hangs during library update

**URL:** <https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193>\
**Category:** General Discussions\
**Created:** [September 6, 2017, 1:48pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193 "2017-09-06T13:48:19Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![dwinarsky](https://avatars.discourse-cdn.com/v4/letter/d/f17d59/32.png) [@dwinarsky](https://forums.plex.tv/u/dwinarsky)\
**Post date:** [September 6, 2017, 1:48pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/1 "2017-09-06T13:48:19Z")

</div>

Hi,

Starting a few weeks ago, my Plex Media Server will hang while updating the library. The hang is so bad that the machine will not even reboot and I need to hardware reboot it. When I look at the status of the library update from the Status Bar menu it says “Loading metadata…” for an individual release, however it’s a different release each time. Can anyone help with this issue?

David

---

<div class="post-metadata">

**Author:** ![dwinarsky](https://avatars.discourse-cdn.com/v4/letter/d/f17d59/32.png) [@dwinarsky](https://forums.plex.tv/u/dwinarsky)\
**Post date:** [September 6, 2017, 1:59pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/2 "2017-09-06T13:59:24Z")

</div>

Attached my server logs (I needed to restart the server just now).

---

<div class="post-metadata">

**Author:** ![dwinarsky](https://avatars.discourse-cdn.com/v4/letter/d/f17d59/32.png) [@dwinarsky](https://forums.plex.tv/u/dwinarsky)\
**Post date:** [September 7, 2017, 7:59pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/3 "2017-09-07T19:59:56Z")

</div>

Wondering if anyone on the Plex team is able to help?

---

<div class="post-metadata">

**Author:** ![nokdim](https://avatars.discourse-cdn.com/v4/letter/n/7ab992/32.png) [@nokdim](https://forums.plex.tv/u/nokdim)\
**Post date:** [September 7, 2017, 8:16pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/4 "2017-09-07T20:16:42Z")

</div>

Have you tried to optimize your db?

![](https://global.discourse-cdn.com/plex/original/3X/6/d/6d6d96c873e29c50038c96c2600c8cd688a195b6.png)

---

<div class="post-metadata">

**Author:** ![dwinarsky](https://avatars.discourse-cdn.com/v4/letter/d/f17d59/32.png) [@dwinarsky](https://forums.plex.tv/u/dwinarsky)\
**Post date:** [September 7, 2017, 8:19pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/5 "2017-09-07T20:19:39Z")

</div>

No, I haven’t tried that, but I did delete my entire database and start Plex from scratch (re-add media to Library etc) and the same issue is reoccurring.

---

<div class="post-metadata">

**Author:** ![nokdim](https://avatars.discourse-cdn.com/v4/letter/n/7ab992/32.png) [@nokdim](https://forums.plex.tv/u/nokdim)\
**Post date:** [September 7, 2017, 8:25pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/6 "2017-09-07T20:25:18Z")

</div>

Sounds like you can dump your library and add it back easily…

can you delete again and add a few items and see if its still crashing on library update?

---

<div class="post-metadata">

**Author:** ![sa2000](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/sa2000/32/6922_2.png) [@sa2000](https://forums.plex.tv/u/sa2000)\
**Post date:** [September 7, 2017, 9:58pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/7 "2017-09-07T21:58:06Z")

</div>

> @dwinarsky said:  
> Attached my [server logs](https://support.plex.tv/articles/200250417-plex-media-server-log-files/) (I needed to restart the server just now).

First i would advise to tidy up how you setup your libraries and follow the guidelines outlined on these support pages [https://support.plex.tv/hc/en-us/categories/200028098-Media-Preparation](https://support.plex.tv/hc/en-us/categories/200028098-Media-Preparation)

You should not be merging all your different media types into one library path  
You have a `Movies` library which is defined with a path that is at the higher level `/shares/data`  
This is wrong thing to do. The paths should be at the directory level for directories that contain movies

```auto
Sep 05, 2017 19:13:19.270 [0x7fffa1aa73c0] DEBUG - Scanning Movies using en(Plex Movie Scanner) with 219 current media items and 1 section locations in the database...

Sep 05, 2017 19:13:19.365 [0x7fffa1aa73c0] DEBUG - * Scanning /shares/data

Sep 05, 2017 19:13:19.371 [0x7fffa1aa73c0] DEBUG - Adding subdirectory for scanner: /shares/data/Home Movies
Sep 05, 2017 19:13:19.372 [0x7fffa1aa73c0] DEBUG - Adding subdirectory for scanner: /shares/data/Movies
Sep 05, 2017 19:13:19.373 [0x7fffa1aa73c0] DEBUG - Adding subdirectory for scanner: /shares/data/TV Shows
Sep 05, 2017 19:13:19.374 [0x7fffa1aa73c0] DEBUG - Adding subdirectory for scanner: /shares/data/nzbs
Sep 05, 2017 19:13:19.375 [0x7fffa1aa73c0] DEBUG - Adding subdirectory for scanner: /shares/data/tmp
Sep 05, 2017 19:13:19.377 [0x7fffa1aa73c0] DEBUG - Adding subdirectory for scanner: /shares/data/Kids TV Shows
Sep 05, 2017 19:13:19.378 [0x7fffa1aa73c0] DEBUG - Adding subdirectory for scanner: /shares/data/Kids Movies

```

You are scanning `nzbs` whatever that is. and `tmp`

So for the `Movies` library, you should set the library path to be `/shares/data/Movies`

I see you already have `/shares/data/TV Shows` in a separate `TV Shows` library and you already have `Kids TV Shows` library for `/shares/data/Kids TV Shows`

and you already `Kids Movies` as a library for `/shares/data/Kids Movies`

so just need to correct the `Movies` library folder to change from `/shares/data` to /shares/data/Movies`

Once you have the paths right then we can review if you still have problems (with fresh logs)

---

<div class="post-metadata">

**Author:** ![dwinarsky](https://avatars.discourse-cdn.com/v4/letter/d/f17d59/32.png) [@dwinarsky](https://forums.plex.tv/u/dwinarsky)\
**Post date:** [September 8, 2017, 1:55pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/8 "2017-09-08T13:55:00Z")

</div>

Thank you for the suggestions, I’ve made all of the changes above and I’ll wait a couple days to see if the hang occurs again (usually it’s once every few days).

---

<div class="post-metadata">

**Author:** ![dwinarsky](https://avatars.discourse-cdn.com/v4/letter/d/f17d59/32.png) [@dwinarsky](https://forums.plex.tv/u/dwinarsky)\
**Post date:** [September 13, 2017, 7:44pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/9 "2017-09-13T19:44:42Z")

</div>

I made all of the above changes and suggestions, however my server is now locked up again. The status shows it is hung scanning the “TV Shows” library. It has been hung in this behavior for a long time now and is not picking up any additional library updates.

I’ve attached a new set of logs with the server in this state.

---

<div class="post-metadata">

**Author:** ![sa2000](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/sa2000/32/6922_2.png) [@sa2000](https://forums.plex.tv/u/sa2000)\
**Post date:** [September 14, 2017, 2:19pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/10 "2017-09-14T14:19:29Z")

</div>

Thanks i am looking at the logs. They show the last scan of the `TV Shows` library being on 10th September at 20:56 but subsequent updates to the library did not generate a new scan because it thought a refresh was done recently - possibly caused by some individual show refresh. I need to look into in more detail

---

<div class="post-metadata">

**Author:** ![dwinarsky](https://avatars.discourse-cdn.com/v4/letter/d/f17d59/32.png) [@dwinarsky](https://forums.plex.tv/u/dwinarsky)\
**Post date:** [September 14, 2017, 2:26pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/11 "2017-09-14T14:26:15Z")

</div>

Thanks for investigating. When I looked at the status on the server, it was stuck in “updating library”. From the menu bar/ status bar it showed “updating library” forever and then from within the Plex web app, the refresh circle was spinning constantly next to “TV Shows”. I tried to trigger a library update manually through both interfaces and nothing happened.

---

<div class="post-metadata">

**Author:** ![sa2000](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/sa2000/32/6922_2.png) [@sa2000](https://forums.plex.tv/u/sa2000)\
**Post date:** [September 14, 2017, 3:01pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/12 "2017-09-14T15:01:12Z")

</div>

Unfortunately the Plex Media Server log files do not go back to the time the last library scan was run - 10th 20:56

May be if reproducible to reboot and when it gets stuck to take the logs and screenshot showing time and to capture before firing any futher updates

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/plex/original/3X/2/a/2acb9765406f63293d357b4ec509ec39aa28f2ad.png) [@system](https://forums.plex.tv/u/system)\
**Post date:** [January 7, 2020, 11:47pm UTC](https://forums.plex.tv/t/plex-media-server-hangs-during-library-update/205193/13 "2020-01-07T23:47:04Z")

</div>


