Skip the navigation

QuickStudy: Logical Volume Manager

By Todd R. Weiss
March 17, 2003 12:00 PM ET

Computerworld - As Linux systems administrators watch over their hardware and software infrastructures, they constantly have to look ahead to how much space to allocate to hard-disk partitions to meet changing needs.

But the process of adding disks or reconfiguring existing drive space is slowed when servers have to be taken off-line for new drive installation and time-consuming rebooting or backup, repartitioning and data restoration.

Those changes can more easily be made using a logical volume manager (LVM), which precludes the need for reboots, shutdowns or downtime. Thus, an LVM can be an administrator's best friend.

Microsoft's Windows and Sun's Solaris and other Unix operating systems have similar volume manager capabilities.

Under Linux, an LVM is enabled by a kernel-loadable module, similar to a device driver in Windows. Kernel modules capture disk functions from user operations and convert them to write to the correct part of the disk. They work like a file system driver, but are far more dynamic.

Support for an LVM wasn't built into the Linux kernel until Version 2.4, but it was available as an add-on. It has been an important tool as Linux continues to make its way into enterprise computing.

"It's a common feature because it's so useful," says Chris Mason, a Linux kernel developer at Nuremburg, Germany-based Linux vendor SuSE Linux AG. "A lot of people, especially in Windows, may not know a lot about it," Mason says. "It's an extra layer to learn about, so a lot of people don't. Then when they move from a smaller server to a larger server, they don't realize how much more easily they can make it work."

The LVM creates an abstraction layer over all the combined storage in a system, so that the details about where the data actually resides are hidden. That allows the total separation of hardware and software because the LVM keeps a table of where the data is written and what volume group and volume it belongs to, allowing drives to be added or changed even while the system is running. And all this happens without software applications or users noticing the changes.

Systems without LVMs are also set up with physical hard drives, but they don't have this virtualization layer. When more disk space is needed, the system must be shut down and the new drives installed, and then they must be provided with file systems to organize data storage. If the new drive is replacing the original drive, the old drive must be backed up so the new drive can receive its data. That all takes time.



Our Commenting Policies