Archive

Archive for the ‘nodemanager’ Category

start the admin server using WLST

January 14th, 2011 tonyxu 2 comments

参考:http://weblogic-wonders.com/weblogic/2011/01/04/remote-administration-of-domain-through-wlst/

To start the admin server using WLST, ensure that the admin server is associated to a machine. Once done, start the WLST tool.

Start the nodemanager using the command startNodeManager() as seen in the image.

直接双击D:\bea\wlserver_10.3\common\bin\wlst.cmd

CLASSPATH=D:\bea\patch_wls1030\profiles\default\sys_manifest_classpath\weblogic_
patch.jar;D:\bea\patch_cie660\profiles\default\sys_manifest_classpath\weblogic_p
atch.jar;D:\bea\JROCKI~1\lib\tools.jar;D:\bea\WLSERV~1.3\server\lib\weblogic_sp.
jar;D:\bea\WLSERV~1.3\server\lib\weblogic.jar;D:\bea\modules\features\weblogic.s
erver.modules_10.3.0.0.jar;D:\bea\WLSERV~1.3\server\lib\webservices.jar;D:\bea\m
odules\ORGAPA~1.5/lib/ant-all.jar;D:\bea\modules\NETSFA~1.0_1/lib/ant-contrib.ja
r;

PATH=D:\bea\patch_wls1030\profiles\default\native;D:\bea\patch_cie660\profiles\d
efault\native;D:\bea\WLSERV~1.3\server\native\win\32;D:\bea\WLSERV~1.3\server\bi
n;D:\bea\modules\ORGAPA~1.5\bin;D:\bea\JROCKI~1\jre\bin;D:\bea\JROCKI~1\bin;C:\W
INDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\Common File
s\Thunder Network\KanKan\Codecs;C:\Program Files\Intel\WiFi\bin\;C:\Program File
s\ThinkPad Wireless LAN Adapter Software;D:\bea\WLSERV~1.3\server\native\win\32\
oci920_8

Your environment has been set.

CLASSPATH=D:\bea\patch_wls1030\profiles\default\sys_manifest_classpath\weblogic_
patch.jar;D:\bea\patch_cie660\profiles\default\sys_manifest_classpath\weblogic_p
atch.jar;D:\bea\JROCKI~1\lib\tools.jar;D:\bea\WLSERV~1.3\server\lib\weblogic_sp.
jar;D:\bea\WLSERV~1.3\server\lib\weblogic.jar;D:\bea\modules\features\weblogic.s
erver.modules_10.3.0.0.jar;D:\bea\WLSERV~1.3\server\lib\webservices.jar;D:\bea\m
odules\ORGAPA~1.5/lib/ant-all.jar;D:\bea\modules\NETSFA~1.0_1/lib/ant-contrib.ja
r;;D:\bea\WLSERV~1.3\common\eval\pointbase\lib\pbembedded57.jar;D:\bea\WLSERV~1.
3\common\eval\pointbase\lib\pbtools57.jar;D:\bea\WLSERV~1.3\common\eval\pointbas
e\lib\pbclient57.jar

Initializing WebLogic Scripting Tool (WLST) …

Welcome to WebLogic Server Administration Scripting Shell

Type help() for help on available commands

wls:/offline> startNodeManager()
Launching NodeManager …
Properties: {}
Command: D:\bea\JROCKI~1\jre\bin\javaw.exe -classpath “D:\bea\JROCKI~1\jre\lib\
rt.jar;D:\bea\JROCKI~1\jre\lib\i18n.jar;D:\bea\patch_wls1030\profiles\default\sy
s_manifest_classpath\weblogic_patch.jar;D:\bea\patch_cie660\profiles\default\sys
_manifest_classpath\weblogic_patch.jar;D:\bea\JROCKI~1\lib\tools.jar;D:\bea\WLSE
RV~1.3\server\lib\weblogic_sp.jar;D:\bea\WLSERV~1.3\server\lib\weblogic.jar;D:\b
ea\modules\features\weblogic.server.modules_10.3.0.0.jar;D:\bea\WLSERV~1.3\serve
r\lib\webservices.jar;D:\bea\modules\ORGAPA~1.5\lib\ant-all.jar;D:\bea\modules\N
ETSFA~1.0_1\lib\ant-contrib.jar;D:\bea\WLSERV~1.3\common\eval\pointbase\lib\pbem
bedded57.jar;D:\bea\WLSERV~1.3\common\eval\pointbase\lib\pbtools57.jar;D:\bea\WL
SERV~1.3\common\eval\pointbase\lib\pbclient57.jar” weblogic.NodeManager “-v”
NMProcess: <2011-1-10 16:12:35> <INFO> <Loading domains file: D:\bea\wlserver_10
.3\common\bin\nodemanager.domains>
NMProcess: <2011-1-10 16:12:36> <WARNING> <Domains file not found: D:\bea\wlserv
er_10.3\common\bin\nodemanager.domains>
NMProcess: <2011-1-10 16:12:38> <INFO> <Loading identity key store: FileName=D:/
bea/WLSERV~1.3/server\lib\DemoIdentity.jks, Type=jks, PassPhraseUsed=true>
NMProcess: <2011-1-10 16:12:39> <WARNING> <Node manager configuration properties
file ‘D:\bea\wlserver_10.3\common\bin\nodemanager.properties’ not found. Using
default settings.>
NMProcess: <2011-1-10 16:12:39> <Info> <
Saving node manager configuration proper
ties to ‘D:\bea\wlserver_10.3\common\bin\nodemanager.properties
“>
NMProcess: Node manager v10.3
NMProcess:
NMProcess: Configuration settings:
NMProcess:
NMProcess: NodeManagerHome=D:\bea\wlserver_10.3\common\bin
NMProcess: ListenAddress=
NMProcess: ListenPort=5556
NMProcess: ListenBacklog=50
NMProcess: SecureListener=true
NMProcess: AuthenticationEnabled=true
NMProcess: NativeVersionEnabled=true
NMProcess: CrashRecoveryEnabled=false
NMProcess: JavaHome=D:\bea\JROCKI~1\jre
NMProcess: StartScriptEnabled=false
NMProcess: StopScriptEnabled=false
NMProcess: StartScriptName=startWebLogic.cmd
NMProcess: StopScriptName=
NMProcess: LogFile=D:\bea\wlserver_10.3\common\bin\nodemanager.log
NMProcess: LogLevel=INFO
NMProcess: LogLimit=0
NMProcess: LogCount=1
NMProcess: LogAppend=true
NMProcess: LogToStderr=true
NMProcess: LogFormatter=weblogic.nodemanager.server.LogFormatter
NMProcess: DomainsFile=D:\bea\wlserver_10.3\common\bin\nodemanager.domains
NMProcess: DomainsFileEnabled=true
NMProcess: StateCheckInterval=500
NMProcess: QuitEnabled=true
NMProcess:
NMProcess: Domain name mappings:
NMProcess:
NMProcess:
NMProcess: <2011-1-10 16:12:41> <INFO> <Secure socket listener started on port 5
556>
Successfully launched the Node Manager.
The Node Manager process is running independent of the WLST process.
Exiting WLST will not stop the Node Manager process. Please refer
to the Node Manager logs for more information.
The Node Manager logs will be under D:\bea\wlserver_10.3\common\bin\.

现在nodemanager成功启动起来了!

Note: Nodemanager starts and runs irrespective of the WLST tool. Even if you exit from WLST, the nodemanager will still be running.

Now you need to connect to the nodemanager using the nmConnect() command. This needs to be done because you need to start the the servers through node manager.

截图05

截图08

在配置的过程中遇到了不少麻烦,对节点管理器的一些机制有了新的理解,繁琐的排错过程就不一一列举了,官方文档还是最给力的,看明白了自然就迎刃而解了!

http://www.oraclefmw.com/wls92/server_start/nodemgr.html#wp1097447

http://download.oracle.com/docs/cd/E13222_01/wls/docs90/config_scripting/reference.html#1111568

WebLogic Server 8.1节点管理器配置

December 14th, 2010 tonyxu 5 comments

转载请注明,谢谢。

之前写过weblogic10.3配置节点管理器的文章,现在把weblogic8版本的步骤也整理一下。

准备:

OS:windows XP

jdk:jdk142_11

weblogic 8.1.6

NodeManager是作为一个操作系统的监听进程运行的,它主要负责听从
%BEA_HOME%\weblogic81\common\nodemanager\nodemanager.hosts中指定的机器上的AdminServer发送过来的命令。

好了,我们开始吧!

配置大体过程如下,一共5个步骤:

A.建立相应的Domain。添加server1和machine。建立Domain的具体步骤略。

我这里的myserver即为Admin Server,Admin Server最终想做的事情就是启动server1。

截图00

截图05

B. 得到 Server的根证书,密钥。并将它们加入KeyStore。

将D:\bea816\weblogic81\server\lib目录内的文件

DemoTrust.jks

DemoIdentity.jks

分别拷贝到如下目录内

D:\bea816\weblogic81\common\nodemanager\

D:\bea816\user_projects\domains\mydomain\

C. 配置WebLogic Server的KeyStore和SSL设置。

使用默认的设置,修改Hostname Verification:None

截图04

D. 配置 Managed Server机器上的NodeManager。

修改D:\bea816\weblogic81\common\nodemanager目录内的nodemanger.properties,nodemanger.hosts文件

1、Nodemanager.properties

关于nodemanger.properties,我在之前的文章里提到过,该文件一开始是不存在的。可以去尝试启动一下nodemanager,即使启动不成功,也会在D:\bea816\weblogic81\common\nodemanager目录下产生

nodemanger.properties文件。内容如下(我们直接在其上修改,修改处标红):

#Syntax:
#
# KeyStores =  DemoIdentityAndDemoTrust CustomIdentityAndJavaStandardTrust CustomIdentityAndCustomTrust
#   default = DemoIdentityAndDemoTrust
#
# KeyStores = DemoIdentityAndDemoTrust
#   Optional Properties
#     JavaStandardTrustKeyStorePassPhrase, default = no passphrase
#
# KeyStores = CustomIdentityAndJavaStandardTrust
#   Required Properties
#     CustomIdentityKeyStoreFileName
#     CustomIdentityAlias
#     CustomIdentityPrivateKeyPassPhrase
#   Optional properties
#     CustomIdentityKeyStoreType, default = default keystore type from java.security
#     CustomIdentityKeyStorePassPhrase, default = no passphrase
#     JavaStandardTrustKeyStorePassPhrase, default = no passphrase
#
# KeyStores = CustomIdentityAndCustomTrust
#   Required Properties
#     CustomIdentityKeyStoreFileName
#     CustomIdentityAlias
#     CustomIdentityPrivateKeyPassPhrase
#     CustomTrustKeyStoreFileName
#   Optional Properties
#     CustomIdentityKeyStoreType, default = default keystore type from java.security
#     CustomIdentityKeyStorePassPhrase, default = no passphrase
#     CustomTrustKeyStoreType, default = default keystore type from java.security
#     CustomTrustKeyStorePassPhrase, default = no passphrase
#
# —-  Non-SSL config properties  —-
#
#     ListenAddress = <hostname/ip address>, default = *.*

ListenAddress =127.0.0.1
#     ListenPort = <port number>, default = 5555

ListenPort =5555
#     SavedLogsDirectory = <Directory containing log files>,
#         default = NodeManagerLogs

SavedLogsDirectory=D:/bea816/weblogic81/common/nodemanager/NodeManagerLogs
#     TrustedHosts = <file containing list of allowable node manager clients>,
#         default = nodemanager.hosts
#     ReverseDnsEnabled = <true/false>, default = false

ReverseDnsEnabled =true

# Specifies whether entries in the trusted hosts file can contain DNS names (instead of IP addresses).
#     ScavangerDelaySeconds = <Number of seconds the node manager waits for the managed server to connect>, default = 180
#     WeblogicHome = <WeblogicHome property for the managed servers>

WeblogicHome=D:/bea816/weblogic81
#         default = null (current directory of the managed server)
#     bea.home = <bea.home for the managed servers>

bea.home =D:/bea816
#         default = null (current directory of the managed server)
#     JavaHome = <JAVA_HOME for the managed servers>
#         default = D:\bea816\JROCKI~1\jre
#     PIDFileReadRetryCount = <Number of times node manager will retry to read the PID, delay between retries is 2 seconds.>#         default = 1
#

#Tue Dec 14 13:58:19 CST 2010
PropertiesVersion=8.1

2、nodemanager.hosts

# Host names from which the connection to the
# node manager will be accepted.
# You can edit this file manually.
# E.g. – for allowing a machine named holly to connect,
# uncomment one of the following lines based on whether
# ReverseDnsEnabled property is turned on or off.
#holly.bea.com
#172.17.24.145
127.0.0.1

localhost

修改后保存。

E. 检查相应设置是否正确后,启动所有Server,完成设置。

进入D:\bea816\weblogic81\server\bin目录

启动节点管理器

startNodeManager.cmd 127.0.0.1 5555

截图07

截图06

启动节点管理器后,启动管理服务,进入控制台,就可以通过控制台启动停止域内的服务

截图08

截图09

截图10

截图11

截图12

至此,全部工作完成。weblogic8版本比后面的版本在节点管理器的配置上还是稍微麻烦一点。

by: tonyxu