Is There An Automated Way To Enable Libumem Debug?

(Doc ID 2346811.1)

Last updated on JANUARY 11, 2018

Applies to:

Oracle Communications Messaging Server - Version 8.0.2 and later
Information in this document applies to any platform.

Goal

Using:  Oracle Communications Messaging Server 8.0.2.1.20171204 64bit (built Dec 4 2017)

Looking for an automated way to enable libumem debug.

The problem with Doc ID 1383299.1 is that the mail admin often does not have access to run as root.
The less-privileged mail admin may have access to use svcadm to enable/disable all of Messaging.
If RBAC is enabled, msstart uses pfexec to run things with elevated privileges to be able to start certain components (but not watcher, since starting watcher as non-root is not supported).
But pfexec intentionally prevents passing things like environment variables that change library path.

So, with RBAC enabled, the following does nothing to enable the desired debug:

UMEM_DEBUG=default,audit=40 UMEM_LOGGING=transaction LD_PRELOAD=libumem.so.1 /opt/sun/comms/messaging64/bin/start-msg mshttpd

On Solaris 11, if the above is done as root, it works. But on Solaris 10 it does not.

Similarly, as mentioned in Doc ID 1383299.1, things started by dispatcher are immune to such debugging.

Is there a feature where such debugging could be enabled by the existence of a debug file? Perhaps the file could contain debug environment variables that would be read in by the processes after passing pfexec, so they would actually take effect?

Perhaps it could be owned by root, like restricted.cnf.

That would still require having root access to enable it. But instructing someone with root access how to install a debug file seems a lot less error prone than the alternative hacking.
 

Solution

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms