Python randomly exits with Linux OS error -9 or -15

Andrew Berg bahamutzero8825 at gmail.com
Mon Apr 9 06:38:48 EDT 2012


On 4/9/2012 5:01 AM, Janis wrote:
> I have this problem with my script exiting randomly with Linux OS
> status code -9 (most often) or -15 (also sometimes, but much more
> rarely). As far as I understand -9 corresponds to Bad file descriptor
> and -15 Block device required.
> 
> 1) Is there a way how I could find out what exactly causes Python
> process to exit?
> 2) What could be the reason of Python exiting with these status code?
> 
> The script is a crawler that crawls several web sites to download web
> pages and extract information. Most often it exits after having run
> for 2 hours and having downloaded ~24 000 files. Some specific web
> sites are more affected than others, i.e., there are other instances
> of the script running in parallel that download more pages and
> complete normally. That could be related to the speed each page is
> returned etc.
Sounds like an issue with either the filesystem (perhaps you ran out of
inodes - entirely possible when running scripts that create tens of
thousands of files) or the disk itself (maybe it's dying).

-- 
CPython 3.2.2 | Windows NT 6.1.7601.17640



More information about the Python-list mailing list