Previous  
Product: File System Manual Pages for Storage Foundation   
Manual: Maintenance Commands (1m)   

vxupgrade

NAME

vxupgrade - upgrade the disk layout of a mounted VxFS file system

SYNOPSIS


vxupgrade [ -n new_version ] [ -r rawdev ] mount_point

AVAILABILITY

VRTSvxfs

DESCRIPTION

vxupgrade prints the current disk layout version number for a VERITAS file system or upgrades the file system to a new disk layout. vxupgrade operates on file systems mounted for read/write access: mount_point must be a mounted VxFS file system. You cannot upgrade directly from the oldest disk layout version to the newest disk layout version; you must upgrade to the next level disk layout first.

Only a privileged user can query or upgrade a VxFS file system.

When invoked with the -n option, vxupgrade upgrades the disk layout to the specified version. When invoked without the -n option, vxupgrade prints the disk layout version number of the file system. To perform an upgrade, vxupgrade freezes the file system, allocates and initializes the new structures, frees the space used by the old structures, then thaws the file system.

vxupgrade employs a lock file ( lost+found/.fsadm ) on the file system to ensure that only one instance of vxupgrade is running at any time. vxupgrade and fsadm cannot run simultaneously, so the lock file also ensures that vxupgrade does not execute while a file system reorganization is in progress. When vxupgrade is invoked for an upgrade, it opens the lock file in the root of the file system specified by mount_point. If the lock file does not exist, it is created. The fcntl(2) system call is used to obtain a write lock on the file. If the write lock fails, vxupgrade fails, assuming that another vxupgrade or fsadm is running.

NOTES

Disk layout versions cannot be downgraded.

Upgrading to disk layout Version 6 changes all inodes in the file system. A file system with disk layout Version 5 can be mounted and upgraded to Version 6 disk layout.

To upgrade from Version 4 disk layout to Version 6, you must upgrade to Version 5 first. This requires two separate invocations of the vxupgrade command. The upgrade may fail due to lack of free space at each step (see Free Space Requirement below).

Optionally, prior to upgrading a file system to disk layout Version 6, delete all existing Storage Checkpoints. A Storage Checkpoint created on a file system with a disk layout prior to Version 6 stores a complete copy of the inodes at the time it was taken. Thus, a file system with one Storage Checkpoint takes approximately twice as long to upgrade as a file system without Storage Checkpoints. Conversely, a Storage Checkpoint created on a file system with disk layout Version 6 or later stores only the inodes of files whose data blocks were modified. As a result, the time required to upgrade the disk layout Version in the future is less affected by the number of Storage Checkpoints on the file system.

CLUSTER FILE SYSTEM ISSUES

Cluster mounted file systems can be upgraded only from the primary.

DIAGNOSTICS

vxupgrade returns an exit value of 0 if the upgrade is successful. vxupgrade returns 1 if the upgrade fails due to insufficient free space, returns 32 if the specified mount point is not a VxFS file system, and returns 2 if the upgrade fails for another reason.

OPTIONS

-n " new_version"

Disk layout version number to which to upgrade. new_version can be 5 or 6.

-r " rawdev"

Path name of a raw device. This option can be used when vxupgrade cannot determine which raw device corresponds to the mount point (when /etc/mnttab is corrupted, for example).

FREE SPACE REQUIREMENT

vxupgrade requires free space on the file system to perform the upgrade; the upgrade may fail if there is not enough free space. It is difficult to determine the exact amount of space required to upgrade a VxFS file system, but you can estimate the maximum space required.

Typically, upgrading a disk layout Version 4 file system to disk layout Version 5 does not require much extra disk space.

The space and time required to complete the upgrade increases with the number of extended attributes or hard links in the file system. Typical maximum space to convert to a Version 6 disk layout is at least two additional inodes with one block for every inode. The number of inodes is the sum total of inodes across all filesets in the file system (see the fsdb_vxfs(1M) manual page for information on how to obtain the number of inodes in a fileset). Allow at least ten minutes to upgrade for every million inodes in the file system.


Note   Note    Upgrading requires free extents of 8K or greater in size. If a file system has sufficient free space, but no extents greater than or equal to 8K, the upgrade will fail. To ensure that there are 8K extents available, defragment the file system (see the fsadm_vxfs(1M) manual page for information on how to obtain the number of free extents in a file system and how to defragment a file system).

FILES

mount_point /lost+found/.fsadm

Lock file.

SEE ALSO

fsadm_vxfs (1M), fsdb_vxfs (1M), mkfs_vxfs (1M), quotaon(1M), vxfsconvert (1M), fcntl(2), fs(4), vxfsio (7)
VERITAS File System Administrator's Guide
 ^ Return to Top Previous  
Product: File System Manual Pages for Storage Foundation  
Manual: Maintenance Commands (1m)  
VERITAS Software Corporation
www.veritas.com