From: "Christian Schröder" <cs@deriva.de>
To: linux-lvm@redhat.com
Subject: Re: [linux-lvm] Is cLVM necessary when accessing different logical volumes on a shared iSCSI target?
Date: Mon, 08 Jul 2013 12:56:57 +0200 [thread overview]
Message-ID: <51DA9AF9.7050807@deriva.de> (raw)
In-Reply-To: <1373132415.9586.YahooMailNeo@web181505.mail.ne1.yahoo.com>
On 06.07.2013 19:40, matthew patton wrote:
>> (either hard-coded or using tags) is *necessary* to make things working or if it
>> is just *adviseable* to prevent using a volume simultaneously from both clients?
>
> You could probably make a case for saying it's adviseable but why do you want to play roulette with your data? Force it to do the right thing and you won't have to run the risk of it doing something unintended. Why the trepidation to doing it correctly?
I just try to understand how things work. But you indeed convinced me to
use tags.
>> logical values are found by vgscan / lvscan, but I cannot access it. Is this the
>> expected behavior? Is there any chance (besides rebooting the client machine) to
>> recover from such a situation?
>
> How did you disconnect from iSCSI? Did you gracefully log out of the client session? However you did it, it seems the kernel believes the device was just yanked offline and after repeated I/O failures marked it bad. Re-introducing the device doesn't magically clear the error state. Then again maybe it's as simple as you not bringing it fully online with a 'vgchange -ay <vg>' and an 'lvchange -ay <lv>'.
After some further investigation I think I have found the reason for the
observed behavior: When I log out of the client session, the block
device (/dev/sda in my case) still seems to be used, probably by the
device mapper itself. So when I log in again, the iSCSI device gets
another device node (/dev/sdb) which obviously doesn't help for the
logical volume. When I deactivate and reactivate the LV, it gets
connected to the new block device and works again.
It also works if I deactivate the LV before logging out of the iSCSI
session. Then the block device is released and reused when I reconnect.
In any case, it seems to be necessary to deactivate and reactivate the LV.
Regards,
Christian
--
Deriva GmbH Tel.: +49 551 489500-42
Financial IT and Consulting Fax: +49 551 489500-91
Hans-B�ckler-Stra�e 2 http://www.deriva.de
D-37079 G�ttingen
Amtsgericht G�ttingen | HRB 3240
Gesch�ftsf�hrer: Dirk Baule, Christian Schr�der
Deriva CA Certificate: http://www.deriva.de/deriva-ca.cer
prev parent reply other threads:[~2013-07-08 10:57 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-02 17:27 [linux-lvm] Is cLVM necessary when accessing different logical volumes on a shared iSCSI target? Christian Schröder
2013-07-03 2:12 ` matthew patton
2013-07-03 13:07 ` Christian Schröder
2013-07-03 13:58 ` matthew patton
2013-07-06 12:47 ` Christian Schröder
2013-07-06 17:40 ` matthew patton
2013-07-08 10:56 ` Christian Schröder [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=51DA9AF9.7050807@deriva.de \
--to=cs@deriva.de \
--cc=linux-lvm@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).