public inbox for linux-bcache@vger.kernel.org
 help / color / mirror / Atom feed
* About physically swapping backing and cache device
@ 2014-01-07  8:52 Josep Lladonosa
  2014-01-07 21:35 ` Kent Overstreet
  0 siblings, 1 reply; 3+ messages in thread
From: Josep Lladonosa @ 2014-01-07  8:52 UTC (permalink / raw)
  To: linux-bcache@vger.kernel.org

Hello,


I have been using bcache for some months. Now I am with 3.12.6 kernel
(stable! :)
Thanks and congratulations for the good work.

I have in the laptop this configuration:

/dev/sda7 as backing device (hard drive partition)
/dev/sdb as cache device (SSD)

1) I would like to physically swap sda and sdb (a matter of different
bus speeds) in order to improve ata speed for SSD. The fact is that in
a case of this, would I have to "reregister" anything in bcache, or it
will run referenced to UUIDs and so?

2) I think I would have to install GRUB into /dev/sdb (it has no
partitions defined). Would it be safe installing GRUB in a cache
device? Future configuration would be /dev/sda for the cache (SSD) and
/dev/sdb for the backing device (hard drive).



-- 
--
Salutacions...Josep
--

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: About physically swapping backing and cache device
  2014-01-07  8:52 About physically swapping backing and cache device Josep Lladonosa
@ 2014-01-07 21:35 ` Kent Overstreet
  2014-01-07 23:07   ` Darrick J. Wong
  0 siblings, 1 reply; 3+ messages in thread
From: Kent Overstreet @ 2014-01-07 21:35 UTC (permalink / raw)
  To: Josep Lladonosa; +Cc: linux-bcache@vger.kernel.org

On Tue, Jan 07, 2014 at 09:52:50AM +0100, Josep Lladonosa wrote:
> Hello,
> 
> 
> I have been using bcache for some months. Now I am with 3.12.6 kernel
> (stable! :)
> Thanks and congratulations for the good work.
> 
> I have in the laptop this configuration:
> 
> /dev/sda7 as backing device (hard drive partition)
> /dev/sdb as cache device (SSD)
> 
> 1) I would like to physically swap sda and sdb (a matter of different
> bus speeds) in order to improve ata speed for SSD. The fact is that in
> a case of this, would I have to "reregister" anything in bcache, or it
> will run referenced to UUIDs and so?

Everything's referenced with UUIDs, so it'll all just work.

> 2) I think I would have to install GRUB into /dev/sdb (it has no
> partitions defined). Would it be safe installing GRUB in a cache
> device? Future configuration would be /dev/sda for the cache (SSD) and
> /dev/sdb for the backing device (hard drive).

Bcache doesn't touch the first 4k of the device, so if it's just grub's MBR (512
bytes) that should be fine. I would verify that grub isn't touching more than
the first 4k of the device though.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: About physically swapping backing and cache device
  2014-01-07 21:35 ` Kent Overstreet
@ 2014-01-07 23:07   ` Darrick J. Wong
  0 siblings, 0 replies; 3+ messages in thread
From: Darrick J. Wong @ 2014-01-07 23:07 UTC (permalink / raw)
  To: Kent Overstreet; +Cc: Josep Lladonosa, linux-bcache@vger.kernel.org

On Tue, Jan 07, 2014 at 01:35:58PM -0800, Kent Overstreet wrote:
> On Tue, Jan 07, 2014 at 09:52:50AM +0100, Josep Lladonosa wrote:
> > Hello,
> > 
> > 
> > I have been using bcache for some months. Now I am with 3.12.6 kernel
> > (stable! :)
> > Thanks and congratulations for the good work.
> > 
> > I have in the laptop this configuration:
> > 
> > /dev/sda7 as backing device (hard drive partition)
> > /dev/sdb as cache device (SSD)
> > 
> > 1) I would like to physically swap sda and sdb (a matter of different
> > bus speeds) in order to improve ata speed for SSD. The fact is that in
> > a case of this, would I have to "reregister" anything in bcache, or it
> > will run referenced to UUIDs and so?
> 
> Everything's referenced with UUIDs, so it'll all just work.
> 
> > 2) I think I would have to install GRUB into /dev/sdb (it has no
> > partitions defined). Would it be safe installing GRUB in a cache
> > device? Future configuration would be /dev/sda for the cache (SSD) and
> > /dev/sdb for the backing device (hard drive).
> 
> Bcache doesn't touch the first 4k of the device, so if it's just grub's MBR (512
> bytes) that should be fine. I would verify that grub isn't touching more than
> the first 4k of the device though.

On a BIOS system, Grub generally uses the next ~31K of the disk (space between
the end of the MBR and the start of cylinder 1) to store its extra stages.
Unfortunately, you can't really overwrite that.

You might just try switching the disk cables and seeing if the BIOS will still
boot off the spinning disk, since that usually works...

Ofc if you have UEFI then it simply stuffs it on the EFI system partition.

--D
> --
> 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

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-01-07 23:08 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-07  8:52 About physically swapping backing and cache device Josep Lladonosa
2014-01-07 21:35 ` Kent Overstreet
2014-01-07 23:07   ` Darrick J. Wong

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox