Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Repotools - appending (rather than overwriting) log files

This might be a simple question with a simple solution - but I have yet to find it :-)

My team and I have developed some custom automation to add and remove (archive) users to RTC.  Therefore part of the automation uses the repotools commands, syncusers and archiveusers specifically.

As part of the command we use the logfile attribute to write to a file, however by default the log file is overwritten every time.  I would like to get the command to append to the log file rather than overwrite, as it would be helpful to have history of previous automation runs.

Does anyone know if this is possible with the command?

0 votes



One answer

Permanent link
According to this wiki page https://jazz.net/wiki/bin/view/Deployment/ManipulatingCLMLog4j repotools logging can be manipulated via its log4j.properties files:

"repotools also has a log4j properties file, repotools_log4j.properties, in the install/server/conf directory as of CLM 4.0.5. There is also a "log4jproperties" argument for repotools"

From examination of a sample  repotools_log4j.properties the default file appender appears to be the simple FileAppender:
log4j.appender.file=org.apache.log4j.FileAppender

You should be able to adjust the setting to an approprate file appender (perhaps RollingFileAppender) to provide the logging you need.

0 votes

Comments

Thanks Alan,
I will give this a try.  Part of the complication (or difference) here is that the automation is not running on a system with a full RTC/CLM install, it runs separately with copies of the repotools.sh files - so I am hoping if I put a repotools_log4j.properties file in the same folder it will find it.

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details

Question asked: Jul 09 '15, 11:32 a.m.

Question was seen: 2,676 times

Last updated: Jul 10 '15, 9:23 a.m.

Confirmation Cancel Confirm