How to configure /var/log/nexus as log directory

I’m trying to configure NXRM3 (3.19.1) like this og Linux:

installdir: /opt/nexus
datadir: /var/lib/nexus/work
tmpdir: /var/lib/nexus/tmp
logdir: /var/log/nexus

by using the following vmoptions:

-Xms2703m
-Xmx2703m
-XX:MaxDirectMemorySize=2703m
-XX:+UnlockDiagnosticVMOptions
-XX:+LogVMOutput
-XX:LogFile=/var/log/nexus/jvm.log
-XX:-OmitStackTraceInFastThrow
-Djava.net.preferIPv4Stack=true
-Dkaraf.home=.
-Dkaraf.base=.
-Dkaraf.etc=etc/karaf
-Djava.util.logging.config.file=etc/karaf/java.util.logging.properties
-Dkaraf.data=/var/lib/nexus/work
-Dkaraf.log=/var/log/nexus
-Djava.io.tmpdir=/var/lib/nexus/tmp
-Dkaraf.startLocalConsole=false
-Djava.endorsed.dirs=lib/endorsed

But the only file that is placed in the logdir is jvm.log …

To me it seems like karaf.log is not used.
I can only find one place where it is used and that is
nexus-3.19.1-01/system/org/apache/karaf/features/standard/4.2.6/standard-4.2.6-features.xml:file.target = ${karaf.log}/audit.txt

It seems like all logging is configured using ${karaf.data}/log/ and not ${karaf.log}/

Is my only option here to change all the configuration files?

Regards
Hugo

The logging is configured in the xml files in the $installdir/etc/logback/ directory, you can change the log locations there.

Rich

Thanks Rich

I found these two files outside the etc/logback folder.

/opt/nexus/nexus-3.19.1-01/etc/fabric/elasticsearch.yml: logs: ${karaf.data}/log
/opt/nexus/nexus-3.19.1-01/etc/karaf/custom.properties:karaf.bootstrap.log=${karaf.data}/log/karaf.log

I guess I’ll have to change these as well ?

-Hugo