NetWorker: restapi.log file not generated on NetWorker server deployed on Red Hat pacemaker cluster

Riepilogo: restapi.log files are not generated on a NetWorker server deployed on the Red Hat pacemaker cluster.

Questo articolo si applica a Questo articolo non si applica a Questo articolo non è legato a un prodotto specifico. Non tutte le versioni del prodotto sono identificate in questo articolo.

Sintomi

  • The NetWorker server is deployed on a Red Hat HA (pacemaker) cluster.
  • Representational State Transfer (REST) Application Programming Interface (API) logs under /nsr/logs/restapi logs are not being generated.

Causa

The shared drive is not being mapped to the REST API logging.

Risoluzione

  1.  Log in to the active node as root.
Active node can be shown with:
pcs resource show
Example:
root@NWrhelNodeC:~# pcs resource show
 Resource Group: NW_group
     fs (ocf::heartbeat:Filesystem):    Started NWrhelNodeC.emclab.local
     ip (ocf::heartbeat:IPaddr):        Started NWrhelNodeC.emclab.local
     nws        (ocf::EMC_NetWorker:Server):    Started NWrhelNodeC.emclab.local
  1. Confirm the mapping used by pacemaker:
lcmap
Example:
root@NWrhelNodeC:~# lcmap
type: NSR_CLU_TYPE;
clu_type: NSR_LC_TYPE;
interface version: 1.0;

type: NSR_CLU_VIRTHOST;
hostname: 192.168.25.40;
local: TRUE;
owned paths: /nsr_share;
  1. Make a copy of the REST API logback.xml:
cp /nsr/authc/webapps/nwrestapi/WEB-INF/classes/logback.xml /nsr/authc/webapps/nwrestapi/WEB-INF/classes/logback.xml.bak
  1. Modify the logback.xml to use the absolute path of the REST API logs directory: 
vi /nsr_share/nsr/authc/webapps/nwrestapi/WEB-INF/classes/logback.xml
Change:
<?xml version="1.0" encoding="UTF-8"?>
<configuration scan="true" scanPeriod="10 seconds">
  <contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator">
    <resetJUL>true</resetJUL>
  </contextListener>

  <define name="logdir" class="com.emc.nw.webapi.LogDir"/>


  <appender name="file" class="ch.qos.logback.core.rolling.RollingFileAppender">
    <file>${logdir}/restapi.log</file>
    <encoder>
      <pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} %-5level [%thread] %logger{15} - %msg%n</pattern>
    </encoder>
    <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
      <fileNamePattern>${logdir}/restapi_%i.log.zip</fileNamePattern>
      <minIndex>1</minIndex>
      <maxIndex>10</maxIndex>
      <totalSizeCap>500MB</totalSizeCap>
...
To:
<?xml version="1.0" encoding="UTF-8"?>
<configuration scan="true" scanPeriod="10 seconds">
  <contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator">
    <resetJUL>true</resetJUL>
  </contextListener>

  <define name="logdir" class="com.emc.nw.webapi.LogDir"/>


  <appender name="file" class="ch.qos.logback.core.rolling.RollingFileAppender">
    <file>/nsr_share/nsr/logs/restapi/restapi.log</file>
    <encoder>
      <pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} %-5level [%thread] %logger{15} - %msg%n</pattern>
    </encoder>
    <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
      <fileNamePattern>/nsr_share/nsr/logs/restapi/restapi_%i.log.zip</fileNamePattern>
      <minIndex>1</minIndex>
      <maxIndex>10</maxIndex>
      <totalSizeCap>500MB</totalSizeCap>
...
NOTE: Ensure that the share path name matches the name of the shared folder outputted by the lcmap command.
  1. Manually create the logs folder
mkdir /nsr_share/nsr/logs/restapi
  1. Change the ownership of the directory to nsrtomcat:
chown nsrtomcat:nsrtomcat /nsr_share/nsr/logs/restapi
  1. Set permissions on the REST API directory:
chmod 755 /nsr_share/nsr/logs/restapi
  1. Restart the clustered NetWorker services:
pcs resource restart nws
  1. Confirm that the restapi.log file is being generated once nws resource starts up:
root@NWrhelNodeC:~# ls -l /nsr_share/nsr/logs/restapi/
total 7428
-rw-------. 1 nsrtomcat nsrtomcat 7603829 Dec 14 11:01 restapi.log
-rw-------. 1 nsrtomcat nsrtomcat       0 Dec 14 10:46 rest_index.raw

Informazioni aggiuntive

Prodotti interessati

NetWorker

Prodotti

NetWorker Family, NetWorker Series
Proprietà dell'articolo
Numero articolo: 000206436
Tipo di articolo: Solution
Ultima modifica: 16 dic 2025
Versione:  4
Trova risposta alle tue domande dagli altri utenti Dell
Support Services
Verifica che il dispositivo sia coperto dai Servizi di supporto.