Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Debian User (http://www.linux-archive.org/debian-user/)
-   -   btrfs install support (http://www.linux-archive.org/debian-user/225664-btrfs-install-support.html)

Bill Nottingham 01-10-2009 03:52 PM

btrfs install support
 
Eric Sandeen (sandeen@redhat.com) said:
> So review would be appreciated....

It was discussed at FUDCon today that the proper commandline argument
is "i-can't-believe-it's-not-btr"

Bill

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

Eric Sandeen 01-10-2009 03:56 PM

btrfs install support
 
Bill Nottingham wrote:
> Eric Sandeen (sandeen@redhat.com) said:
>> So review would be appreciated....
>
> It was discussed at FUDCon today that the proper commandline argument
> is "i-can't-believe-it's-not-btr"
>
> Bill

I approve that modification. :)

-Eric

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

Radek Vykydal 01-12-2009 09:47 AM

btrfs install support
 
Hi Eric,

Eric Sandeen wrote:

Now that btrfs is in mainline, let's let anaconda play with
it too ;) We still need btrfs.ko in the kernel, and btrfs
support in e2fsprogs. I've got the latter patch submitted and
will just pull it into rawhide if upstream doesn't merge it soon.



we should also make sure that libblkid detects brtfs


Note that the below is 100% totally untested and may even have
typos, my track record with python is not too good, sorry. :)
So review would be appreciated....

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
---

Index: anaconda-11.5.0.5/fsset.py
================================================== =================
--- anaconda-11.5.0.5.orig/fsset.py 2009-01-08 16:09:53.029637743 -0600
+++ anaconda-11.5.0.5/fsset.py 2009-01-08 16:26:16.128575694 -0600
@@ -731,6 +731,72 @@ class ext4FileSystem(extFileSystem):

fileSystemTypeRegister(ext4FileSystem())

+class btrfsFileSystem(FileSystemType):

+ def __init__(self):
+ FileSystemType.__init__(self)
+ self.partedFileSystemType = parted.file_system_type_get("btrfs")
+ self.formattable = 1
+ self.checked = 1
+ self.linuxnativefs = 1
+ self.bootable = False
+ self.maxLabelChars = 256
+ # Wow, you must be brave!
+ # this is totally, 100% unsupported. Boot with "linux btrfs"
+ # at the boot: prompt will let you make new btrfs filesystems
+ # in the installer.
+ if flags.cmdline.has_key("btrfs"):
+ self.supported = -1
+ else:
+ self.supported = 0
+
+ self.name = "btrfs"
+ self.packages = [ "btrfs-progs" ]
+ self.needProgram = [ "mkfs.btrfs", "btrfsctl" ]
+
+ # Bigger, really, depending on machine
+ self.maxSizeMB = 16 * 1024 * 1024
+
+ # We'll sneakily label it here, too.
+ def formatDevice(self, entry, progress, chroot='/'):
+ devicePath = entry.device.setupDevice(chroot)
+ label = self.createLabel(entry.mountpoint, self.maxLabelChars,
+ kslabel = entry.label)
+
+ rc = iutil.execWithRedirect("mkfs.btrfs",
+ ["-L", label, devicePath,



a typo here - missing closing square bracket after devicePath


+ stdout = "/dev/tty5",
+ stderr = "/dev/tty5", searchPath = 1)
+
+ if rc:
+ raise SystemError
+ entry.setLabel(label)
+ def labelDevice(self, entry, chroot):
+ # We did this on the initial format; no standalone labeler yet
+ pass
+
+ def resize(self, entry, size, progress, chroot='/'):
+ devicePath = entry.device.setupDevice(chroot)
+ log.info("resizing %s" %(devicePath,))
+
+ w = None
+ if progress:
+ w = progress(_("Resizing"),
+ _("Resizing filesystem on %s...") %(devicePath),
+ 100, pulse = True)
+
+ rc = iutil.execWithPulseProgress("btrfsctl",
+ ["-r", "%sM" %(size,), devicePath],
+ stdout="/tmp/resize.out",
+ stderr="/tmp/resize.out",
+ progress = w)
+ if progress:
+ w.pop()
+ if rc:
+ raise ResizeError, ("Resize of %s failed: %s" %(devicePath, rc), devicePath)
+
+
+fileSystemTypeRegister(btrfsFileSystem())
+
class raidMemberDummyFileSystem(FileSystemType):
def __init__(self):
FileSystemType.__init__(self)
Index: anaconda-11.5.0.5/liveinst/liveinst.sh
================================================== =================
--- anaconda-11.5.0.5.orig/liveinst/liveinst.sh 2009-01-08 12:47:59.000000000 -0600
+++ anaconda-11.5.0.5/liveinst/liveinst.sh 2009-01-08 16:13:02.253574832 -0600
@@ -32,7 +32,7 @@ if [ ! -b $LIVE_BLOCK ]; then
fi

# load modules that would get loaded by the loader... (#230945)

-for i in raid0 raid1 raid5 raid6 raid456 raid10 fat msdos gfs2 reiserfs ext2 ext3 jfs xfs dm-mod dm-zero dm-mirror dm-snapshot dm-multipath dm-round-robin vfat ; do /sbin/modprobe $i ; done
+for i in raid0 raid1 raid5 raid6 raid456 raid10 fat msdos gfs2 reiserfs ext2 ext3 jfs xfs btrfs dm-mod dm-zero dm-mirror dm-snapshot dm-multipath dm-round-robin vfat ; do /sbin/modprobe $i ; done

export ANACONDA_PRODUCTNAME=$( cat /etc/system-release | cut -d ' ' -f 1 )

export ANACONDA_PRODUCTVERSION=$( cat /etc/system-release | sed -r -e 's/^.*([0-9]+) *(.*$/1/' )
Index: anaconda-11.5.0.5/loader/loader.c
================================================== =================
--- anaconda-11.5.0.5.orig/loader/loader.c 2009-01-08 12:47:59.000000000 -0600
+++ anaconda-11.5.0.5/loader/loader.c 2009-01-08 16:13:45.730575402 -0600
@@ -2044,7 +2044,7 @@ int main(int argc, char ** argv) {
stop_fw_loader(&loaderData);
start_fw_loader(&loaderData);

- mlLoadModuleSet("raid0:raid1:raid5:raid6:raid456:r aid10:linear:fat:msdos:gfs2:reiserfs:jfs:xfs:dm-mod:dm-zero:dm-mirror:dm-snapshot:dm-multipath:dm-round-robin:dm-crypt:cbc:sha256:lrw:xts");

+ mlLoadModuleSet("raid0:raid1:raid5:raid6:raid456:r aid10:linear:fat:msdos:gfs2:reiserfs:jfs:xfs:btrfs :dm-mod:dm-zero:dm-mirror:dm-snapshot:dm-multipath:dm-round-robin:dm-crypt:cbc:sha256:lrw:xts");

if (!access("/mnt/runtime/usr/lib/libunicode-lite.so.1", R_OK))

setenv("LD_PRELOAD", "/mnt/runtime/usr/lib/libunicode-lite.so.1", 1);
Index: anaconda-11.5.0.5/scripts/mk-images
================================================== =================
--- anaconda-11.5.0.5.orig/scripts/mk-images 2009-01-08 12:47:59.000000000 -0600
+++ anaconda-11.5.0.5/scripts/mk-images 2009-01-08 16:13:56.141820641 -0600
@@ -112,7 +112,7 @@ FIREWIREMODS="ohci1394 sbp2 fw-ohci fw-s
SDMODS="mmc-block sdhci sdhci-pci"
IDEMODS="ide-cd ide-cd_mod"
SCSIMODS="sr_mod sg st sd_mod scsi_mod iscsi_tcp iscsi_ibft"
-FSMODS="fat msdos vfat ext2 ext3 ext4 reiserfs jfs xfs gfs2 cifs"
+FSMODS="fat msdos vfat ext2 ext3 ext4 reiserfs jfs xfs gfs2 cifs btrfs"
LVMMODS="dm-mod dm-zero dm-snapshot dm-mirror dm-multipath dm-round-robin dm-crypt"
RAIDMODS="raid0 raid1 raid5 raid6 raid456 raid10 linear"
CRYPTOMODS="sha256_generic cbc xts lrw aes_generic crypto_blkcipher crc32c ecb arc4"
Index: anaconda-11.5.0.5/scripts/upd-instroot
================================================== =================
--- anaconda-11.5.0.5.orig/scripts/upd-instroot 2009-01-08 12:47:59.000000000 -0600
+++ anaconda-11.5.0.5/scripts/upd-instroot 2009-01-08 16:15:17.316576435 -0600
@@ -150,7 +150,7 @@ die () {

PACKAGES="GConf2 NetworkManager ORBit2 PolicyKit VLGothic-fonts acl anaconda

anaconda-yum-plugins at-spi atk attr audit-libs bash bitmap-fonts-cjk
- booty busybox-anaconda bzip2 bzip2-libs cairo cjkunifonts-uming
+ booty btrfs-progs busybox-anaconda bzip2 bzip2-libs cairo cjkunifonts-uming
comps-extras coreutils cpio cracklib cracklib-dicts cracklib-python
cryptsetup-luks db4 dbus dbus-python dejavu-fonts device-mapper
device-mapper-libs dhclient dhcpv6-client dmapi dmraid dmraid-libs




in upd-instroot, we also need to explicitly specify (in KEEPFILE var)
which files from added package we want to keep in the image
something like:

diff --git a/scripts/upd-instroot b/scripts/upd-instroot
index 23efc51..aa3dd2a 100755
--- a/scripts/upd-instroot
+++ b/scripts/upd-instroot
@@ -341,6 +341,8 @@ lib/udev
sbin/*gfs*
sbin/arping
sbin/badblocks
+sbin/btrfsctl
+sbin/btrfsck
sbin/busybox.anaconda
sbin/clock
sbin/consoletype
@@ -382,6 +384,7 @@ sbin/mkfs.jfs
sbin/mkfs.msdos
sbin/mkfs.vfat
sbin/mkfs.xfs
+sbin/mkfs.btrfs
sbin/mkraid
sbin/mkreiserfs
sbin/mkswap


Radek

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

Eric Sandeen 01-12-2009 08:03 PM

btrfs install support
 
Radek Vykydal wrote:
> Hi Eric,
>
> Eric Sandeen wrote:
>> Now that btrfs is in mainline, let's let anaconda play with
>> it too ;) We still need btrfs.ko in the kernel, and btrfs
>> support in e2fsprogs. I've got the latter patch submitted and
>> will just pull it into rawhide if upstream doesn't merge it soon.
>>
>
> we should also make sure that libblkid detects brtfs

It does already (in rawhide anyway, patch is sent upstream)

...

>> + rc = iutil.execWithRedirect("mkfs.btrfs",
>> + ["-L", label, devicePath,
>>
>
> a typo here - missing closing square bracket after devicePath

Oops, thanks.


...

> in upd-instroot, we also need to explicitly specify (in KEEPFILE var)
> which files from added package we want to keep in the image
> something like:
>
> diff --git a/scripts/upd-instroot b/scripts/upd-instroot
> index 23efc51..aa3dd2a 100755
> --- a/scripts/upd-instroot
> +++ b/scripts/upd-instroot
> @@ -341,6 +341,8 @@ lib/udev
> sbin/*gfs*
> sbin/arping
> sbin/badblocks
> +sbin/btrfsctl
> +sbin/btrfsck
> sbin/busybox.anaconda
> sbin/clock
> sbin/consoletype
> @@ -382,6 +384,7 @@ sbin/mkfs.jfs
> sbin/mkfs.msdos
> sbin/mkfs.vfat
> sbin/mkfs.xfs
> +sbin/mkfs.btrfs
> sbin/mkraid
> sbin/mkreiserfs
> sbin/mkswap

Ah that's right.... thanks! I'll fix up and resend.

-Eric

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

Eric Sandeen 01-12-2009 08:19 PM

btrfs install support
 
Now that btrfs is in mainline, let's let anaconda play with
it too ;) We still need btrfs.ko in the kernel, and btrfs
support in e2fsprogs. I've got the latter patch submitted
upstream, and it's in rawhide now.

Note that the below is 100% totally untested and may even have
typos, my track record with python is not too good, sorry. :)
So review would be appreciated....

Updated to address Radek's review, as well as adding the requisite
witty (commandline-space-eating) boot option...

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
---

Index: anaconda-11.5.0.5/fsset.py
================================================== =================
--- anaconda-11.5.0.5.orig/fsset.py 2009-01-08 16:09:53.029637743 -0600
+++ anaconda-11.5.0.5/fsset.py 2009-01-12 15:17:08.444575320 -0600
@@ -731,6 +731,72 @@ class ext4FileSystem(extFileSystem):

fileSystemTypeRegister(ext4FileSystem())

+class btrfsFileSystem(FileSystemType):
+ def __init__(self):
+ FileSystemType.__init__(self)
+ self.partedFileSystemType = parted.file_system_type_get("btrfs")
+ self.formattable = 1
+ self.checked = 1
+ self.linuxnativefs = 1
+ self.bootable = False
+ self.maxLabelChars = 256
+ # Wow, you must be brave!
+ # this is totally, 100% unsupported. Boot with "linux btrfs"
+ # at the boot: prompt will let you make new btrfs filesystems
+ # in the installer.
+ if flags.cmdline.has_key("icantbelieveitsnotbtr"):
+ self.supported = -1
+ else:
+ self.supported = 0
+
+ self.name = "btrfs"
+ self.packages = [ "btrfs-progs" ]
+ self.needProgram = [ "mkfs.btrfs", "btrfsctl" ]
+
+ # Bigger, really, depending on machine
+ self.maxSizeMB = 16 * 1024 * 1024
+
+ # We'll sneakily label it here, too.
+ def formatDevice(self, entry, progress, chroot='/'):
+ devicePath = entry.device.setupDevice(chroot)
+ label = self.createLabel(entry.mountpoint, self.maxLabelChars,
+ kslabel = entry.label)
+
+ rc = iutil.execWithRedirect("mkfs.btrfs",
+ ["-L", label, devicePath],
+ stdout = "/dev/tty5",
+ stderr = "/dev/tty5", searchPath = 1)
+
+ if rc:
+ raise SystemError
+ entry.setLabel(label)
+ def labelDevice(self, entry, chroot):
+ # We did this on the initial format; no standalone labeler yet
+ pass
+
+ def resize(self, entry, size, progress, chroot='/'):
+ devicePath = entry.device.setupDevice(chroot)
+ log.info("resizing %s" %(devicePath,))
+
+ w = None
+ if progress:
+ w = progress(_("Resizing"),
+ _("Resizing filesystem on %s...") %(devicePath),
+ 100, pulse = True)
+
+ rc = iutil.execWithPulseProgress("btrfsctl",
+ ["-r", "%sM" %(size,), devicePath],
+ stdout="/tmp/resize.out",
+ stderr="/tmp/resize.out",
+ progress = w)
+ if progress:
+ w.pop()
+ if rc:
+ raise ResizeError, ("Resize of %s failed: %s" %(devicePath, rc), devicePath)
+
+
+fileSystemTypeRegister(btrfsFileSystem())
+
class raidMemberDummyFileSystem(FileSystemType):
def __init__(self):
FileSystemType.__init__(self)
Index: anaconda-11.5.0.5/liveinst/liveinst.sh
================================================== =================
--- anaconda-11.5.0.5.orig/liveinst/liveinst.sh 2009-01-08 12:47:59.000000000 -0600
+++ anaconda-11.5.0.5/liveinst/liveinst.sh 2009-01-12 15:09:48.938995015 -0600
@@ -32,7 +32,7 @@ if [ ! -b $LIVE_BLOCK ]; then
fi

# load modules that would get loaded by the loader... (#230945)
-for i in raid0 raid1 raid5 raid6 raid456 raid10 fat msdos gfs2 reiserfs ext2 ext3 jfs xfs dm-mod dm-zero dm-mirror dm-snapshot dm-multipath dm-round-robin vfat ; do /sbin/modprobe $i ; done
+for i in raid0 raid1 raid5 raid6 raid456 raid10 fat msdos gfs2 reiserfs ext2 ext3 jfs xfs btrfs dm-mod dm-zero dm-mirror dm-snapshot dm-multipath dm-round-robin vfat ; do /sbin/modprobe $i ; done

export ANACONDA_PRODUCTNAME=$( cat /etc/system-release | cut -d ' ' -f 1 )
export ANACONDA_PRODUCTVERSION=$( cat /etc/system-release | sed -r -e 's/^.*([0-9]+) *(.*$/1/' )
Index: anaconda-11.5.0.5/loader/loader.c
================================================== =================
--- anaconda-11.5.0.5.orig/loader/loader.c 2009-01-08 12:47:59.000000000 -0600
+++ anaconda-11.5.0.5/loader/loader.c 2009-01-12 15:09:50.187913261 -0600
@@ -2044,7 +2044,7 @@ int main(int argc, char ** argv) {
stop_fw_loader(&loaderData);
start_fw_loader(&loaderData);

- mlLoadModuleSet("raid0:raid1:raid5:raid6:raid456:r aid10:linear:fat:msdos:gfs2:reiserfs:jfs:xfs:dm-mod:dm-zero:dm-mirror:dm-snapshot:dm-multipath:dm-round-robin:dm-crypt:cbc:sha256:lrw:xts");
+ mlLoadModuleSet("raid0:raid1:raid5:raid6:raid456:r aid10:linear:fat:msdos:gfs2:reiserfs:jfs:xfs:btrfs :dm-mod:dm-zero:dm-mirror:dm-snapshot:dm-multipath:dm-round-robin:dm-crypt:cbc:sha256:lrw:xts");

if (!access("/mnt/runtime/usr/lib/libunicode-lite.so.1", R_OK))
setenv("LD_PRELOAD", "/mnt/runtime/usr/lib/libunicode-lite.so.1", 1);
Index: anaconda-11.5.0.5/scripts/mk-images
================================================== =================
--- anaconda-11.5.0.5.orig/scripts/mk-images 2009-01-08 12:47:59.000000000 -0600
+++ anaconda-11.5.0.5/scripts/mk-images 2009-01-12 15:09:54.798574912 -0600
@@ -112,7 +112,7 @@ FIREWIREMODS="ohci1394 sbp2 fw-ohci fw-s
SDMODS="mmc-block sdhci sdhci-pci"
IDEMODS="ide-cd ide-cd_mod"
SCSIMODS="sr_mod sg st sd_mod scsi_mod iscsi_tcp iscsi_ibft"
-FSMODS="fat msdos vfat ext2 ext3 ext4 reiserfs jfs xfs gfs2 cifs"
+FSMODS="fat msdos vfat ext2 ext3 ext4 reiserfs jfs xfs gfs2 cifs btrfs"
LVMMODS="dm-mod dm-zero dm-snapshot dm-mirror dm-multipath dm-round-robin dm-crypt"
RAIDMODS="raid0 raid1 raid5 raid6 raid456 raid10 linear"
CRYPTOMODS="sha256_generic cbc xts lrw aes_generic crypto_blkcipher crc32c ecb arc4"
Index: anaconda-11.5.0.5/scripts/upd-instroot
================================================== =================
--- anaconda-11.5.0.5.orig/scripts/upd-instroot 2009-01-08 12:47:59.000000000 -0600
+++ anaconda-11.5.0.5/scripts/upd-instroot 2009-01-12 15:12:19.850575024 -0600
@@ -150,7 +150,7 @@ die () {

PACKAGES="GConf2 NetworkManager ORBit2 PolicyKit VLGothic-fonts acl anaconda
anaconda-yum-plugins at-spi atk attr audit-libs bash bitmap-fonts-cjk
- booty busybox-anaconda bzip2 bzip2-libs cairo cjkunifonts-uming
+ booty btrfs-progs busybox-anaconda bzip2 bzip2-libs cairo cjkunifonts-uming
comps-extras coreutils cpio cracklib cracklib-dicts cracklib-python
cryptsetup-luks db4 dbus dbus-python dejavu-fonts device-mapper
device-mapper-libs dhclient dhcpv6-client dmapi dmraid dmraid-libs
@@ -341,6 +341,8 @@ lib/udev
sbin/*gfs*
sbin/arping
sbin/badblocks
+sbin/btrfsctl
+sbin/btrfsck
sbin/busybox.anaconda
sbin/clock
sbin/consoletype
@@ -375,6 +377,7 @@ sbin/lvm*
sbin/mdadm
sbin/mkdosfs
sbin/mke2fs
+sbin/mkfs.btrfs
sbin/mkfs.ext2
sbin/mkfs.ext3
sbin/mkfs.gfs2

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

David Cantrell 01-13-2009 01:29 PM

btrfs install support
 
Eric Sandeen wrote:
> Now that btrfs is in mainline, let's let anaconda play with
> it too ;) We still need btrfs.ko in the kernel, and btrfs
> support in e2fsprogs. I've got the latter patch submitted
> upstream, and it's in rawhide now.
>
> Note that the below is 100% totally untested and may even have
> typos, my track record with python is not too good, sorry. :)
> So review would be appreciated....
>
> Updated to address Radek's review, as well as adding the requisite
> witty (commandline-space-eating) boot option...
>
> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
> ---
>
> Index: anaconda-11.5.0.5/fsset.py
> ================================================== =================
> --- anaconda-11.5.0.5.orig/fsset.py 2009-01-08 16:09:53.029637743 -0600
> +++ anaconda-11.5.0.5/fsset.py 2009-01-12 15:17:08.444575320 -0600
> @@ -731,6 +731,72 @@ class ext4FileSystem(extFileSystem):
>
> fileSystemTypeRegister(ext4FileSystem())
>
> +class btrfsFileSystem(FileSystemType):
> + def __init__(self):
> + FileSystemType.__init__(self)
> + self.partedFileSystemType = parted.file_system_type_get("btrfs")

For this line to work, libparted needs to grow a macro identifying the
btrfs type.

> + self.formattable = 1
> + self.checked = 1
> + self.linuxnativefs = 1
> + self.bootable = False
> + self.maxLabelChars = 256
> + # Wow, you must be brave!
> + # this is totally, 100% unsupported. Boot with "linux btrfs"
> + # at the boot: prompt will let you make new btrfs filesystems
> + # in the installer.
> + if flags.cmdline.has_key("icantbelieveitsnotbtr"):
> + self.supported = -1
> + else:
> + self.supported = 0
> +
> + self.name = "btrfs"
> + self.packages = [ "btrfs-progs" ]
> + self.needProgram = [ "mkfs.btrfs", "btrfsctl" ]
> +
> + # Bigger, really, depending on machine
> + self.maxSizeMB = 16 * 1024 * 1024
> +
> + # We'll sneakily label it here, too.
> + def formatDevice(self, entry, progress, chroot='/'):
> + devicePath = entry.device.setupDevice(chroot)
> + label = self.createLabel(entry.mountpoint, self.maxLabelChars,
> + kslabel = entry.label)
> +
> + rc = iutil.execWithRedirect("mkfs.btrfs",
> + ["-L", label, devicePath],
> + stdout = "/dev/tty5",
> + stderr = "/dev/tty5", searchPath = 1)
> +
> + if rc:
> + raise SystemError
> + entry.setLabel(label)
> + def labelDevice(self, entry, chroot):
> + # We did this on the initial format; no standalone labeler yet
> + pass
> +
> + def resize(self, entry, size, progress, chroot='/'):
> + devicePath = entry.device.setupDevice(chroot)
> + log.info("resizing %s" %(devicePath,))
> +
> + w = None
> + if progress:
> + w = progress(_("Resizing"),
> + _("Resizing filesystem on %s...") %(devicePath),
> + 100, pulse = True)
> +
> + rc = iutil.execWithPulseProgress("btrfsctl",
> + ["-r", "%sM" %(size,), devicePath],
> + stdout="/tmp/resize.out",
> + stderr="/tmp/resize.out",
> + progress = w)
> + if progress:
> + w.pop()
> + if rc:
> + raise ResizeError, ("Resize of %s failed: %s" %(devicePath, rc), devicePath)
> +
> +
> +fileSystemTypeRegister(btrfsFileSystem())
> +
> class raidMemberDummyFileSystem(FileSystemType):
> def __init__(self):
> FileSystemType.__init__(self)
> Index: anaconda-11.5.0.5/liveinst/liveinst.sh
> ================================================== =================
> --- anaconda-11.5.0.5.orig/liveinst/liveinst.sh 2009-01-08 12:47:59.000000000 -0600
> +++ anaconda-11.5.0.5/liveinst/liveinst.sh 2009-01-12 15:09:48.938995015 -0600
> @@ -32,7 +32,7 @@ if [ ! -b $LIVE_BLOCK ]; then
> fi
>
> # load modules that would get loaded by the loader... (#230945)
> -for i in raid0 raid1 raid5 raid6 raid456 raid10 fat msdos gfs2 reiserfs ext2 ext3 jfs xfs dm-mod dm-zero dm-mirror dm-snapshot dm-multipath dm-round-robin vfat ; do /sbin/modprobe $i ; done
> +for i in raid0 raid1 raid5 raid6 raid456 raid10 fat msdos gfs2 reiserfs ext2 ext3 jfs xfs btrfs dm-mod dm-zero dm-mirror dm-snapshot dm-multipath dm-round-robin vfat ; do /sbin/modprobe $i ; done
>
> export ANACONDA_PRODUCTNAME=$( cat /etc/system-release | cut -d ' ' -f 1 )
> export ANACONDA_PRODUCTVERSION=$( cat /etc/system-release | sed -r -e 's/^.*([0-9]+) *(.*$/1/' )
> Index: anaconda-11.5.0.5/loader/loader.c
> ================================================== =================
> --- anaconda-11.5.0.5.orig/loader/loader.c 2009-01-08 12:47:59.000000000 -0600
> +++ anaconda-11.5.0.5/loader/loader.c 2009-01-12 15:09:50.187913261 -0600
> @@ -2044,7 +2044,7 @@ int main(int argc, char ** argv) {
> stop_fw_loader(&loaderData);
> start_fw_loader(&loaderData);
>
> - mlLoadModuleSet("raid0:raid1:raid5:raid6:raid456:r aid10:linear:fat:msdos:gfs2:reiserfs:jfs:xfs:dm-mod:dm-zero:dm-mirror:dm-snapshot:dm-multipath:dm-round-robin:dm-crypt:cbc:sha256:lrw:xts");
> + mlLoadModuleSet("raid0:raid1:raid5:raid6:raid456:r aid10:linear:fat:msdos:gfs2:reiserfs:jfs:xfs:btrfs :dm-mod:dm-zero:dm-mirror:dm-snapshot:dm-multipath:dm-round-robin:dm-crypt:cbc:sha256:lrw:xts");
>
> if (!access("/mnt/runtime/usr/lib/libunicode-lite.so.1", R_OK))
> setenv("LD_PRELOAD", "/mnt/runtime/usr/lib/libunicode-lite.so.1", 1);
> Index: anaconda-11.5.0.5/scripts/mk-images
> ================================================== =================
> --- anaconda-11.5.0.5.orig/scripts/mk-images 2009-01-08 12:47:59.000000000 -0600
> +++ anaconda-11.5.0.5/scripts/mk-images 2009-01-12 15:09:54.798574912 -0600
> @@ -112,7 +112,7 @@ FIREWIREMODS="ohci1394 sbp2 fw-ohci fw-s
> SDMODS="mmc-block sdhci sdhci-pci"
> IDEMODS="ide-cd ide-cd_mod"
> SCSIMODS="sr_mod sg st sd_mod scsi_mod iscsi_tcp iscsi_ibft"
> -FSMODS="fat msdos vfat ext2 ext3 ext4 reiserfs jfs xfs gfs2 cifs"
> +FSMODS="fat msdos vfat ext2 ext3 ext4 reiserfs jfs xfs gfs2 cifs btrfs"
> LVMMODS="dm-mod dm-zero dm-snapshot dm-mirror dm-multipath dm-round-robin dm-crypt"
> RAIDMODS="raid0 raid1 raid5 raid6 raid456 raid10 linear"
> CRYPTOMODS="sha256_generic cbc xts lrw aes_generic crypto_blkcipher crc32c ecb arc4"
> Index: anaconda-11.5.0.5/scripts/upd-instroot
> ================================================== =================
> --- anaconda-11.5.0.5.orig/scripts/upd-instroot 2009-01-08 12:47:59.000000000 -0600
> +++ anaconda-11.5.0.5/scripts/upd-instroot 2009-01-12 15:12:19.850575024 -0600
> @@ -150,7 +150,7 @@ die () {
>
> PACKAGES="GConf2 NetworkManager ORBit2 PolicyKit VLGothic-fonts acl anaconda
> anaconda-yum-plugins at-spi atk attr audit-libs bash bitmap-fonts-cjk
> - booty busybox-anaconda bzip2 bzip2-libs cairo cjkunifonts-uming
> + booty btrfs-progs busybox-anaconda bzip2 bzip2-libs cairo cjkunifonts-uming
> comps-extras coreutils cpio cracklib cracklib-dicts cracklib-python
> cryptsetup-luks db4 dbus dbus-python dejavu-fonts device-mapper
> device-mapper-libs dhclient dhcpv6-client dmapi dmraid dmraid-libs
> @@ -341,6 +341,8 @@ lib/udev
> sbin/*gfs*
> sbin/arping
> sbin/badblocks
> +sbin/btrfsctl
> +sbin/btrfsck
> sbin/busybox.anaconda
> sbin/clock
> sbin/consoletype
> @@ -375,6 +377,7 @@ sbin/lvm*
> sbin/mdadm
> sbin/mkdosfs
> sbin/mke2fs
> +sbin/mkfs.btrfs
> sbin/mkfs.ext2
> sbin/mkfs.ext3
> sbin/mkfs.gfs2

The rest of it looks fine to me.

--
David Cantrell <dcantrell@redhat.com>
Red Hat / Honolulu, HI

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

Eric Sandeen 01-13-2009 03:37 PM

btrfs install support
 
David Cantrell wrote:
> Eric Sandeen wrote:
>> Now that btrfs is in mainline, let's let anaconda play with
>> it too ;) We still need btrfs.ko in the kernel, and btrfs
>> support in e2fsprogs. I've got the latter patch submitted
>> upstream, and it's in rawhide now.
>>
>> Note that the below is 100% totally untested and may even have
>> typos, my track record with python is not too good, sorry. :)
>> So review would be appreciated....
>>
>> Updated to address Radek's review, as well as adding the requisite
>> witty (commandline-space-eating) boot option...
>>
>> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
>> ---
>>
>> Index: anaconda-11.5.0.5/fsset.py
>> ================================================== =================
>> --- anaconda-11.5.0.5.orig/fsset.py 2009-01-08 16:09:53.029637743 -0600
>> +++ anaconda-11.5.0.5/fsset.py 2009-01-12 15:17:08.444575320 -0600
>> @@ -731,6 +731,72 @@ class ext4FileSystem(extFileSystem):
>>
>> fileSystemTypeRegister(ext4FileSystem())
>>
>> +class btrfsFileSystem(FileSystemType):
>> + def __init__(self):
>> + FileSystemType.__init__(self)
>> + self.partedFileSystemType = parted.file_system_type_get("btrfs")
>
> For this line to work, libparted needs to grow a macro identifying the
> btrfs type.
>

Crud, I wondered about that. So the path to anaconda is libblkid ->
parted -> anaconda?

Well, I've looked at parted before. Guess maybe I'll do so again.

Thanks,
-Eric

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

Eric Sandeen 01-13-2009 04:14 PM

btrfs install support
 
Eric Sandeen wrote:
> David Cantrell wrote:
>> Eric Sandeen wrote:

>>> +class btrfsFileSystem(FileSystemType):
>>> + def __init__(self):
>>> + FileSystemType.__init__(self)
>>> + self.partedFileSystemType = parted.file_system_type_get("btrfs")
>> For this line to work, libparted needs to grow a macro identifying the
>> btrfs type.
>>
>
> Crud, I wondered about that. So the path to anaconda is libblkid ->
> parted -> anaconda?
>
> Well, I've looked at parted before. Guess maybe I'll do so again.

On the other hand, I notice that gfs2 support in anaconda does not use
this. What happens if it's just dropped until parted is updated? :)

-Eric

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

Jeremy Katz 01-19-2009 05:23 PM

btrfs install support
 
On Tuesday, January 13 2009, Eric Sandeen said:
> Eric Sandeen wrote:
> > David Cantrell wrote:
> >> Eric Sandeen wrote:
> >>> +class btrfsFileSystem(FileSystemType):
> >>> + def __init__(self):
> >>> + FileSystemType.__init__(self)
> >>> + self.partedFileSystemType = parted.file_system_type_get("btrfs")
> >> For this line to work, libparted needs to grow a macro identifying the
> >> btrfs type.
> >
> > Crud, I wondered about that. So the path to anaconda is libblkid ->
> > parted -> anaconda?
> >
> > Well, I've looked at parted before. Guess maybe I'll do so again.
>
> On the other hand, I notice that gfs2 support in anaconda does not use
> this. What happens if it's just dropped until parted is updated? :)

Yeah, that should be fine. I'll do the edit by hand and commit and push
this.

Jeremy

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


All times are GMT. The time now is 09:53 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.