# Correct Agent order.

**URL:** <https://forums.plex.tv/t/correct-agent-order/200159>\
**Category:** General Discussions\
**Created:** [July 25, 2017, 10:54am UTC](https://forums.plex.tv/t/correct-agent-order/200159 "2017-07-25T10:54:40Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![\_TheMikey](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/_themikey/32/88159_2.png) [@\_TheMikey](https://forums.plex.tv/u/_TheMikey)\
**Post date:** [July 25, 2017, 10:54am UTC](https://forums.plex.tv/t/correct-agent-order/200159/1 "2017-07-25T10:54:40Z")

</div>

I am trying to set up the agents for movies and series, so it will use TheTVDB for info, and still get subtitles from the local file too.

In Programmes \> TheTVDB I got “Local Media Assets (TV)” on top, then “TheTVDB”, with both options inside checked, just below. But with this it isn’t finding the show on TheTVDB, but I am getting subtitles from the local file. If I change TheTVDB to be on top, it finds the info, but then the subtitles from the local file is gone.

---

<div class="post-metadata">

**Author:** ![NewPlaza](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/newplaza/32/128634_2.png) [@NewPlaza](https://forums.plex.tv/u/NewPlaza)\
**Post date:** [July 25, 2017, 10:59am UTC](https://forums.plex.tv/t/correct-agent-order/200159/2 "2017-07-25T10:59:54Z")

</div>

Okay.  
What is the exact folder/name you are using?  
example

```
/TV Shows
   /Grey's Anatomy
      /Season 01
         Grey's Anatomy - s01e01.avi
         Grey's Anatomy - s01e02 - The First Cut is the Deepest.avi
         Grey's Anatomy - s01e03.mp4
      /Season 02
         Grey's Anatomy - s02e01.avi
         Grey's Anatomy - s02e02.mkv
         Grey's Anatomy - s02e03.m4v
```

---

<div class="post-metadata">

**Author:** ![\_TheMikey](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/_themikey/32/88159_2.png) [@\_TheMikey](https://forums.plex.tv/u/_TheMikey)\
**Post date:** [July 25, 2017, 11:06am UTC](https://forums.plex.tv/t/correct-agent-order/200159/3 "2017-07-25T11:06:36Z")

</div>

The naming isn’t the problem. It finds them correctly, but the problem is either it finds the local subtitles, or the online info if I change them around. The problem is I cant get it to find the online info, and the local subtitles.

But, naming I use is like this /Series/Title/Title.E01S01.mkv and both plex and Kodi is parsing it correct, but the problem again, is what I am doing wrong with the agent setup. When it finds the subtitles, but not online info. I can go in and press Match on the series, then select TheTVDB, and it finds it without problems, and I can select it. But I would like to just have it find it all by itself, so I don’t have to manually tell it to get the metadata from TheTVDB.

---

<div class="post-metadata">

**Author:** ![JuiceWSA](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/juicewsa/32/12253_2.png) [@JuiceWSA](https://forums.plex.tv/u/JuiceWSA)\
**Post date:** [July 25, 2017, 1:49pm UTC](https://forums.plex.tv/t/correct-agent-order/200159/4 "2017-07-25T13:49:34Z")

</div>

If your naming isn’t EXACTLY as shown - it’s a problem. Believe it.

If you’re using MP4/M4V files move Local Media Assets to the bottom of every Agent list under all tabs in Shows and Movies.

Then:

The Plex Dance®:

1. remove show/movie from library
2. update library
3. empty trash
4. clean bundles  
[https://support.plex.tv/hc/en-us/articles/200392106-Library-Actions](https://support.plex.tv/hc/en-us/articles/200392106-Library-Actions) \<— update library, empty trash, clean bundles
5. bring names and structures into compliance/ or the ultimate bundle reboot operation
6. replace corrected show/movie into library
7. update library

_ **All Steps. In Order. No Shortcuts.** _

[https://support.plex.tv/hc/en-us/categories/200028098-Media-Preparation](https://support.plex.tv/hc/en-us/categories/200028098-Media-Preparation)  
[https://support.plex.tv/hc/en-us/articles/200220687-Naming-Series-Season-Based-TV-Shows](https://support.plex.tv/hc/en-us/articles/200220687-Naming-Series-Season-Based-TV-Shows)  
[https://support.plex.tv/hc/en-us/articles/200381023-Naming-Movie-files](https://support.plex.tv/hc/en-us/articles/200381023-Naming-Movie-files)

As far as the Agents - Under every tab that named Agent should be at the top of the list. The alternate Agent should be under it. Local Media Assets should be at the bottom of the lists - unless for some strange reason you need it at the top, but most users do not.

If you do all of the above and are still having problems:  
[https://support.plex.tv/hc/en-us/articles/200250417-Plex-Media-Server-Log-Files](https://support.plex.tv/hc/en-us/articles/200250417-Plex-Media-Server-Log-Files)  
Drag zip file to message window and drop it.

---

<div class="post-metadata">

**Author:** ![OttoKerner](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/ottokerner/32/10079_2.png) [@OttoKerner](https://forums.plex.tv/u/OttoKerner)\
**Post date:** [July 25, 2017, 2:19pm UTC](https://forums.plex.tv/t/correct-agent-order/200159/5 "2017-07-25T14:19:33Z")

</div>

Please do this:  
Settings - Server - Agents - Shows - TheTVDB  
drag the line ‘Local Media Assets’ line downwards (but do **not** clear its checkbox!)

Then make a screenshot of the settings under  
Settings - Server - Agents - Shows - TheTVDB

Post the _actual_ file names **and** the folder layout of this series

Performe a ‘Fix Match’ procedure of the series during which you choose TheTVDB as the ‘agent’

After a few minutes, copy the contents of the [Plex XML info](https://support.plex.tv/hc/en-us/articles/201998867-Investigate-Media-Information-and-Formats "Plex XML info") of an **episode**  
and post them here

---

<div class="post-metadata">

**Author:** ![NewPlaza](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/newplaza/32/128634_2.png) [@NewPlaza](https://forums.plex.tv/u/NewPlaza)\
**Post date:** [July 25, 2017, 8:24pm UTC](https://forums.plex.tv/t/correct-agent-order/200159/6 "2017-07-25T20:24:24Z")

</div>

> @_TheMikey_ said:  
> The naming isn’t the problem. But, naming I use is like this /Series/Title/Title.E01S01.mkv

That is not correct naming for Plex. It _may_ work but you are asking for a world of hurt.  
If anything, it should be /Series/Title/SeasonXX/Title.E01S01.mkv. And the ROOT of your library points to /Series

---

<div class="post-metadata">

**Author:** ![\_TheMikey](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/_themikey/32/88159_2.png) [@\_TheMikey](https://forums.plex.tv/u/_TheMikey)\
**Post date:** [July 26, 2017, 2:07pm UTC](https://forums.plex.tv/t/correct-agent-order/200159/7 "2017-07-26T14:07:11Z")

</div>

Moving local media down, and The Plex Dance combined solved the problem.

---

<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:34pm UTC](https://forums.plex.tv/t/correct-agent-order/200159/8 "2020-01-07T23:34:25Z")

</div>


