Caused By: java.net.UnknownHostException: XX: Name or service not known

启动weblogic报错

JAVA Memory arguments: -Xms256m -Xmx512m -XX:CompileThreshold=8000 -XX:PermSize=128m  -XX:MaxPermSize=256m
.
WLS Start Mode=Development
.
CLASSPATH=/opt/bosssoft/patch_wls1036/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/bosssoft/patch_ocp371/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/jdk1.7.0_80/lib/tools.jar:/opt/bosssoft/wlserver_10.3/server/lib/weblogic_sp.jar:/opt/bosssoft/wlserver_10.3/server/lib/weblogic.jar:/opt/bosssoft/modules/features/weblogic.server.modules_10.3.6.0.jar:/opt/bosssoft/wlserver_10.3/server/lib/webservices.jar:/opt/bosssoft/modules/org.apache.ant_1.7.1/lib/ant-all.jar:/opt/bosssoft/modules/net.sf.antcontrib_1.1.0.0_1-0b2/lib/ant-contrib.jar:/opt/bosssoft/wlserver_10.3/common/derby/lib/derbyclient.jar:/opt/bosssoft/wlserver_10.3/server/lib/xqrl.jar:.:/opt/java/jdk1.7.0_79/lib/tools.jar:
.
PATH=/opt/bosssoft/wlserver_10.3/server/bin:/opt/bosssoft/modules/org.apache.ant_1.7.1/bin:/opt/jdk1.7.0_80/jre/bin:/opt/jdk1.7.0_80/bin:/usr/lib64/qt-3.3/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/opt/java/jdk1.7.0_79/bin:/root/bin
.
***************************************************
*  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        *
***************************************************
starting weblogic with Java version:
Picked up _JAVA_OPTIONS: -DBOSSSOFT_HOME=/opt/boss_home
java version "1.7.0_80"
Java(TM) SE Runtime Environment (build 1.7.0_80-b15)
Java HotSpot(TM) 64-Bit Server VM (build 24.80-b11, mixed mode)
Starting WLS with line:
/opt/jdk1.7.0_80/bin/java -client   -Xms256m -Xmx512m -XX:CompileThreshold=8000 -XX:PermSize=128m  -XX:MaxPermSize=256m -Dweblogic.Name=AdminServer -Djava.security.policy=/opt/bosssoft/wlserver_10.3/server/lib/weblogic.policy  -Xverify:none  -da -Dplatform.home=/opt/bosssoft/wlserver_10.3 -Dwls.home=/opt/bosssoft/wlserver_10.3/server -Dweblogic.home=/opt/bosssoft/wlserver_10.3/server   -Dweblogic.management.discover=true  -Dwlw.iterativeDev= -Dwlw.testConsole= -Dwlw.logErrorsToConsole= -Dweblogic.ext.dirs=/opt/bosssoft/patch_wls1036/profiles/default/sysext_manifest_classpath:/opt/bosssoft/patch_ocp371/profiles/default/sysext_manifest_classpath  weblogic.Server
Picked up _JAVA_OPTIONS: -DBOSSSOFT_HOME=/opt/boss_home
<May 5, 2019 3:52:58 PM EDT> <Info> <Security> <BEA-090905> <Disabling CryptoJ JCE Provider self-integrity check for better startup performance. To enable this check, specify -Dweblogic.security.allowCryptoJDefaultJCEVerification=true> 
<May 5, 2019 3:53:14 PM EDT> <Info> <Security> <BEA-090906> <Changing the default Random Number Generator in RSA CryptoJ from ECDRBG to FIPS186PRNG. To disable this change, specify -Dweblogic.security.allowCryptoJDefaultPRNG=true> 
<May 5, 2019 3:53:15 PM EDT> <Info> <WebLogicServer> <BEA-000377> <Starting WebLogic Server with Java HotSpot(TM) 64-Bit Server VM Version 24.80-b11 from Oracle Corporation> 
<May 5, 2019 3:53:17 PM EDT> <Info> <Management> <BEA-141107> <Version: WebLogic Server 10.3.6.0  Tue Nov 15 08:52:36 PST 2011 1441050 > 
<May 5, 2019 3:53:20 PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING> 
<May 5, 2019 3:53:20 PM EDT> <Info> <WorkManager> <BEA-002900> <Initializing self-tuning thread pool> 
<May 5, 2019 3:53:20 PM EDT> <Notice> <LoggingService> <BEA-320400> <The log file /opt/bosssoft/user_projects/domains/boss/servers/AdminServer/logs/AdminServer.log will be rotated. Reopen the log file if tailing has stopped. This can happen on some platforms like Windows.> 
<May 5, 2019 3:53:20 PM EDT> <Notice> <LoggingService> <BEA-320401> <The log file has been rotated to /opt/bosssoft/user_projects/domains/boss/servers/AdminServer/logs/AdminServer.log00001. Log messages will continue to be logged in /opt/bosssoft/user_projects/domains/boss/servers/AdminServer/logs/AdminServer.log.> 
<May 5, 2019 3:53:20 PM EDT> <Notice> <Log Management> <BEA-170019> <The server log file /opt/bosssoft/user_projects/domains/boss/servers/AdminServer/logs/AdminServer.log is opened. All server side log events will be written to this file.> 
<May 5, 2019 3:53:25 PM EDT> <Critical> <WebLogicServer> <BEA-000386> <Server subsystem failed. Reason: java.lang.AssertionError: Could not obtain the localhost address. The most likely cause is an error in the network configuration of this machine.
java.lang.AssertionError: Could not obtain the localhost address. The most likely cause is an error in the network configuration of this machine.
	at weblogic.server.channels.AddressUtils$AddressMaker.getLocalHost(AddressUtils.java:38)
	at weblogic.server.channels.AddressUtils$AddressMaker.<clinit>(AddressUtils.java:33)
	at weblogic.server.channels.AddressUtils.getIPAny(AddressUtils.java:154)
	at weblogic.protocol.configuration.ChannelHelper.checkConsistency(ChannelHelper.java:61)
	at weblogic.server.channels.ChannelService.start(ChannelService.java:207)
	Truncated. see log file for complete stacktrace
Caused By: java.net.UnknownHostException: boss: boss: Name or service not known
	at java.net.InetAddress.getLocalHost(InetAddress.java:1475)
	at weblogic.server.channels.AddressUtils$AddressMaker.getLocalHost(AddressUtils.java:36)
	at weblogic.server.channels.AddressUtils$AddressMaker.<clinit>(AddressUtils.java:33)
	at weblogic.server.channels.AddressUtils.getIPAny(AddressUtils.java:154)
	at weblogic.protocol.configuration.ChannelHelper.checkConsistency(ChannelHelper.java:61)
	Truncated. see log file for complete stacktrace
Caused By: java.net.UnknownHostException: boss: Name or service not known
	at java.net.Inet6AddressImpl.lookupAllHostAddr(Native Method)
	at java.net.InetAddress$1.lookupAllHostAddr(InetAddress.java:901)
	at java.net.InetAddress.getAddressesFromNameService(InetAddress.java:1295)
	at java.net.InetAddress.getLocalHost(InetAddress.java:1471)
	at weblogic.server.channels.AddressUtils$AddressMaker.getLocalHost(AddressUtils.java:36)
	Truncated. see log file for complete stacktrace
> 
<May 5, 2019 3:53:25 PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to FAILED> 
<May 5, 2019 3:53:25 PM EDT> <Error> <WebLogicServer> <BEA-000383> <A critical service failed. The server will shut itself down> 
<May 5, 2019 3:53:25 PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to FORCE_SHUTTING_DOWN> 

提示告诉我们是因为hostname缺少造成的

解决方法:
1)vim /etc/hosts

2)新增hostname

127.0.0.1  自己主机的hostname(我是boss)

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值