~ubuntu-branches/debian/jessie/lvm2/jessie

« back to all changes in this revision

Viewing changes to lib/metadata/vg.c

  • Committer: Package Import Robot
  • Author(s): Bastian Blank
  • Date: 2013-08-27 13:13:17 UTC
  • mfrom: (30.1.6 sid)
  • Revision ID: package-import@ubuntu.com-20130827131317-4s1pa4b2trpl3xiz
Tags: 2.02.98-6
* Update init script:
  - Use auto-activation.
  - Drop manual loading of dm-mod.
* Fix udev rules:
  - Re-add another oversight.

Show diffs side-by-side

added added

removed removed

Lines of Context:
514
514
 
515
515
        /*
516
516
         * We do not currently support switching the cluster attribute
517
 
         * on active mirrors or snapshots.
 
517
         * on active mirrors, snapshots or RAID logical volumes.
518
518
         */
519
519
        dm_list_iterate_items(lvl, &vg->lvs) {
520
 
                if (lv_is_mirrored(lvl->lv) && lv_is_active(lvl->lv)) {
521
 
                        log_error("Mirror logical volumes must be inactive "
522
 
                                  "when changing the cluster attribute.");
 
520
                /*
 
521
                 * FIXME:
 
522
                 * We could allow exclusive activation of RAID LVs, but
 
523
                 * for now we disallow them in a cluster VG at all.
 
524
                 */
 
525
                if (lv_is_raid_type(lvl->lv)) {
 
526
                        log_error("RAID logical volumes are not allowed "
 
527
                                  "in a cluster volume group.");
 
528
                        return 0;
 
529
                }
 
530
 
 
531
                if (lv_is_active(lvl->lv) &&
 
532
                    (lv_is_mirrored(lvl->lv) || lv_is_raid_type(lvl->lv))) {
 
533
                        log_error("%s logical volumes must be inactive "
 
534
                                  "when changing the cluster attribute.",
 
535
                                  lv_is_raid_type(lvl->lv) ? "RAID" : "Mirror");
523
536
                        return 0;
524
537
                }
525
538