From: Stan Hoeppner <stan@hardwarefreak.com>
To: Slava Pestov <sp@datera.io>
Cc: linux-bcache@vger.kernel.org
Subject: Re: can't attach
Date: Fri, 03 Oct 2014 15:50:01 -0500 [thread overview]
Message-ID: <542F0BF9.8040401@hardwarefreak.com> (raw)
In-Reply-To: <CACHGV4+T0fc3Na=6yrne+NxW+wzd=mxSUqYWGscpuBZwSc9q9g@mail.gmail.com>
On 10/03/2014 03:37 PM, Slava Pestov wrote:
> Please include any bcache messages printed in dmesg when this happens.
[87579.418945] bcache: bch_cached_dev_attach() Can't attach dm-4: already attached
[87579.418947] bcache: __cached_dev_store() Can't attach 8246b830-95d4-420d-aff8-894efc348801
[87579.418947] : cache set not found
For completeness, these are the steps are performed, soup to nuts:
# wipefs -a /dev/dm-4
4 bytes [58 46 53 42] erased at offset 0x0 (xfs)
# wipefs -a /dev/dm-7
4 bytes [58 46 53 42] erased at offset 0x0 (xfs)
# wipefs -a /dev/sdc
# ./make-bcache -B /dev/dm-4 /dev/dm-7 -C /dev/sdc
Already a bcache device on /dev/sdc, overwrite with --wipe-bcache
# ./make-bcache -B /dev/dm-4 /dev/dm-7 -C /dev/sdc --wipe-bcache
UUID: 501486ea-d614-4a32-a137-bc8e004fcb85
Set UUID: 8246b830-95d4-420d-aff8-894efc348801
version: 0
nbuckets: 761856
block_size: 1
bucket_size: 1024
nr_in_set: 1
nr_this_dev: 0
first_bucket: 1
UUID: 261cf532-ca93-45b7-a8fb-1eff57078953
Set UUID: 8246b830-95d4-420d-aff8-894efc348801
version: 1
block_size: 1
data_offset: 16
UUID: eeca31ab-a632-4d7b-94f6-35e9b878344f
Set UUID: 8246b830-95d4-420d-aff8-894efc348801
version: 1
block_size: 1
data_offset: 16
# echo /dev/dm-4 > /sys/fs/bcache/register
# echo /dev/dm-7 > /sys/fs/bcache/register
# echo /dev/sdc > /sys/fs/bcache/register
# ls -la /dev/b*
brw-rw---- 1 root disk 253, 0 Oct 3 14:39 /dev/bcache0
brw-rw---- 1 root disk 253, 1 Oct 3 14:39 /dev/bcache1
# mkfs.xfs /dev/bcache0
meta-data=/dev/bcache0 isize=256 agcount=44, agsize=268435455 blks
= sectsz=512 attr=2, projid32bit=0
data = bsize=4096 blocks=11709285374, imaxpct=5
= sunit=0 swidth=0 blks
naming =version 2 bsize=4096 ascii-ci=0
log =internal log bsize=4096 blocks=521728, version=2
= sectsz=512 sunit=0 blks, lazy-count=1
realtime =none extsz=4096 blocks=0, rtextents=0
# mkfs.xfs /dev/bcache1
meta-data=/dev/bcache1 isize=256 agcount=44, agsize=268435455 blks
= sectsz=512 attr=2, projid32bit=0
data = bsize=4096 blocks=11709285374, imaxpct=5
= sunit=0 swidth=0 blks
naming =version 2 bsize=4096 ascii-ci=0
log =internal log bsize=4096 blocks=521728, version=2
= sectsz=512 sunit=0 blks, lazy-count=1
realtime =none extsz=4096 blocks=0, rtextents=0
# mount -o inode64,nobarrier,noatime,nodiratime /dev/bcache0 /mnt/V1A
# mount -o inode64,nobarrier,noatime,nodiratime /dev/bcache1 /mnt/V2A
# ls -la /sys/fs/bcache
total 0
drwxr-xr-x 3 root root 0 Oct 3 14:39 .
drwxr-xr-x 6 root root 0 Oct 2 16:32 ..
drwxr-xr-x 7 root root 0 Oct 3 14:50 8246b830-95d4-420d-aff8-894efc348801
--w------- 1 root root 4096 Oct 3 14:39 register
--w------- 1 root root 4096 Oct 3 14:50 register_quiet
# echo 8246b830-95d4-420d-aff8-894efc348801 > /sys/block/bcache0/bcache/attach
bash: echo: write error: Invalid argument
> On Fri, Oct 3, 2014 at 1:21 PM, Stan Hoeppner <stan@hardwarefreak.com> wrote:
>> # ls -la /sys/fs/bcache
>> total 0
>> drwxr-xr-x 3 root root 0 Oct 3 14:39 .
>> drwxr-xr-x 6 root root 0 Oct 2 16:32 ..
>> drwxr-xr-x 7 root root 0 Oct 3 14:50 8246b830-95d4-420d-aff8-894efc348801
>> --w------- 1 root root 4096 Oct 3 14:39 register
>> --w------- 1 root root 4096 Oct 3 14:50 register_quiet
>>
>>
>> # echo 8246b830-95d4-420d-aff8-894efc348801 > /sys/block/bcache0/bcache/attach
>> bash: echo: write error: Invalid argument
>>
>>
>> What's the problem here?
>>
>> Thanks,
>> Stan
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-bcache" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2014-10-03 20:49 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-03 20:21 can't attach Stan Hoeppner
2014-10-03 20:37 ` Slava Pestov
2014-10-03 20:50 ` Stan Hoeppner [this message]
2014-10-03 20:57 ` Slava Pestov
2014-10-03 21:14 ` Stan Hoeppner
2014-10-03 21:21 ` Slava Pestov
2014-10-03 21:37 ` Stan Hoeppner
2014-10-03 21:49 ` Slava Pestov
2014-10-03 22:05 ` Stan Hoeppner
2014-10-03 22:08 ` Slava Pestov
2014-10-03 22:43 ` Stan Hoeppner
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=542F0BF9.8040401@hardwarefreak.com \
--to=stan@hardwarefreak.com \
--cc=linux-bcache@vger.kernel.org \
--cc=sp@datera.io \
/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).