ORA-20006: ORA-20100: File l0005120.tmp creation for FND_FILE failed   2 comments

BEGIN
*
ERROR at line 1:
ORA-20006: ORA-20100: File l0005230.tmp creation for FND_FILE failed.
You will find more information on the cause of the error in request log.
ORA-06512: at “APPS.OUR_CUSTOM_CODE”, line 949
ORA-06512: at line 2

This is due to wrong configuration of environment variable APPLPTMP. To which ever location APPLPTMP is pointing the same location should there in UTL_FILE_DIR on the database side.

We have hit this error before and usually its the utl_file_dir database parameter.  I have a script which writes to our utl file directories.

This script help to write to a file, then try and read from it.

set serveroutput on

DECLARE 
  file_location VARCHAR2(256) := '/ordev/applcf/tmp'; 
  file_name VARCHAR2(256) := 'utlfile1.lst'; 
  file_text VARCHAR2(256) := 'THIS IS A TEST'; 
  file_id UTL_FILE.file_type; 
BEGIN 
  file_id := UTL_FILE.fopen(file_Location, file_name, 'W'); 
  UTL_FILE.put_line(file_id, file_text); 
  UTL_FILE.fclose(file_id); 
EXCEPTION 
  WHEN UTL_FILE.INVALID_PATH 
  THEN dbms_output.put_line('Invalid path ' || SQLERRM); 
    WHEN OTHERS 
  THEN dbms_output.put_line('Others '|| SQLCODE || ' ' || SQLERRM); 
END; 
/

The next common resolution was to check the location to which the APPLPTMP environment variable points. We have multiple environments on our test, dev,stage servers and its not uncommon for one environment to own a tmp file, thus blocking another environment from writing to it. In this case, the file l0005120.tmp existed and was owned by the proper user but was zero size.

-rw-r–r– 1 orastg dba 0 Aug 29 10:06 l0005120.tmp

SQL> exec FND_FILE.PUT_LINE(FND_FILE.LOG, ‘THIS IS A TEST’);

If everything is setup correctly, this will write to a file in the directory pointed to by APPLPTMP. Don’t go to this directory looking for a file named FND_FILE.LOG. You won’t find it. The data, “THIS IS A TEST”, will be written to a temp file. So look at tmp files created around the time you executed that command.

$cat l0006120.tmp
THIS IS A TEST

The following steps provide general setup verifications for the temporary directory and also specific steps:

1. Verify the temporary directory setup

a) Check the UTL_FILE_DIR settings of your system:

SELECT value FROM  v$parameter WHERE name = ‘utl_file_dir’;

The first directory path defined in this parameter should be the temporary directory e.g. /usr/tmp

b) Ensure this directory physically exists and is not full

c) Verify that this directory has write permissions for the application user (applmgr) – change directory file permission to 777

e.g. chmod 777 /usr/tmp

d) Check the APPLPTMP variable value is the same as the  first directory path defined in UTL_FILE_DIR

e.g. echo $APPLPTMP
If the above steps do not resolve the issue…

Perform the following additional steps:

1. Stop all services. This is to make sure that no user is logged on and making use of $APPLPTMP directory.
2. Remove all files from directory pointed to by $APPLPTMP
3. Start all services

Advertisements

Posted October 8, 2013 by balaoracledba.com in 11i/R12, Issues, OracleAppsR12

2 responses to “ORA-20006: ORA-20100: File l0005120.tmp creation for FND_FILE failed

Subscribe to comments with RSS.

  1. Pingback: How To Fix Error Code 20100 Errors - Windows Vista, Windows 7 & 8

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: