3 Replies Latest reply on Oct 17, 2012 1:39 PM by Linda Lee-Oracle

    Changing the Naming convention of Log Files


      Is there a way to change the naming convention of log files. Instead of
      00000000.jdb, 00000001.jdb, ... to
      DB000000.jdb, DB000001.jdb etc

      Thanks in advance.
        • 1. Re: Changing the Naming convention of Log Files
          No, there isn't a way to do that. We didn't anticipate a need to do that -- could you please explain the need?

          Putting a prefix on the file name would unnecessarily limit the total size of the data set, if file names are limited to the 8.dot.3 format as you've shown.

          1 person found this helpful
          • 2. Re: Changing the Naming convention of Log Files
            Hi mark,

            Example of what I need is that I will put the records of cats, records of dogs and records of birds in one environment. If I want to remove all the records of dogs, I will just delete the log files for dogs if there is a naming convention in the log files. I thought of using a subdirectory in case the log files cant be rename but my problem is that, if I want to search for a certain record, I will search in the 3 directories. Can you give me some solutions in my problem.

            • 3. Re: Changing the Naming convention of Log Files
              Linda Lee-Oracle
              You may want to read http://docs.oracle.com/cd/E17277_02/html/GettingStartedGuide/logfilesrevealed.html for an explanation of why arbitrary deletion of log files will corrupt your data store.

              It is best to stick to the public APIs to manage your data. There are com.sleepycat.je.{Database,Cursor} or com.sleepycat.persist.{PrimaryIndex,  SecondaryIndex, EntityCursor, etc} methods to select and delete data records, or You may also want to consider organizing different types of records into different databases or primary indexes within a single environment, so you can take advantage of the Environment.removeDatabase. But since the user does not explicitly control the mapping of data to log files, you cannot delete data in that way.
              1 person found this helpful