Closed Sloepie closed 9 years ago
On 08/01/2015 04:39 PM, Sloepie wrote:
Is it possible that you make "grub-mkconfig-zfs-support.diff" available (again).
With this file I was able to install ZFS on CentOS as a root filesystem before.
But in the meantime you replaced it with grub-zfs-fixer. Unfortunately I don't know enough about rpm to be able to make an rpm file of grub-zfs-fixer.spec. Also I don't know if grub-zfs-fixer will work on CentOS the way it should.
So I would appreciate it very much if you could make "grub-mkconfig-zfs-support.diff" available again because I had ZFS working on CentOS with that file before.
— Reply to this email directly or view it on GitHub https://github.com/Rudd-O/zfs-fedora-installer/issues/9.
Hi! Here are quick instructions to get you to have the grub zfs fixer RPM. I will update the documentation about it very soon.
As the zeroth step: make sure that you have vanilla distribution GRUB installed on your system, instade of any of the patched GRUBs that you may have had in the past.
Then, as first step, get these sources:
https://github.com/Rudd-O/zfs-fedora-installer
Then, tar up the directory grub-zfs-fixer into a file named grub-zfs-fixer.tar.gz
Then, run the command rpmbuild -ta grub-zfs-fixer.tar.gz
This command will generate an installable RPM in ~/rpmbuild/RPMS/noarch (this directorry may vary, but the outpiut of the command will make it clear, I believe).
When you install the noarch RPM that will be created, you will end up with the exact proper GRUB files that will let you continue booting from your ZFS on root. The RPM will take care of modifying your GRUB scripts as GRUB gets upgraded, so you won't have to worry about GRUB problems anymore.
Rudd-O
http://rudd-o.com/
I have added official instructions on how to patch GRUB on an installed system.
https://github.com/Rudd-O/zfs-fedora-installer/tree/master/grub-zfs-fixer
Hello Rudd-O
Thank you very much for your answer and I succeeded now in generating and installing grub-zfs-fixer-0.0.3-1.noarch.rpm
Unfortunately I still could not get ZFS working on CentOs.
Maybe I still did something wrong, but I followed almost exactly your instructions for Fedora. I worked with msdos instead of GPT so I did not make a BIOS Boot partition. Furthermore I only generated one pool called "rpool" instead of "pool"
All steps worked fine without any errors (by the way: you made a typo with zfs set mountpoint=/ root/POOL/fedora which should be zfs set mountpoint=/ pool/ROOT/fedora)
But after the reboot I get: dracut: FATAL: Don't know how to handle 'root=ZFS=rpool
It looks like your grub-zfs-fixer-0.0.3-1.noarch.rpm is not working correctly or I used it the wrong way.
Therefore I enclosed the contents of the most important files (like fstab and grub.cfg) and the steps I did.
Also I would appreciate it very much if you still could send me the "grub-mkconfig-zfs-support.diff" because I had that working before with CentOS.
That does not mean I am no longer interested in grub-zfs-fixer, but when I have grub-mkconfig-zfs-support.diff I can go on with building my site, and later test grub-zfs-fixer in virtualbox until it is working fine.
Kind regards,
Maarten
Op 10-08-15 om 01:22 schreef Rudd-O:
On 08/01/2015 04:39 PM, Sloepie wrote:
Is it possible that you make "grub-mkconfig-zfs-support.diff" available (again).
With this file I was able to install ZFS on CentOS as a root filesystem before.
But in the meantime you replaced it with grub-zfs-fixer. Unfortunately I don't know enough about rpm to be able to make an rpm file of grub-zfs-fixer.spec. Also I don't know if grub-zfs-fixer will work on CentOS the way it should.
So I would appreciate it very much if you could make "grub-mkconfig-zfs-support.diff" available again because I had ZFS working on CentOS with that file before.
— Reply to this email directly or view it on GitHub https://github.com/Rudd-O/zfs-fedora-installer/issues/9.
Hi! Here are quick instructions to get you to have the grub zfs fixer RPM. I will update the documentation about it very soon.
As the zeroth step: make sure that you have vanilla distribution GRUB installed on your system, instade of any of the patched GRUBs that you may have had in the past.
Then, as first step, get these sources:
https://github.com/Rudd-O/zfs-fedora-installer
Then, tar up the directory grub-zfs-fixer into a file named grub-zfs-fixer.tar.gz
Then, run the command rpmbuild -ta grub-zfs-fixer.tar.gz
This command will generate an installable RPM in ~/rpmbuild/RPMS/noarch (this directorry may vary, but the outpiut of the command will make it clear, I believe).
When you install the noarch RPM that will be created, you will end up with the exact proper GRUB files that will let you continue booting from your ZFS on root. The RPM will take care of modifying your GRUB scripts as GRUB gets upgraded, so you won't have to worry about GRUB problems anymore.
Rudd-O http://rudd-o.com/
— Reply to this email directly or view it on GitHub https://github.com/Rudd-O/zfs-fedora-installer/issues/9#issuecomment-129260641.
The diffs are still in the repository. Just browse back in time. For example:
https://github.com/Rudd-O/zfs/tree/92410ad73e0649c2744cae54a87dd05d1854f979/grub2
There is the diff.
Please let me know if you fix grub zfs fixer. I would love to incorporate the changes. Thanks.
By the way, where did you find the typo?
Hi Rudd-O,
Thanks for your browse back in time link. I am very new to github and did not know that that was possible.
About the grub zfs fixer. Do you mean for CentOs? I will let you know as soon as I got ZFS on CentOs working again, though I had that working with te diffs file based on a ZFS approach I used with Ubuntu. But if that works I will test it again with your Fedora approach on a CentOS system.
I have ZFS (root) running on Ubuntu 14.04 now, but I prefer working with CentOS. Beside that with the ZFS on Ubuntu you have to upgrade it manually after each kernel change. So I was very curious to your claim that with your grub fixer this should go automatically.
Your typo is in your https://rudd-o.com/linux-and-free-software/installing-fedora-on-top-of-zfs in this part
Export the pool and reimport it with an alternate root
Run the following commands:
zpool export pool zpool import -o altroot=/sysroot pool
This will make the ZFS system mount any file systems within the pool in /sysroot.
Mount the file system that will be the destination for your
operating system
Set the mountpoint property on the root file system for your operating system:
zfs set mountpoint=/ root/POOL/fedora
By the way, I am not a programmer but a systems designer. But I really really love ZFS, that is why I like to play around with it. And than, in order to gain more (production) experience with it, I implement it in several small private production sites.
Thanks a lot. I let you know
Regards,
Maarten
Op 14-08-15 om 02:18 schreef Rudd-O:
The diffs are still in the repository. Just browse back in time. For example:
https://github.com/Rudd-O/zfs/tree/92410ad73e0649c2744cae54a87dd05d1854f979/grub2
There is the diff.
Please let me know if you fix grub zfs fixer. I would love to incorporate the changes. Thanks.
By the way, where did you find the typo?
— Reply to this email directly or view it on GitHub https://github.com/Rudd-O/zfs-fedora-installer/issues/9#issuecomment-130898402.
On 08/13/2015 05:50 PM, Sloepie wrote:
Hi Rudd-O,
Thanks for your browse back in time link. I am very new to github and did not know that that was possible.
About the grub zfs fixer. Do you mean for CentOs? I will let you know as soon as I got ZFS on CentOs working again, though I had that working with te diffs file based on a ZFS approach I used with Ubuntu. But if that works I will test it again with your Fedora approach on a CentOS system.
I have ZFS (root) running on Ubuntu 14.04 now, but I prefer working with CentOS. Beside that with the ZFS on Ubuntu you have to upgrade it manually after each kernel change. So I was very curious to your claim that with your grub fixer this should go automatically.
Your typo is in your https://rudd-o.com/linux-and-free-software/installing-fedora-on-top-of-zfs
in this part
Thanks for the typo info! I just fixed it on the Web site.
When you get grub zfs fixer to work for your system (whether Fedora, CentOS or Ubuntu) I will personally incorporate your fix into the project and will credit you for doing so. As you probably know, the grub zfs fixer is just a script that patches your grub-mkconfig or grub2-mkconfig such that they will not crap out on the detection and generation of grub.cfg. But it only works properly with GRUB 2 and in CentOS / Fedora systems, because it searches for the file grub2-mkconfig which is not the name of the file in GRUB 2 for Ubuntu or Debian.
Welcoming your future contributions,
Rudd-O
http://rudd-o.com/
Hi Rudd-O
I don't know if you took a look at the grub.cfg I have send you. But when you take a look at it you will see that the grub-zfs-fixer indeed generates "root=ZFS=rpool" which is more or less the same as in Ubuntu, but it will not boot.
Compare both grubs
Ubuntu:
menuentry 'Ubuntu' --class ubuntu --class gnu-linux --class gnu --class
os $menuentry_id_option 'gnulinux-simple-46bca7d7902081ce' {
recordfail
load_video
gfxmode $linux_gfx_mode
insmod gzio
insmod part_msdos
insmod zfs
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root 46bca7d7902081ce
else
search --no-floppy --fs-uuid --set=root 46bca7d7902081ce
fi
linux /@/boot/vmlinuz-3.13.0-61-generic root=ZFS=rpool/ ro
boot=zfs rpool=rpool bootfs=rpool
initrd /@/boot/initrd.img-3.13.0-61-generic
}
_CentOS_: menuentry 'CentOS Linux 7 (Core), with Linux 3.10.0-229.el7.x86_64' --class rhel fedora --class gnu-linux --class gnu --class os --unrestricte$ load_video set gfxpayload=keep insmod gzio insmod part_msdos insmod ext2 set root='hd0,msdos1' if [ x$feature_platform_search_hint = xy ]; then search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint- baremetal=ahci0,msdos1 --hint='hd0,msdos$ else search --no-floppy --fs-uuid --set=root a1c3a774-18c2-43c3-b8dd-3cb2a3e2d1e4 fi linux16 /vmlinuz-3.10.0-229.el7.x86_64 root=ZFS=rpool ro crashkernel=auto rhgb quiet initrd16 /initramfs-3.10.0-229.el7.x86_64.img }
It is my impression, as the Ubuntu version is working (but without grub-zfs-fixer!), that the difference between the two might be that the Ubuntu version is using a file called mountall (see: https://launchpad.net/~zfs-native/+archive/ubuntu/stable)which might explain the fact that Ubuntu does not have the command set root='hd0,msdos1'
Another (maybe much more important) difference is the fact that the Ubuntu version uses /@/boot in front of vmlinuz Later today I will edit this line manually in the CentOS grub.cfg because to me is seems logic _to include the complete path _to vmlinuz.
What the /@ in front of /boot is doing and why root=zfs=rpool/ is with a / I don't know, but I will try all. This all seems to have to do with the right paths
As I told you, I am not a programmer, but if I could get CentOS running by manually editing the grub.cfg to the Ubuntu way (especially by including the /boot part), maybe than you will know what you have to change in grub-zfs-fixer.
I will let you know.
Regards,
Maarten
Op 14-08-15 om 09:34 schreef Rudd-O:
On 08/13/2015 05:50 PM, Sloepie wrote:
Hi Rudd-O,
Thanks for your browse back in time link. I am very new to github and did not know that that was possible.
About the grub zfs fixer. Do you mean for CentOs? I will let you know as soon as I got ZFS on CentOs working again, though I had that working with te diffs file based on a ZFS approach I used with Ubuntu. But if that works I will test it again with your Fedora approach on a CentOS system.
I have ZFS (root) running on Ubuntu 14.04 now, but I prefer working with CentOS. Beside that with the ZFS on Ubuntu you have to upgrade it manually after each kernel change. So I was very curious to your claim that with your grub fixer this should go automatically.
Your typo is in your
https://rudd-o.com/linux-and-free-software/installing-fedora-on-top-of-zfs
in this part
Thanks for the typo info! I just fixed it on the Web site.
When you get grub zfs fixer to work for your system (whether Fedora, CentOS or Ubuntu) I will personally incorporate your fix into the project and will credit you for doing so. As you probably know, the grub zfs fixer is just a script that patches your grub-mkconfig or grub2-mkconfig such that they will not crap out on the detection and generation of grub.cfg. But it only works properly with GRUB 2 and in CentOS / Fedora systems, because it searches for the file grub2-mkconfig which is not the name of the file in GRUB 2 for Ubuntu or Debian.
Welcoming your future contributions,
Rudd-O http://rudd-o.com/
— Reply to this email directly or view it on GitHub https://github.com/Rudd-O/zfs-fedora-installer/issues/9#issuecomment-131005545.
Ubuntu uses a very different mechanism to mount the root file system (which is going to change in a release or two). My grub zfs fixer script SHOULD have made your system generate a correct root=rpool/ROOT/whatever
but clearly did not accomplish that. It's hard to predict what grub2-mkconfig will do, simply because it's not actuallyy specified in any specification what it's supposed to do, but my script tries to fix your grub2-mkconfig to generate the right thing. If it does not, please help me with data. Thanks
Is it possible that you make "grub-mkconfig-zfs-support.diff" available (again).
With this file I was able to install ZFS on CentOS as a root filesystem before.
But in the meantime you replaced it with grub-zfs-fixer. Unfortunately I don't know enough about rpm to be able to make an rpm file of grub-zfs-fixer.spec. Also I don't know if grub-zfs-fixer will work on CentOS the way it should.
So I would appreciate it very much if you could make "grub-mkconfig-zfs-support.diff" available again because I had ZFS working on CentOS with that file before.