[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference decwet::winnt-clusters

Title:WinNT-Clusters
Notice:Info directories moved to DECWET::SHARE1$:[NT_CLSTR]
Moderator:DECWET::CAPPELLOF
Created:Thu Oct 19 1995
Last Modified:Fri Jun 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:863
Total number of notes:3478

858.0. "Notes from Installing Oracle on Cluster" by GUIDUK::HEALY (Alan Healy @ZSO) Wed Jun 04 1997 08:51

    I recently installed a cluster with Oracle Workgroup Server. Since I'm
    not familiar with Oracle, I got some help from an Oracle person.  
    Oracle is more difficult to configure than SQL Server.
    
    In hopes of helping someone else avoid some of the pain, I put together
    my scribbled notes and have entered them as reply #1 to this note. 
    
    Disclaimers:
    
    	1. I don't present this as the best way to set up an Oracle
    	installation, but it worked for me.  Some of this would
    	undoubtedly be considered hacks by a knowledgeable Oracle DBA.  
    	I'd be interested in hearing if there are better ways of
    	accomplishing some of these things.
    
    	2. This works for a new installation. If you have an existing 
    	Oracle installation, these procedures will overwrite some of it 
    	(particularly the Oracle networking setup).
    
    	3. Although I used Oracle Workgroup Server 7.3.2, the process
    	should be similar for other versions and for Enterprise Server.
    
    
    Enjoy -
    
    	Alan Healy
    	Enterprise Solutions Center
    
    
T.RTitleUserPersonal
Name
DateLines
858.1The NotesGUIDUK::HEALYAlan Healy @ZSOWed Jun 04 1997 09:08359
Oracle Workgroup Server Installation on NT Clusters                     6/3/97
---------------------------------------------------

===================================================================
I. Install Oracle Server
------------------------

    Do this on both servers before installing clusters.

    Usually the Oracle Install Window will autorun when you insert the CD;
    otherwise run the Oracle Installer.  OK the language "English".

    Pick "Database Server" on the "what to install" screen

    Protocol Adapter selection screen - select TCP/IP (and Named Pipes if
    you want it)

    Accept default Host Name/Port for Web Listener (not needed for cluster)

    Administrator Name/Password for Web Listener   (not needed for cluster)
    	system		<--default Oracle admin account
    	manager		<--default password

    Enter password for "Internal" account (this is important - write it
    down)

    16-bit Client? NO
    
    Accept Oracle Home for 16-bit
    
    Accept 9999 for Web Listener Port

    At this point it copies files for awhile.......

    A message is displayed that you must run the SQL*NET configuration -
    You MUST DO THIS, but do it later.

    Install Completed.

    Informational Messages:

	Missing TOPOLOGY.ORA file - ignore

	TNSNAMES.ORA not found - This is OK, you will create it later

	Repository Message - ignore (don't need for basic demos but you will
	need it for some of the Oracle Administrator tools if you use them)



PostInstallation
----------------

    Go to \ORANT\NETWORK\ADMIN

    Check that there is a LISTENER.ORA file with the SID for "ORCL" and the
    correct Host name.  Another file is needed in this directory -
    TNSNAMES.ORA:

	Get a sample one from the .\Sample directory
		OR
	Run the SQLNet Easy Configuration tool.

	Choose a database alias for the default database. TCP/IP Host
	Name is the name or IP address of the server.  Use the default
	Database Instance Name of "ORCL" (this is the database that is 
	created by default at installation).


Check out the installation
--------------------------

    Run the SQLPLUS utility and log in to the DB (user system, password
    manager) using the database alias you configured in SQLNet.  If
    successful you will see a "SQL>" prompt.  If you get a "Please login"
    prompt, something is mis-configured.

    At the SQL> prompt type
    
	SELECT * FROM V$DATABASE;
	- should return a name of ORACLE

	This is the "db_name" in the INIT.ORA file for the database.

    Connect to a user with some data:
    
	connect Scott/Tiger
	select * from emp;
	etc.   (note that SQL statements must be ended with a ;)
	exit   (when done)

    Run the Oracle Schema Manager to show all elements of the schema



===================================================================

II. Install Digital Clusters for NT V1.1 
----------------------------------------

    Assign the same drive letters to the shared drives on both servers as
    suggested in the documentation.

    Create a failover group on the primary server.  Create an IP failover
    object and place it in the group.



===================================================================

III. Create a shared database
-----------------------------

    Each Oracle database has its own set of associated services and
    datafiles.  Collectively this is called an "Oracle Instance".  You will
    need to choose an Oracle SID (4 characters) and a database alias
    (longer name) for this new instance.  The instance has to be created on
    both servers but the procedure is somewhat different for the second
    server.  Each instance has an account named INTERNAL that is used to
    control it.

    To create a new instance:
    
    On the primary server, make sure the shared drive(s) on which the
    database will be created are currently online.  Create a new directory
    for the instance on the shared disk.  Create a subdirectory in this
    directory named "Trace".

    Copy the INIT.ORA file (probably named "INITORCL.ORA") that is in the
    \ORANT\DATABASE directory to this new directory and rename it
    INIT<sid>.ORA, e.g., if you have chosen ABCD as your SID, name it
    INITABCD.ORA.  This file contains references to other files in the
    \ORANT\DATABASE directory; change the path on all these references to
    <shared device>:\<new directory> - except for the "background_dump_dest" 
    and "user_dump_dest": change these to point to 
    <shared device>:\<new directory>\Trace.  Also, some of the filenames
    contain the SID (ORCL in the default) - change this to your chosen SID. 
    Finally, the "db_name" parameter in this file must be changed to your
    chosen Alias.

    Create the new instance using Instance Manager (run the NT Instance
    Manager in the "Oracle for Windows NT" Group).  Select "New".

    Enter your chosen SID and the administrative password (this is for the
    INTERNAL account).  Set the Instance Startup Mode to "Automatic".  The
    Parameter Initialization File textbox should point to your edited
    INIT<sid>.ORA file on the shared drive.

    Now click the "Advanced" button.  On this screen change DATABASE to
    your chosen Alias.  Edit the Logfile box so the paths point to the
    directory on the shared drive (note: this is a scrolling text field -
    there are two paths you need to change).  The filenames listed should
    be OK.

    Edit the path in the DATAFILE field.  At the end of this field is the
    database size (10MB is the default).  You should probably increase it
    to at least 15MB since a database of 10MB will have very little free
    space in it.

    CHARACTER SET field - select WE8ISO8859P1.  (I don't know why - but
    that's the one that works).

    All other parameters on this screen should be left as is unless you
    know what you're doing.

    Click OK on this screen and then OK on the main screen, and it will
    start creating the database.  It will display a message about "Password
    file created" - click OK to continue.  You will see the icon "Please
    Wait".  After a minute or two of disk activity it will display a
    message saying "Database Created" and propose to run some scripts -
    click OK to run the scripts that are listed.

    Now the database structure is created in the background.  You must wait
    until it is done before proceeding.  You can wait until there is no
    disk activity for a while, or watch process ORACLE73.EXE using Task
    Manager (there are at least 2 of these so pick the one that's using CPU
    time).  When it has stopped using CPU it's done (took about 10 minutes
    on a Prioris ZX 5133 for a 20MB database).

    Your SID should be shown on the Instance Manager main screen with
    Services and Instance both started.  Close Instance manager.

    Modify \ORANT\NETWORK\ADMIN\LISTENER.ORA for the new instance as
    described in the Clusters Administrator's Guide, chapter 3.  The
    following is a brief description:

	There are one or two ADDRESS= entries for COMMUNITY=TCP.world. 
	Change the Host Name on both to be either the DNS name or IP address 
	of the failover group.

	In the SID_LIST section, add a SID_DESC entry for your database. The
	format should be exactly the same as the "ORCL" SID; i.e.:

		(SID_DESC =
			(SID_NAME = ABCD)
		)

	if your database SID is ABCD.

    Also in \ORANT\NETWORK\ADMIN,  modify TNSNAMES.ORA - copy the TCP
    section & modify for your database instance as described in the Cluster
    Admin Guide chapter 3 - or you can run the "SQLNet Easy Configuration"
    tool.

    Then, go to Control Panel/Services:

	1. Stop OracleTNSListener

	2. Start OracleStart<sid>

	3. Start OracleTNSListener

    Using SQLPLUS, log in to the new database using 'system/manager' and
    the database alias you configured in SQLNet.  If successful you will
    see the "SQL>" prompt.

    At the prompt type
    
	SELECT * FROM V$DATABASE;
	it should return the alias name you configured.

    The database is now accessible on the primary server.  There is nothing
    in it but system tables - you can create user tables and load data using
    SQL statements in SQLPLus or other tools.



Create Database on Failover Server
----------------------------------

    Shut down the instance as stated in Cluster Admin Guide:

      - Run Server Manager from the Oracle Enterprise Manager Group
	
      - Connect and shutdown the database by typing the following:

        connect internal/manager@newdb   <--if you have set the password
        SHUTDOWN IMMEDIATE                  for the INTERNAL account to
        exit                                "manager" and the alias to newdb

    Failover the group to the other server as described in the Admin Guide.

    On the failover server,

    You now need to "hide" the database files created by the primary
    server.  Rename all Oracle database files on the shared disk except for
    INIT<sid>.ORA by changing the extension on all of them to something
    other than .ORA - this makes it easier to change them back later. 
    INIT<sid>.ORA must remain as is.

    To create the second instance, go through the exact same procedure as
    above, using Instance Manager on the Failover server using the "New
    Instance" and "Advanced" windows to enter all the parameters EXACTLY
    the same as you did on the Primary server.  

    When done with Instance Manager, click OK on the main screen and it
    will start creating the database.  Everything is the same up to when
    the message pops up about "Database Created" and proposing to run the
    scripts - in this case click Cancel to AVOID running the scripts (they
    are not necessary).

    In Control Panel/Services, Stop OracleService<sid>

    Delete the .ORA files just created (be sure to leave INIT<sid>.ORA).
    Now rename the original database files back to their original names.

    Make the same changes to the LISTENER.ORA and TNSNAMES.ORA files as on
    the Primary (you may be able to just copy the files over).

    In Control Panel/Services,

	1. Stop OracleTNSListener Service.

	2. Start OracleTNSListener.

	3. Start OracleService<sid>.

	4. Start OracleStart<sid>.

    Now you should be able to log in to the database locally using SQLPlus
    and verify that it is accessible.

    Now shut down the database using Server Manager and fail the group back
    over to the primary server.


Create Oracle Failover Object for the Database
----------------------------------------------

    On the primary server, create the Oracle failover object.  Enter the
    SID for the database you have created, enter the full name including
    path of the INIT<sid>.ORA file in the "Oracle sid Parameter File"
    textbox and your Alias name in the "Oracle Database" box.  In the
    "Oracle Listener Name" box, enter the name of the listener from the
    LISTENER.ORA file (see the Cluster Admin Guide's description of
    LISTENER.ORA - the default name is LISTENER).  Leave "Oracle Pipe Name"
    box empty unless you will be using Named Pipes.

    Place the object in the Failover group (last).


===================================================================

Install Oracle Client (Win 95 or NT Workstation)
---------------------

    Insert the Oracle CD in the client machine - usually the Oracle
    Installer will autorun; otherwise run the Oracle Installer from the CD. 
    OK the language.

    Pick "Database Client" on the "what to install" screen, if it has not
    already picked it for you.

    Protocol Adapter selection screen - select TCP/IP (and Named Pipes if
    you want it).

    After installation, configure SQLNet to connect to server by running
    the SQLNet Easy Configuration tool:

	- Choose to "Add a Database Alias"

	- Enter a local name for the connection

	- Choose the TCP/IP protocol

	- Enter the Failover Group name or IP address as the TCP/IP Host 
	  Name

	- Change the default Database Instance from "ORCL" to the Oracle 
	  SID you chose for your database.

    The only query tool installed by default on the client is SQLPlus. You
    can use this to test your connection to the cluster.

===================================================================

Miscellaneous notes, etc.
-------------------------

    Stopping the Network Listener (as recommended in Cluster doc)- name of
    the listener and password for the listener is in the LISTENER.ORA file
    for the server.

	C:\> LSNRCTL
	LSNRCTL> set password oracle  <-- default password
	LSNRCTL> stop listener        <--- default name in LISTENER.ORA


    Starting up the instance - didn't work with Server Manager for some
    reason- got error "ORA-01081 cannot start already-running ORACLE -
    shut it down first".

    Stop and restart services in Control Panel instead:

	Go to Control Panel / Services

	Look for services OracleStart<sid> and OracleService<sid>
	Stop and start them from here.