Avamar: Avamar User Interface (AUI) and Avamar Administrator Console bad response when creating or editing a backup group

Summary: This article addresses an issue with the Avamar Management Console database (MCDB) regarding a column value in the retention_policies table.

This article applies to This article does not apply to This article is not tied to any specific product. Not all product versions are identified in this article.

Symptoms

An attempt to create or edit a backup group results in no response.
Nothing is referenced in the Management Console Service (MCS) logs, but in the rest api logs.

Below shows the Avamar REST API log.
/usr/local/avamar/var/mc/server_log/mc-rest-api.log

java.lang.IllegalArgumentException: No enum constant com.avamar.mc.api.replication.dto.DurationUnits.HOURS
  at java.lang.Enum.valueOf(Unknown Source)
  at com.avamar.mc.api.replication.dto.DurationUnits.valueOf(DurationUnits.java:3)
  at com.avamar.mc.api.retention.service.RetentionServiceImpl.convertRetentionPolicyDescriptor(RetentionServiceImpl.java:194)
  at com.avamar.mc.api.retention.service.RetentionServiceImpl.getRetentions(RetentionServiceImpl.java:65)
  at com.avamar.mc.api.retention.web.RetentionController.getRetentions(RetentionController.java:48)
  at com.avamar.mc.api.retention.web.RetentionController$$FastClassBySpringCGLIB$$5ac7ec93.invoke(<generated>)
  at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218)
  at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:749)
  at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
  at org.springframework.security.access.intercept.aopalliance.MethodSecurityInterceptor.invoke(MethodSecurityInterceptor.java:69)
  at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
  at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:93)
  at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
  at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:688)
  at com.avamar.mc.api.retention.web.RetentionController$$EnhancerBySpringCGLIB$$ebae7189.getRetentions(<generated>)
  at sun.reflect.GeneratedMethodAccessor4160.invoke(Unknown Source)
  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
  at java.lang.reflect.Method.invoke(Unknown Source)

Attention to the error:
java.lang.IllegalArgumentException: No enum constant com.avamar.mc.api.replication.dto.DurationUnits.HOURS

Cause

The MCDB recorded a value of 0 in the unit column of the retention_policies table. 

A value of 0 in this column suggests that the retention period is measured in hours. However, the retention period unit is defined by four values: days [1], weeks [2], months [3], and years [4].

Java does not have a constant value set for the unit of hours so it is not a valid constant value when running enum.valueOf() method.

You can see DurationUnits.HOURS, where it is throwing an error saying no enumeration constant of hours exists.

Example:
MCDB with the faulty entries
admin@avamar:~/>: psql -p 5555 mcdb
psql (10.6)
Type "help" for help.

mcdb=# select id,name,duration,unit from retention_policies;
        id        |             name             | duration | unit
------------------+------------------------------+----------+------
 MONTHLY:PolicyID | Monthly Retention            |        1 |    3
 WEEKLY:PolicyID  | Weekly Retention             |        1 |    2
 Default:POLICYID | Default Retention            |       60 |    1
 EndUser:PolicyID | End User On Demand Retention |       60 |    1
 Minimal:PolicyID | Minimal Retention            |       60 |    1
 RP1652848159766  | Platinum                     |       60 |    0 <-- These 0s
 RP1652848162931  | Gold                         |       60 |    0 <-- These 0s
 RP1652848166086  | Silver                       |       60 |    0 <-- These 0s
 RP1652848169312  | Bronze                       |       60 |    0 <-- These 0s
(9 rows)

Resolution

Step 1:
Take a backup of MCS.
mcserver.sh --flush


Step 2:
Stop MCS.
mcserver.sh --stop --force


Step 3:
Bring up the MCDB manually.
dbmaint.sh  --db=on --dbname=mcdb


Step 4:
Update the value for the retention policies unit to 1, from 0.
psql -d mcdb -p 5555 -c "update retention_policies set unit=1 where unit=0"


Step 5:
Start MCS.
mcserver.sh --start


Step 6:
Ensure that you can now add or edit backup policy in AUI or Avamar Administrator and start the backup scheduler.

Additional Information

See this video:

You can also view this video on YouTube.

Affected Products

Avamar
Article Properties
Article Number: 000200096
Article Type: Solution
Last Modified: 03 Feb 2025
Version:  6
Find answers to your questions from other Dell users
Support Services
Check if your device is covered by Support Services.