Avamar: Avamar User Interface (AUI) ja Avamar Administrator Console epäonnistuivat varmuuskopioryhmää luotaessa tai muokattaessa

Summary: Artikkeli korjaa Avamar Management Console -tietokannan (MCDB) ongelman, joka liittyy retention_policies-taulukon sarakearvoon.

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

Yritys luoda varmuuskopioryhmä tai muokata sitä ei johda vastaukseen.
Management Console Service (MCS) -lokeissa ei viitata mihinkään muuhun kuin muihin API-lokeihin.

Alla näkyy Avamar REST API -loki.
/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)

Huomio virheeseen:
java.lang.IllegalArgumentException: No enum constant com.avamar.mc.api.replication.dto.DurationUnits.HOURS

Cause

MCDB kirjasi arvon 0 retention_policies taulukon yksikkösarakkeeseen. 

Tämän sarakkeen arvo 0 tarkoittaa, että säilytysjakso mitataan tunteina. Säilytysjaksoyksikkö määritellään kuitenkin neljällä arvolla: päivät [1], viikot [2], kuukaudet [3] ja vuodet [4].

Java-tunnille ei ole määritetty vakioarvoa, joten se ei ole kelvollinen vakioarvo enum.valueOf()-menetelmää suoritettaessa.

Näet DurationUnits.HOURS, jossa se heittää virheen, jonka mukaan tuntien luettelointivakiota ei ole.

Esimerkki:
MCDB virheellisillä merkinnöillä
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

Vaihe 1:
Ota varmuuskopio MCS: stä.
mcserver.sh --flush


Vaihe 2:
Pysäytä MCS.
mcserver.sh --stop --force


Vaihe 3:
Avaa MCDB manuaalisesti.
dbmaint.sh  --db=on --dbname=mcdb


Vaihe 4:
Päivitä säilytyskäytäntöyksikön arvo 0:sta arvoon 1.
psql -d mcdb -p 5555 -c "update retention_policies set unit=1 where unit=0"


Vaihe 5:
Käynnistä MCS.
mcserver.sh --start


Vaihe 6:
Varmista, että voit nyt lisätä varmuuskopiointikäytännön tai muokata sitä AUI:ssa tai Avamar Administratorissa ja käynnistää varmuuskopioinnin ajoituksen.

Additional Information

Katso tämä video:

Voit katsoa tämän videon myös YouTubessa.

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.