Kevin Closson's Blog: Platforms, Databases and Storage


Home | Pages | Archives


Just How Well Do You Know Your Oracle Home Directory Tree?

April 4, 2009 8:29 pm

How Deep is Your…Oracle Home?
This is likely the most trivial of pursuits sort of posts I’ve made in a long while. Please don’t ask me why, but I had to take a few minutes to inventory directory depth in an Oracle Database 11g Enterprise Edition (with Real Application Clusters) Oracle Home directory tree on Linux. The data in the following box shows each directory depth that exits under my Oracle Home and a tall of how many directories are nested that deeply.

Maybe we should all breathe a sigh of relief that there are only 3 directories laying 13 levels deep? That is, after all, only .07% of all directories (4208) under a typical 11g Oracle Home! I’m not losing sleep.

Hey, like I said, trivial pursuit. Ho hum.

SQL> select d,count(*) from oh_dirs
  2  group by d
  3  order by 2 desc ;

         D   COUNT(*)
---------- ----------
         8        796
         5        729
         6        663
         4        651
         9        437
         7        369
         3        306
        10        145
         2         70
        11         31
        12          6

         D   COUNT(*)
---------- ----------
        13          3
        14          1
         1          1

14 rows selected.

SQL> select count(*) from oh_dirs;

  COUNT(*)
----------
      4208

Posted by kevinclosson

Categories: oracle

Tags:

4 Responses to “Just How Well Do You Know Your Oracle Home Directory Tree?”

  1. How did you populate oh_dirs?

    Greetings
    Bernd

    By Bernd Eckenfels on April 6, 2009 at 11:53 pm

    1. cd $ORACLE_HOME
      find . -type d -print | sed -e ‘s~/~#~g’ -e ‘s/[^#]//g’ | while read dir
      do echo -n “$dir” | wc -c
      done | while read cnt
      do
      echo “INSERT INTO oh_dirs VALUES (‘$cnt’);”
      done

      By kevinclosson on April 7, 2009 at 12:44 am

  2. When I first saw this I thought you were talking about the depth of the beginning of the OH – I am always amazed at shops with the unruly combination of 6+ level deep OHs and a failure to use tab completion.

    By Eric Gross on April 10, 2009 at 3:42 am

    1. Nope…this is a look the various depths and count of each depth starting in OH … trivial pursuit mostly… (well, not really, but I’m not blabbering about why I was looking at that stuff anyway 🙂 )

      Hey, say “Hi” to Matt for me would ya?

      By kevinclosson on April 10, 2009 at 4:43 pm

Leave a Reply

You must be logged in to post a comment.



Mobile Site | Full Site


Get a free blog at WordPress.com Theme: WordPress Mobile Edition by Alex King.