GT4

 

第一章支持软件的安装

假设该文件放在/home/globus/

当前目录为/home/globus

. j2sdk-1_4_2_08-linux-i586.bin

以下操作以root帐号执行

1 首先确保有执行该文件的权限

chmod +x j2sdk-1_4_2_08-linux-i586.bin


2 将该文件拷到/usr/local并更改目录到/usr/local

cp j2sdk-1_4_2_08-linux-i586.bin /usr/local

cd /usr/local


3 ./j2sdk-1_4_2_08-linux-i586.bin

会出现协议书类的一直回车直到显示

Do you agree to the above license terms? [yes or no]

输入y,会自动安装在/usr/local/j2sdk1.4.2_08目录下

apache-ant-1.6.0-src.tar.gz

以下命令以root帐号执行

1 将该文件拷到/usr/local并更改目录到/usr/local

cp apache-ant-1.6.0-bin.tar.gz /usr/local

cd /usr/local


2 安装,解压到/usr/local

tar zxpvf apache-ant-1.6.0-bin.tar.gz

ln -s apache-ant-1.6.0 ant

postgresql-8.0.3.tar.gz

先以下命令以root帐号执行

1 设计人员为了安全考虑,PostgreSQL 不能以 root 用户运行,所以必须建立对应的用户和组:

useradd postgres

mkdir /usr/local/pgsql

chown postgres:postgres /usr/local/pgsql

mkdir /usr/local/src

mkdir /usr/local/src/pgsql

chown postgres:postgres /usr/local/src/pgsql

2 解压到 /usr/local/srcpostgres帐号

su postgres

tar xvfz postgresql-8.0.3.tar.gz

cd postgresql-8.0.3

./configure --prefix=/usr/local/pgsql

make

make install

3 这样安装完毕后,并不是万事大吉了,还有一些收尾工作要做:

打开配置文件, 还是以postgres帐号

cd

vi .bashrc


添加下面的内容:

PATH=$PATH:/usr/local/pgsql/bin

export POSTGRES_HOME=/usr/local/pgsql

export PGLIB=$POSTGRES_HOME/lib

export PGDATA=$POSTGRES_HOME/data

export ANPATH=$MANPTH:$POSTGRES_HOME/man

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PGLIB

存盘退出后执行:

. ./.bashrc


4 启动数据库引擎:默认将环境变量PGDATA指向目录作为数据库目录

initdb -E EUC_CN

指定系统默认字符编码。除GB(EUC_CN) 外,还可以指定为日语

(EUC_JP)、韩语(EUC_KR) 、台湾(EUC_TW) 、UNICODEMULE_INTERNALLATIN1等。

注意,如使用6.3.2版需用--with-template=... 指定操作系统,具体内容见源程序附带的说明文件。

configure如顺利完成,将生成GNUmakefile,Makefile.globalMakefile.port等文件


使用以下命令启动PostgreSQL:

postmaster -S

停止PostgreSQL可以使用下面的命令:

pg_ctl stop

四 统一设置环境变量

vi /etc/profile

在最后添加下面的内容

export ANT_HOME=/usr/local/ant

export JAVA_HOME=/usr/local/j2sdk1.4.2_08

export CLASSPATH="./:JAVA_HOME/lib:JAVA_HOME/jre/lib"

export PATH=$PATH:$JAVA_HOME/bin:JAVA_HOME/jre/bin:$ANT_HOME/bin

输入:wq保存退出后执行

. ./profile

运行java显示相关信息说明安装成功

运行antant -version命令显示相关信息





第二章 GT4安装

1. 首先创建globus帐号用来进行安装操作


2. root帐号创建安装目录/usr/local/globus-4.0.0

mkdir /usr/local/globus-4.0.0

chown globus:globus /usr/local/globus-4.0.0


3. globus帐号开始安装

设置环境变量GLOBUS_LOCATION(一劳永逸的办法)

cd

vi .bashrc

在该文件最后添加:

export GLOBUS_LOCATION=/usr/local/globus-4.0.0

:wq保存退出并执行下面的命令,使其生效:

. ./.bashrc


4. 下面开始安装二进制包,假设该软件放在/home/globus/.

执行下面的命令解压缩,会生成安装目录gt4.0.0-ia32-redhat9-binary-installer

tar zxvf gt4.0.0-ia32-redhat9-binary-installer.tar.gz

cd gt4.0.0-ia32-redhat9-binary-installer

依此执行下面的命令

./configure --prefix=$GLOBUS_LOCATION

make 2>&1 | tee build.log

make install


这样就安装成功,但是还需要进行安全认证及配置。














GT4.0 SimpleCA安装与配置

第一节 前言

本章介绍安装与配置自己的SimpleCA服务器

第二节 Building & Installing

一 创建用户

确保系统上已经有下面两个用户:

1.于运行客户端的用户如zm

2Globus用户,用来执行管理任务,如启动和终止container,部署服务等,也可以用于管理SimpleCA服务器。

二 开始安装

运行下面的命令:

$GLOBUS_LOCATION/setup/globus/setup-simple-ca

1.设置subject name

上面的命令执行后将会提示输入CA相关信息:

The unique subject name for this CA is:

cn=Globus Simple CA, ou=simpleCA-mayed.mcs.anl.gov, ou=GlobusTest, o=Grid

Do you want to keep this as the CA subject (y/n) [y]:

其中:cn表示“common name”,证书名;

ou表示“organizational unit”,本SimpleCA服务器区别于其他服务器的标志,第二个ou表示机器名;

o 表示“organization”,本网格所属的组织名。

输入y表示接受默认的设置,输入n表示自己设置相关信息。


2.提示设置CAemail

Enter the email of the CA (this is the email where certificate

requests will be sent to be signed by the CA):

输入接受认证请求的邮件地址。


3.提示设置有效期

The CA certificate has an expiration date. Keep in mind that

once the CA certificate has expired, all the certificates

signed by that CA become invalid. A CA should regenerate

the CA certificate and start re-issuing ca-setup packages

before the actual CA certificate expires. This can be done

by re-running this setup script. Enter the number of DAYS

the CA certificate should last before it expires.

[default: 5 years (1825 days)]:

输入CA证书的有效期,如果过了有效期需要重新创建证书。


4.提示输入密码

Generating a 1024 bit RSA private key

........++++++

................++++++

writing new private key to '/home/globus/.globus/simpleCA//private/cakey.pem'

Enter PEM pass phrase:

设置签发证书的密码,不能有空格


5.确认生成的证书

A self-signed certificate has been generated

for the Certificate Authority with the subject: /O=Grid/OU=GlobusTest/OU=simpleCA-mayed.mcs.anl.gov/CN=Globus Simple CA

If this is invalid, rerun this script

setup/globus/setup-simple-ca

and enter the appropriate fields. -------------------------------------------------------------------

The private key of the CA is stored in /home/globus/.globus/simpleCA//private/cak ey.pem

The public CA certificate is stored in /home/globus/.globus/simpleCA//cacert.pem

The distribution package built for this CA is stored in /home/globus/.globus/simpleCA//globus_simple_ca_68ea3306_setup-0.17.tar.gz

这个信息对于在自己建立的网格中其他机器的安装非常重要。最后一行中68ea3306这个数字表示CA hash

输入任意键,继续安装,直到显现下面的内容。

*************************************************************************** Note: To complete setup of the GSI software you need to run the

following script as root to configure your security configuration

directory:

/opt/gt4/setup/globus_simple_ca_68ea3306_setup/setup-gsi

For further information on using the setup-gsi script, use the -help

option. The -default option sets this security configuration to be

the default, and -nonroot can be used on systems where root access is

not available. *************************************************************************** setup-ssl-utils: Complete

接下来运行setup-gsi命令。



6.完成安装GSI (网格安全基础设施(GSI,Grid Security Infrastructure))

下面以root运行下面的内容:(source $GLOBUS_LOCATION/etc/globus-user-env.sh)

$GLOBUS_LOCATION/setup/globus_simple_ca_CA_Hash_setup/setup-gsi -default

接下来将显示下面的内容:

setup-gsi: Configuring GSI security Installing /etc/grid-security/certificates//grid-security.conf.CA_Hash...

Running grid-security-config...

Installing Globus CA certificate into trusted CA certificate directory...

Installing Globus CA signing policy into trusted CA certificate directory...

setup-gsi: Complete





host证书

要运行服务程序必须申请并签发host证书,并将其拷贝到适当的目录下。申请之前,必须设置机器名。这里设机器名为:betty

1.以root用户执行:

grid-cert-request –host betty

这个命令将创建下面的文件:

/etc/grid-security/hostkey.pem

/etc/grid-security/hostcert_request.pem

/etc/grid-security/hostcert.pem(这是一个空文件)

如果使用自己的CA服务器,下面将介绍如何创建hostcert,并将其放回/etc/grid-security/

2.签发host证书

在安装CA服务器的机器上,以globus身份执行:

grid-ca-sign –in hostcert_request.pem –out hostsigned.pem

提示输入密码时输入第二部分4设置的CA服务器密码。

签发的证书hostsigned.pem将在当前目录下生成。

root身份将该证书move/etc/grid-security/hostcert.pem

user证书

用户也需要申请用户证书。我的机器上添加了zm用户。

1.以zm身份执行下面的命令:

grid-cert-request

提示输入密码后,将创建下面的文件:

~$USER/.globus/usercert.pem(空文件)

~$USER/.globus/userkey.pem

~$USER/.globus/usercert_request.pem

usercert_request.pem发给SimpleCA服务器的管理员等待认证,这里因为在本机上安装了自己的CA服务器,可以在本机上进行认证。


2.在CA服务器上,以globus身份执行下面的命令:

grid-ca-sign –in usercert_request.pem –out signed.pem

提示输入密码时输入第二部分4设置的CA服务器密码。

将得到的signed.pem拷贝到上面提到的/home/zm/.globus/usercert.pem

第三节 为多个机器配置SimpleCA

到此为止,我们已经在一台机器上安装了SimpleCA。第二节中第二部分5中生成了globus_simple_ca_68ea3306_setup-0.17.tar.gz文件。如果希望在其他机器B上使用刚申请的证书就必须在该机器上安装这个CA安装包。

首先将这个CA安装包拷贝到机器B上,执行下面的命令:

$GLOBUS_LOCATION/sbin/gpt-build globus_simple_ca_HASH_setup-0.17.tar.gz gcc32dbg


然后执行第二节第二部分6执行的命令:setup-gsi –default.

如果要第二个host上运行services,需要进行本节介绍的相关配置,并配置grid-mapfile文件(后面将会详细介绍)。

第四节 测试

为了确定host证书的有效性,执行下面的命令:

grid-proxy-init –debug -verify

输入密码后,输出下面的信息表示成功:

[bacon@mayed schedulers]$ grid-proxy-init -debug -verify

User Cert File: /home/user/.globus/usercert.pem

User Key File: /home/user/.globus/userkey.pem

Trusted CA Cert Dir: /etc/grid-security/certificates

Output File: /tmp/x509up_u1817

Your identity: /O=Grid/OU=GlobusTest/OU=simpleCA-mayed.mcs.anl.gov/OU=mcs.anl.gov/CN=User Name

Enter GRID pass phrase for this identity:

Creating proxy ..............................++++++++++++

...............++++++++++++

Done

Proxy Verify OK

Your proxy is valid until: Sat Mar 20 03:01:46 2004


第五节 基本的安全配置

一 设置环境变量

1.以globus身份将GLOBUS_LOCATION环境变量设置为安装GT4.0的目录。(指南一中已经设置)

2.执行下面的命令配置环境:

$GLOBUS_LOCATION/etc/gloubs-user-env.sh









评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值