• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 13560
  • Last Modified:

ORACLE ERROR ORA-09817 and ORA-09945

Hi, I am having a problem:

ORA-09817: Write to audit file failed.
Linux Error: 28: No space left on device
ORA-09945: Unable to initialize the audit trail file
Linux Error: 28: No space left on device

It's apparent that the filesystem is full.  df shows that there is no space left.
what I would like to know is how to move the tablespace to another filesystem temporarily to clean up the filesystem
because I couldn't connect / as sysdba anymore

1 Solution
Which Oracle version are you using?

In 9i,try connecting as sys:

sqlplus /nolog
connect sys/change_on_install@<sid> as sysdba

where change_on_install is the default password..
markchih, you have to move other files that are not Oracle files to a new location to release the space to solve the problem. Or you can delete/move the old archived log files if possible.

For your information Oracle always generate an audit (.aud) file when you connect INTERNAL, regardless of whether auditing has been turned on in the database and this is a security feature and expected behavior. So if the systemfile is full you will get trouble when trying to connect

Hope this helps
!!! For first make full backup copy of your db !!!

If you lost password use orapwd to recreate password file. replace old, restart db.
Connect to oracle using new password as sysdba or internal.

Database is in ARCHIVELOG mode:

1. Take the datafile offline with the "ALTER DATABASE DATAFILE '/old/location'  OFFLINE;" command.
2. Copy or move the datafile to its new location. On Unix this can be
   done with the "dd" command. Example:
      dd if=/old/location of=/new/location bs=4096
3. SVRMGR> ALTER DATABASE RENAME FILE '/old/location' TO '/new/location';
4. SVRMGR> RECOVER DATAFILE '/new/location';

Database is in NOARCHIVELOG mode:

1. Shutdown the database
2. Copy or move the datafile to its new location. On Unix this can be
   done with the "dd" command. Example:
      dd if=/old/location of=/new/location bs=4096
3. Start Server Manager and do a "STARTUP MOUNT"
4. ALTER DATABASE RENAME FILE '/old/location' TO '/new/location';

then delete old file.
What a using in your DB you can see
select df.name "Path", ts.name "TableSpace name"
    from v_$datafile df, ts$ ts
    where ts.ts# = df.file#

Best regards
Your audit file destination is full.

"show parameter aud" will tell you where audit_file_dest is.

Using your operating sysdtem commands, delete most (or all) of your.aud files.
Or you can compress them into a zip or tar file.
Alternately add space if you don't want to do either of the above.

The first message (from catchmeifuwant) gives you instructions that should let you login to the database if your problem had been a full archive log destination.  Try logging in as a non-sysdba user as that won't require a .aud file.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Get 10% Off Your First Squarespace Website

Ready to showcase your work, publish content or promote your business online? With Squarespace’s award-winning templates and 24/7 customer service, getting started is simple. Head to Squarespace.com and use offer code ‘EXPERTS’ to get 10% off your first purchase.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now