读书人

Linux停的WebLogic安装部署

发布时间: 2012-06-28 15:20:03 作者: rapoo

Linux下的WebLogic安装部署

Input new *User password: OR [Exit][Reset][Accept]> [输入八位密码]??


Configure Administrative Username and Password:
--------------------

Create a user automatically assigned to the Administrative Role. This user is the default administrator used to start development mode
servers.


? ? |? ?? ?? ? Name? ?? ?? ???|? ?? ?? ?? ???Value? ?? ?? ?? ???|
? ?_|_________________________|_________________________________|
? ?1|? ?? ? *User name:? ?? ? |? ?? ?? ?? ?weblogic? ?? ?? ?? ? |
? ?2|? ???*User password:? ???|? ?? ?? ?? ? ******? ?? ?? ?? ???|
? ?3| *Confirm user password: |? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?|
? ?4|? ?? ?Description:? ?? ? | The default administration user |

Select Option:
? ? 1 - Modify "User name"
? ? 2 - Modify "User password"
? ? 3 - Modify "Confirm user password"
? ? 4 - Modify "Description"
? ? 5 - Discard Changes

Enter option number to select OR [Exit][Previous][Next]> 3


Configure Administrative Username and Password:
--------------------

Create a user automatically assigned to the Administrative Role. This user is the default administrator used to start development mode
servers.

? ? "*Confirm user password:" = []

Input new *Confirm user password: OR [Exit][Reset][Accept]> [确认八位密码] ///口令必须与上面的一样



Configure Administrative Username and Password:
--------------------

Create a user automatically assigned to the Administrative Role. This user is the default administrator used to start development mode
servers.






? ? |? ?? ?? ? Name? ?? ?? ???|? ?? ?? ?? ???Value? ?? ?? ?? ???|
? ?_|_________________________|_________________________________|
? ?1|? ?? ? *User name:? ?? ? |? ?? ?? ?? ?weblogic? ?? ?? ?? ? |
? ?2|? ???*User password:? ???|? ?? ?? ?? ?********? ?? ?? ?? ? |
? ?3| *Confirm user password: |? ?? ?? ?? ?********? ?? ?? ?? ? |
? ?4|? ?? ?Description:? ?? ? | The default administration user |

Select Option:
? ? 1 - Modify "User name"
? ? 2 - Modify "User password"
? ? 3 - Modify "Confirm user password"
? ? 4 - Modify "Description"
? ? 5 - Discard Changes

Enter option number to select OR [Exit][Previous][Next]> next



Domain Mode Configuration:
--------------------------

Enable Development or Production Mode for this domain.

->1|Development Mode

? ?2|Production Mode

Enter index number to select OR [Exit][Previous][Next]> 2



Java SDK Selection:
-------------------

->1|JRockit SDK 1.4.2_04-8130 @ /home/weblogic/bea/jrockit81sp3_142_04
??2|Sun SDK 1.4.2_04 @ /home/weblogic/bea/jdk142_04
? ?3|Other Java SDK

Enter index number to select OR [Exit][Previous][Next]> 1



Select the target domain directory for this configuration:
----

? ? "Target Location" = [/home/weblogic/bea/user_projects/domains]

Input new Target Location OR [Exit][Previous][Next]> [直接回车]


Edit Domain Information:
------------------------

? ? | Name | Value? ?|
? ?_|________|__________|
? ?1| *Name: | mydomain |

Enter value for "Name" OR [Exit][Previous][Next]> [输入名称或者直接回车]




Creating Domain...

0%? ?? ?? ? 25%? ?? ?? ? 50%? ?? ?? ? 75%? ?? ?? ? 100%
[------------|------------|------------|------------]
[***************************************************]


**** Domain Created Successfully! ****
完成服务的建立!

1.4部署应用
1.4.1启动和关闭
1、如何启动WebLogic
[weblogic@jcms bin]$ cd /var/web/jsp/bea/user_projects/domains/mydomain
[weblogic@jcms bin]$ ./startWebLogic.sh? ? (需要输入用户名密码)

2、如何关闭WebLogic
[weblogic@jcms bin]$ ./stopWebLogic.sh



1.4.2 设置自动启动WebLogic
1、无需输入用户名密码启动关闭weblogic。
以weblogic账户在mydomain目录下,新建boot.properties文件,输入:

password=12345678
username=weblogic

把启动weblogic的用户名密码写进入。

2、修改starWeblogic.sh和stopWeblogic脚本
①startWeblogic.sh
/usr/bin/nohup ${JAVA_HOME}……………… weblogic.Server > /var/web/weblogic.log 2>&1

注意:红色部分为添加的命令。意为将启动脚本放到后台执行,并输出日志。

? ?②stopWeblogic.sh
? ???#!/bin/sh
………………脚本内容………(删除这段脚本,用于身份验证,删除后就无需输入用户名密码)
# set server name

? ?
3、将weblogic的启动关闭作为linux系统服务。
以root账户在/etc/init.d下新建weblogic文件,内容如下:
? ?? ?
? ?? ?? ?? ?#!/bin/sh
# chkconfig: 345 20 80
# description: Weblogic auto start-stop script.

DOMAIN_HOME=/var/web/jsp/user_projects/domains/mydomain
WLS_OWNER=weblogic
? ?? ?? ???
case "$1" in
? ???'start')
? ???su - ${WLS_OWNER} -c "cd ${DOMAIN_HOME}; ./startWebLogic.sh"
? ???;;
? ???'stop')
? ???su - ${WLS_OWNER} -c "cd ${DOMAIN_HOME}; ./stopWebLogic.sh"
? ???;;
Esac

其中DOMAIN_HOME是你创建的用户域的路径。文件配置好后,就可以利用linux的服务来启动和关闭weblogic了。
#service weblogic start

4、随系统自动启动和关闭weblogic
? ?以root用户执行如下命令:


? ?? ?? ?? ?ln -s /etc/init.d/weblogic /etc/rc.d/rc1.d/K80weblogic
ln -s /etc/init.d/weblogic /etc/rc.d/rc2.d/S20weblogic
ln -s /etc/init.d/weblogic /etc/rc.d/rc3.d/S20weblogic
ln -s /etc/init.d/weblogic /etc/rc.d/rc4.d/S20weblogic
ln -s /etc/init.d/weblogic /etc/rc.d/rc5.d/S20weblogic
ln -s /etc/init.d/weblogic /etc/rc.d/rc6.d/K80weblogic

另外,其实我们也可以通过运行setup命令,在system services里面设置weblogic服务是否自动启动。


1.5 常见问题FAQ
A:weblogic无法启动,错误信息包含如下,
? ?

Q:LDAP启动失败,导致的问题可能是用root账户启动了weblogic。检查mydomain目录下myserver/ldap/ldapfiles下的文件权限,是否是weblogic用户组,如果还是无法启动,请删除.tran文件。
A:weblogic无法启动,错误信息包含如下,
? ?? ???

Q:问题是管理域无法与用户域通信。查看linux系统主机名,查看/etc/hosts文件,看是否有如下一行主机记录,如果没有,请将这一行记录加入到/etc/hosts文件中。
127.0.0.1? ? localhost.localdomain? ? localhost

没有这一行记录,就会导致启动失败,一般在安装系统时,设置了主机名、有两块网卡,在设置主机名时,上面的记录就没有了。


本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/6436/showart_476426.html

读书人网 >Web前端

热点推荐