(转)Weblogic 8.1的安装与配置
本文转载自:http://hi.baidu.com/shirdrn/item/da6a96539ba0089709be17d9
Weblogic 8.1的安装与配置
下面通过设置几个标题来说明Weblogic 8.1的安装与配置,并给出简单的对配置的测试。
下载
可以从地址http://download2.bea.com/pub/platform/81/platform814_zh_CN_win32.exe下载Weblogic 8.1 SP4,得到软件。
安装
首先启动安装文件platform814_zh_CN_win32.exe,如图所示:
在安装的过程中,主要有如下选择步骤:
1、选择是否同意BEA许可条款;
2、选择BEA主目录,我选择了D:\bea作为主目录;
3、选择安装组件:全部安装主要安装了Webogic Server、Webogic Workshop、Webogic Portal、Webogic Integration这四个组件,可以自定义;
安装完成,如图所示:
配置
选择“开始”->“程序”->“BEA WebLogic Platform 8.1”->“Configuration Wizard”,如图所示:
选择“新建Weblogic配置”,单击“下一步”,如图所示:
默认选中“Basic Weblogic Server Domain”,单击“下一步”,如图所示:
选择自定义配置,单击“下一步”,如图所示:
配置服务器,这里修改Name为snserver,其他根据自己的需要设置,单击“下一步”,如图所示:
选择“否,单击“下一步”,如图所示:
选择“否,单击“下一步”,如图所示:
选择“否,单击“下一步”,如图所示:
配置管理用户名和密码,下面选择“否,单击“下一步”,如图所示:
保持默认选项,单击“下一步”,如图所示:
保持默认选项,单击“下一步”,如图所示:
选择Java的JDK,选择BEA自带的,单击“下一步”,如图所示:
设置域名为sndomain,单击“创建”,创建并完成配置,如图所示:
上面是详细的简单的配置。
测试
启动上面我们配置的Weblogic Server,按照下图所示的启动路径,启动snserver,如图所示:
可以看到启动成功的CMD窗口,如图所示:
这时,可以通过登录Web console,方便地管理Weblogic Server。浏览器地址栏输入http://192.168.151.201:7001/console,启动后的登录界面,如图所示:
输入配置Weblogic Server过程中设置的用户名和密码,登录成功,如图所示:
异常
在配置Weblogic Server的过程中,有一步是选择JDK,如果你选择自定义的其他Java JDK,比如,我选择了我在本地安装的JDK 1.6,如图所示:
配置完成后,在启动的过程中会发生异常,无法启动Weblogic Server,异常信息如下所示:
.
CLASSPATH=D:\PROGRA~1\JAVA\JDK16~1.0_0\lib\tools.jar;D:\bea\WEBLOG~1\server\lib\
weblogic_sp.jar;D:\bea\WEBLOG~1\server\lib\weblogic.jar;D:\bea\WEBLOG~1\common\e
val\pointbase\lib\pbserver44.jar;D:\bea\WEBLOG~1\common\eval\pointbase\lib\pbcli
ent44.jar;D:\PROGRA~1\JAVA\JDK16~1.0_0\jre\lib\rt.jar;D:\bea\WEBLOG~1\server\lib
\webservices.jar;.;3rdparty.jar;config.jar;comdev.jar;wizard.jar;;D:\bea\WEBLOG~
1\common\eval\pointbase\lib\pbserver44.jar;D:\bea\WEBLOG~1\common\eval\pointbase
\lib\pbclient44.jar;D:\bea\WEBLOG~1\common\eval\pointbase\lib\pbtools44.jar;D:\b
ea\WEBLOG~1\server\lib\ojdbc14.jar;D:\bea\WEBLOG~1\server\lib\wloracle.jar;D:\be
a\WEBLOG~1\server\lib\wlsqlserver.jar;D:\bea\WEBLOG~1\server\lib\wldb2.jar ;D:\
bea\WEBLOG~1\server\lib\wlsybase.jar;D:\bea\WEBLOG~1\server\lib\jConnect.jar;D:\
bea\WEBLOG~1\server\lib\wlinformix.jar;D:\bea\WEBLOG~1\server\lib\weblogic.jar;D
:\bea\WEBLOG~1\server\lib\ant\ant.jar
.
PATH=D:\bea\WEBLOG~1\server\bin;D:\PROGRA~1\JAVA\JDK16~1.0_0\jre\bin;D:\PROGRA~1
\JAVA\JDK16~1.0_0\bin;D:\bea\WEBLOG~1\server\bin;D:\bea\jdk142_05\jre\bin;D:\bea
\jdk142_05\bin;D:\Program Files\Java\jdk1.6.0_05\bin;C:\WINDOWS\system32;C:\WIND
OWS;C:\WINDOWS\System32\Wbem;d:\Program Files\StormII\Codec;d:\Program Files\Sto
rmII;D:\AppServ\MySQL\bin;D:\AppServ\Apache2.2\bin;D:\AppServ\php5;D:\bea\WEBLOG
~1\server\bin\oci920_8;D:\bea\WEBLOG~1\server\bin\oci920_8
.
***************************************************
* To start WebLogic Server, use a username and *
* password assigned to an admin-level user. For *
* server administration, use the WebLogic Server *
* console at http:\\[hostname]:[port]\console *
***************************************************
<2009-4-9 上午09时56分44秒 CST> <Info> <WebLogicServer> <BEA-000377> <Starting W
ebLogic Server with Java HotSpot(TM) Client VM Version 10.0-b19 from Sun Microsy
stems Inc.>
<2009-4-9 上午09时56分45秒 CST> <Info> <Configuration Management> <BEA-150016> <
This server is being started as the administration server.>
<2009-4-9 上午09时56分45秒 CST> <Info> <Management> <BEA-141107> <Version: WebLo
gic Server 8.1 SP4 Sat Jan 8 02:45:14 PST 2005 485534
WebLogic XMLX Module 8.1 SP4 Sat Jan 8 02:45:14 PST 2005 485534 >
***************************************************************************
The WebLogic Server did not start up properly.
java.io.InvalidClassException: javax.management.MBeanAttributeInfo; local class
incompatible: stream classdesc serialVersionUID = 7043855487133450673, local cla
ss serialVersionUID = 8644704819898565848
at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:562)
at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:158
3)
at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1496)
at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:158
3)
at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1496)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1
732)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:19
47)
at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:48
0)
at javax.management.MBeanInfo.readObject(MBeanInfo.java:669)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:974
)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1
753)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
at weblogic.management.internal.TypesHelper.getMBeanInfo(TypesHelper.jav
a:261)
at weblogic.management.internal.TypesHelper.getAdminOrConfigMBeanInfo(Ty
pesHelper.java:366)
at weblogic.management.internal.ConfigurationMBeanImpl.<init>(Configurat
ionMBeanImpl.java:130)
at weblogic.management.AdminServer.<init>(AdminServer.java:59)
at weblogic.management.AdminServerAdmin.initialize(AdminServerAdmin.java
:245)
at weblogic.t3.srvr.T3Srvr.initializeHere(T3Srvr.java:771)
at weblogic.t3.srvr.T3Srvr.initialize(T3Srvr.java:670)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:344)
at weblogic.Server.main(Server.java:32)
--------------- nested within: ------------------
weblogic.management.configuration.ConfigurationException: - with nested excepti
on:
[java.io.InvalidClassException: javax.management.MBeanAttributeInfo; local class
incompatible: stream classdesc serialVersionUID = 7043855487133450673, local cl
ass serialVersionUID = 8644704819898565848]
at weblogic.management.internal.TypesHelper.getMBeanInfo(TypesHelper.jav
a:266)
at weblogic.management.internal.TypesHelper.getAdminOrConfigMBeanInfo(Ty
pesHelper.java:366)
at weblogic.management.internal.ConfigurationMBeanImpl.<init>(Configurat
ionMBeanImpl.java:130)
at weblogic.management.AdminServer.<init>(AdminServer.java:59)
at weblogic.management.AdminServerAdmin.initialize(AdminServerAdmin.java
:245)
at weblogic.t3.srvr.T3Srvr.initializeHere(T3Srvr.java:771)
at weblogic.t3.srvr.T3Srvr.initialize(T3Srvr.java:670)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:344)
at weblogic.Server.main(Server.java:32)
--------------- nested within: ------------------
weblogic.management.configuration.ConfigurationError - with nested exception:
[weblogic.management.configuration.ConfigurationException: - with nested except
ion:
[java.io.InvalidClassException: javax.management.MBeanAttributeInfo; local class
incompatible: stream classdesc serialVersionUID = 7043855487133450673, local cl
ass serialVersionUID = 8644704819898565848]]
at weblogic.management.internal.TypesHelper.getAdminOrConfigMBeanInfo(Ty
pesHelper.java:377)
at weblogic.management.internal.ConfigurationMBeanImpl.<init>(Configurat
ionMBeanImpl.java:130)
at weblogic.management.AdminServer.<init>(AdminServer.java:59)
at weblogic.management.AdminServerAdmin.initialize(AdminServerAdmin.java
:245)
at weblogic.t3.srvr.T3Srvr.initializeHere(T3Srvr.java:771)
at weblogic.t3.srvr.T3Srvr.initialize(T3Srvr.java:670)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:344)
at weblogic.Server.main(Server.java:32)
***************************************************************************
解决的办法就是,不要选择自定义的更高版本的JDK,使用BEA默认自带的JDK,对于Weblogic 8.1来说,这样就能够解决上面的异常,成功启动Weblogic Server。