Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Format of /etc/oratab file on Unix : With Simplify Script
Ken Friday wrote:
>
> Just to add my two cents worth....... this file is used by only a couple of
> Oracle supplied shell scripts. You can extend the functionality of this
> file by adding fields referenced in your own shell scripts. Note that aside
> from the shell scripting this file is optional in Sql*Net 2.x and greater
> environments.
>
Like the idea, but I wouldn't screw with this file.
However, given that it has a "key" (the SID), there is nothing
stopping you putting supplementary information in a supplementary
table you have real control of, say /usr/oracle/local/etc/sidextra.tab
Also, check out the following script which should be "fed" oratab through stdin. It gets out garbage lines, and makes further parsing trivial. (The wide spaces between square brackets are a space and a tab).
#!/bin/sed -f
s/^[ ]*//
s/[ ].*$//
/^[^:]*$/d /^:/d /::/d /^[^:]*:[^:]*$/d /^[^:]*:[^:]*:[^:*]:/d
--