Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP-UX System Administrator's Guide: Logical Volume Management: HP-UX 11i Version 3 > Chapter 4 Troubleshooting LVM

Problems After Reducing the Size of a Logical Volume

» 

Technical documentation

Complete book in PDF
» Feedback
Content starts here

 » Table of Contents

 » Glossary

 » Index

When a file system is first created within a logical volume, it is made as large as the logical volume permits.

If you extend the logical volume without extending its file system, you can subsequently safely reduce the logical volume size, as long as it remains as big as its file system. (Use the bdf command to determine the size of your file system.) After you expand the file system, you can no longer safely reduce the size of the associated logical volume.

If you reduce the size of a logical volume containing a file system to a size smaller than that of a file system within it using the lvreduce command, you corrupt the file system. If you subsequently attempt to mount the corrupt file system, you might crash the system. If this occurs, follow these steps:

  1. Reboot your system in single-user mode.

  2. If you already have a good current backup of the data in the now corrupt file system, skip this step. If you do not have backup data and if that data is critical, try to recover whatever part of the data that might remain intact by attempting to back up the files on the file system.

    Before you attempt any current backup, consider the following:

    • When your backup program accesses the corrupt part of the file system, your system will crash again. You must reboot your system again to continue with the next step.

    • There is no guarantee that all (or any) of your data on that file system will be intact or recoverable. This step is an attempt to save as much as possible. That is, any data successfully backed up in this step will be recoverable, but some or all of your data might not be successfully backed up because of file corruption.

  3. Immediately unmount the corrupted file system if it is mounted.

  4. Use the logical volume for swap space or raw data storage, or use HP SMH or the newfs command to create a new file system in the logical volume. This new file system now matches the current reduced size of the logical volume.

  5. If you have created a new file system on the logical volume, do one of the following:

    • If you have a good prior backup (not the backup from step 2), restore its contents. Because the new file system in the smaller logical volume is smaller than the original file system, you might not have enough space to restore all your original files.

    • If you do not have a good prior backup, attempt to restore as many files as possible from any backup you made in step 2.

    • Use the new file system for creating and storing a new set of files (not for trying to restore the original files).

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 2008 Hewlett-Packard Development Company, L.P.