Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Linux Red Hat AND Oracle 11g

Posted on 2009-05-15
5
809 Views
Last Modified: 2013-11-11
experts,

      I often need to open the terminal window and set the Oracle environment for one SID. Is there a way to automate this process? I looked up the solution but the web site listed that the commands should be saved to a file ~oracle/.bash         where is that? The oracle home path? What directory do I place the script?

MissyMadi
0
Comment
Question by:missymadi
  • 2
5 Comments
 
LVL 74

Expert Comment

by:sdstuber
ID: 24396394
~oracle

means the  home directory of the oracle user,  NOT necessarily the samething as an ORACLE_HOME (and probably not)


probably something like

/home/oracle

0
 

Author Comment

by:missymadi
ID: 24396482
Where would I set the environment variables for Oracle SID so that I don't have to keep entering each time a terminal window is opened?
0
 
LVL 30

Accepted Solution

by:
Kerem ERSOY earned 125 total points
ID: 24396582
$HOME/.bash_profile file is where you save your oracle variables. If you place them there they will be in your environment as soon as you logon. To see the result you need to logoff and logon back.

If you want to check what is in your environmen simply type :
# env

and it will show all your environment variables.

Cheers,
K.
0
 
LVL 74

Assisted Solution

by:sdstuber
sdstuber earned 125 total points
ID: 24396633
inside your resource file put these lines

export ORAENV_ASK=NO
export ORACLE_SID=YOURSID
. oraenv 2>/dev/null
unset ORAENV_ASK

if oraenv isn't in your path then fully qualify it,
it might look like...

. /usr/local/bin/oraenv 2>/dev/null

and you can, of course, redirect your stderr to a file instead of devnull if you want a log.

0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Create Index on a Materialized View 5 33
lunix and unix command 21 86
Sybase and replication server 13 39
PHP error function not working on AWS 10 70
How to Unravel a Tricky Query Introduction If you browse through the Oracle zones or any of the other database-related zones you'll come across some complicated solutions and sometimes you'll just have to wonder how anyone came up with them.  …
From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
This video shows how to Export data from an Oracle database using the Original Export Utility.  The corresponding Import utility, which works the same way is referenced, but not demonstrated.
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question