Public bug reported:

# lsb_release -rd

Description:    Ubuntu 12.10
Release:        12.10

# apt-cache policy lvm2
lvm2:
  Installed: 2.02.95-4ubuntu1
  Candidate: 2.02.95-4ubuntu1
  Version table:
 *** 2.02.95-4ubuntu1 0
        500 http://us.archive.ubuntu.com/ubuntu/ quantal/main amd64 Packages
        100 /var/lib/dpkg/status
root@server01:~# apt-cache policy drbd
drbd8-utils  drbdlinks    

# apt-cache policy drbd8-utils 
drbd8-utils:
  Installed: 2:8.3.13-1.1ubuntu1
  Candidate: 2:8.3.13-1.1ubuntu1
  Version table:
 *** 2:8.3.13-1.1ubuntu1 0
        500 http://us.archive.ubuntu.com/ubuntu/ quantal/main amd64 Packages
        100 /var/lib/dpkg/status

# uname -a
Linux server01 3.5.0-19-generic #30-Ubuntu SMP Tue Nov 13 17:48:01 UTC 2012 
x86_64 x86_64 x86_64 GNU/Linux

# cat /etc/drbd.d/drbd_sp1.res 
resource drbd_sp1 {

        protocol C;
        
        startup {
                wfc-timeout 15;
                degr-wfc-timeout 60;
                become-primary-on server01;
        }

        disk {
                on-io-error detach;
        }

        net {
                cram-hmac-alg sha1;
                shared-secret "asdasd";
                after-sb-0pri discard-zero-changes;
                after-sb-1pri discard-secondary;
                after-sb-2pri disconnect;
                rr-conflict disconnect;
        }

        syncer {
                rate 100M;
                verify-alg sha1;
                al-extents 257;
        }

        on server01 {
                device  /dev/drbd1;
                disk    /dev/sda6;
                address 10.0.0.35:7788;
                meta-disk internal;
        }

        on server02 {
                device  /dev/drbd1;
                disk    /dev/sda6;
                address 10.0.0.36:7788;
                meta-disk internal;
        }
}

# pvdisplay 
  --- Physical volume ---
  PV Name               /dev/drbd1
  VG Name               sp1
  PV Size               9.02 GiB / not usable 3.68 MiB
  Allocatable           yes 
  PE Size               4.00 MiB
  Total PE              2308
  Free PE               2052
  Allocated PE          256
  PV UUID               PV1zLn-tDNh-DK3E-3egp-SqG0-6coB-IA3864
   
# vgdisplay 
  --- Volume group ---
  VG Name               sp1
  System ID             
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  2
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                1
  Open LV               0
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               9.02 GiB
  PE Size               4.00 MiB
  Total PE              2308
  Alloc PE / Size       256 / 1.00 GiB
  Free  PE / Size       2052 / 8.02 GiB
  VG UUID               kfRfDM-4L32-sv33-wsQv-ApqA-wFW2-sSTo3e
   
# lvdisplay 
  --- Logical volume ---
  LV Path                /dev/sp1/test_disk01
  LV Name                test_disk01
  VG Name                sp1
  LV UUID                uNYEy7-zwo5-WAjh-Gw1i-jmO7-ERpQ-E5JHIt
  LV Write Access        read/write
  LV Creation host, time server01, 2012-12-14 11:40:56 +0100
  LV Status              available
  # open                 0
  LV Size                1.00 GiB
  Current LE             256
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           252:0

# df -k
Filesystem     1K-blocks    Used Available Use% Mounted on
/dev/sda1       38445384 1488864  35003448   5% /
udev             2015328       4   2015324   1% /dev
tmpfs             809936     244    809692   1% /run
none                5120       4      5116   1% /run/lock
none             2024836       0   2024836   0% /run/shm
none              102400       0    102400   0% /run/user


# drbd-overview 
 1:drbd_sp1  Connected Primary/Secondary UpToDate/UpToDate C r-----

# lvchange -a n /dev/sp1/test_disk01
(cannot see any error messages) 
# lvscan 
  ACTIVE            '/dev/sp1/test_disk01' [1.00 GiB] inherit


It seems lvm2 not change from ACTIVE to inactive if drbd driver used as
pv.


# vgchange -a n sp1
  0 logical volume(s) in volume group "sp1" now active
# lvscan 
  ACTIVE            '/dev/sp1/test_disk01' [1.00 GiB] inherit

Same problem if you try to de-activate volume group.


In this situation you cannot migrate drbd device :
# drbdadm secondary drbd_sp1 
1: State change failed: (-12) Device is held open by someone
Command 'drbdsetup 1 secondary' terminated with exit code 11


On Precise Pangolin this configuration run without problem.

** Affects: lvm2 (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: 12.10 activate deactivate drbd logical lvm2 quantal quetzal volume

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1090315

Title:
  drbd+lvm2 on quantal quetzal uname to de-activate logical volumes

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/lvm2/+bug/1090315/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to