How do I replace a 'serverName' parameter in a log. xml file of a .war application with the Ibm websphere server name on deployment time (by command ile on linux env). I mean what is the syntax for it in the log.xml file and in the command line. Can I do this also with the wasadmin app ?
As far as I am aware, you don't - depending on which commons-logging method you're using it's different, but in general the external Log4j/JSR configs only dictate the logging levels, patterns and filenames (as well as the base factory used, etc.). You need to actually edit your Java code to pull that out (getProperty) and insert it into the log.INFO() (sic) calls when writing. To my knowledge there's no way to do it at the configuration (XML) level.