Solaris10 installation howto: Difference between revisions

From OrcaWiki
Jump to navigation Jump to search
Omegax (talk | contribs)
Omegax (talk | contribs)
No edit summary
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
This "How To" is probably just one way to setup the server, but it works.
# This "How To" is probably just one way to setup the server, but it works.
# The procedure to set up a central repository server or a client on which statistics is to be collected in similar.
# The extra steps to be performed for a server install are indicated where necessary.
#
# All the extra software used were downloaded from sunfreeware.com (similar packages from blastwave.org were not tested but should also work)
# 1. make 3.80
# 2. gcc 3.4.6
# 3. libgcc 3.4.6 (don't install until you read security comment below)
# 4. libiconv 1.11
# 5. orca-snapshot-r535 (http://www.orcaware.com)
# 6. RICHPse (ftp://ftp.sunfreeware.com/pub/freeware/SOURCES/RICHPse.gz, http://www.sunfreeware.com/setoolkit.html)
#
# Quick: if you need to install Apache2 from scratch on the central repository server, here is a list of packages you will likely need:
# 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.
#


All the extra software used were downloaded from sunfreeware.com (similar packages from blastwave.org should also work)
1. Install or ensure there is a suitable C compiler e.g., gcc 3.4.2, gcc 3.4.6
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)


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)


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


Installing Apache2 on the Central Server
4. Install libiconv (only if using the GNU gcc from sunfreeware for example)
========================================
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.


5. For a server install, the package SUNWsprot must be installed (usually installed by default)


Installing ORCA on server and clients
6. Install SE Toolkit (version 3.4 at least for Solaris 10)
=====================================


1. install or ensure there is a suitable C compiler e.g., gcc 3.4.2, gcc 3.4.6
gunzip RICHPse.gz
 
pkgadd -d . RICHPse
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


Alternatively, if using the RICHPse-3.3.tar.gz package, then use the following commands instead:
gunzip RICHPse-3.3.tar.gz
gunzip RICHPse-3.3.tar.gz
tar -xvf RICHPse-3.3.tar
tar -xvf RICHPse-3.3.tar
pkgadd -d RICHPse
pkgadd -d RICHPse
(OR: gunzip RICHPse.gz; pkgadd -d . RICHPse )


6. install Orca (or orcallator.se on clients)
7. Install Orca
extract the Orca compressed package e.g., to /opt
Extract the Orca compressed package e.g., to /tmp
NOTE: it may be a good idea to install orcallator somewhere else apart
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.
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
gunzip orca-snapshot-r535.tar.gz
tar -xvf orca-snapshot-r535.tar
tar -xf orca-snapshot-r535.tar
cd orca-snapshot-r535
cd orca-snapshot-r535


=== Solaris 10 NOTE ==============================================
# The next 2 steps only applies to Solaris 10
 
8. Edit file: orca-snapshot-r535/packages/rrdtool-1.0.50/perl-shared/Makefile


IN FILE: orca-snapshot-r535/packages/rrdtool-1.0.50/perl-shared/Makefile
a. change the line
CCCDLFLAGS = -KPIC
To:
CCCDLFLAGS =


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


c. change the line
OPTIMIZE = -xO3 -xspace -xildoff
To:
OPTIMIZE =


3. change the line "OPTIMIZE = -xO3 -xspace -xildoff" to "OPTIMIZE ="
9. Edit file: orca-snapshot-r535/packages/Storable-2.15/Makefile
 
 
IN FILE: orca-snapshot-r535/packages/Storable-2.15/Makefile


1. change the line "CCCDLFLAGS = -KPIC" to "CCCDLFLAGS ="
a. change the line
CCCDLFLAGS = -KPIC
To:
CCCDLFLAGS =


2. change the line
b. change the line
CCFLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -xarch=v8 -D_TS_ERRNO
CCFLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -xarch=v8 -D_TS_ERRNO
 
To:
TO:
CCFLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_TS_ERRNO
CCFLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_TS_ERRNO


c. change the line
OPTIMIZE = -xO3 -xspace -xildoff
To:
OPTIMIZE =


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


# if you are reinstalling, remember to delete the existing orca folder or else the new installation will not succeed e.g.,
rm -rf /usr/local/var/orca


=== END OF Solaris 10 NOTE ==============================
# "make" fails when using the default perl installation as it (perl) expects to use the cc compiler, so
 
 
# 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
 
# make fails because the default perl expects to use the cc compiler, so
# create a soft link to the gcc compiler i.e.,
# create a soft link to the gcc compiler i.e.,
cd /usr/local/bin
cd /usr/local/bin
ln -s gcc cc
ln -s gcc cc


# make fails because it couldn't locate perl pod2man executable, so find it and add to PATH
# "make" fails because it couldn't locate perl pod2man executable, so find it and add to PATH variable
# variable
find /usr | grep pod2man
bash-3.00# find /usr | grep pod2man
/usr/perl5/5.6.1/bin/pod2man
/usr/perl5/5.6.1/bin/pod2man
/usr/perl5/5.6.1/man/man1/pod2man.1
/usr/perl5/5.6.1/man/man1/pod2man.1
Line 106: Line 101:
export PATH=$PATH:/usr/perl5/5.8.4/bin
export PATH=$PATH:/usr/perl5/5.8.4/bin


# go back to the extracted installation source folder
pwd
orca-snapshot-r535


bash-3.00# cd ..
# run the configure script
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
./configure --with-html-dir=/var/apache2/htdocs/orca --with-ncsa-log=/var/apache2/logs/access_log


make; make install; make orcallator_run_at_boot
# install orca
make
make install
make orcallator_run_at_boot


 
# NOTE: orca doesn't start on solaris 10 after the installation process above
============ orca doesn't start on solaris 10 ============================
# The Reason: 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
Because the following statement in the orcallator startup script is used
# orcalltor, orcallator does not start
to derive part of the name of the PATH to some of the files needed by
# "/opt/RICHPse/bin/se -version | awk '{print $4}'"
orcalltor, orcallator does not start
# the command above returns 3.4.1 which is the used to
"/opt/RICHPse/bin/se -version | awk '{print $4}'"
# generate the PATH /usr/local/lib/SE/3.4.1 which does not exist.
the reason is that the command above returns 3.4.1 which is the used to
# The actual path on the server is /usr/local/lib/SE/3.4
generate the PATH /usr/local/lib/SE/3.4.1 which does not exist.
# The solution is to create a soft link as below.
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
cd /usr/local/lib/SE
ln -s 3.4 3.4.1
ln -s 3.4 3.4.1


============ orca doesn't start on solaris 10 ============================
# start the orcallator
 
 
start the orcallator
/etc/init.d/orcallator start
/etc/init.d/orcallator start


 
# This is only needed on the central server
mkdir -p /var/apache2/htdocs/orca/orcallator
mkdir -p /var/apache2/htdocs/orca/orcallator


# Final words: for security reasons, you may prefer to install gcc 3.4.6 and make 3.80, finish compiling
# and installing orca and anything else that requires gcc in order to successfully install, then uninstall gcc
# and make 3.80. Finally, install only the libgcc so that does applications that require the library will work properly


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 rest ONLY applies to the central server
#
# 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
# The commands below are ONLY needed on the server
/usr/local/bin/orca -v /usr/local/lib/orcallator.cfg
/usr/local/bin/orca -v /usr/local/lib/orcallator.cfg


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


then restart orca as a daemon i.e.,
# then restart orca as a daemon i.e.,
/usr/local/bin/orca -d /usr/local/lib/orcallator.cfg
/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.


You are adviced to create an auto-start script in /etc/init.d and /etc/rc2.d
Ayotunde Itayemi (Last updated 22/05/2008)
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!)

Latest revision as of 09:16, 22 May 2008

  1. This "How To" is probably just one way to setup the server, but it works.
  2. The procedure to set up a central repository server or a client on which statistics is to be collected in similar.
  3. The extra steps to be performed for a server install are indicated where necessary.
  4. All the extra software used were downloaded from sunfreeware.com (similar packages from blastwave.org were not tested but should also work)
  5. 1. make 3.80
  6. 2. gcc 3.4.6
  7. 3. libgcc 3.4.6 (don't install until you read security comment below)
  8. 4. libiconv 1.11
  9. 5. orca-snapshot-r535 (http://www.orcaware.com)
  10. 6. RICHPse (ftp://ftp.sunfreeware.com/pub/freeware/SOURCES/RICHPse.gz, http://www.sunfreeware.com/setoolkit.html)
  11. Quick: if you need to install Apache2 from scratch on the central repository server, here is a list of packages you will likely need:
  12. make, expat, db-4, apr, aprutil, openssl, libiconv, gdbm, gcc (if not installed), apache2 (of course!)
  13. You can get all the packages above from sunfreeware.com.

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)

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. Install libiconv (only if using the GNU gcc from sunfreeware for example)

5. For a server install, the package SUNWsprot must be installed (usually installed by default)

6. Install SE Toolkit (version 3.4 at least for Solaris 10)

gunzip RICHPse.gz pkgadd -d . RICHPse

Alternatively, if using the RICHPse-3.3.tar.gz package, then use the following commands instead: gunzip RICHPse-3.3.tar.gz tar -xvf RICHPse-3.3.tar pkgadd -d RICHPse

7. Install Orca Extract the Orca compressed package e.g., to /tmp 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 -xf orca-snapshot-r535.tar cd orca-snapshot-r535

  1. The next 2 steps only applies to Solaris 10

8. Edit file: orca-snapshot-r535/packages/rrdtool-1.0.50/perl-shared/Makefile

a. change the line CCCDLFLAGS = -KPIC To: CCCDLFLAGS =

b. 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

c. change the line OPTIMIZE = -xO3 -xspace -xildoff To: OPTIMIZE =

9. Edit file: orca-snapshot-r535/packages/Storable-2.15/Makefile

a. change the line CCCDLFLAGS = -KPIC To: CCCDLFLAGS =

b. 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

c. change the line OPTIMIZE = -xO3 -xspace -xildoff To: OPTIMIZE =


  1. if you are reinstalling, remember to delete the existing orca folder or else the new installation will not succeed e.g.,

rm -rf /usr/local/var/orca

  1. "make" fails when using the default perl installation as it (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 variable

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

  1. go back to the extracted installation source folder

pwd orca-snapshot-r535

  1. run the configure script

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

  1. install orca

make make install make orcallator_run_at_boot

  1. NOTE: orca doesn't start on solaris 10 after the installation process above
  2. The Reason: the following statement in the orcallator startup script is used
  3. to derive part of the name of the PATH to some of the files needed by
  4. orcalltor, orcallator does not start
  5. "/opt/RICHPse/bin/se -version | awk '{print $4}'"
  6. the command above returns 3.4.1 which is the used to
  7. generate the PATH /usr/local/lib/SE/3.4.1 which does not exist.
  8. The actual path on the server is /usr/local/lib/SE/3.4
  9. The solution is to create a soft link as below.

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

  1. start the orcallator

/etc/init.d/orcallator start

  1. This is only needed on the central server

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

  1. Final words: for security reasons, you may prefer to install gcc 3.4.6 and make 3.80, finish compiling
  2. and installing orca and anything else that requires gcc in order to successfully install, then uninstall gcc
  3. and make 3.80. Finally, install only the libgcc so that does applications that require the library will work properly


  1. The rest ONLY applies to the central server
  2. DO THIS ONLY if using GNU perl (e.g., from sunfreeware.com)
  3. Edit the file /usr/local/bin/orca and change the first line to use the new perl installation i.e.,
  4. the line changes from #!/usr/bin/perl TO: #!/usr/local/bin/perl
  1. The commands below are ONLY needed on the server

/usr/local/bin/orca -v /usr/local/lib/orcallator.cfg

  1. Once it starts up successfully without errors and completes the first run,
  2. kill the process (find it's pid with "ps -ef | grep orca")
  1. then restart orca as a daemon i.e.,

/usr/local/bin/orca -d /usr/local/lib/orcallator.cfg

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

Ayotunde Itayemi (Last updated 22/05/2008)