A problem restoring vm with dsmc

joluinfante

ADSM.ORG Member
Joined
Sep 28, 2015
Messages
22
Reaction score
0
Points
0
PREDATAR Control23

Hi!
I have a script with dsmc restore vm. This script works ok. I'm using to restore all vm's to drs environment. But, I did problems with a few vm's (3 from 30), I'm receiving the "TSM Scrollable PICK Window". I'm thinking there is a problem with last backup, and, I need to (automatically), answer to it responding "1" and "O". But, I did try:
echo "1\nO\n" | dsmc restore vm ...
But, don't works.
There is a method to inject by stdin the options?
If I type the options by hand, It is working, but, this is a batch script, and I need to do i automatically.
Can any one help me?

TIA
jorge infante
rosario - santa fe - argentina
 
PREDATAR Control23

What are the questions you have to answer 1 and 0 to?
 
PREDATAR Control23

Hi!
Thanks for your response.
I'm receiving this screen:

Restore of Virtual Machine 'xxx' started
TSM Scrollable PICK Window - Restore VM
# Backup Date/Time Size Type
1. |11/03/16 01:11:31 35,15 GB IFINCR A xxx
2. |12/03/16 00:34:53 35,15 GB IFINCR A xxx

<U>=Up <D>=Down <T>=Top <B>=Bottom <R#>=Right <L#>=LEft
<G#>=Goto Line # <#>=Toggle Entry <+>=Select All <->=Deselect All
<#:#+>=Select a Range <#:#->=Deselect A Range <O>=Ok <C>=Cancel
pick>


I'm thinking the <2> backup have problems.
Then, I need to select the <1> backup.
 
PREDATAR Control23

What's the command you used to do the restore? Shouldn't see that list unless you have "-pick" in the options for the command.
 
PREDATAR Control23

I'm not using the -pick parameter.
I'm thinking I have a problem with last backup, and then, tsm give me a list to select another backup to do the restore.
The command I'm using is:
dsmc restore vm xxx -vmname="xxx" -datacenter="XXX" -host=ip-of-destination-host -datastore=destination-datastore -asnodename=YYY
This command are working for a lot of vm's, but, is failing for a few vm's.
 
PREDATAR Control23

Hi.
More information.
If I did select the "2" option (vm backup with error), I receive this message:

TSM Scrollable PICK Window - Restore VM

# Backup Date/Time Size Type A/I Virtual Machine
------------------------------------------------------------------------
1. | 11/03/16 01:11:32 35,15 GB IFINCR A talasa
2. | 12/03/16 00:34:53 35,15 GB IFINCR A talasa
|
0---------10--------20--------30--------40--------50--------60--------70
<U>=Up <D>=Down <T>=Top <B>=Bottom <R#>=Right <L#>=Left
<G#>=Goto Line # <#>=Toggle Entry <+>=Select All <->=Deselect All
<#:#+>=Select A Range <#:#->=Deselect A Range <O>=Ok <C>=Cancel
pick> 2
TSM Scrollable PICK Window - Restore VM

# Backup Date/Time Size Type A/I Virtual Machine
------------------------------------------------------------------------
1. | 11/03/16 01:11:32 35,15 GB IFINCR A talasa
x 2. | 12/03/16 00:34:53 35,15 GB IFINCR A talasa
|
0---------10--------20--------30--------40--------50--------60--------70
<U>=Up <D>=Down <T>=Top <B>=Bottom <R#>=Right <L#>=Left
<G#>=Goto Line # <#>=Toggle Entry <+>=Select All <->=Deselect All
<#:#+>=Select A Range <#:#->=Deselect A Range <O>=Ok <C>=Cancel
pick> O
Starting Full VM restore of VMware Virtual Machine 'talasa' target node name='RM', data mover node name='
DM1_DRS'
Restoring virtual machine 'talasa' to new VM with name 'talasa'.
ANS2092I The restore process will override the original inventory path that was saved with this virtual machine.
Restoring VM configuration information for 'talasa'
Creating snapshot for virtual machine 'talasa'
Restoring disk [DRSSTG02_ESX04_ENSAYO] talasa/talasa.vmdk (Hard Disk 1), Capacity: 38.654.705.664 (hotadd)[receiving]
Restoring IFINCR (12/03/16 00:34:53) - bytes to restore: 31.879.856.128
Removing snapshot for virtual machine 'talasa'
** Unsuccessful **
ANS0225E Low level qualifier of the object name should start with the directory delimiter.
< 0 B> [ - ]
>>>>>> Restore Processing Interrupted!! <<<<<<
ANS4177E Full VM restore of VMware Virtual Machine 'talasa' failed with RC=2018 target node name='RM', data mover node name='DM1_DRS'

Total number of objects restored: 0
Total number of objects failed: 1
Total number of bytes transferred: 0 B
Data transfer time: 0,00 sec
Network data transfer rate: 0,00 KB/sec
Aggregate data transfer rate: 0,00 KB/sec
Elapsed processing time: 00:01:41
ANS0225E Low level qualifier of the object name should start with the directory delimiter.

And returns a code "12"


Then, If I can't to restore another version of vm backup, I need to resolve the problem of vm backup (is RC=2018). I did enable the debug for it, and cannot know what is the problem.
 
PREDATAR Control23

So, for this VM, you have 2 active backups. The first one works and the second doesn't, is that correct?

Compare with other VMs, one that works without being prompted and one that doesn't using:
Code:
dsmc query vm xxx -vmname="xxx"
Check to see if you have 2 active backups for the ones you are not prompted. If there is only ones for the ones with no prompt, and 2 for those that you get prompted, that's likely the cause. If that's the case, then you should delete the 2nd backup.
 
PREDATAR Control23

You are ok, I have 2 backups active.
I'm seeing:

# Backup date Mgmt Class Size Type A/I Virtual Machine
--- ----------- ---------- ---- ---- --- ---------------
1 11/03/16 01:11:32 RMVMCFG_MC 35,15 GB IFINCR A talasa
2 12/03/16 00:34:53 RMVMCFG_MC 35,15 GB IFINCR A talasa

What is the method to delete the backup?

What is the cause of the two backups actives?
Very important: I'm restoring from a replicated node.

I did enable the debug, and, I see this messages:

vmcommonrestvddk.cpp( 683): Restoring disk [DRSSTG02_ESX04_ENSAYO] talasa/talasa.vmdk (Hard Disk 1), Capacity: 38.654.705.664 (hotadd)[receiving]
vmoptrestvddk.cpp (3666): =========> vmVMwareOptRestoreDisk(): Entering
vmoptrestvddk.cpp (3044): =========> Entering vmCommonGetAndCheckDiskItem()
vmoptrestvddk.cpp (3117): vmCommonPrepareTimeAndDateStrings(): snapshot timestamp: 12/03/16 00:34:53
vmoptrestvddk.cpp (3125): Restoring IFINCR (12/03/16 00:34:53) - bytes to restore: 31.879.856.128
vmVSphereTaskStatus.cpp( 511): =========> Entering setVSphereTaskDescription()
vmVSphereTaskStatus.cpp( 522): setVSphereTaskDescription: Setting description for vSphere task to 'Incremental Forever - Incremental'; moRef 'task-2402'
vmvisdk.cpp (10906): ENTER =====> visdkSetTaskDescription
vmvisdk.cpp (9945): ENTER =====> visdkGetTaskStatus()
vmvisdk.cpp (4600): =========> Entering visdkGetObjectProperties(v5.0)
vmvisdk.cpp (4657): <========= Exiting visdkGetObjectProperties() , rc = 0
vmvisdk.cpp (9975): visdkGetTaskStatus(): info objects found 1
vmvisdk.cpp (9984): visdkGetTaskStatus(): property 1
vmvisdk.cpp (10061): visdkGetTaskStatus(): TaskInfoState = 'ns2__TaskInfoState__running'
vmvisdk.cpp (9945): EXIT <===== visdkGetTaskStatus()
vmvisdk.cpp (10906): EXIT <===== visdkSetTaskDescription, rc = 0
vmVSphereTaskStatus.cpp( 542): <========= Exiting setVSphereTaskDescription()
vmoptrestvddk.cpp (2956): =========> Entering BuildCtlAndDatList()
vmAPISendData.cpp ( 499): =========> Entering vmAPISendData::vmAPISendData()
vmAPISendData.cpp ( 511): =========> vmAPISendData::vmAPISendData(): Exiting
vmquery.cpp (1123): =========> Entering vmVddkQueryVM()
vmquery.cpp (1125): vmVddkQueryVM(): fs=\VMFULL-talasa, hl=, ll=, objState=255
vmAPISendData.cpp (1589): =========> Entering vmAPISendData::beginQuery()
vmAPISendData.cpp (1607): vmAPISendData::beginQuery(): Performing backup query.
sesscntl.cpp (6095): ---------> Entering AsNodeCheck()
sesscntl.cpp (6223): <--------- Exiting AsNodeCheck()
vmAPISendData.cpp (1678): vmAPISendData::beginQuery(): error in dsmBeginQuery. rcMsg=ANS0225E (RC2018) Low level qualifier of the object name should start with the directory delimiter.
vmquery.cpp (1228): vmVddkQueryVM(): beginQuery() failed with rc = 2018
vmAPISendData.cpp ( 522): =========> Entering vmAPISendData::~vmAPISendData()
vmAPISendData.cpp ( 523): =========> vmAPISendData::~vmAPISendData(): Exiting
vmoptrestvddk.cpp (2979): BuildCtlAndDatList(): vmVddkQueryVM() returned rc=2018 and number returned VMs = 0
vmoptrestvddk.cpp (3720): =========> vmVMwareOptRestoreDisk(): Exiting, rc = 2018
 
PREDATAR Control23

You are ok, I have 2 backups active.
I'm seeing:
Are you seeing 2 backups as well for the VMs that restore fine?

What is the cause of the two backups actives?
Very important: I'm restoring from a replicated node.

I did enable the debug, and, I see this messages:

Probably best to open a problem ticket with IBM to troubleshoot this and provide the best course of action for your situation.
 
PREDATAR Control23

Thanks for all.
I did resolve with:

dsmc query vm ${1} -asnodename=RM | grep "IF.... A" >${TMP1}
if [ `cat ${TMP1} | wc -l` -ne 1 ]
then
export WATH="-pitdate=`head -1 ${TMP1} | awk {'print $2'}` -pittime=`head -1 ${TMP1} | awk {'print $3'}`"
else
export WATH=""
fi
rm -f ${TMP1}
#
dsmc restore vm ${1} -vmname="${1}" -datacenter="DRS" -host=${ip} -datastore=${DATASTORE} -asnodename=RM ${WATH}
 
Top