Description of problem: With Anaconda 7.4, the NIST partitions will be generated by anaconda when choosing auto partitioning, after installation finished, the mount infos would be like: /dev/mapper/rhvh_dhcp--10--111-rhvh--4.1--0.20170714.0+1 on / type ext4 (rw,relatime,seclabel,discard,stripe=16,data=ordered) /dev/mapper/rhvh_dhcp--10--111-var on /var type ext4 (rw,relatime,seclabel,discard,stripe=16,data=ordered) /dev/mapper/rhvh_dhcp--10--111-var_log on /var/log type ext4 (rw,relatime,seclabel,stripe=16,data=ordered) /dev/mapper/rhvh_dhcp--10--111-tmp on /tmp type ext4 (rw,relatime,seclabel,stripe=16,data=ordered) /dev/mapper/rhvh_dhcp--10--111-home on /home type ext4 (rw,relatime,seclabel,stripe=16,data=ordered) /dev/mapper/rhvh_dhcp--10--111-var_log_audit on /var/log/audit type ext4 (rw,relatime,seclabel,stripe=16,data=ordered) In the mounting parameters, there is no discard for /var/log, /tmp, /home, and /var/log/audit, which are NIST partitions generated by program. Version-Release number of selected component (if applicable): redhat-virtualization-host-4.1-20170714.1 How reproducible: 100% Steps to Reproduce: 1. Install redhat-virtualization-host-4.1-20170714.1 via Anaconda GUI, and choose auto partitioning, finish all needed steps. 2. Reboot and log into RHVH, run 'mount' Actual results: 1. After step2, there is missing discard for /var/log, /tmp, /home, and /var/log/audit. Expected results: 1. After step2, there is discard for /var/log, /tmp, /home, and /var/log/audit. Additional info: There is discard for the NIST partitions if choosing manual partitioning(clicking '+' to add partitions), the mount infos are like: /dev/mapper/rhvh_dhcp--10--111-rhvh--4.1--0.20170714.0+1 on / type ext4 (rw,relatime,seclabel,discard,stripe=16,data=ordered) /dev/mapper/rhvh_dhcp--10--111-home on /home type ext4 (rw,relatime,seclabel,discard,stripe=16,data=ordered) /dev/mapper/rhvh_dhcp--10--111-tmp on /tmp type ext4 (rw,relatime,seclabel,discard,stripe=16,data=ordered) /dev/mapper/rhvh_dhcp--10--111-var on /var type ext4 (rw,relatime,seclabel,discard,stripe=16,data=ordered) /dev/mapper/rhvh_dhcp--10--111-var--log on /var/log type ext4 (rw,relatime,seclabel,discard,stripe=16,data=ordered) /dev/mapper/rhvh_dhcp--10--111-var--log--audit on /var/log/audit type ext4 (rw,relatime,seclabel,discard,stripe=16,data=ordered)
This is a regression from behavior in RHEL 7.3 Since LVM thin provisions are used in RHV-H, this is very important to us.
Could you please attach installation logs for both working (custom) and non-working (autopart) case? /var/log/anaconda/storage.log /var/log/anaconda/journal.log Or point to the image to reproduce with. I think the change in autopartitioning went only to rhv installclass. https://github.com/rhinstaller/anaconda/commit/1596d0b3e2bb58b723f0d099ab3c072ef87cf306 I am assuming the regression/change is that in 7.3 autopart would create only / and /var having discard, now there are more partitions of which only / and /var have discard. AFAIK there were no similar changes of autopartitioning in other products so there should be no such regressions.
CCing storage experts for hints.
Created attachment 1300799 [details] anaconda log for autopart
Created attachment 1300800 [details] anaconda log for custom part
Anaconda doesn't add discard options to /etc/fstab. It seems to be done by imgbase tool run from kickstart %post embedded by rhv to installer environment, so this tool should be responsible for setting the option and perhaps it should be adapted to the new autopartitioning based on NIST? I tried with http://download-node-02.eng.bos.redhat.com/devel/candidate-trees/RHVH-4.1-20170718.2/compose/RHVH/x86_64/iso/ to create the NIST layout in custom partitioning with the same result as reported for auto - only / and /var had discard set in /etc/fstab of installed sytem. OTOH from the logs for custom installation in comment #7 - it seems there was only ordinary / partition created, also the version of anaconda (20:47:04,311 INFO anaconda: /sbin/anaconda 21.48.22.93-1 - RHEL 7.3) is different for the auto case in comment #6 (11:14:30,771 INFO anaconda: /sbin/anaconda 21.48.22.121-1 - the latest 7.4)? I wonder how the reporter got the result claimed in Additional info of Description though. To sum up to me it seems that there is no regression in installer but rhv tools (imgbase) need to be updated to reflect the changes done in rhv autopartitioning in RHEL 7.4 (https://github.com/rhinstaller/anaconda/commit/1596d0b3e2bb58b723f0d099ab3c072ef87cf306), ie to set the discard option for added partitions/mount points.
(In reply to Radek Vykydal from comment #8) > Anaconda doesn't add discard options to /etc/fstab. It seems to be done by > imgbase tool run from kickstart %post embedded by rhv to installer > environment, so this tool should be responsible for setting the option and > perhaps it should be adapted to the new autopartitioning based on NIST? > > I tried > with > http://download-node-02.eng.bos.redhat.com/devel/candidate-trees/RHVH-4.1- > 20170718.2/compose/RHVH/x86_64/iso/ > to create the NIST layout in custom partitioning with the same result as > reported for auto - only / and /var had discard set in /etc/fstab of > installed sytem. > > OTOH from the logs for custom installation in comment #7 - it seems there > was only ordinary / partition created, also the version of anaconda > (20:47:04,311 INFO anaconda: /sbin/anaconda 21.48.22.93-1 - RHEL 7.3) is > different for the auto case in comment #6 (11:14:30,771 INFO anaconda: > /sbin/anaconda 21.48.22.121-1 - the latest 7.4)? I wonder how the reporter > got the result claimed in Additional info of Description though. > Thanks for pointing out this error. I tried to retest this, the steps and results are: 1. Install RHVH-4.1-20170718.2-RHVH-x86_64-dvd1.iso, choose auto partitioning 2. After installation finished, log into RHVH, check /var/log/anaconda/anaconda.log for the version, it's 21.48.22.121-1 3. Reinstall RHVH-4.1-20170718.2-RHVH-x86_64-dvd1.iso, choose custom partitioning(click '+' to add partitions) 4. After installation finished, log into RHVH, check /var/log/anaconda/anaconda.log for the version, it's 21.48.22.93-1 So, it's wired that the version in /var/log/anaconda/anaconda.log differs according to the partitioning method. > To sum up to me it seems that there is no regression in installer but rhv > tools (imgbase) need to be updated to reflect the changes done in rhv > autopartitioning in RHEL 7.4 > (https://github.com/rhinstaller/anaconda/commit/ > 1596d0b3e2bb58b723f0d099ab3c072ef87cf306), ie to set the discard option for > added partitions/mount points.
It should be the same version of anaconda on the ISO either way. I wonder why there are different version number?
To add one more thing that when using custom partitioning, there won't have related records for the NIST partitions in /etc/fstab. They are mounted via *.mount under /etc/systemd/system/ during boot time. [root@fctest ~]# ll /etc/systemd/system |grep .mount -rw-r--r--. 1 root root 132 Jul 19 20:36 home.mount -rw-r--r--. 1 root root 130 Jul 19 20:36 tmp.mount -rw-r--r--. 1 root root 150 Jul 19 20:36 var-log-audit.mount -rw-r--r--. 1 root root 138 Jul 19 20:36 var-log.mount
(In reply to Qin Yuan from comment #9) > So, it's wired that the version in /var/log/anaconda/anaconda.log differs > according to the partitioning method. Ii is still telling me that, for some mysterious reason, you are doing quite a different installation in your step 3. I wonder if it can be caused by the data on disks from previous installation (step 1.) What if you try step 3. on clean disks? (In reply to Radek Vykydal from comment #8) > I tried > with > http://download-node-02.eng.bos.redhat.com/devel/candidate-trees/RHVH-4.1- > 20170718.2/compose/RHVH/x86_64/iso/ > to create the NIST layout in custom partitioning with the same result as > reported for auto - only / and /var had discard set in /etc/fstab of > installed sytem. This is the /etc/fstab: # # /etc/fstab # Created by anaconda on Wed Jul 19 10:48:54 2017 # # Accessible filesystems, by reference, are maintained under '/dev/disk' # See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info # /dev/rhvh/rhvh-4.1-0.20170714.0+1 / ext4 defaults,discard 1 1 UUID=aa856ef4-8719-4e38-a17b-a0ed2ae26714 /boot ext4 defaults 1 2 /dev/mapper/rhvh-home /home ext4 defaults 1 2 /dev/mapper/rhvh-tmp /tmp ext4 defaults 1 2 /dev/mapper/rhvh-var /var ext4 defaults,discard 1 2 /dev/mapper/rhvh-var_log /var/log ext4 defaults 1 2 /dev/mapper/rhvh-var_log_audit /var/log/audit ext4 defaults 1 2 /dev/mapper/rhvh-swap swap swap defaults 0 0
(In reply to Radek Vykydal from comment #12) > (In reply to Qin Yuan from comment #9) > > > So, it's wired that the version in /var/log/anaconda/anaconda.log differs > > according to the partitioning method. > > Ii is still telling me that, for some mysterious reason, you are doing quite > a different installation in your step 3. I wonder if it can be caused by the > data on disks from previous installation (step 1.) What if you try step 3. > on clean disks? > Tried step3 on clean disk, the result is the same, the version is: 20:47:04,311 INFO anaconda: /sbin/anaconda 21.48.22.93-1 The time is always "20:47:04,311", no matter what the real installation time is. > (In reply to Radek Vykydal from comment #8) > > > I tried > > with > > http://download-node-02.eng.bos.redhat.com/devel/candidate-trees/RHVH-4.1- > > 20170718.2/compose/RHVH/x86_64/iso/ > > to create the NIST layout in custom partitioning with the same result as > > reported for auto - only / and /var had discard set in /etc/fstab of > > installed sytem. > > This is the /etc/fstab: > > # > # /etc/fstab > # Created by anaconda on Wed Jul 19 10:48:54 2017 > # > # Accessible filesystems, by reference, are maintained under '/dev/disk' > # See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info > # > /dev/rhvh/rhvh-4.1-0.20170714.0+1 / ext4 defaults,discard 1 1 > UUID=aa856ef4-8719-4e38-a17b-a0ed2ae26714 /boot ext4 > defaults 1 2 > /dev/mapper/rhvh-home /home ext4 defaults 1 2 > /dev/mapper/rhvh-tmp /tmp ext4 defaults 1 2 > /dev/mapper/rhvh-var /var ext4 defaults,discard 1 2 > /dev/mapper/rhvh-var_log /var/log ext4 defaults 1 2 > /dev/mapper/rhvh-var_log_audit /var/log/audit ext4 defaults > 1 2 > /dev/mapper/rhvh-swap swap swap defaults 0 0 Is this the /etc/fstab for custom partitioning? If so, I guess you might have chosen "click here to create them automatically" on the manual partitioning page, this will have the same effect with auto partitioning. The custom partitioning method I used was clicking "+" at the left bottom corner of manual partitioning page to add /boot, /var, /, and swap manually.
(In reply to Qin Yuan from comment #13) > Is this the /etc/fstab for custom partitioning? If so, I guess you might > have chosen "click here to create them automatically" on the manual > partitioning page, this will have the same effect with auto partitioning. > The custom partitioning method I used was clicking "+" at the left bottom > corner of manual partitioning page to add /boot, /var, /, and swap manually. Yes, I created the partitions individually using "+"
(In reply to Radek Vykydal from comment #15) > (In reply to Qin Yuan from comment #13) > > > Is this the /etc/fstab for custom partitioning? If so, I guess you might > > have chosen "click here to create them automatically" on the manual > > partitioning page, this will have the same effect with auto partitioning. > > The custom partitioning method I used was clicking "+" at the left bottom > > corner of manual partitioning page to add /boot, /var, /, and swap manually. > > Yes, I created the partitions individually using "+" Oh, I see, you must have added /var/log, /var/log/audit, /tmp, and /home via "+". I didn't add these partitions, just only added /boot, /var, / and swap via "+". I tried your case, and the /etc/fstab is: [root@dhcp-10-111 ~]# cat /etc/fstab # # /etc/fstab # Created by anaconda on Thu Jul 20 18:51:52 2017 # # Accessible filesystems, by reference, are maintained under '/dev/disk' # See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info # /dev/rhvh_dhcp-10-111/rhvh-4.1-0.20170714.0+1 / ext4 defaults,discard 1 1 UUID=5417af9e-b1b3-4007-9877-6f2395ff037c /boot ext4 defaults 1 2 /dev/mapper/rhvh_dhcp--10--111-home /home ext4 defaults 1 2 /dev/mapper/rhvh_dhcp--10--111-tmp /tmp ext4 defaults 1 2 /dev/mapper/rhvh_dhcp--10--111-var /var ext4 defaults,discard 1 2 /dev/mapper/rhvh_dhcp--10--111-var_log /var/log ext4 defaults 1 2 /dev/mapper/rhvh_dhcp--10--111-var_log_audit /var/log/audit ext4 defaults 1 2 /dev/mapper/rhvh_dhcp--10--111-swap swap swap defaults 0 0 You could try my case that only add /boot, /var, /, and swap via "+", then check mount infos after installation finished, the result will be like the one in the Additional info.
(In reply to Qin Yuan from comment #16) > You could try my case that only add /boot, /var, /, and swap via "+", then > check mount infos after installation finished, the result will be like the > one in the Additional info. It is.
(In reply to Radek Vykydal from comment #8) > To sum up to me it seems that there is no regression in installer but rhv > tools (imgbase) need to be updated to reflect the changes done in rhv > autopartitioning in RHEL 7.4 > (https://github.com/rhinstaller/anaconda/commit/ > 1596d0b3e2bb58b723f0d099ab3c072ef87cf306), ie to set the discard option for > added partitions/mount points. Therefore changing the component.
Verify Versions: RHVH-4.1-20170723.1-RHVH-x86_64-dvd1.iso redhat-virtualization-host-4.1-20170721.0 imgbased-0.9.34-0.1.el7ev.noarch Verify Steps and Results: 1. Install RHVH via Anaconda GUI, choose auto partitioning, and finish other needed steps. 2. After installation finished, log into to system, run `cat /etc/fstab' to check the discard option for the NIST partitions: [root@fctest ~]# cat /etc/fstab # # /etc/fstab # Created by anaconda on Wed Jul 26 10:06:56 2017 # # Accessible filesystems, by reference, are maintained under '/dev/disk' # See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info # /dev/rhvh_fctest/rhvh-4.1-0.20170721.0+1 / ext4 defaults 1 1 UUID=0e5dc5d4-2dea-48be-bc63-8dc6a032f69e /boot ext4 defaults 1 2 /dev/mapper/rhvh_fctest-home /home ext4 defaults,discard 1 2 /dev/mapper/rhvh_fctest-tmp /tmp ext4 defaults,discard 1 2 /dev/mapper/rhvh_fctest-var /var ext4 defaults,discard 1 2 /dev/mapper/rhvh_fctest-var_log /var/log ext4 defaults,discard 1 2 /dev/mapper/rhvh_fctest-var_log_audit /var/log/audit ext4 defaults,discard 1 2 /dev/mapper/rhvh_fctest-swap swap swap defaults 0 0 There is discard for /home, /tmp, /var/log, and /var/log/audit. But the discard is missing for /, this issue is tracked by Bug 1475111. Since the issue described in the bug is solved, change the status to verified.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2017:2464