Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

limit on open files

Scott_L_
New Contributor I
919 Views

 

I am getting an error (IOMSG from open) that there are too many open files.  The logical unit I am using is 93.

acsyscommand:  open error = too many open files

 

So, what is the limit?  Is there a way to change it?  Any options to diagnose the problem?   I am not sure how many files the application has open (600K lines of code).

intel fortran on Linux

solutions: ifort -V
Intel(R) Fortran Intel(R) 64 Compiler for applications running on Intel(R) 64, Version 16.0.4.258 Build 20160811
Copyright (C) 1985-2016 Intel Corporation.  All rights reserved.

 

Code has been working for years on windows, currently on ifort 17.1, previously on 15.0.

 


 

thanks,

Scott

 

0 Kudos
2 Replies
DavidWhite
Valued Contributor II
919 Views

Scott,

I don't think the unit number is the problem.  Googling on too many open files suggests that there are specific Linux OS issues regarding numbers of open files, and you can find suggestions about how to change this in the OS.

David

0 Kudos
Kevin_D_Intel
Employee
919 Views

There is no limit in Fortran. Some have inquired before here and here. Maybe you are hitting the shell imposed limit. Check the shell limit setting with: ulimit -u

You can change the limit by supplying a new limit value, e.g. ulimit -n 1024

Based on the error shown it seems like the condition was detected and trapped by the app. When exceeding the shell imposed limit, our Fortran RTL produces an error like this:

forrtl: Too many open files
forrtl: severe (603): too many open files

0 Kudos
Reply