Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Default DB is remote
Ed Jennings wrote:
>
> I have an application running on unix server 'A'. The Oracle DB is also
> running on server 'A'. The application has recently evolved and has
> become extremely cpu intensive, and the number of child processes has
> increased dramatically. With performance degradation the end result, I
> have decided to relocate the application to unix server 'B'. Relocatng
> the DB is more difficult because there are many other apps using this
> particular DB. My problem is that I don't know how to make the
> application now running on server 'B' log into the DB on server 'A' by
> default. All of the scripts, Pro*C, and Pro COBOL DO NOT reference the
> DB with the login_at_instance syntax. It would be an enormous effort to
> modify them all to do so. Is there a way to set this up with
> environment variables? Can the app issue a "sqlplus login" command and
> have it transparently translated into "sqlplus login_at_instance"?
>
> Ed Jennings
> --
> ~~~~~~~~~~~~~~~~~~~~~~~~~
> jenningse_at_mindspring.com
Hi Ed,
I think you might be looking for the TWO_TASK environment variable. On
Unix you can set this in the users startup shell scripts:
csh:
setenv TWO_TASK ora_sid
or
bourne shell:
TWO_TASK=ora_sid ; export TWO_TASK
As long as the ora_sid can be found in your TNSNAMES.ORA, the default login for all Oracle applications will be to the oracle_sid named in the TWO_TASK variable rather than the local database identified by ORACLE_SID You could point TWO_TASK to the local database, the only difference may be the protocol used to connect.
Hope this helps....
-- Barry P. Grove BarrySoft Systems Applications grovebg_at_iSTAR.ca (604)929-5433 Developer, Oracle DBA, Unix Sysadmin North Vancouver, BCReceived on Sun May 18 1997 - 00:00:00 CDT
![]() |
![]() |