JBoss 7.1.1 does not create server.log

吃可爱长大的小学妹 提交于 2019-12-13 05:08:48

问题


Here is what we currently have running, JBoss 7.1.1 in Domain Mode. OS Red Hat:Red Hat Enterprise Linux Server release 6.4 (Santiago)

So on the host(Host-A) that acts as the Domain Controller we also have an App-Server. We have 17 other hosts but I am testing it out on Host-A right now.

In the domain.xml on that very server, we have created a custom profile and in that profile I have configured a log location like this:

<profile name="AppLogix-full-ha">
            <subsystem xmlns="urn:jboss:domain:logging:1.1">
                <console-handler name="CONSOLE">
                    <level name="INFO"/>
                    <formatter>
                        <pattern-formatter pattern="%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/>
                    </formatter>
                </console-handler>
                <periodic-rotating-file-handler name="FILE">
                    <level name="INFO"/>
                    <formatter>
                        <pattern-formatter pattern="%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/>
                    </formatter>
                   <file relative-to="jboss.server.log.dir" path="/apps/logs/AppLogix.Cluster/server.log"/>
                    <suffix value=".yyyy-MM-dd"/>
                    <append value="true"/>
                </periodic-rotating-file-handler>

and this the only place where the log is configured for the app server. I don't have anything in the host.xml on Host-A.

Problem is it still keeps creating the log in the /apps/jboss/jboss-as-7.1.1.Final/domain/servers/AppLogix.Member1/log ( which I THINK is the default location)

What am I doing wrong here experts? What did I miss? Any help is monumentally appreciated. Sincerely, KK.


回答1:


Remove the relative-to attribute. See this similar answer.

<periodic-rotating-file-handler name="FILE">
  ...
  <file path="/apps/logs/AppLogix.Cluster/server.log"/>
  ...
 </periodic-rotating-file-handler>



回答2:


OK I figured it out....I was using the wrong profile at the end of the domain.xml..........OK I figured it out at the bottom of the domain.xml All the profiles had the correct locations for the server.log file but there was another profile called full-ha( an un-used useless profile) that will still pointing to the default location. I forgot to change it from full-ha to appropriate profile name Once I changed it , it all worked fine !!!



来源:https://stackoverflow.com/questions/19039755/jboss-7-1-1-does-not-create-server-log

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!