home *** CD-ROM | disk | FTP | other *** search
/ Clickx 115 / Clickx 115.iso / software / tools / windows / tails-i386-0.16.iso / live / filesystem.squashfs / usr / share / doc / lvm2 / testing.txt < prev   
Encoding:
Text File  |  2007-09-25  |  1.2 KB  |  42 lines

  1. Here's how I test new LVM2 builds without interfering with the stable
  2. LVM2 that is running the LV's on my development box.
  3.  
  4. 1) Create a set of loopback devices.
  5.  
  6. 2) Create a new directory to contain the LVM2 configuration files for
  7.    this setup.  (I use /etc/lvm_loops)
  8.  
  9. 3) Write a suitable lvm.conf file, this goes in the directory you just
  10.    created.  eg, my /etc/lvm_loops/lvm.conf looks like:
  11.  
  12.    log {
  13.         file="/tmp/lvm2_loop.log"
  14.         level=9
  15.         verbose=0
  16.         overwrite=1
  17.    }
  18.  
  19.    devices {
  20.         scan = "/dev"
  21.         filter = ["a/loop/", "r/.*/"]
  22.    }
  23.  
  24.  
  25.    The important thing to note is the devices section which makes sure
  26.    that only the loopback devices are considered for LVM2 operations.
  27.  
  28. 4) When you want to use this test setup just set the environment
  29.    variable LVM_SYSTEM_DIR to point to your config directory
  30.    (/etc/lvm_loops in my case).
  31.  
  32. 5) It's a good idea to do a vgscan to initialise the filters:
  33.  
  34.    export LVM_SYSTEM_DIR=/etc/lvm_loops
  35.    ./lvm vgscan
  36.  
  37.    where ./lvm is the new build of LVM2 that I'm trying out.
  38.  
  39. 7) Test away.  Make sure that you are explicit about which lvm
  40.    executable you want to execute (eg, ./lvm if you are in
  41.    LVM2/tools).
  42.