Debian Bug report logs - #488332
LVM sysfs_scan with newer 2.6.x kernels needs deprecated sysfs layout

version graph

Package: lvm2; Maintainer for lvm2 is Debian LVM Team <pkg-lvm-maintainers@lists.alioth.debian.org>; Source for lvm2 is src:lvm2 (PTS, buildd, popcon).

Reported by: "Stephen M. Benoit" <linux@magnumline.com>

Date: Fri, 27 Jun 2008 23:15:01 UTC

Severity: normal

Found in version lvm2/2.02.06-4etch1

Done: Ben Hutchings <ben@decadent.org.uk>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Debian LVM Team <pkg-lvm-maintainers@lists.alioth.debian.org>:
Bug#488332; Package lvm2. (full text, mbox, link).


Acknowledgement sent to "Stephen M. Benoit" <linux@magnumline.com>:
New Bug report received and forwarded. Copy sent to Debian LVM Team <pkg-lvm-maintainers@lists.alioth.debian.org>. (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: "Stephen M. Benoit" <linux@magnumline.com>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: LVM sysfs_scan with newer 2.6.x kernels needs deprecated sysfs layout
Date: Fri, 27 Jun 2008 18:59:30 -0400
Package: lvm2
Version: 2.02.06-4etch1
Severity: normal
File: /lib/lvm-200/lvm


Hi!  I ran into an LVM bug when I upgraded my kernel to 2.6.25.9.

Briefly:
  Upgrading kernel to 2.6.25.9, the LVM utilities could not find any Volume
  Groups.  This is due to the new /sys/block layout and the LVM sysfs_scan
  expecting the old layout.  Two fixes until sysfs_scan gets updated:
  (1) configure kernel to use deprecated sysfs layout, or,
  (2) set "sysfs_scan = 1" in /etc/lvm/lvm.conf.


In more detail:

  In more recent 2.6.x kernels, the /sys/block/<device> are symlinks to
  elsewhere in /sys/, instead actual directories like they used to be.

  In the stable version of lvm2, pvscan, pvs, and (all?) other lvm tools skip
  over the devices listed as symlinks in /sys/block/.  This meant that none of
  the Volume Groups or Physical Volumes were found.

  I also note that /etc/lvm/lvm.conf uses the default setting of

  sysfs_scan = 1

  which checks if the device is a valid block device.  I probably should have
  just set this to 0, but to test another fix, I recompiled the kernel with
  the options:

    CONFIG_SYSFS_DEPRECATED=y 
    CONFIG_SYSFS_DEPRECATED_V2=y

  This reverted to the old layout of /sys/block/, and my Volume Groups came
  back without other difficulty.  But the kernel config warns that:

    "None of these features or values should be used today, as they export
    driver core implementation details to userspace or export properties which
    can't be kept stable across kernel releases.
    ...
    If enabled, this option will also move any device structures that belong
    to a class, back into the /sys/class hierarchy, in order to support older
    versions of udev and some userspace programs."

  A real fix would be to adjust the sysfs_scan to use the new sysfs block
  device layout (following symlinks).


Best regards,

Stephen Benoit

-- System Information:
Debian Release: 4.0
  APT prefers stable
  APT policy: (990, 'stable')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.25.9
Locale: LANG=en_US, LC_CTYPE=en_US (charmap=ISO-8859-1)

Versions of packages lvm2 depends on:
ii  debconf [debconf-2.0]  1.5.11etch1       Debian configuration management sy
ii  libc6                  2.3.6.ds1-13etch5 GNU C Library: Shared libraries
ii  libdevmapper1.02       2:1.02.08-1       The Linux Kernel Device Mapper use
ii  libncurses5            5.5-5             Shared libraries for terminal hand
ii  libreadline5           5.2-2             GNU readline and history libraries
ii  libselinux1            1.32-3            SELinux shared libraries
ii  libsepol1              1.14-2            Security Enhanced Linux policy lib
ii  lvm-common             1.5.20            The Logical Volume Manager for Lin

lvm2 recommends no packages.

-- debconf information excluded




Information forwarded to debian-bugs-dist@lists.debian.org, Debian LVM Team <pkg-lvm-maintainers@lists.alioth.debian.org>:
Bug#488332; Package lvm2. (full text, mbox, link).


Acknowledgement sent to Alasdair G Kergon <agk@redhat.com>:
Extra info received and forwarded to list. Copy sent to Debian LVM Team <pkg-lvm-maintainers@lists.alioth.debian.org>. (full text, mbox, link).


Message #10 received at 488332@bugs.debian.org (full text, mbox, reply):

From: Alasdair G Kergon <agk@redhat.com>
To: "Stephen M. Benoit" <linux@magnumline.com>, 488332@bugs.debian.org
Subject: Re: Bug#488332: LVM sysfs_scan with newer 2.6.x kernels needs deprecated sysfs layout
Date: Sat, 28 Jun 2008 00:40:31 +0100
On Fri, Jun 27, 2008 at 06:59:30PM -0400, Stephen M. Benoit wrote:
>   Upgrading kernel to 2.6.25.9, the LVM utilities could not find any Volume
>   Groups.  This is due to the new /sys/block layout and the LVM sysfs_scan
>   expecting the old layout.  Two fixes until sysfs_scan gets updated:
>   (1) configure kernel to use deprecated sysfs layout, or,
>   (2) set "sysfs_scan = 1" in /etc/lvm/lvm.conf.

I think you mean = 0 to turn the feature off.
 
or

(3) update your copy of lvm2 to match when you update your kernel to one that
changes part of the userspace-kernel interface that lvm2 uses.

Alasdair
-- 
agk@redhat.com




Reply sent to Ben Hutchings <ben@decadent.org.uk>:
You have taken responsibility. (Fri, 13 Mar 2015 13:54:05 GMT) (full text, mbox, link).


Notification sent to "Stephen M. Benoit" <linux@magnumline.com>:
Bug acknowledged by developer. (Fri, 13 Mar 2015 13:54:05 GMT) (full text, mbox, link).


Message #15 received at 488332-done@bugs.debian.org (full text, mbox, reply):

From: Ben Hutchings <ben@decadent.org.uk>
To: 488332-done@bugs.debian.org
Subject: Re: LVM sysfs_scan with newer 2.6.x kernels needs deprecated sysfs layout
Date: Fri, 13 Mar 2015 13:50:26 +0000
[Message part 1 (text/plain, inline)]
Closing as this doesn't affect any supported version of Debian.

Ben.

-- 
Ben Hutchings
If the facts do not conform to your theory, they must be disposed of.
[signature.asc (application/pgp-signature, inline)]

Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Sat, 11 Apr 2015 07:27:48 GMT) (full text, mbox, link).


Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Sun Jan 7 08:57:37 2018; Machine Name: beach

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.