Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

[SSI] openssi install,NONE,1.1: msg#00272

Subject: [SSI] openssi install,NONE,1.1
Update of /cvsroot/ssic-linux/openssi
In directory sc8-pr-cvs1:/tmp/cvs-serv19460

Added Files:
        install 
Log Message:
Installation script for RPM release


--- NEW FILE: install ---
#!/bin/bash
#
# Date   :     Jul 30 2003
# Authors:     Brian Watson <Brian.J.Watson>
#
#      This program is free software; you can redistribute it and/or
#      modify it under the terms of the GNU General Public License as
#      published by the Free Software Foundation; either version 2 of
#      the License, or (at your option) any later version.
#
#      This program is distributed in the hope that it will be useful,
#      but WITHOUT ANY WARRANTY; without even the implied warranty of
#      MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE
#      or NON INFRINGEMENT.  See the GNU General Public License for more
#      details.
#

if [ $UID -ne 0 ]; then
        echo "This script must be run as root"
        exit 1
fi

# required packages
REQS="  dhcp            \
        nasm            \
        perl            \
        tftp-server     \
        "

# packages to install
PKGS="  cluster-tools   \
        chkconfig       \
        devfsd          \
        e2fsprogs       \
        initscripts     \
        mknbi           \
        mount           \
        nfs-utils       \
        SysVinit        \
        openssi-tools   \
        kernel-ssi      \
        "


#
# Check what packages are installed
#

for pkg in $REQS; do
        rpm -q $pkg >/dev/null
        if [ $? -ne 0 ]; then
                echo "Please install $pkg from your Red Hat CDs and
"                       " try running this script again."
                exit 1
        fi
done

UPGRADE=0
rpm -q kernel-ssi >/dev/null 2>&1
if [ $? -eq 0 ]; then
        UPGRADE=1
fi

INSTALL=''
for pkg in $PKGS; do
        path=`ls --color=no RPMS/$pkg*.rpm 2>/dev/null | sort -u | tail -1`
        if [ -z "$path" ]; then
                echo "Missing package: $path"
                exit 1
        fi

        NAME=`rpm -qp --qf '%{NAME}' $path`
        NEWVER=`rpm -qp --qf '%{VERSION}' $path`
        NEWREL=`rpm -qp --qf '%{RELEASE}' $path`
        CURVER=`rpm -q --qf '%{VERSION}' $NAME 2>/dev/null`
        CURREL=`rpm -q --qf '%{RELEASE}' $NAME 2>/dev/null`
        if [ $? -eq 0 ]; then
                if [[ $NEWVER < $CURVER ]]; then
                        continue
                fi
                if [[ $NEWVER == $CURVER && ! ( $NEWREL > $CURREL ) ]]; then
                        continue
                fi
        fi
        INSTALL="$INSTALL $path"
done


#
# XXX: we should ask configuration questions before installing packages
#


#
# Install new packages
#

for pkg in $INSTALL; do
        rpm -Uhv $pkg
done
echo "All packages have been installed/updated."


#
# Configure cluster
#

if [ -f /etc/clustertab ]; then
        echo "This cluster appears to have been previously configured."
        exit 0
fi

echo -n "What node number do you want to use for this node? [1]: "
NODENUM=`head -1 -`
if [ -z "$NODENUM" ]; then
        NODENUM=1
fi

/usr/sbin/openssi_cluster_create --nodenum=$NODENUM




-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
ide.eclipse.wtp...    bug-tracking.ro...    xfree86.cvs/200...    lisp.wxcl.devel...    file-systems.ar...    kde.devel.kwrit...    jakarta.jetspee...    qnx.openqnx.dev...    drivers.openib/...    ports.xbox.deve...    gis.gdal.devel/...    netbsd.ports.ma...    ubuntu.marketin...    systemtap/2005-...    web.omniweb/200...    mail.qmail.ldap...    hardware.soekri...    os.netbsd.devel...    audio.madman.ge...    tv.freeguide-tv...    cluster.openmos...    education.ezpro...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe

Navigation