PostProcessing Error 13

Post any problems / bugs / issues that are Mylar-related in here.
Post Reply
asitaka
Posts: 6
Joined: Mon Mar 24, 2014 11:21 pm

PostProcessing Error 13

Post by asitaka »

I just re-installed Mylar since it was having trouble updating and downloading, now the post processing keeps giving me an error message:

Code: Select all

Loading config from /home/asitaka/.sickbeard/autoProcessTV/autoProcessComics.cfg
Opening URL: http://192.168.1.16:8090/post_process?nzb_name=The+Walking+Dead+121+%282014%29+%28Digital%29&nzb_folder=%2Fmediafiles%2Fcomics%2FThe+Walking+Dead+121+%282014%29+%28Digital%29
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"

"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html>

<head>

    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"></meta>

    <title>500 Internal Server Error</title>

    <style type="text/css">

    #powered_by {

        margin-top: 20px;

        border-top: 2px solid black;

        font-style: italic;

    }



    #traceback {

        color: red;

    }

    </style>

</head>

    <body>

        <h2>500 Internal Server Error</h2>

        <p>The server encountered an unexpected condition which prevented it from fulfilling the request.</p>

        <pre id="traceback">Traceback (most recent call last):

  File "/opt/mylar/cherrypy/_cprequest.py", line 645, in respond

    response.body = self.handler()

  File "/opt/mylar/cherrypy/lib/encoding.py", line 188, in __call__

    self.body = self.oldhandler(*args, **kwargs)

  File "/opt/mylar/cherrypy/_cpdispatch.py", line 29, in __call__

    return self.callable(*self.args, **self.kwargs)

  File "/opt/mylar/mylar/webserve.py", line 411, in post_process

    result = PostProcess.Process()

  File "/opt/mylar/mylar/PostProcessor.py", line 440, in Process

    return self.Process_next(comicid,issueid,issuenumOG)

  File "/opt/mylar/mylar/PostProcessor.py", line 738, in Process_next

    os.rename(os.path.join(self.nzb_folder, str(ofilename)), os.path.join(self.nzb_folder,str(nfilename + ext)))

OSError: [Errno 13] Permission denied

</pre>

    <div id="powered_by">

    <span>Powered by <a href="http://www.cherrypy.org">CherryPy 3.2.0</a></span>

    </div>

    </body>

</html>
I went ahead and did a chmod -R 777 on /mediafiles/comics and added the user "mylar" to the group owner of the directory.
This is running on a 'buntu 64 server.
User avatar
evilhero
Site Admin
Posts: 2887
Joined: Sat Apr 20, 2013 3:43 pm
Contact:

Re: PostProcessing Error 13

Post by evilhero »

Well, like you had said in your post, the errno 13 is a permission problem related to the rename command.

Somewhere along the lines, it doesn't have permission to actually rename it (which would be a copy, then a delete file if I'm not mistaken). If you already 'sudo chmod -R 777' and added the user into the group's directory owner then it could be one of two things (that I can think of off the top of my head).

1 - In the Mylar configuration, you have a directory stated for SABnzbd Download directory that is not your given directory (/mediafiles/comics) and it's trying to do something funky (I dont' think that's it, but it's off the top of my head).

2- The permissions are getting changed on the directory once SABnzbd creates the directory to put the download into (ie. /mediafiles/comics/mediafiles/The Walking Dead 121 (2014) (Digital)/). I'm not sure what the setting is by default, but in the SABnzbd config / Folders tab - there's a setting for 'Permission for completed downloads' (I'm going to assume that the Completed Downloads folder just above that setting is set to /mediafiles/comics).

If the user running SAB is different than that of Mylar (but is in the SABnzbd group), then it should be 775 (owner:group:others), otherwise you can try setting it to 777 and seeing if that works just as a test run until you can get the permissions sorted. I'm pretty sure you know that chmod'ing only affects the files/directories that currently exist - not future ones (but hey, I tend to blurb at 3am). If it helps, I have the same user running SAB & Mylar on my Ubuntu 12.04, and my permissions in SABnzbd are set to 755 ;)

Hopefully one of those 2 is the culprit and you can get it going again.
asitaka
Posts: 6
Joined: Mon Mar 24, 2014 11:21 pm

Re: PostProcessing Error 13

Post by asitaka »

Thanks for your response, i had to change sab to 777 to get this to work, I'll have to look into what group sab is in (since I set it up so long ago and forgot about it)

Yes, I know it only applies to current files, but I made sure to do it to make sure the main directory wasn't restricting created files/folders in the directory.

Now, how do I force mylar to rescan the directory and sort the piles of comics that are sitting in /mediafiles/comics into their respective directories?
User avatar
evilhero
Site Admin
Posts: 2887
Joined: Sat Apr 20, 2013 3:43 pm
Contact:

Re: PostProcessing Error 13

Post by evilhero »

Rescanning (or manual post-processing) can be done via the Manage tab / manual post-processing tab. Just set the directory to the root of what you want to scan (/mediafiles/comics) and it will scan all files and subdirectories - only post-processing on series' that match up to your watchlist, otherwise it'll just skip it.

Provided nothing is funnily named, you should be able to import everything with probably no issues. If you do have a problem with some not scanning in, please post the results in here so I can figure out what's happening and fix it so it scans in correctly next time.
Post Reply