Sybase Adaptive Server Enterprise 12.5.4/Installation 2006.09.11 Waregem

Aus Mikiwiki
Version vom 24. Januar 2009, 13:17 Uhr von Michi (Diskussion | Beiträge)
(Unterschied) ← Nächstältere Version | Aktuelle Version (Unterschied) | Nächstjüngere Version → (Unterschied)
Zur Navigation springen Zur Suche springen

1. Pre-installation tasks

Add user "sybase" and login.

# groupadd sybase
# useradd -g sybase -d /home/sybase -s /bin/bash -c "Sybase master" -m -p sybase sybase

Unzip the installation software

# cd /backup/software/SybaseASE-12.5.4
# tar xzf ase1254linux32.tgz

Create directory /opt/sybase

# cd /opt
# mkdir sybase && chown sybase:sybase sybase

# cd /SunRiseDatabase
# mkdir sybaseDatabase && chown sybase:sybase sybaseDatabase

# cd /var/spool
# mkdir sybase && chown sybase:sybase sybase

2. Installation of Sybase ASE

Set shared memory

# /sbin/sysctl -w kernel.shmmax=121634816

Become user "sybase" and start the installation

# su - sybase
$ ./setup -console
InstallShield Wizard
Initializing InstallShield Wizard...
Searching for Java(tm) Virtual Machine...
Running InstallShield Wizard...

-------------------------------------------------------------------------------
Welcome to the InstallShield Wizard for Sybase Adaptive Server Enterprise Suite
version 12.5.4 GA

The InstallShield Wizard will install Sybase Adaptive Server Enterprise Suite
on your computer.
To continue, choose Next.
Press 1 for Next, 3 to Cancel or 4 to Redisplay [1]

-------------------------------------------------------------------------------
 3)  Belgium(English)

   Please enter the number of the location you are installing. (1-37) [1] 3

LICENSE AGREEMENT
BELGIUM
...

Press ENTER to read the text [Type q to quit] q

I agree to the terms of the Sybase license for the install location
specified.(Y/N) [N]Y

Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1]

-------------------------------------------------------------------------------
Please enter the directory where you would like to install the products or
press ENTER to accept the default.

   Destination Directory [/opt/sybase]

   Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1]

-------------------------------------------------------------------------------
Choose the setup type that best suits your needs.

To select an item enter its number, or 0 when you are finished: [0] 2
                                                                                
[X] 2 - Full
        The program will be installed with all the products and features.
                                                                                
To select an item enter its number, or 0 when you are finished: [0]

Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1]

Please wait while the installer checks your system information...

-------------------------------------------------------------------------------
Sybase Adaptive Server Enterprise Suite will be installed in the following
location:
...
Press ENTER to read the text [Type q to quit] q

Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1]

Installing Sybase Adaptive Server Enterprise Suite. Please wait...

|-----------|-----------|-----------|------------|
0%         25%         50%         75%        100%
||||||||||||||||||||||||||||||||||||||||||||||||||

Creating uninstaller...

-------------------------------------------------------------------------------
The InstallShield Wizard has successfully installed Sybase Adaptive Server
Enterprise Suite. Choose Next to continue the wizard.

Press 1 for Next, 3 to Cancel or 4 to Redisplay [1]

-------------------------------------------------------------------------------
The Adaptive Server Enterprise suite contains a number of programs in addition
to the Adaptive Server Enterprise database server. At this point in the
installation you can choose to configure various products. If you select the
options on this screen, you will be given the option of specifying
configuration options for each product or to allow the installer to set default
values for these on the next screen. If you do not choose to configure the
products at this time, you can configure them using the ASE configuration
utility at a later time.

Please deselect any products that you do not want to configure now :

      To select an item enter its number, or 0 when you are finished: [0] 3
      To select an item enter its number, or 0 when you are finished: [0] 4
      To select an item enter its number, or 0 when you are finished: [0] 5
      To select an item enter its number, or 0 when you are finished: [0] 6
      To select an item enter its number, or 0 when you are finished: [0] 7

   [X]  1  -  Configure new Adaptive Server
   [X]  2  -  Configure new Backup Server
   [ ]  3  -  Configure new Monitor Server
   [ ]  4  -  Configure new XP Server
   [ ]  5  -  Configure new Job Scheduler
   [ ]  6  -  Configure Web Services
   [ ]  7  -  Configure new Full-Text Search SDS

      To select an item enter its number, or 0 when you are finished: [0]

Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1]

-------------------------------------------------------------------------------
You have chosen to configure the products listed below. You can accept default
configuration values or provide customized values for the configuration options
required by each product. If you do not select custom configuration below, this
installer will configure the products you have selected with default values. If
you accept default values at this time you can change the configuration values
for a product at later time.

Please select the products that you want to custom configure.

      To select an item enter its number, or 0 when you are finished: [0] 1
      To select an item enter its number, or 0 when you are finished: [0] 2

   [X]  1  -  Custom configure new Adaptive Server
   [X]  2  -  Custom configure new Backup Server

      To select an item enter its number, or 0 when you are finished: [0]

Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1]

-------------------------------------------------------------------------------
Please enter custom configuration values for the new Adaptive Server

   Adaptive Server Name [BIBWAR] sisisSYB
   Port Number [5000] 4000
   Error Log [/opt/sybase/ASE-12_5/install/sisisSYB.log] /var/spool/sybase/sisisSYB.errorlog
   Page Size
      1. 2k
      2. 4k
      3. 8k
      4. 16k
   Select a page size :  [1]
   Master Device [/opt/sybase/data/master.dat] /SunRiseDatabase/sybaseDatabase/masterDev
   Master Device Size (MB) [30] 200
   Master Database Size (MB) [6] 100
   System Procedure Device [/opt/sybase/data/sysprocs.dat] /SunRiseDatabase/sybaseDatabase/sysprocsDev
   System Procedure Device Size (MB) [132] 200
   System Procedure Database Size (MB) [132]
   System Device [/opt/sybase/data/sybsysdb.dat] /SunRiseDatabase/sybaseDatabase/sybsysdbDev
   System Device Size (MB) [1] 10
   System Database Size (MB) [1]

   Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1]

-------------------------------------------------------------------------------
Please enter custom configuration values for the new Backup Server

   Backup Server Name [sisisSYB_BS] sisisSYBbackup
   Port Number [5001] 4001
   Error Log [/opt/sybase/ASE-12_5/install/sisisSYBbackup.log] /var/spool/sybase/sisisSYBbackup.errorlog

   Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1]

-------------------------------------------------------------------------------
The installer will now configure new servers with the following values. Please
click Next to proceed with the server configurations.
...

   Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1]
   
   Building Adaptive Server 'sisisSYB':
   Writing entry into directory services...
   Directory services entry complete.
   Building master device...
   Master device complete.
   Writing RUN_sisisSYB file...
   RUN_sisisSYB file complete.
   Starting server...
   Server started.
   Building sysprocs device and sybsystemprocs database...
   sybprocs device and sybsystemprocs database created.
   Running installmaster script to install system stored procedures...
   installmaster: 10% complete.
   installmaster: 20% complete.
   installmaster: 30% complete.
   installmaster: 40% complete.
   installmaster: 50% complete.
   installmaster: 60% complete.
   installmaster: 70% complete.
   installmaster: 80% complete.
   installmaster: 90% complete.
   installmaster: 100% complete.
   installmaster script complete.
   Creating two-phase commit database...
   Two phase commit database complete.
   Installing common character sets (Code Page 437, Code Page 850, ISO Latin-1,
   Macintosh and HP Roman-8)...
   Character sets installed.
   Setting server name in Adaptive Server...
   Server name added.
   Server 'sisisSYB' was successfully created.
   Building Backup Server 'sisisSYBbackup':
   Writing entry into directory services...
   Directory services entry complete.
   Writing RUN_sisisSYBbackup file...
   RUN_sisisSYBbackup file complete.
   Starting server...
   Server started.
   Setting server name in Adaptive Server...
   Server name added.
   Server 'sisisSYBbackup' was successfully created.

-------------------------------------------------------------------------------
   The installation was successful.

   Please check regularly for updates at http://www.sybase.com/downloads.

   If you have Sybase Software Asset Management Certificates to enter, this is
   done by running the tool /opt/sybase/SYSAM-1_0/bin/lmgr after the
   installation is complete.

   Press 3 to Finish or 4 to Redisplay [3]

To determine whether the servers you installed are running, enter:

$ export SYBASE=/opt/sybase
$ export SYBASE_ASE=ASE-12_5
$ $SYBASE/$SYBASE_ASE/install/showserver
$ PATH=$SYBASE/OCS-12_5/bin:$PATH
$ export DSQUERY=sisisSYB
$ isql -U sa -P
Msg 2401, Level 11, State 2:
Server 'sisisSYB':
Character set conversion is not available between client character set 'utf8'
and server character set 'iso_1'.
No conversions will be done.
1> select @@version
2> go
 Adaptive Server Enterprise/12.5.4/EBF 13388/P/Linux Intel/Enterprise Linux/ase1
         254/2006/32-bit/OPT/Fri May 19 23:17:01 2006                            

Set password (better than our 6 x):

1> sp_password null, xxxxxx     
2> go
Password correctly set.
1> quit

Install german language support (optional):

$ $SYBASE/ASE-12_5/bin/langinstall -Pxxxxxx german iso_1
Loading datetime information from file /opt/sybase/locales/german/iso_1/common.loc.
Loading system messages from file /opt/sybase/locales/german/iso_1/server.loc.
7812 Messages processed.
Loading complete.
Summary: 0 deleted, 7410 inserted, 0 updated, 402 duplicates,   0 unsuccessful.

Increase tempdb (typically 1-2 GB at customer systems):

$ isql -Usa -Pxxxxxx
1> disk init name="tempdev", physname="/SunRiseDatabase/sybaseDatabase/tempDev",
2> size="2g",
3> dsync=false
4> go

1> alter database tempdb on tempdev = 2048
2> go

1> sp_addlogin sisis, sisis123
2> go

3. Configuring and tuning the server for SISIS

There are some server-wide config parameters which have to make fit your needs; most of the DEFAULT values does not fit, see below;

For the SISIS database we need more than 10 devices; so up the devices value in the server with:

Important: Change the following parameters before you perform DiskInit.sql!!

$ $SYBASE/OCS-12_5/bin/isql -Usa -Pxxxxxx -SsisisSYB

Max memory depends on the number of Sisis servers. 64000 is for a small library:

1> sp_configure "max memory", 128000
2> go

By default the procedure cache size is 3167 pages (6334 KB). For big libraries this value should increased to 10240 pages.

1> sp_configure "procedure cache size", 10240
2> go

The default data cache has the default size 8M. For bigger libraries increase this value.

1> sp_cacheconfig "default data cache", "80M"
2> go
1> sp_configure devices, 50                        /* DEFAULT: 10 */
2> go

up the number of concurrent connects into the server:

1> sp_configure "number of open objects", 2000     /* DEFAULT: 50 */
2> go
1> sp_configure "number of open indexes", 2000     /* DEFAULT: 500 */
2> go
1> sp_configure "number of user connections", 150  /* DEFAULT: 25 */
2> go
1> sp_configure "number of locks", 10000           /* DEFAULT: 5000 */
2> go
1> sp_configure "tcp no delay", 1                  /* DEFAULT:  0 */
2> go

the latter parameter influences the performance dramatically by a factor of more than 10 because we have small TLI packages and there is no need to delay the send/receive and wait for fillings;

up the "max online engines" to the real number of CPU's minus 1 (in the example below: 4-1=3):

1> sp_configure "max online engines", 3           /* DEFAULT: 1  */
2> go

For single processor machines set the next paramter

1> sp_configure "runnable process search count", 5
2> go

The server parameter "allow sql server async i/o" may have a huge influence on performance.

On some Linux server performance drops vanished by disabling async i/o.

To disable async i/o:

1> sp_configure "allow sql server async i/o", 0
2> go

and restart server.

You should compare the boot time of the ASE with and without async i/o.

IMPORTANT: Stop and restart the sybase server to make sure, that all changes takes effect.

4. Verify both servers (sisisSYB, sisisSYBbackup) are up and running

Install script "sybase" in /etc/init.d and restart both servers

# ./sybase stop
# ./sybase start
kernel.shmmax = 243269632
Starting Sybase ASE ... RUN_sisisSYB RUN_sisisSYBbackup
$ $SYBASE/ASE-12_5/install/showserver

To show all servers:

$ $SYBASE/OCS-12_5/bin/isql -Usa -Pxxxxxx -SsisisSYB
1> sp_helpserver
2> go

5. How to setup the SISIS database for Sybase

As usual install the necessary SISIS-SunRise packages, at least package, sisis-pap and sisisbase for the moment; for more information about this read the nice FGM and the how-to "unixForSISIS.txt".

Of course you must choose the Sybase trunk and provide the necessary password information for Sybase during the installation process of SISISBASE; you will be asked for:

  • do you want to use Sybase at all
  • the full path of $SYBASE
  • the name of the SISIS Sybase-user (preferred "sisis")
  • the Sybase-password of the SISIS Sybase-user
  • the Sybase-password of the Sybase admin "sa"

The information will be stored read-only for the UNIX-user "sisis" into a file

$SISISROOT/etc/syb/syb.pw

If you change the information later by hand keep in mind that the information is also stored in Sybase (the pw's for user "sa" and "sisis") and even in the created SISIS database (i.e. that Sybase-user "sisis" is allowed to connect to the database);

After installation of SISISBASE create the database with these SQL files:

  • "DiskInit.sql" creates the devices for ASE
  • "CreatDb.sql" creates the database, gives the devices to the database and add segments, set some parameters

You have to fit these files to your environment and to the structure of your database.

Please insert the values of the device_fragments in "pages". ( Value = 1024 * device_fragments [MB] / 2 )

DON'T RUN THE FILES UNMODIFIED - this can override accidently files in your filesystem.

If your connection is unreliable you can also run them in the nohup-mode.

Become user "sisis", set LC_ALL and run "DiskInit.sql" and "CreatDb.sql":

$ LC_ALL=de ; export LC_ALL
$ SYBASE=/opt/sybase export SYBASE
$ $SYBASE/OCS-12_5/bin/isql -Usa -Pxxxxxx -SsisisSYB -i ~sisis/sc/DiskInit.sql
$ $SYBASE/OCS-12_5/bin/isql -Usa -Pxxxxxx -SsisisSYB -i /home/sisis/sc/CreatDb.sql

Do not worry - this will take some time without output...!!

You should check Sybase's disk allocations with:

$ printf "sp_helpdb sisis\ngo\n" | $SYBASE/OCS-12_5/bin/isql -Usisis -Psisis123 -SsisisSYB
   ...
    device_fragments               size          usage
            created             free kbytes
    ------------------------------ ------------- --------------------
            ------------------- ------------------------------
    logdev                         1023.5 MB     log only
            Sep 27 2002  1:53PM not applicable
    data0dev                       1024.0 MB     data only
            Sep 27 2002  1:53PM          1043280
    data1dev                       2047.0 MB     data only
            Sep 27 2002  2:40PM          2096128
    data2dev                       2047.0 MB     data only
            Sep 27 2002  3:31PM          2096128
    data3dev                       2047.0 MB     data only
            Sep 27 2002  4:24PM          2096128
    data4dev                       2047.0 MB     data only
            Sep 27 2002  5:18PM          2096128

    --------------------------------------------------------------
    log only free kbytes = 1043968

Check if the packages "package", "sisisbase" and "sisis-pap" are installed.

Become "root" and create a symbolic link to avoid perl error messages:

Important: Check, whether the package "glibc-locale-2.2.5-163.i586.rpm" is already installed - otherwise install it first!!

# cd /usr/lib/locale
# ln -s de_DE@euro de

Become user "sisis" again and following the instructions in the release notes (Freigabemitteilungen) from the package "sisisbase" to create the tables and indizes and load the default values in the database:

6. Miscellaneous

IP-addr of the server and port number is in $SYBASE/interfaces as:

sisisSYB
        master tcp ether machine-name 4000
        query tcp ether machine-name 4000

sisisSYBbackup
        master tcp ether machine-name 4001
        query tcp ether machine-name 4001