Informix Error -8010: The file filename could not be opened. The operating system was asked to open it for writing. It is possible that a file by the same name already exists, but the user has no permission to write over it, or, if -o is used, the destination directory does not exist.
Cause and resolution
The file filename could not be opened. The operating system was asked to open it for writing. It is possible that a file by the same name already exists, but the user has no permission to write over it, or, if -o is used, the destination directory does not exist.
Ensure that filename is spelled correctly and that your account name has write access to the directory where it will be stored. (That directory might be the one that the environment variable DBTEMP names.) If a file of that name already exists, either erase it or make sure that your account has write access to it.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-8010 fires when the ACE compiler can't open a named file for writing — per the official guidance.
- A file of that name already exists, and the account lacks write permission over it, per the official guidance — the first named cause.
- The destination directory (when
-ois used) doesn't exist, per the official guidance — the second named cause.
Solutions / Resolution
- Ensure the filename is spelled correctly and the account has write access to the
destination directory, per the official guidance — possibly the directory named by the
DBTEMPenvironment variable. - If a file of that name already exists, erase it or make sure the account has write access to it, per the official guidance.
Examples
Checking DBTEMP and write access
$ echo $DBTEMP
$ ls -ld $DBTEMP
Diagnostic Checks
- Check the filename's spelling, write permission on the destination directory (possibly
DBTEMP), and whether a conflicting file already exists there.
Related Errors / Related Topics
- -8008 — "The file filename could not be opened. The operating system was asked to open it for reading." The equivalent failure, for opening a file to read rather than write.
A file couldn't be opened for writing — check the destination directory's existence and write permission, and any existing file of the same name.