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

FOR$IOS_NO_SUCDEV and FOR$IOS_FILNAMSPE

Ilie__Daniel
Beginner
630 Views

Hello All,

Could you possibly tell me when I would get the following errors while calling an OPEN statement?

 

42

severe (42): No such device

FOR$IOS_NO_SUCDEV. A pathname included an invalid or unknown device name when an OPEN operation was attempted.

43

severe (43): File name specification error

FOR$IOS_FILNAMSPE. A pathname or file name given to an OPEN or INQUIRE statement was not acceptable to the Intel® Fortran RTL I/O system.

 

Thank you for your help.

Daniel.

0 Kudos
6 Replies
Kevin_D_Intel
Employee
630 Views

I've inquired w/Development.

0 Kudos
Steve_Lionel
Honored Contributor III
630 Views

You have a file specification not acceptable to Windows (The Fortran I/O system really doesn't care.) How about you show us what filespec you're passing to OPEN, and perhaps also print it with Z format so we can see if there are invalid characters within.

0 Kudos
Ilie__Daniel
Beginner
630 Views

Steve,

Unfortunately, the file that caused this issue was deleted by a different process.

We have tried many times to recreate the issue, but we have been unlucky so far.

If I manage to reproduce it, I will let you know.

Daniel.

 

0 Kudos
Steve_Lionel
Honored Contributor III
630 Views

The issue pertains to the string passed as FILE= in the OPEN, not the actual file. I suggest adding some logging output when the OPEN fails.

0 Kudos
Kevin_D_Intel
Employee
630 Views

Development offered:

Try to open some incorrect device. e.g. “/dev/log”

$ cat f.f90
    open(1, file='/dev/log')
    end
 
$ ifort f.f90 && ./a.out                                                                                    
forrtl: No such device or address
forrtl: severe (42): no such device, unit 1, file /dev/log

This specify that file name is incorrect. Example is filename of zero length:

$cat f.f90
    open(1, file="")
    end

$ ifort f.f90 && ./a.out
forrtl: severe (43): file name specification error, unit 1, file "Unknown"

0 Kudos
Ilie__Daniel
Beginner
630 Views

Steve and Kevin - Thank you.

I have already added logging if this happens again.

0 Kudos
Reply