Grammin
Grammin

Reputation: 12205

How can I find out through java where jboss is going to put my server logs?

Is there a way I can detect where jboss is writing the console log file?

I am using java.util.logger and log4j.

Upvotes: 1

Views: 126

Answers (2)

Rick K
Rick K

Reputation: 26

Check to see if there's a system property called jboss.server.log.dir. You should be able to read this value with System.getProperty("jboss.server.log.dir").

Upvotes: 1

Ondra Žižka
Ondra Žižka

Reputation: 46796

If it's AS 7, you can add the logging module as your module's dependency and reach the logging service, which will have this info. Also, you might get that info through the Management API.

https://docs.jboss.org/author/display/AS71/Management+API+reference

Unfortunately what you need is still empty: https://docs.jboss.org/author/display/AS71/The+native+management+API

Upvotes: 0

Related Questions