Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1833618
  • 博文数量: 286
  • 博客积分: 3713
  • 博客等级: 少校
  • 技术积分: 2275
  • 用 户 组: 普通用户
  • 注册时间: 2012-01-11 09:47
个人简介

http://blog.chinaunix.net/uid/16979052.html

文章分类

全部博文(286)

文章存档

2018年(1)

2017年(16)

2016年(9)

2015年(17)

2014年(15)

2013年(112)

2012年(116)

分类: 架构设计与优化

2013-04-08 07:35:09

原文地址:linux下安装tuxedo 作者:Junn9527

1、建用户及目录
campost:/ # groupadd tuxedo
campost:/ # useradd tuxedo -g tuxedo
campost:/ # passwd tuxedo
campost:/ # mkdir /home/tuxedo
campost:/ # chown tuxedo:tuxedo /home/tuxedo
campost:/ # mkdir /opt/tuxedo
campost:/ # chown tuxedo:tuxedo /opt/tuxedo
2、安装
campost:/home/tuxedo # ./tuxedo111130_64_Linux_01_x86.bin -i console
Preparing to install...
Extracting the JRE from the installer archive...
Unpacking the JRE...
Extracting the installation resources from the installer archive...
Configuring the installer for this system's environment...
Launching installer...
Preparing CONSOLE Mode Installation...
===============================================================================
Choose Locale...
----------------
    1- English
CHOOSE LOCALE BY NUMBER: 1
===============================================================================
Tuxedo 11.1.1.3.0                 (created with InstallAnywhere by Macrovision)
-------------------------------------------------------------------------------
===============================================================================
Introduction
------------
InstallAnywhere will guide you through the Tuxedo 11.1.1.3.0 installation.
It is strongly recommended that you quit all programs before continuing with this installation.
Enter "next' to proceed to the next screen. Enter "back" to modify the previousscreen.
You may cancel this installation at any time by typing "quit".

WARNING: "Quitting" creates an incomplete  Tuxedo 11.1.1.3.0 installation.You
must re-install  Tuxedo 11.1.1.3.0. For more information, see "Preparing to
Install the Oracle Tuxedo System" in the  Tuxedo 11.1.1.3.0 Installation Guide.

PRESS TO CONTINUE:
===============================================================================

Choose Install Set
------------------
Please choose the Install Set to be installed by this installer.
  ->1- Full Install
    2- Server Install
    3- Full Client Install
    4- Jolt Client Install
    5- ATMI Client Install
    6- CORBA Client Install
    7- Customize...

ENTER THE NUMBER FOR THE INSTALL SET, OR PRESS TO ACCEPT THE DEFAULT
   : 1

===============================================================================
Choose Oracle Home
------------------
    1- Create new Oracle Home
Enter a number: 1
Specify a new Oracle Home directory: /opt/tuxedo

===============================================================================
Choose Product Directory
------------------------
    1- Modify Current Selection (/opt/tuxedo/tuxedo11gR1)
    2- Use Current Selection (/opt/tuxedo/tuxedo11gR1)
Enter a number: 2
Install Samples (Y/N): y

===============================================================================
Pre-Installation Summary
------------------------
Please Review the Following Before Continuing:
Product Name:
    Tuxedo 11.1.1.3.0
Install Folder:
    /opt/tuxedo/tuxedo11gR1
Link Folder:
    /root
Required Space:
    187 MB
Available Space:
    29631 MB

PRESS TO CONTINUE:

===============================================================================
Ready To Install
----------------
InstallAnywhere is now ready to install Tuxedo 11.1.1.3.0 onto your system at the following location:
   /opt/tuxedo/tuxedo11gR1

PRESS TO INSTALL:
===============================================================================
Installing...
-------------
 [==================|==================|==================|==================]
 [------------------|------------------|------------------|------------------]

===============================================================================
Configure tlisten Service
-------------------------
Password:      
Verify Password:      
Password Accepted! Please wait...

===============================================================================
SSL Installation Choice.
------------------------
Would you like to install SSL Support?

  ->1- Yes
    2- No

ENTER THE NUMBER FOR YOUR CHOICE, OR PRESS TO ACCEPT THE DEFAULT:
   : 2

==============================================================================
Installation Complete
---------------------
Congratulations. Tuxedo 11.1.1.3.0 has been successfully installed to:
   /opt/tuxedo/tuxedo11gR1

PRESS TO EXIT THE INSTALLER:
安装说明:
(1)安装使用root和tuxedo用户都可以,实际上,不建tuxedo用户也可以,只是为了使用tuxedo用户操作才创建了tuxedo;
   而oracle数据库必须需要使用oracle用户安装,PostgreSQL数据库必须使用root用户安装。
(2)安装之后,把安装目录直接拷贝到另一台机器即可直接使用tuxedo,例如上面安装的/opt/tuxedo/tuxedo11gR1;
   windows下的安装软件一般情况下是不可以这样做的
3、部署例子
安装完成后,/opt/tuxedo/tuxedo11gR1/samples目录下为例子,/opt/tuxedo/tuxedo11gR1/samples/atmi为atmi例子,以下使用最简单的例子:simpapp。
为了部署该例子,可以在/opt/tuxedo/tuxedo11gR1/samples/atmi/simpapp下进行配置,配置tux.env和ubbsimple;
也可以把simpapp拷贝到tuxedo的home目录/home/tuxedo下进行配置,我使用第二种。
配置步骤如下图:

(1)配置应用的环境变量
可以在tux.env中配置(临时环境变量):
> cat tux.env
TUXDIR=/opt/tuxedo/tuxedo11gR1; export TUXDIR
JAVA_HOME=$TUXDIR/jre; export JAVA_HOME
JVMLIBS=$JAVA_HOME/lib/amd64/server:$JAVA_HOME/jre/bin
PATH=$TUXDIR/bin:$JAVA_HOME/bin:$PATH; export PATH
COBCPY=:$TUXDIR/cobinclude; export COBCPY
COBOPT="-C ANS85 -C ALIGN=8 -C NOIBMCOMP -C TRUNC=ANSI -C OSEXT=cbl"; export COBOPT
SHLIB_PATH=$TUXDIR/lib:$JVMLIBS:$SHLIB_PATH; export SHLIB_PATH
LIBPATH=$TUXDIR/lib:$JVMLIBS:$LIBPATH; export LIBPATH
LD_LIBRARY_PATH=$TUXDIR/lib:$JVMLIBS:$LD_LIBRARY_PATH; export LD_LIBRARY_PATH
WEBJAVADIR=$TUXDIR/udataobj/webgui/java; export WEBJAVADIR
LANG=C; export LANG
APPDIR=/home/tuxedo/simpapp; export APPDIR
TUXCONFIG=/home/tuxedo/simpapp/tuxconfig; export TUXCONFIG
里面的环境变量有些不是必须的,例如SHLIB_PATH用于HP-UX,LIBPATH用于IBM AIX,而LD_LIBRARY_PATH用于linux。
配置完之后执行:
> . ./tux.env
也可以在tuxedo用户的.profile中添加以上环境变量,是它们在进入tuxedo时自动生效
(2)配置ubbconfig,编译程序
先修改文本形式的ubbconfig:
vi ubbsimpapp
仅修改以下几个地方即可:
*RESOURCES
IPCKEY          123456
*MACHINES
DEFAULT:
                APPDIR="/home/tuxedo/simpapp"
                TUXCONFIG="/home/tuxedo/simpapp/tuxconfig"
                TUXDIR="/opt/tuxedo/tuxedo11gR1"
campost         LMID=simple
tuxedo需要二进制形式的ubbconfig,需要使用tmloadcf得到二进制的ubbconfig:
> tmloadcf -y ubbsimple
可以使用tmunloadcf命令从二进制形式的ubbconfig得到文本形式的ubbconfig。
编译服务端程序:
> buildserver -o simpserv -f simpserv.c -s TOUPPER
服务端程序及服务名不能任意命名,因为在配置文件中有配置。
编译客户端程序:
> buildserver -o simpserv -f simpserv.c -s TOUPPER
客户端可执行程序可任意命名。
(3)启动tuxedo应用,运行程序
> tmboot -y
Booting all admin and server processes in /home/tuxedo/simpapp/tuxconfig
INFO: Oracle Tuxedo, Version 11.1.1.3.0, 64-bit, Patch Level (none)
Booting admin processes ...
exec BBL -A :
        process id=22679 ... Started.
Booting server processes ...
exec simpserv -A :
        process id=22680 ... Started.
2 processes started.
> ./client "Hello, world"
Returned string is: HELLO, WORLD
4、常见错误处理
 就是两个配置文件(环境变量和ubb)一个日志(ULOG),问百度不行的话就问google大叔。
(1)执行tmadmin命令,出现如下错误
> tmadmin
tmadmin - Copyright (c) 1996-2010 Oracle.
Portions * Copyright 1986-1997 RSA Data Security, Inc.
All Rights Reserved.
Distributed under license by Oracle.
Tuxedo is a registered trademark.
NLS:4: Cannot open message catalog TMADMIN_CAT, set 1, num 188; check TUXDIR=/opt/tuxedo/tuxedo11gR1, LANG=zh_CN.GB2312
解决办法:
设置如下环境变量:export LANG=C
(2)执行tmboot -y,出现如下错误
> tmboot -y
Booting all admin and server processes in /home/tuxedo/simpapp/tuxconfig
INFO: Oracle Tuxedo, Version 11.1.1.3.0, 64-bit, Patch Level (none)
Booting admin processes ...
exec BBL -A :
        Failed.
tmboot: WARN: No BBL available on site simple.
        Will not attempt to boot server processes on that site.
Booting server processes ...
0 processes started.
解决办法:
> tmadmin
tmadmin - Copyright (c) 1996-2010 Oracle.
Portions * Copyright 1986-1997 RSA Data Security, Inc.
All Rights Reserved.
Distributed under license by Oracle.
Tuxedo is a registered trademark.
No bulletin board exists. Entering boot mode.
> crdl -b 500 -z /home/tuxedo/simpapp/TLOG
Device created: /home/tuxedo/simpapp/TLOG
也可能是配置文件错误:
我的就是: TUXDIR="/opt/tuxedo/tuxedo11gR1"写成了TUXDIR="/opt/tuxedo"

阅读(9227) | 评论(1) | 转发(0) |
给主人留下些什么吧!~~

wuqixiufen22014-06-18 17:30:34

编译客户端程序:
tuxedo@campost:~/simpapp> buildserver -o simpserv -f simpserv.c -s TOUPPER  这个应该修改成

编译客户端程序:
tuxedo@campost:~/simpapp> buildclient -o simpcl -f simpcl.c