当前位置: 技术问答>linux和unix
linux下weblogic网络配置问题
来源: 互联网 发布时间:2017-05-09
本文导语: weblogic安装配置好后,启动startWebLoigc.sh,报这个错 Could not obtain the localhost address. The most likely cause is an error in the network configuration of this machine. 知道这是网络配置问题,部署本机IP是固定的,配置服务器...
weblogic安装配置好后,启动startWebLoigc.sh,报这个错
![linux下weblogic网络配置问题[图片]](/img/tech-article-img/img_1418228317_47270.jpeg)
Could not obtain the localhost address. The most likely cause is an error in the network configuration of this machine.
知道这是网络配置问题,部署本机IP是固定的,配置服务器地址的时候就填了固定的IP。后来在网上搜索,要在/etc/hosts这个文件里添加ip及域名,可是我不知道固定ip的名称和域名是什么,里面内容只有127.0.0.1这个ip的信息,配置服务器地址时,输入127.0.0.1就能用,但部署应用后局域网内不能访问。
问题:1.如何在/etc/hosts文件里填正确的IP、名称和域名?
2.如何配置服务器的地址,能够让局域网内都能访问?
![linux下weblogic网络配置问题[图片]](/img/tech-article-img/img_1418228317_47270.jpeg)
Could not obtain the localhost address. The most likely cause is an error in the network configuration of this machine.
知道这是网络配置问题,部署本机IP是固定的,配置服务器地址的时候就填了固定的IP。后来在网上搜索,要在/etc/hosts这个文件里添加ip及域名,可是我不知道固定ip的名称和域名是什么,里面内容只有127.0.0.1这个ip的信息,配置服务器地址时,输入127.0.0.1就能用,但部署应用后局域网内不能访问。
问题:1.如何在/etc/hosts文件里填正确的IP、名称和域名?
2.如何配置服务器的地址,能够让局域网内都能访问?
|
执行这个命令:
hostname
假设结果是:
xxoo
假设IP是:
192.168.1.100
在/etc/hosts里面加一行:
192.168.1.100 xxoo.csdn.com xxoo
域名不知道的话:
nslookup 192.168.1.100
hostname
假设结果是:
xxoo
假设IP是:
192.168.1.100
在/etc/hosts里面加一行:
192.168.1.100 xxoo.csdn.com xxoo
域名不知道的话:
nslookup 192.168.1.100
|
用域名的好处就是IP变了,配置不用修改直接修改hosts即可