Toolpack prerequisite FedoraCore12 2-5

From TBwiki
Revision as of 13:36, 16 June 2010 by Atremblay (Talk | contribs)
Jump to: navigation, search

This page shows the Toolpack 2-4 and 2-5 prerequisites for Fedora Core 12.

Contents

Toolpack Prerequisites

Toolpack Basic packages

The software listed below is required by the host machines.

yum install gcc zlib-devel

This prerequisite list contains special packages for ruby, ruby-devel and rubygems. Make sure they are NOT installed:

yum remove ruby ruby-devel rubygems

Toolpack System Database

The Toolpack system database is used by the main host and requires mySQL database server. The system database packages are as follows:

yum install mysql-server mysql-devel

1. Start and enable mysql.

/sbin/chkconfig mysqld on
/sbin/service mysqld start

2. Setup initial database root password (replace [RootPassword] by a password of your choice). [YourHostName] corresponds to the machine's hostname.

/usr/bin/mysqladmin -u root password [RootPassword]
/usr/bin/mysqladmin -u root -p[RootPassword] -h [YourHostName] password [RootPassword]

IMPORTANT: Please read the 'Securing the Initial MySQL Accounts' article to learn how to manage users and privileges.

3. Install the database.

mysql_install_db

4. Log onto mysql, create a tbdb user. The [DatabaseUsername] and [DatabasePassword] will need to be supplied to the toolpack installer. If you cannot log in it is possible that the host name is not configured properly, use an IP Address instead.

mysql -u root -p[RootPassword]
CREATE USER '[DatabaseUsername]'@'%' IDENTIFIED BY '[DatabasePassword]';
GRANT ALL PRIVILEGES ON *.* TO '[DatabaseUsername]'@'%';
CREATE USER '[DatabaseUsername]'@'localhost' IDENTIFIED BY '[DatabasePassword]';
GRANT ALL PRIVILEGES ON *.* TO '[DatabaseUsername]'@'localhost';
FLUSH PRIVILEGES;
exit

ex.

mysql -u root -p[RootPassword]
CREATE USER 'tbdb'@'%' IDENTIFIED BY 'tbdbpw';
GRANT ALL PRIVILEGES ON *.* TO 'tbdb'@'%';
CREATE USER 'tbdb'@'localhost' IDENTIFIED BY 'tbdbpw';
GRANT ALL PRIVILEGES ON *.* TO 'tbdb'@'localhost';
FLUSH PRIVILEGES;
exit

The second user is added to mask the local anonymous account. If it has been removed, you do not have to add the 'tbdb@localhost' user. Please read 'Adding User Accounts' to learn more about this issue.

To verify if the user is created:

mysql -u root 
SELECT * FROM mysql.user;
exit

5.Install odbc driver and driver manager

yum install unixODBC mysql-connector-odbc

6. Configure mysql to support database replication (Will not interfere if your system do not use it).

vim /etc/my.cnf

Add 2 new variable in the mysql config file

Add log-bin and server-id. The value of server-id needs to be unique on each host( do not use 0 ).

Make sure it is in the [mysqld] section

log-bin
server-id=[UniqueId]

Example:

[root@FEDORACORE12 tblab]# cat /etc/my.cnf
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
log-bin
server-id=1
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1

[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
[root@FEDORACORE12 tblab]#

Restart the mysql service

/sbin/service mysqld restart

Toolpack System Web Portal

The Toolpack System Web Portal is required in order to host the Toolpack Web Portal. It requires the execution of all following commands:

1. Install fcgi:

yum install fcgi fcgi-devel

2. Make sure pcre, libxml2 and openssl-devel are installed:

yum install pcre libxml2 openssl-devel

3. Install lighttpd and lighttpd-fastcgi:

yum install lighttpd lighttpd-fastcgi

4. Install ruby

4a. For 32 bits system:

wget http://download.distribution.telcobridges.com/3rdparty/prerequisite/src/fc12/ruby-1.8.7-p249-with-openssl-1.0.0.tar.gz
tar -zxf ruby-1.8.7-p249-with-openssl-1.0.0.tar.gz
cd ruby-1.8.7-p249
./configure --libdir=/usr/local/lib  --enable-shared
make
make install
cd ../../..
ln -s /usr/local/bin/ruby /usr/bin/ruby
ln -s /usr/local/lib/libruby.so.1.8 /lib/libruby.so.1.8

4b. For 64 bits system:

wget http://download.distribution.telcobridges.com/3rdparty/prerequisite/src/fc12/ruby-1.8.7-p249-with-openssl-1.0.0.tar.gz
tar -zxf ruby-1.8.7-p249-with-openssl-1.0.0.tar.gz
cd ruby-1.8.7-p249
./configure --libdir=/usr/local/lib64 --enable-shared
make
make install
cd ../../..
ln -s /usr/local/bin/ruby /usr/bin/ruby
ln -s /usr/local/lib64/libruby.so.1.8 /lib64/libruby.so.1.8

5. Install rubygems

wget http://download.distribution.telcobridges.com/3rdparty/prerequisite/src/fc12/rubygems-1.3.5.tgz
tar -zxf rubygems-1.3.5.tgz
cd rubygems-1.3.5
ruby setup.rb
cd ..

6. Install gem fcgi

/usr/local/bin/gem install fcgi

Make sure that the firewall enables these following services and ports. Failure to open those ports will render socket communication between the distributed software elements unavailable.

Service: http (12358/tcp)
Port: All ports (tcp/udp) enabled for local networks 

Disabling SELinux

Check SELinux status

sestatus

If SELinux is enabled, see the Disabling SELinux article to disable it.

Toolpack Stream Server

The Tmedia Toolpack Stream Server requires the execution of the following commands:

yum install libpcap

Toolpack Development Prerequisite

The Toolpack System Development prerequisite section is only required for customers that will develop their own application using the Toolpack API:

yum install gcc-c++ libxml2-devel libpcap-devel unixODBC-devel

Validation Guide (Optional)

If you would like to verify your installation go to the Toolpack Validation Guide

Toolpack System installation

Now that the prerequisite are installed, now it is time to install the Toolpack system

Personal tools