Re: converting to btrfs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 04/07/2016 04:00 PM, Jeffrey Ross wrote:
I had an raid1 partition with ext4 on it which was empty.

it was /dev/md124 which was made up of /dev/sda1 and /dev/sdb1, I decided
to change this to be a btrfs partition.

Initially I figured I'd simply unmount /dev/md124 and simply do a
"mkfs.btrfs -f -L home2 /dev/md124" and remount the partition, however
after doing some reading I believe btrfs supports raid1 directly without
using the software raid driver md (?).

so I then tried "mkfs.btrfs -m raid1 -d raid1 -L home2 -f /dev/sdb1
/dev/sda1" and something was successfully created but this is where I am
confused, is this truly a raid1 partition? secondly mounting this
partition I simply specify something like "mount /dev/sda1 /mntpoint".

I can see -
# btrfs filesystem show
Label: 'home2'  uuid: 635be1e8-31d2-4b5c-b81c-1ec2cd8d9101
         Total devices 2 FS bytes used 664.00KiB
         devid    1 size 376.46GiB used 2.01GiB path /dev/sdb1
         devid    2 size 376.46GiB used 2.01GiB path /dev/sda1

To me this looks like two different partitions but I maybe wrong, so
assuming it is one raid partition how would I go around having this auto
mounted in /etc/fstab? I would assume this entry -

UUID=635be1e8-31d2-4b5c-b81c-1ec2cd8d9101 /home2  btrfs defaults  0 0

but I'm looking for some confirmation first that I actually have a raid
partition and I've done everything correctly first.

Yeah, I think you have to use the UUID. From the mkfs.btrfs man page:

	"Multiple devices are grouped by UUID of the filesystem."

You can also include "-o device=/dev/sda1,device=/dev/sdb1" in the fstab
entry to force a scan at mount time.

Lastly if I'm reading correctly the system will NOT automatically mount a
degraded array, how can I force it to automatically mount on a reload even
if the array is degraded.

Use the "degraded" option in the mount. With the other options, I think
it'd be:

UUID=635be1e8-31d2-4b5c-b81c-1ec2cd8d9101 /home2 btrfs device=/dev/sda1,device=/dev/sdb1,degraded,rw 0 0

or something like that. Dunno, can't test it at the moment.
----------------------------------------------------------------------
- Rick Stevens, Systems Engineer, AllDigital    ricks@xxxxxxxxxxxxxx -
- AIM/Skype: therps2        ICQ: 226437340           Yahoo: origrps2 -
-                                                                    -
-    When you don't know what to do, walk fast and look worried.     -
----------------------------------------------------------------------
--
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
http://lists.fedoraproject.org/admin/lists/users@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: http://fedoraproject.org/code-of-conduct
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux