- Community Home
- >
- Storage
- >
- HPE SimpliVity
- >
- Re: Copy Backup Jobs
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-12-2019 02:59 AM
12-12-2019 02:59 AM
Copy Backup Jobs
Hello to all,
i´ve got an implementation of new cubes at a customer site. Now i would like to copy the existing backups to the new federation. From the gui it is possible to copy the jobs but only one after another. Selecting more backup jobs doen´t give you the menue point "copy backups". With the cli it is also not to comfortable because the use of wildcarts is very limited so are my abilities to write a script.
I once had a copy backup script from SimpliVity that did the job but with the version 3.7.x it doesnt work anymore.
Could someone please tell me an easy way to copy the backups to the new federation? Any help is appreciated
Cheers,
Nick
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-16-2019 04:01 AM
12-16-2019 04:01 AM
Re: Copy Backup Jobs
Is the original cluster being decommissioned ?
Probably best to open a support case a script should exist.
I am an HPE employee
[Any personal opinions expressed are mine, and not official statements on behalf of Hewlett Packard Enterprise]

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-17-2019 04:02 AM
12-17-2019 04:02 AM
Re: Copy Backup Jobs
@NZamp, The script that @DaveOb is referring to is this one:
#!/usr/bin/env python
'''
This script will move VM backups from one cluster to another, VM-by-VM.
USAGE: ./backup_move.py --vm <vm> --datastore <datastore> --source_cluster <source_cluster> --destination_cluster <destination_cluster>
'''
import argparse
import subprocess
import sys
import xml.etree.ElementTree as etree
def parse_args():
'''Parse command line arguments'''
parser = argparse.ArgumentParser()
parser.add_argument('--vm',
required=True,
help="Specify the VM name")
parser.add_argument('--datastore',
required=True,
help="Specify the source datastore")
parser.add_argument('--source_cluster',
required=True,
help="Specify the source cluster")
parser.add_argument('--destination_cluster',
required=True,
help="Specify the destination cluster")
return parser.parse_args()
class Parameter(object):
'''Create Parameter dictionary and strip UUIDs'''
def __init__(self, name):
self.name = name
self.value = []
def __len__(self):
return len(self.value)
def __getitem__(self, key):
return self.value[key]
def add(self, line):
'''Strip XML and append to a list'''
xml = etree.fromstring(line)
value = etree.tostring(xml, encoding='UTF-8', method='text')
self.value.append(value)
def enumerate_backups(vm, datastore):
'''Use svt-backup-show to enumerate backups'''
command = subprocess.check_output(['svt-backup-show',
'--vm', vm,
'--datastore', datastore,
'--output', 'xml',
'--max-results', '25000'])
temp = command.splitlines()
virtual_machine = Parameter('virtual_machine')
backup = Parameter('backup')
datastore = Parameter('datastore')
for line in temp:
if 'hiveName' in line: virtual_machine.add(line)
elif 'name' in line: backup.add(line)
elif 'dsId' in line: datastore.add(line)
return (virtual_machine, backup, datastore)
def move_backup(args):
'''Calculate backup unique bytes'''
virtual_machine, backup, datastore = enumerate_backups(args.vm, args.datastore)
zipper = zip(virtual_machine, backup, datastore)
for index, (virtual_machine,
backup,
datastore) in enumerate(zipper, start=1):
try:
print "* Copying {}({}) backup {} of {}".format(backup, virtual_machine, index, len(zipper))
subprocess.check_output(['svt-backup-copy',
'--vm', virtual_machine,
'--backup', backup,
'--datastore', datastore,
'--src-cluster', args.source_cluster,
'--dst-cluster', args.destination_cluster])
except subprocess.CalledProcessError as error:
pass
if __name__ == '__main__':
ARGS = parse_args()
move_backup(ARGS)
Please note, this is provided as-is with no warranty of any kind. While I am a HPE employee, this is not the work of HPE.
Let me know if this works for you.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-27-2019 12:25 AM
12-27-2019 12:25 AM
Re: Copy Backup Jobs
Hello Scott,
the script works on machines that are still running on the old cluster. The backups are copied with no problems but when i try to copy a backup of a machine that is already migrated, i get the error "ERROR [10]: Unknown VM or VM not found in datastore or VM not stored by SimpliVity.". When i use the gui i can copy the backups without a problem.
Cheers,
Nick