Linux Error

Heya,

First of all, great that you got it to start and run on Linux. Most things seems to work.
Right now I only have one issue:
When I try to import the TV-series I already have on my drive, I get the following errors:

Lower right corner:
[POST] Internal Server Error : /api/rootfolder

Log:
NzbDroneErrorPipeline Request Failed: Recent directory already exist. 12:45 AM

NzbDrone.txt:

System.InvalidOperationException: Recent directory already exist.
  at NzbDrone.Core.RootFolders.RootFolderService.Add (NzbDrone.Core.RootFolders.RootFolder rootFolder) [0x00000] in <filename unknown>:0 
  at NzbDrone.Api.NzbDroneRestModule`1[NzbDrone.Api.RootFolders.RootFolderResource].ToResource[RootFolder] (System.Func`2 function, NzbDrone.Api.RootFolders.RootFolderResource resource) [0x00000] in <filename unknown>:0 
  at NzbDrone.Api.RootFolders.RootFolderModule.CreateRootFolder (NzbDrone.Api.RootFolders.RootFolderResource rootFolderResource) [0x00000] in <filename unknown>:0 
  at NzbDrone.Api.REST.RestModule`1[NzbDrone.Api.RootFolders.RootFolderResource].<set_CreateResource>b__f (System.Object options) [0x00000] in <filename unknown>:0 
  at Nancy.Routing.Route.Invoke (Nancy.DynamicDictionary parameters) [0x00000] in <filename unknown>:0 
  at Nancy.Routing.DefaultRouteInvoker.Invoke (Nancy.Routing.Route route, Nancy.DynamicDictionary parameters, Nancy.NancyContext context) [0x00000] in <filename unknown>:0 
  at Nancy.Routing.DefaultRequestDispatcher.Dispatch (Nancy.NancyContext context) [0x00000] in <filename unknown>:0

Hoping you guys can have a look at this. Great work so far in any case!

Off topic:

  1. Am I supposed to post bug reports somewhere else?
    2. Is there any way to add formating (such as code blocks) to these forums? Nvm, found it! Markdown!

Were you able to add any folders?
What version on linux are you running on?

Off-Topic
Forums are great, easier to converse than our Trello board, we can always add it there later.

Nope, this actually happens as soon as I press “add series”, and then repeat each time I try to add a folder, or add a series for that matter.

Possibly worth noting is that it seems to be able to “read” the folders - the autocomplete part works just fine.

Running Ubuntu 12.04 Server. NzbDrone is run as normal user, not as root, and is installed under my home directory.
Can’t remember which version of Mono i’m running, but it’s the latest one in the Ubuntu 12.04 repos.

Sorry to be a pain and bumping, but just wanted to see if you found any issues here. Can’t see anything regarding this on Trello, so just need to know if this is a NzbDrone issue, or if it is only at my end :slight_smile:

@nosscire was away for a few days and didn’t have time to look into this, Should be able to take a look later today.

Hi,

Update on this.
As the idiot I am, I never actually tried adding different folders then the correct ones. This only occur when I try to enter the directory to my external drives (where all the media is saved).

I did manage to get arount this issue by simply making a symlink and then entering that instead of the real directory.

Don’t know if this is because of some issues with mounted drives, or if it’s an issue specifically with NTFS drives (which is what I use for all my external storage). Niether really makes sense as the symlink works. I mean, it can read and write to the drives, just not through the directory /mnt/Filedrive1 etc

Also, it still throws some of the exact same errors at me, but everything seems to actually work.

Well, despite being less than awesome news, this is great. Neither of us were able to repro this when adding a folder, but we never had another drive either (just a VM with a single drive).

We’ll give this another go with a similar virtualized setup.

Heya,

Did another test by mounting a SMB share, and got the same issues. If I try to add a folder on the mounted SMB share it won’t work, if I symlink it it does - so doesn’t seem to be niether about the drive nor filesystem.
I can also say for sure it is not related to permissions, as I decided to give this share 777 permissions on everything, as well as run NzbDrone as both root and normal user.

And yet another update, which confuses me even more then previously.

When I tried adding old series at /mnt/Filedrive/TV I got the result above
When I instead made a symlink from /home/simon/Fildrive to /mnt/Filedrive, I could then successfully scan in my old series at /home/simon/Filedrive/TV.

Now, when I try to add a new series to /home/simon/Filedrive/TV the result is the same as in the original post BUT
if I try to add a new series to /home/simon/Filedrive/(any other existing folder), or for that matter any other folder at all (apart from anything on a mounted drive in /mnt/(whatever)) everything works.

For some reason it seems that if I try to add a new series - or for that matter search in the same folder for old series - I get the same result as in the original post, but if I try it with ANY other folder it works.

Oh, just thought one more thing - if you need some more info from me, and want it in slightly more real time then these forums, I would have no problem with giving you my skype/gchat details, just send me a PM if that would help you fix these issues :slight_smile:

I’m getting a bit confused here, are you able to add a “Recent Folder”? Things just fail on add series?

You only need to add a recent folder once, the error happens when it sees another in the DB. For example, my one and only recent folder is T:\\ (Windows obviously).

You get similar (though different errors) in the event you try to add a recent folder that falls under these areas:

  • Same as Drone Factory folder
  • Folder doesn’t exist on disk (or NzbDrone doesn’t have permissions to access it)

I understand that you are getting confused, because so am I :slight_smile:

First I tried adding /mnt/Filedrive/TV to import existing folders. That did not work. Gave the error in first post.
Then I made a symlink and added /home/simon/Filedrive/TV instead which did work.

Today, I tried adding a new series, Newsroom. At this point I don’t have any path to select, I can only choose between “Select Path” and “Add different path” in the dropdown. From my understanding and what I remember from running on Windows, I should already have a path to select here, right? From importing previous series? I don’t however.

I then selected “Add different path” and tried adding /home/simon/Filedrive/TV, but that did not work, I get the following error:

[Fatal] NzbDroneErrorPipeline: Request Failed

System.InvalidOperationException: Recent directory already exists.
  at NzbDrone.Core.RootFolders.RootFolderService.Add (NzbDrone.Core.RootFolders.RootFolder rootFolder) [0x00000] in <filename unknown>:0
  at NzbDrone.Api.NzbDroneRestModule`1[NzbDrone.Api.RootFolders.RootFolderResource].ToResource[RootFolder] (System.Func`2 function, NzbDrone.Api.RootFolders.RootFolderResource resource) [0x00000] in <filename unknown>:0
  at NzbDrone.Api.RootFolders.RootFolderModule.CreateRootFolder (NzbDrone.Api.RootFolders.RootFolderResource rootFolderResource) [0x00000] in <filename unknown>:0
  at NzbDrone.Api.REST.RestModule`1[NzbDrone.Api.RootFolders.RootFolderResource].<set_CreateResource>b__f (System.Object options) [0x00000] in <filename unknown>:0
  at Nancy.Routing.Route.Invoke (Nancy.DynamicDictionary parameters) [0x00000] in <filename unknown>:0
  at Nancy.Routing.DefaultRouteInvoker.Invoke (Nancy.Routing.Route route, Nancy.DynamicDictionary parameters, Nancy.NancyContext context) [0x00000] in <filename unknown>:0
  at Nancy.Routing.DefaultRequestDispatcher.Dispatch (Nancy.NancyContext context) [0x00000] in <filename unknown>:0

Then I try to do it again, but this time I choose /home/simon/Filedrive/muppettest as the folder, and now it all works just fine.

Worth noting is that as soon as I press the “add series” button, I get the following error:

[Fatal] NzbDroneErrorPipeline: Request Failed

System.InvalidOperationException: Operation is not valid due to the current state of the object
  at System.Linq.Enumerable.Single[DriveInfo] (IEnumerable`1 source, System.Func`2 predicate, Fallback fallback) [0x00000] in <filename unknown>:0
  at System.Linq.Enumerable.SingleOrDefault[DriveInfo] (IEnumerable`1 source, System.Func`2 predicate) [0x00000] in <filename unknown>:0
  at NzbDrone.Common.DiskProvider.GetAvilableSpace (System.String path) [0x00000] in <filename unknown>:0
  at NzbDrone.Core.RootFolders.RootFolderService.<AllWithUnmappedFolders>b__0 (NzbDrone.Core.RootFolders.RootFolder folder) [0x00000] in <filename unknown>:0
  at System.Collections.Generic.List`1[NzbDrone.Core.RootFolders.RootFolder].ForEach (System.Action`1 action) [0x00000] in <filename unknown>:0
  at NzbDrone.Core.RootFolders.RootFolderService.AllWithUnmappedFolders () [0x00000] in <filename unknown>:0
  at NzbDrone.Api.NzbDroneRestModule`1[NzbDrone.Api.RootFolders.RootFolderResource].ToListResource[RootFolder] (System.Func`1 function) [0x00000] in <filename unknown>:0
  at NzbDrone.Api.RootFolders.RootFolderModule.GetRootFolders () [0x00000] in <filename unknown>:0
  at NzbDrone.Api.REST.RestModule`1[NzbDrone.Api.RootFolders.RootFolderResource].<set_GetResourceAll>b__c (System.Object options) [0x00000] in <filename unknown>:0
  at Nancy.Routing.Route.Invoke (Nancy.DynamicDictionary parameters) [0x00000] in <filename unknown>:0
  at Nancy.Routing.DefaultRouteInvoker.Invoke (Nancy.Routing.Route route, Nancy.DynamicDictionary parameters, Nancy.NancyContext context) [0x00000] in <filename unknown>:0
  at Nancy.Routing.DefaultRequestDispatcher.Dispatch (Nancy.NancyContext context) [0x00000] in <filename unknown>:0

But everything still seems to work

I hope this makes any kind of sense to you :slight_smile:

Are the requests still coming back from the server? Check in Firefox or Chrome Dev tools.

Also take a look at the DB, specifically the RootFolders table, the paths you already added should be there (and you can’t add them again).

You can’t add a new series without selecting a folder for it to live in.

Heya,

This would appear to be the problem. Yes, I do get requests back from the server.

I checked the database, and the rootfolder paths were all there. It would seem that the issue is that the root folder is not read into the program, thereby not showing up, while at the same time, as you say, I can not add it again.

Edit: hold a bit on this, I made a completely clean install of the latest version of NzbDrone now, and it seems to be working

Awesome, keep us posted.