linux 安裝WildFly 及可能遇到的問題


背景

公司決定用JBoss為應用服務器,JBoss已更名為WildFly

問題

安裝官網的教程進行了安裝,服務器本機可以訪問,客戶端無法進行訪問

解決

方案1: 修改standalone/configuration/standalone.xml中所有127.0.0.1的值為0.0.0.0
方案2: 啟動的時候添加 參數 ./standalone.sh -b 10.0.6.129 ;參考:http://feng88724.iteye.com/blog/263211

過程

  1. 安裝jdk http://www.cnblogs.com/blueying/p/3988962.html
  2. 安裝wildfly http://blog.csdn.net/kylinsoong/article/details/19203981
  3. 打開防火牆端口 http://www.cnblogs.com/blueying/p/3976548.html

服務器上使用 curl 127.0.0.1:8080可以查看到服務器啟動了

[root@test4 ~]# curl 127.0.0.1:8080
<!--
  ~ JBoss, Home of Professional Open Source.
  ~ Copyright (c) 2011, Red Hat, Inc., and individual contributors
  ~ as indicated by the @author tags. See the copyright.txt file in the
  ~ distribution for a full listing of individual contributors.
  ~
  ~ This is free software; you can redistribute it and/or modify it

使用客戶端無法訪問。
使用 netstat -apn 查看端口

[root@test4 ~]# netstat -apn
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address               Foreign Address             State       PID/Program name   
tcp        0      0 127.0.0.1:8080              0.0.0.0:*                   LISTEN      2930/java           
tcp        0      0 0.0.0.0:22                  0.0.0.0:*                   LISTEN      860/sshd            
tcp        0      0 127.0.0.1:25                0.0.0.0:*                   LISTEN      937/master          
tcp        0      0 127.0.0.1:9990              0.0.0.0:*                   LISTEN      2930/java           
tcp        0      0 192.168.1.14:22             192.168.1.110:60642         ESTABLISHED 3017/sshd           
tcp        0      0 192.168.1.14:22             192.168.1.110:60624         ESTABLISHED 2876/sshd        

發現端口是開啟的;ssh可以連接,觀察

0 0.0.0.0:22                  0.0.0.0:*
192.168.1.14:22             192.168.1.110:60642 
0 192.168.1.14:22             192.168.1.110:60624

而8080的只有127.0.0.1:8080 所以才只能本地訪問;故修改了wildfly的配置文件。具體是為什么暫時不知道...


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM