LFD: Unterschied zwischen den Versionen

Aus Admin Kuhn GmbH
Zur Navigation springen Zur Suche springen
Keine Bearbeitungszusammenfassung
(Die Seite wurde geleert.)
Zeile 1: Zeile 1:
== Software installation ==


As usual first install the needed SISIS-SunRise packages, at least
* package
* sisis-pap
* sisisbase
<b>Be sure to install the needed versions!</b>
For more information about this read the release notes ("Freigabemitteilung") 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
* approval to install Sybase at all
* the full path of $SYBASE (preferred "/opt/sybase")
* the name of the Sybase user under SISIS-SunRise (preferred "sisis")
* the Sybase password of that Sybase user
* the Sybase password of the Sybase administrator "sa"
The information will be stored read-only for the Linux user "sisis" into the file "/opt/lib/sisis/etc/syb/syb.pw".
If you change the information later by hand keep in mind that the information is also stored in Sybase (the passwords for users "sa" and "sisis") and even in the created SISIS-SunRise database (i. e. that Sybase user "sisis" is allowed to connect to the database).
== Creating database "sisis" ==
After the 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 ). If your connection is unreliable you can also run them in the nohup-mode.
<b>Don't run these files unmodified</b> - this can accidentally override files in your filesystem.
The actual standard file "DiskInit.sql.orig" for SISIS-SunRise V4.0 looks like this.
<pre>
/* $Id: DiskInit.sql 237392 2009-07-22 14:11:02Z bajdalaj $ */
disk init                                /* explanation:                  */
name="datadev",                          /* logical name                  */
physname="/dev/sybaseDatabase/datadev",  /* file  or link to raw device  */
size="4G",                              /* size in M or G */
dsync=false                              /* for files for better performance */
go
disk init                                /* explanation:                  */
name="logdev",                          /* logical name                  */
physname="/dev/sybaseDatabase/logdev",  /* file  or link to raw device  */
size="2G",                              /* size in M or G */
dsync=false                              /* for files for better performance */
go
</pre>
The actual standard file "CreateDb.sql.orig" for SISIS-SunRise V4.0 looks like this.
<pre>
sp_configure "lock scheme", 0, datarows
go
create database sisis
on DBsisisdev=10240
log on logdev=4096
go
sp_dboption "sisis","select into/bulkcopy","true"
go
sp_dboption sisis,"auto identity","true"
go
sp_dboption sisis,"trunc. log on chkpt.", true
go
use sisis
go
checkpoint
go
execute sp_adduser "sisis"
go
if @@error != 0
begin
print "Error in adding the user $USER in database."
rollback transaction
end
go
grant ALL to sisis
go
if @@error != 0
begin
print "Error in granting the permissions to $USER."
rollback transaction
end
go
use master
go
</pre>
Configure the files "DiskInit.sql" and "CreatDb.sql" and execute them as user "sisis".
$ <b>. /opt/lib/sisis/etc/syb.rc && export LANG=de</b>
$ <b>$SYBASE/OCS-12_5/bin/isql -Usa -Pxxxxxx -SsisisSYB -i /home/sisis/sc/DiskInit.sql</b>
$ <b>$SYBASE/OCS-12_5/bin/isql -Usa -Pxxxxxx -SsisisSYB -i /home/sisis/sc/CreatDb.sql</b>
Don't worry - processing of both scripts will take some time without output!
== Check Sybase disk allocations ==
Check the disk allocations of Sybase
$ <b>$SYBASE/OCS-12_5/bin/isql -Usisis -Psisis123 -SsisisSYB</b>
1> <b>sp_helpdb sisis</b>
2> <b>go</b>
In the case of Waregem the output looked like this:
<pre>
device_fragments              size          usage
        created                  free kbytes
------------------------------ ------------- --------------------
        ------------------------- ----------------
DBsisisdev                        10240.0 MB Nur Daten
        Sep 12 2006 11:18AM              10443606
logdev                            4096.0 MB Nur Log
        Sep 12 2006 11:18AM      nicht zutreffend
--------------------------------------------------------------
Nur Log free kbytes = 4177918
</pre>
Become user "root" and create a symbolic link to avoid perl error messages. <b>Note:</b> Check, whether the package "glibc-locale-2.2.5-163.i586.rpm" is already installed - otherwise install it first!
# <b>cd /usr/lib/locale</b>
# <b>ln -s de_DE@euro de</b>
== Backup ==
# <b>mkdir -p /backup/sybase</b>
# <b>chmod 777 /backup/sybase</b>
Backup your (still completely empty) database:
# <b>su - sisis</b>
$ <b>. /opt/lib/sisis/etc/syb.rc && export LANG=de</b>
$ <b>$SYBASE/OCS-12_5/bin/isql -Usa -Pxxxxxx -SsisisSYB</b>
1> <b>dump database sisis to "compress::/backup/sybase/DBSAVEsisis.20060911.cdmp"</b>
2> <b>go</b>
If you need to configure your database for SISIS-SunRise the document [[SISIS-SunRise - Configuration of database "sisis" for SISIS-SunRise|Configuration of database "sisis" for SISIS-SunRise]] may be useful to you.
== Easy login ==
For an easy login as Sybase user "sa" create the file "/home/sisis/bin/SybSQLsa" with rights "700".
<pre>
#!/bin/bash
# Name          SybSQLsa
# Date          2010.02.02
# Author        Michael Kuhn, OCLC AG
# Description  Automatic login as user "sa"
##### AUTOMATIC CONFIGURATION #####
. $(pkgparam sisisbase SISISROOT)/etc/syb.rc
if  [ "$(echo ${SC_SQL} | grep -q 12_5 ; echo $?)" = 0 ]; then
  export LANG=de
elif [ "$(echo ${SC_SQL} | grep -q 15_0 ; echo $?)" = 0 ]; then
  export LANG=de_DE.UTF-8
else
  echo "Unknown Sybase version. No connection possible"
  exit 1
fi
SYBASEUSER=sa
PASSWORD=$(cat ${SISISROOT}/etc/syb/syb.pw | \
  grep ^${SYBASEUSER}: | awk -F: '{ print $2 }' | tr -d '\012')
##### MANUAL CONFIGURATION #####
SYBASESERVER=sisisSYB
##### MAIN #####
${SC_SQL} -U${SYBASEUSER} -P${PASSWORD} -S${SYBASESERVER}
</pre>
For an easy login as Sysbase user "sisis" and database "sisis" create the file "/home/sisis/bin/SybSQLsisis_DBsisis" with rights "700".
<pre>
#!/bin/bash
# Name          SybSQLsisis_DBsisis
# Date          2010.02.02
# Author        Michael Kuhn, OCLC AG
# Description  Automatic login as user "sisis" into database "sisis"
##### AUTOMATIC CONFIGURATION #####
. $(pkgparam sisisbase SISISROOT)/etc/syb.rc
if  [ "$(echo ${SC_SQL} | grep -q 12_5 ; echo $?)" = 0 ]; then
  export LANG=de
elif [ "$(echo ${SC_SQL} | grep -q 15_0 ; echo $?)" = 0 ]; then
  export LANG=de_DE.UTF-8
else
  echo "Unknown Sybase version. No connection possible"
  exit 1
fi
SYBASEUSER=sisis
PASSWORD=$(cat ${SISISROOT}/etc/syb/syb.pw | \
  grep ^${SYBASEUSER}: | awk -F: '{ print $2 }' | tr -d '\012')
##### MANUAL CONFIGURATION #####
DATABASE=sisis
SYBASESERVER=sisisSYB
##### MAIN #####
${SC_SQL} -U${SYBASEUSER} -P${PASSWORD} -S${SYBASESERVER} -D${DATABASE}
</pre>
[[Category:Sybase ASE|Creation of Sybase ASE database "sisis"]]
[[Category:SISIS-SunRise]]
[[Category:Documentation]]

Version vom 28. August 2013, 15:01 Uhr