Solaris10 installation howto: Difference between revisions

From OrcaWiki
Jump to navigation Jump to search
Omegax (talk | contribs)
New page: This "How To" is probably just one way to setup the server, but it works. All the extra software used were downloaded from sunfreeware.com (similar packages from blastwave.org should also...
 
Omegax (talk | contribs)
Line 18: Line 18:
make, expat, db-4, apr, aprutil, openssl, libiconv, gdbm, gcc (if not installed), apache2 (of course!)
make, expat, db-4, apr, aprutil, openssl, libiconv, gdbm, gcc (if not installed), apache2 (of course!)
You can get all the packages above from sunfreeware.com.
You can get all the packages above from sunfreeware.com.




Installing ORCA on server and clients
Installing ORCA on server and clients
==================================================
=====================================


1. install or ensure there is a suitable C compiler e.g., gcc 3.4.2, gcc 3.4.6
1. install or ensure there is a suitable C compiler e.g., gcc 3.4.2, gcc 3.4.6
Line 44: Line 43:
pkgadd -d RICHPse
pkgadd -d RICHPse
(OR: gunzip RICHPse.gz; pkgadd -d . RICHPse )
(OR: gunzip RICHPse.gz; pkgadd -d . RICHPse )


6. install Orca (or orcallator.se on clients)
6. install Orca (or orcallator.se on clients)
Line 54: Line 52:
gunzip orca-snapshot-r535.tar.gz
gunzip orca-snapshot-r535.tar.gz
tar -xvf orca-snapshot-r535.tar
tar -xvf orca-snapshot-r535.tar
cd orca-snapshot-r535
cd orca-snapshot-r535



Revision as of 08:42, 22 May 2008

This "How To" is probably just one way to setup the server, but it works.

All the extra software used were downloaded from sunfreeware.com (similar packages from blastwave.org should also work) 1. make 3.80 2. gcc 3.4.6 3. libgcc 3.4.6 (not needed unless you intend to uninstall gcc after you finish the installation, only then will you install libgcc) 4. libiconv-1.11-sol10-sparc-local.gz 5. orca-snapshot-r535.tar.bz2

HOW TO SETUP ORCA (CLIENTS AND SERVER)

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

Ayotunde Itayemi (Last updated 22/05/2008)


Installing Apache2 on the Central Server

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

make, expat, db-4, apr, aprutil, openssl, libiconv, gdbm, gcc (if not installed), apache2 (of course!) You can get all the packages above from sunfreeware.com.


Installing ORCA on server and clients

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

1. install or ensure there is a suitable C compiler e.g., gcc 3.4.2, gcc 3.4.6

2. use the default system perl or install GNU Perl built with gcc e.g., Perl 5.8.7 (you may need autoconf and m4 packages on Solaris 10)

  Not necessary: Install freetype2 package from sunfreeware

3. set your PATH and LD_LIBRARY_PATH variables temporarily export PATH=/usr/local/bin:/usr/ccs/bin:$PATH export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH

4. You need to install libiconv (e.g., libiconv-1.8-sol9-sparc-local) if using gcc

5. install SE Toolkit (version 3.4 at least for Solaris 10) Also the package SUNWsprot must be installed on the server - it is usually installed by default)

  ftp://ftp.sunfreeware.com/pub/freeware/SOURCES/RICHPse.gz
  http://www.sunfreeware.com/setoolkit.html

gunzip RICHPse-3.3.tar.gz tar -xvf RICHPse-3.3.tar pkgadd -d RICHPse (OR: gunzip RICHPse.gz; pkgadd -d . RICHPse )

6. install Orca (or orcallator.se on clients) extract the Orca compressed package e.g., to /opt NOTE: it may be a good idea to install orcallator somewhere else apart from the default /usr/local since its files will grow e.g., on a dedicated filesystem or under /var for example.

gunzip orca-snapshot-r535.tar.gz tar -xvf orca-snapshot-r535.tar cd orca-snapshot-r535

Solaris 10 NOTE ===========================================

IN FILE: orca-snapshot-r535/packages/rrdtool-1.0.50/perl-shared/Makefile

1. change the line "CCCDLFLAGS = -KPIC" to "CCCDLFLAGS =" 2. change the line CCFLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -xarch=v8 -D_TS_ERRNO -DHAVE_CONFIG_H

TO: CCFLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_TS_ERRNO -DHAVE_CONFIG_H


3. change the line "OPTIMIZE = -xO3 -xspace -xildoff" to "OPTIMIZE ="


IN FILE: orca-snapshot-r535/packages/Storable-2.15/Makefile

1. change the line "CCCDLFLAGS = -KPIC" to "CCCDLFLAGS ="

2. change the line CCFLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -xarch=v8 -D_TS_ERRNO

TO: CCFLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_TS_ERRNO


3. change the line "OPTIMIZE = -xO3 -xspace -xildoff" to "OPTIMIZE ="


END OF Solaris 10 NOTE ===========================

  1. if you are reinstalling, remember to delete the existing orca folder or else

the new installation will not succeed e.g., bash-3.00# rm -rf /usr/local/var/orca

  1. make fails because the default perl expects to use the cc compiler, so
  2. create a soft link to the gcc compiler i.e.,

cd /usr/local/bin ln -s gcc cc

  1. make fails because it couldn't locate perl pod2man executable, so find it and add to PATH
  2. variable

bash-3.00# find /usr | grep pod2man /usr/perl5/5.6.1/bin/pod2man /usr/perl5/5.6.1/man/man1/pod2man.1 /usr/perl5/5.8.4/bin/pod2man /usr/perl5/5.8.4/man/man1/pod2man.1

  1. "perl -v" returns 5.8.4, so use the "second" pod2man above

export PATH=$PATH:/usr/perl5/5.8.4/bin


bash-3.00# cd .. bash-3.00# pwd orca-0.27b3

bash-3.00#

./configure --with-html-dir=/var/apache2/htdocs/orca --with-ncsa-log=/var/apache2/logs/access_log

make; make install; make orcallator_run_at_boot


====== orca doesn't start on solaris 10 ======================

Because the following statement in the orcallator startup script is used to derive part of the name of the PATH to some of the files needed by orcalltor, orcallator does not start "/opt/RICHPse/bin/se -version | awk '{print $4}'" the reason is that the command above returns 3.4.1 which is the used to generate the PATH /usr/local/lib/SE/3.4.1 which does not exist. The actual path on the server is /usr/local/lib/SE/3.4 The solution is to create a soft link as below.

cd /usr/local/lib/SE ln -s 3.4 3.4.1

====== orca doesn't start on solaris 10 ======================

start the orcallator /etc/init.d/orcallator start


mkdir -p /var/apache2/htdocs/orca/orcallator


DO THIS ONLY if using GNU perl (e.g., from sunfreeware.com) Edit the file /usr/local/bin/orca and change the first line to use the new perl installation i.e., the line changes from #!/usr/bin/perl TO: #!/usr/local/bin/perl


The commands below are ONLY needed on the server /usr/local/bin/orca -v /usr/local/lib/orcallator.cfg

(once it starts up completely without errors and completes the first run, kill the process (find it's pid with "ps -ef | grep orca")

then restart orca as a daemon i.e., /usr/local/bin/orca -d /usr/local/lib/orcallator.cfg


You are adviced to create an auto-start script in /etc/init.d and /etc/rc2.d for the above process.


edit the /etc/hosts on both the server and client and ensure they can "see" each other (alternatively use DNS)


Configure the client for "password-less" login to the server

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

on the client (as root) run "ssh-keygen -t rsa" to generate the client's authentication key files, when asked for the name of the file in which to save the key, just press the ENTER key and when asked for a paraphrase also press the ENTER key. Press ENTER key again to confirm the blank paraphrase. This generates the default pair of files /.ssh/id_rsa and /.ssh/id_rsa.pub

copy the content of the /.ssh/id_rsa.pub from the client into the /.ssh/authorized_keys on the server. (make the permission on the authorized_keys file 400 i.w., "chmod 400 authorized_keys")

NOTE: the content of the id_rsa.pub file is one single continuous line NOTE: if there are other lines in the authorized_keys file on the server, just place the content of the id_rsa.pub file on a new line. NOTE: extablish a test connection from client to server (at least once)

     manually so that you can accept the public key of the server
     otherwise the crontab entry may not work.

Now configure the client to send the Orca stats files to the server on the client add the entry to root's crontab ("crontab -e"):

0,5,10,15,20,25,30,35,40,45,50,55 * * * * /usr/bin/scp -r /usr/local/var/orca/orcallator/ test-server:/usr/local/var/orca/orcallator/ (where vnl-evddb01 is the name of the server in this example which must be resolvable on the client)


NOTE: it seems once you have added a new client to the configuration, and at least one set of statistics have been copied to the server, you may have to kill and restart the Orca daemon on the server so that it will see the new client: i.e., kill the process (find it's pid with "ps -ef | grep orca") and restart it /usr/local/bin/orca -d /usr/local/lib/orcallator.cfg


NOTE: it seems once you have added a new client to the configuration, and at least one set of statistics have been copied to the server, you may have to kill and restart the Orca daemon on the server so that it will see the new client: i.e., kill the process (find it's pid with "ps -ef | grep orca") and restart it /usr/local/bin/orca -d /usr/local/lib/orcallator.cfg


Final words: I prefer to install gcc3.4.6 and make 3.80, finish compiling and installing everything that requires gcc, then uninstall gcc and make 3.80. Then install just libgcc3.4.6 (security reasons!)