Using the direct copy method

Sometimes you must use the direct copy method to migrate data. This method uses the logical volume manager, which uses the UNIX find and cpio commands.

About this task

The find command generates the list of files that are to be migrated. The cpio command migrates the files that are on the list. The following example assumes that you created a file system on the /dev/lv00 logical volume. AIX LVM uses this file system to view part or all of the virtual disks that the storage system made available.

Procedure

  1. Mount the logical volume on a temporary mount point (/mnt in the example).
  2. Change directories to the directory at the top of the file system that you want to move (cd/data in the example).
  3. Enter the find command for a list of file names. A pipe (|) passes as standard output to the standard input of the cpio command.
  4. Unmount both file systems and mount the new file system over the original mount point directory when the migration is complete.

Invoking the mount, cd, find, cpio, and unmount UNIX commands for the direct copy method of data migration

# mount /dev/lv00 /mnt
# cd /data
# find . -print | cpio -pdmuv /mnt
 .
 .
 .
# umount /mnt
# umount /data
# mount /dev/lv00 /data

What to do next

Volume management methods can be usable if the database uses volume serial numbers in its licensing code or uses validity checking. In either of these cases, you might be limited to exporting the database from its old locations or importing the database to its new location.

The database software provides the mechanism to move the data. This mechanism can take the form of a standard database backup and restore if it does not have any specific tools for moving data.