tfactl fails with error “Exception in thread “CommandLine” java.lang.IllegalStateException: ManagerFactory [org.apache.logging.log4j.core.appender.rolling.RollingRandomAccessFileManager$RollingRandomAccessFileManagerFactory@5c5eefef] unable to create manager”

Dear Readers,

Trust you are doing well!!

Today I am going to write about issue I recently faced during running TFA for collecting SRDC regarding the performance issue I was working on. These TFA files were requested by Oracle global support for investigation purpose.

I used below command for collecting SRDC with option dbperf.

tfactl diagcollect -srdc dbperf -all -database RATDB -from “JAN/07/2022 23:20:00” -to “JAN/08/2022 01:00:00”

This command was exiting without giving any errors & was just showing one warning as given below.

When I tried to run command tfactl status which failed giving actual error:

Complete Error:

Exception in thread “CommandLine” java.lang.IllegalStateException: ManagerFactory [org.apache.logging.log4j.core.appender.rolling.RollingRandomAccessFileManager$RollingRandomAccessFileManagerFactory@5c5eefef] unable to create manager for [/grid_19c/app/grid/oracle.ahf/data/uatsrvm7client0101/diag/tfa/tfactl/user_oracle/tfa_client.trc] with data [org.apache.logging.log4j.core.appender.rolling.RollingRandomAccessFileManager$FactoryData@16293aa2]
at org.apache.logging.log4j.core.appender.AbstractManager.getManager(AbstractManager.java:115)
at org.apache.logging.log4j.core.appender.OutputStreamManager.getManager(OutputStreamManager.java:100)
at org.apache.logging.log4j.core.appender.rolling.RollingRandomAccessFileManager.getRollingRandomAccessFileManager(RollingRandomAccessFileManager.java:108)
at org.apache.logging.log4j.core.appender.RollingRandomAccessFileAppender$Builder.build(RollingRandomAccessFileAppender.java:133)
at oracle.rat.tfa.util.TFACLogger.initClient(TFACLogger.java:164)
at oracle.rat.tfa.CommandLine.processTFARequest(CommandLine.java:531)
at oracle.rat.tfa.CommandLine.main(CommandLine.java:474)
.—————————————————————————.
| Host | Status of TFA | PID | Port | Version | Build ID | Inventory Status |
+——+—————+—–+——+———+———-+——————+
‘——+—————+—–+——+———+———-+——————‘

From the error it looks like issue related to permissions, so thought of checking tfactl status using root user, and it worked without any issues. So this provided confirmation that something is wrong with Oracle permissions for TFA.

I continued to collect SRDC using root user but it failed as expected, saying “SRDC diagnostic collections must be run as an oracle privileged user – not root”

After digging more on this, I checked access levels for all users for TFACTL using command: tfactl access lsusers.

As shown in above diagram OS user Oracle was not enabled for TFACTL on node 1 which was causing this issue.

I added Oracle in TFACTL access list using command: tfactl access add -user oracle.

After this I was able to collect TFA SRDC as expected.

Hope u will find this post very useful.

Cheers

Regards,
Adityanath

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s