Activity log for bug #2065180

Date Who What changed Old value New value Message
2024-05-08 13:37:56 Viraniac bug added bug
2024-05-08 13:40:26 Viraniac description When compared to Ubuntu 23.10, creating intramfs files with update-initramfs takes 2 to 5 times more time on Arm devices. IIUC, dracut-install usage was added to initramfs-tools to speed up the process. But now its way slower. Even running update-initramfs on jammy, which doesn't use dracut-install, is way faster then the time taken on Noble. first bad commit - https://github.com/dracutdevs/dracut/commit/3de4c7313260fb600507c9b87f780390b874c870 $ lsb_release -rd No LSB modules are available. Description: Ubuntu 24.04 LTS Release: 24.04 $ apt-cache policy dracut-install dracut-install: Installed: 060+5-1ubuntu3 Candidate: 060+5-1ubuntu3 Version table: *** 060+5-1ubuntu3 500 500 http://ports.ubuntu.com/ubuntu-ports noble/main arm64 Packages 100 /var/lib/dpkg/status When compared to Ubuntu 23.10, creating intramfs files with update-initramfs takes 2 to 5 times more time on ARM devices. IIUC, dracut-install usage was added to initramfs-tools to speed up the process. But now its way slower. Even running update-initramfs on jammy, which doesn't use dracut-install, is way faster then the time taken on Noble. first bad commit - https://github.com/dracutdevs/dracut/commit/3de4c7313260fb600507c9b87f780390b874c870 $ lsb_release -rd No LSB modules are available. Description: Ubuntu 24.04 LTS Release: 24.04 $ apt-cache policy dracut-install dracut-install:   Installed: 060+5-1ubuntu3   Candidate: 060+5-1ubuntu3   Version table:  *** 060+5-1ubuntu3 500         500 http://ports.ubuntu.com/ubuntu-ports noble/main arm64 Packages         100 /var/lib/dpkg/status
2024-05-09 15:03:22 Dave Jones attachment added initramfs.diff https://bugs.launchpad.net/ubuntu/+source/dracut/+bug/2065180/+attachment/5776701/+files/initramfs.diff
2024-05-24 05:02:44 Benjamin Drung summary performance regression in dracut-install performance regression in dracut-install 060
2024-05-24 05:11:13 Benjamin Drung bug watch added https://github.com/dracut-ng/dracut-ng/issues/316
2024-05-24 05:11:13 Benjamin Drung bug task added dracut
2024-05-24 06:24:59 Bug Watch Updater dracut: status Unknown New
2024-05-24 07:53:09 Benjamin Drung bug task added thin-provisioning-tools (Ubuntu)
2024-05-24 07:53:30 Benjamin Drung bug task added lvm2 (Ubuntu)
2024-05-24 07:54:01 Benjamin Drung bug task added cryptsetup (Ubuntu)
2024-05-24 10:36:18 Launchpad Janitor thin-provisioning-tools (Ubuntu): status New Fix Released
2024-05-25 08:57:42 Launchpad Janitor lvm2 (Ubuntu): status New Fix Released
2024-06-03 17:30:18 Launchpad Janitor cryptsetup (Ubuntu): status New Fix Released
2024-06-04 14:04:36 Benjamin Drung nominated for series Ubuntu Noble
2024-06-04 14:04:36 Benjamin Drung bug task added lvm2 (Ubuntu Noble)
2024-06-04 14:04:36 Benjamin Drung bug task added cryptsetup (Ubuntu Noble)
2024-06-04 14:04:36 Benjamin Drung bug task added dracut (Ubuntu Noble)
2024-06-04 14:04:36 Benjamin Drung bug task added thin-provisioning-tools (Ubuntu Noble)
2024-06-04 14:05:18 Benjamin Drung bug task added miniramfs (Ubuntu)
2024-06-04 15:20:41 Benjamin Drung description When compared to Ubuntu 23.10, creating intramfs files with update-initramfs takes 2 to 5 times more time on ARM devices. IIUC, dracut-install usage was added to initramfs-tools to speed up the process. But now its way slower. Even running update-initramfs on jammy, which doesn't use dracut-install, is way faster then the time taken on Noble. first bad commit - https://github.com/dracutdevs/dracut/commit/3de4c7313260fb600507c9b87f780390b874c870 $ lsb_release -rd No LSB modules are available. Description: Ubuntu 24.04 LTS Release: 24.04 $ apt-cache policy dracut-install dracut-install:   Installed: 060+5-1ubuntu3   Candidate: 060+5-1ubuntu3   Version table:  *** 060+5-1ubuntu3 500         500 http://ports.ubuntu.com/ubuntu-ports noble/main arm64 Packages         100 /var/lib/dpkg/status [ Impact ] When compared to Ubuntu 23.10, creating intramfs files with update-initramfs takes 2 to 5 times more time on ARM devices. IIUC, dracut-install usage was added to initramfs-tools to speed up the process. But now its way slower. Even running update-initramfs on jammy, which doesn't use dracut-install, is way faster then the time taken on Noble. first bad commit - https://github.com/dracutdevs/dracut/commit/3de4c7313260fb600507c9b87f780390b874c870 Updating the initrd on a Raspberry Pi Zero 2W on Ubuntu 24.04 (noble) with initramfs-tools 0.142ubuntu25.1 takes over six minutes: ``` bdrung@zero2w:~$ sudo hyperfine --warmup 1 -r 10 "update-initramfs -u" Benchmark 1: update-initramfs -u Time (mean ± σ): 402.751 s ± 5.592 s [User: 166.316 s, System: 228.909 s] Range (min … max): 394.380 s … 411.445 s 10 runs ``` [ Test Plan ] 1. Measure `update-initramfs -u` before the update. 2. Log the content of the initrd before the update: `lsinitramfs /boot/initrd.img` 3. update dracut-install / initramfs-tools-core 4. Measure `update-initramfs -u`. It should be faster (the performance improvements on amd64 should be very small and might be within the measurement uncertainty). 5. Check with lsinitramfs that the content of the newly generated initrd hasn't changed. [ Where problems could occur ] The code that is responsible for including the kernel modules into the initrd is touched. Negative consequences could be that some needed kernel modules will not be included any more (should be covered by the test case) or that building new initrds will fail. The initramfs-tools fix changes how manual_add_modules behaves. `manual_add_modules` does not copy kernel modules, but queues them for being copied when the newly added function `apply_add_modules` is called. I checked all instances of calls to `manual_add_modules` for possible regressions (see comment #15). Only miniramfs needs to be adjusted to also call `apply_add_modules`. But this change could break consumers of the `manual_add_modules` function that are outside of the Ubuntu archive. I googled for `apply_add_modules` but found no public outside users. [ Other Info ] $ lsb_release -rd No LSB modules are available. Description: Ubuntu 24.04 LTS Release: 24.04 $ apt-cache policy dracut-install dracut-install:   Installed: 060+5-1ubuntu3   Candidate: 060+5-1ubuntu3   Version table:  *** 060+5-1ubuntu3 500         500 http://ports.ubuntu.com/ubuntu-ports noble/main arm64 Packages         100 /var/lib/dpkg/status
2024-06-04 15:28:30 Benjamin Drung dracut (Ubuntu): importance Undecided High
2024-06-04 15:28:30 Benjamin Drung dracut (Ubuntu): status New Fix Committed
2024-06-04 15:28:54 Benjamin Drung miniramfs (Ubuntu): importance Undecided High
2024-06-04 15:28:54 Benjamin Drung miniramfs (Ubuntu): status New Fix Committed
2024-06-04 15:29:20 Benjamin Drung bug task added initramfs-tools (Ubuntu)
2024-06-04 15:29:35 Benjamin Drung initramfs-tools (Ubuntu): importance Undecided High
2024-06-04 15:29:35 Benjamin Drung initramfs-tools (Ubuntu): status New Fix Committed
2024-06-04 21:13:32 Launchpad Janitor miniramfs (Ubuntu): status Fix Committed Fix Released
2024-06-04 21:13:34 Launchpad Janitor initramfs-tools (Ubuntu): status Fix Committed Fix Released
2024-06-05 03:04:39 Launchpad Janitor dracut (Ubuntu): status Fix Committed Fix Released
2024-06-06 15:05:40 Launchpad Janitor merge proposal linked https://code.launchpad.net/~jefferyto/ubuntu/+source/initramfs-tools/+git/initramfs-tools/+merge/467015
2024-06-06 18:49:47 Launchpad Janitor merge proposal unlinked https://code.launchpad.net/~jefferyto/ubuntu/+source/initramfs-tools/+git/initramfs-tools/+merge/467015
2024-06-14 14:21:05 Timo Aaltonen dracut (Ubuntu Noble): status New Fix Committed
2024-06-14 14:21:06 Timo Aaltonen bug added subscriber Ubuntu Stable Release Updates Team
2024-06-14 14:21:10 Timo Aaltonen bug added subscriber SRU Verification
2024-06-14 14:21:13 Timo Aaltonen tags verification-needed verification-needed-noble
2024-06-17 13:20:21 Benjamin Drung tags verification-needed verification-needed-noble verification-done verification-done-noble
2024-06-19 08:15:29 Chris Halse Rogers initramfs-tools (Ubuntu Noble): status New Incomplete
2024-06-27 18:28:42 Launchpad Janitor dracut (Ubuntu Noble): status Fix Committed Fix Released
2024-06-27 18:28:47 Andreas Hasenack removed subscriber Ubuntu Stable Release Updates Team
2024-07-01 08:36:09 Benjamin Drung tags verification-done verification-done-noble fountations-todo verification-done verification-done-noble
2024-07-01 08:36:25 Benjamin Drung initramfs-tools (Ubuntu Noble): assignee Benjamin Drung (bdrung)
2024-07-01 09:05:16 Steve Langasek tags fountations-todo verification-done verification-done-noble foundations-todo verification-done verification-done-noble
2024-07-01 15:24:36 Benjamin Drung description [ Impact ] When compared to Ubuntu 23.10, creating intramfs files with update-initramfs takes 2 to 5 times more time on ARM devices. IIUC, dracut-install usage was added to initramfs-tools to speed up the process. But now its way slower. Even running update-initramfs on jammy, which doesn't use dracut-install, is way faster then the time taken on Noble. first bad commit - https://github.com/dracutdevs/dracut/commit/3de4c7313260fb600507c9b87f780390b874c870 Updating the initrd on a Raspberry Pi Zero 2W on Ubuntu 24.04 (noble) with initramfs-tools 0.142ubuntu25.1 takes over six minutes: ``` bdrung@zero2w:~$ sudo hyperfine --warmup 1 -r 10 "update-initramfs -u" Benchmark 1: update-initramfs -u Time (mean ± σ): 402.751 s ± 5.592 s [User: 166.316 s, System: 228.909 s] Range (min … max): 394.380 s … 411.445 s 10 runs ``` [ Test Plan ] 1. Measure `update-initramfs -u` before the update. 2. Log the content of the initrd before the update: `lsinitramfs /boot/initrd.img` 3. update dracut-install / initramfs-tools-core 4. Measure `update-initramfs -u`. It should be faster (the performance improvements on amd64 should be very small and might be within the measurement uncertainty). 5. Check with lsinitramfs that the content of the newly generated initrd hasn't changed. [ Where problems could occur ] The code that is responsible for including the kernel modules into the initrd is touched. Negative consequences could be that some needed kernel modules will not be included any more (should be covered by the test case) or that building new initrds will fail. The initramfs-tools fix changes how manual_add_modules behaves. `manual_add_modules` does not copy kernel modules, but queues them for being copied when the newly added function `apply_add_modules` is called. I checked all instances of calls to `manual_add_modules` for possible regressions (see comment #15). Only miniramfs needs to be adjusted to also call `apply_add_modules`. But this change could break consumers of the `manual_add_modules` function that are outside of the Ubuntu archive. I googled for `apply_add_modules` but found no public outside users. [ Other Info ] $ lsb_release -rd No LSB modules are available. Description: Ubuntu 24.04 LTS Release: 24.04 $ apt-cache policy dracut-install dracut-install:   Installed: 060+5-1ubuntu3   Candidate: 060+5-1ubuntu3   Version table:  *** 060+5-1ubuntu3 500         500 http://ports.ubuntu.com/ubuntu-ports noble/main arm64 Packages         100 /var/lib/dpkg/status [ Impact ] When compared to Ubuntu 23.10, creating intramfs files with update-initramfs takes 2 to 5 times more time on ARM devices. IIUC, dracut-install usage was added to initramfs-tools to speed up the process. But now its way slower. Even running update-initramfs on jammy, which doesn't use dracut-install, is way faster then the time taken on Noble. first bad commit - https://github.com/dracutdevs/dracut/commit/3de4c7313260fb600507c9b87f780390b874c870 Updating the initrd on a Raspberry Pi Zero 2W on Ubuntu 24.04 (noble) with initramfs-tools 0.142ubuntu25.1 takes over six minutes: ``` bdrung@zero2w:~$ sudo hyperfine --warmup 1 -r 10 "update-initramfs -u" Benchmark 1: update-initramfs -u   Time (mean ± σ): 402.751 s ± 5.592 s [User: 166.316 s, System: 228.909 s]   Range (min … max): 394.380 s … 411.445 s 10 runs ``` [ Test Plan ] 1. Measure `update-initramfs -u` before the update. 2. Log the content of the initrd before the update: `lsinitramfs /boot/initrd.img` 3. update dracut-install / initramfs-tools-core 4. Measure `update-initramfs -u`. It should be faster (the performance improvements on amd64 should be very small and might be within the measurement uncertainty). 5. Check with lsinitramfs that the content of the newly generated initrd hasn't changed. [ Where problems could occur ] The code that is responsible for including the kernel modules into the initrd is touched. Negative consequences could be that some needed kernel modules will not be included any more (should be covered by the test case) or that building new initrds will fail. The initramfs-tools fix changes how manual_add_modules behaves. `manual_add_modules` does not copy kernel modules, but queues them for being copied when the newly added function `apply_add_modules` is called. I checked all instances of calls to `manual_add_modules` for possible regressions (see comment #15). Only miniramfs needs to be adjusted to also call `apply_add_modules`. But this change could break consumers of the `manual_add_modules` function that are outside of the Ubuntu archive. I googled for `apply_add_modules` but found no public outside users. [ Benchmarks ] Stock noble on a Raspberry Pi Zero 2W: ``` bdrung@zero2w:~$ sudo hyperfine -r 5 "update-initramfs -u" Benchmark 1: update-initramfs -u Time (mean ± σ): 415.664 s ± 6.015 s [User: 166.728 s, System: 232.523 s] Range (min … max): 409.139 s … 422.632 s 5 runs ``` [ Other Info ] $ lsb_release -rd No LSB modules are available. Description: Ubuntu 24.04 LTS Release: 24.04 $ apt-cache policy dracut-install dracut-install:   Installed: 060+5-1ubuntu3   Candidate: 060+5-1ubuntu3   Version table:  *** 060+5-1ubuntu3 500         500 http://ports.ubuntu.com/ubuntu-ports noble/main arm64 Packages         100 /var/lib/dpkg/status
2024-07-01 16:27:17 Benjamin Drung description [ Impact ] When compared to Ubuntu 23.10, creating intramfs files with update-initramfs takes 2 to 5 times more time on ARM devices. IIUC, dracut-install usage was added to initramfs-tools to speed up the process. But now its way slower. Even running update-initramfs on jammy, which doesn't use dracut-install, is way faster then the time taken on Noble. first bad commit - https://github.com/dracutdevs/dracut/commit/3de4c7313260fb600507c9b87f780390b874c870 Updating the initrd on a Raspberry Pi Zero 2W on Ubuntu 24.04 (noble) with initramfs-tools 0.142ubuntu25.1 takes over six minutes: ``` bdrung@zero2w:~$ sudo hyperfine --warmup 1 -r 10 "update-initramfs -u" Benchmark 1: update-initramfs -u   Time (mean ± σ): 402.751 s ± 5.592 s [User: 166.316 s, System: 228.909 s]   Range (min … max): 394.380 s … 411.445 s 10 runs ``` [ Test Plan ] 1. Measure `update-initramfs -u` before the update. 2. Log the content of the initrd before the update: `lsinitramfs /boot/initrd.img` 3. update dracut-install / initramfs-tools-core 4. Measure `update-initramfs -u`. It should be faster (the performance improvements on amd64 should be very small and might be within the measurement uncertainty). 5. Check with lsinitramfs that the content of the newly generated initrd hasn't changed. [ Where problems could occur ] The code that is responsible for including the kernel modules into the initrd is touched. Negative consequences could be that some needed kernel modules will not be included any more (should be covered by the test case) or that building new initrds will fail. The initramfs-tools fix changes how manual_add_modules behaves. `manual_add_modules` does not copy kernel modules, but queues them for being copied when the newly added function `apply_add_modules` is called. I checked all instances of calls to `manual_add_modules` for possible regressions (see comment #15). Only miniramfs needs to be adjusted to also call `apply_add_modules`. But this change could break consumers of the `manual_add_modules` function that are outside of the Ubuntu archive. I googled for `apply_add_modules` but found no public outside users. [ Benchmarks ] Stock noble on a Raspberry Pi Zero 2W: ``` bdrung@zero2w:~$ sudo hyperfine -r 5 "update-initramfs -u" Benchmark 1: update-initramfs -u Time (mean ± σ): 415.664 s ± 6.015 s [User: 166.728 s, System: 232.523 s] Range (min … max): 409.139 s … 422.632 s 5 runs ``` [ Other Info ] $ lsb_release -rd No LSB modules are available. Description: Ubuntu 24.04 LTS Release: 24.04 $ apt-cache policy dracut-install dracut-install:   Installed: 060+5-1ubuntu3   Candidate: 060+5-1ubuntu3   Version table:  *** 060+5-1ubuntu3 500         500 http://ports.ubuntu.com/ubuntu-ports noble/main arm64 Packages         100 /var/lib/dpkg/status [ Impact ] When compared to Ubuntu 23.10, creating intramfs files with update-initramfs takes 2 to 5 times more time on ARM devices. IIUC, dracut-install usage was added to initramfs-tools to speed up the process. But now its way slower. Even running update-initramfs on jammy, which doesn't use dracut-install, is way faster then the time taken on Noble. first bad commit - https://github.com/dracutdevs/dracut/commit/3de4c7313260fb600507c9b87f780390b874c870 Updating the initrd on a Raspberry Pi Zero 2W on Ubuntu 24.04 (noble) with initramfs-tools 0.142ubuntu25.1 takes over six minutes: ``` bdrung@zero2w:~$ sudo hyperfine --warmup 1 -r 10 "update-initramfs -u" Benchmark 1: update-initramfs -u   Time (mean ± σ): 402.751 s ± 5.592 s [User: 166.316 s, System: 228.909 s]   Range (min … max): 394.380 s … 411.445 s 10 runs ``` [ Test Plan ] 1. Measure `update-initramfs -u` before the update. 2. Log the content of the initrd before the update: `lsinitramfs /boot/initrd.img` 3. update dracut-install / initramfs-tools-core 4. Measure `update-initramfs -u`. It should be faster (the performance improvements on amd64 should be very small and might be within the measurement uncertainty). 5. Check with lsinitramfs that the content of the newly generated initrd hasn't changed. [ Where problems could occur ] The code that is responsible for including the kernel modules into the initrd is touched. Negative consequences could be that some needed kernel modules will not be included any more (should be covered by the test case) or that building new initrds will fail. The initramfs-tools fix changes how manual_add_modules behaves. `manual_add_modules` does not copy kernel modules, but queues them for being copied when the newly added function `apply_add_modules` is called. I checked all instances of calls to `manual_add_modules` for possible regressions (see comment #15). Only miniramfs needs to be adjusted to also call `apply_add_modules`. But this change could break consumers of the `manual_add_modules` function that are outside of the Ubuntu archive. I googled for `apply_add_modules` but found no public outside users. [ Benchmarks ] Stock noble on a Raspberry Pi Zero 2W: ``` bdrung@zero2w:~$ sudo hyperfine -r 5 "update-initramfs -u" Benchmark 1: update-initramfs -u   Time (mean ± σ): 415.664 s ± 6.015 s [User: 166.728 s, System: 232.523 s]   Range (min … max): 409.139 s … 422.632 s 5 runs ``` noble with dracut-install 060+5-1ubuntu3.1 (with linux 6.8.0-1006.6 on 2024-07-01): ``` bdrung@zero2w:~$ sudo hyperfine --warmup 1 -r 10 "update-initramfs -u" Benchmark 1: update-initramfs -u Time (mean ± σ): 248.054 s ± 5.569 s [User: 67.410 s, System: 169.412 s] Range (min … max): 238.909 s … 257.384 s 10 runs ``` [ Other Info ] $ lsb_release -rd No LSB modules are available. Description: Ubuntu 24.04 LTS Release: 24.04 $ apt-cache policy dracut-install dracut-install:   Installed: 060+5-1ubuntu3   Candidate: 060+5-1ubuntu3   Version table:  *** 060+5-1ubuntu3 500         500 http://ports.ubuntu.com/ubuntu-ports noble/main arm64 Packages         100 /var/lib/dpkg/status
2024-07-01 19:03:29 Benjamin Drung bug task added open-iscsi (Ubuntu)
2024-07-01 19:03:44 Benjamin Drung open-iscsi (Ubuntu): status New Invalid
2024-07-01 19:17:13 Zicheng Ji bug added subscriber Zicheng Ji
2024-07-02 09:50:55 Launchpad Janitor merge proposal linked https://code.launchpad.net/~bdrung/cloud-initramfs-tools/+git/cloud-initramfs-tools/+merge/468579
2024-07-02 10:42:17 Benjamin Drung bug task added cloud-initramfs-tools (Ubuntu)
2024-07-02 10:50:27 Paride Legovini cloud-initramfs-tools (Ubuntu): status New Fix Committed
2024-07-02 10:51:22 Launchpad Janitor merge proposal linked https://code.launchpad.net/~bdrung/ubuntu/+source/initramfs-tools/+git/initramfs-tools/+merge/468583
2024-07-02 11:19:33 Benjamin Drung merge proposal unlinked https://code.launchpad.net/~bdrung/ubuntu/+source/initramfs-tools/+git/initramfs-tools/+merge/468583
2024-07-02 11:52:27 Benjamin Drung description [ Impact ] When compared to Ubuntu 23.10, creating intramfs files with update-initramfs takes 2 to 5 times more time on ARM devices. IIUC, dracut-install usage was added to initramfs-tools to speed up the process. But now its way slower. Even running update-initramfs on jammy, which doesn't use dracut-install, is way faster then the time taken on Noble. first bad commit - https://github.com/dracutdevs/dracut/commit/3de4c7313260fb600507c9b87f780390b874c870 Updating the initrd on a Raspberry Pi Zero 2W on Ubuntu 24.04 (noble) with initramfs-tools 0.142ubuntu25.1 takes over six minutes: ``` bdrung@zero2w:~$ sudo hyperfine --warmup 1 -r 10 "update-initramfs -u" Benchmark 1: update-initramfs -u   Time (mean ± σ): 402.751 s ± 5.592 s [User: 166.316 s, System: 228.909 s]   Range (min … max): 394.380 s … 411.445 s 10 runs ``` [ Test Plan ] 1. Measure `update-initramfs -u` before the update. 2. Log the content of the initrd before the update: `lsinitramfs /boot/initrd.img` 3. update dracut-install / initramfs-tools-core 4. Measure `update-initramfs -u`. It should be faster (the performance improvements on amd64 should be very small and might be within the measurement uncertainty). 5. Check with lsinitramfs that the content of the newly generated initrd hasn't changed. [ Where problems could occur ] The code that is responsible for including the kernel modules into the initrd is touched. Negative consequences could be that some needed kernel modules will not be included any more (should be covered by the test case) or that building new initrds will fail. The initramfs-tools fix changes how manual_add_modules behaves. `manual_add_modules` does not copy kernel modules, but queues them for being copied when the newly added function `apply_add_modules` is called. I checked all instances of calls to `manual_add_modules` for possible regressions (see comment #15). Only miniramfs needs to be adjusted to also call `apply_add_modules`. But this change could break consumers of the `manual_add_modules` function that are outside of the Ubuntu archive. I googled for `apply_add_modules` but found no public outside users. [ Benchmarks ] Stock noble on a Raspberry Pi Zero 2W: ``` bdrung@zero2w:~$ sudo hyperfine -r 5 "update-initramfs -u" Benchmark 1: update-initramfs -u   Time (mean ± σ): 415.664 s ± 6.015 s [User: 166.728 s, System: 232.523 s]   Range (min … max): 409.139 s … 422.632 s 5 runs ``` noble with dracut-install 060+5-1ubuntu3.1 (with linux 6.8.0-1006.6 on 2024-07-01): ``` bdrung@zero2w:~$ sudo hyperfine --warmup 1 -r 10 "update-initramfs -u" Benchmark 1: update-initramfs -u Time (mean ± σ): 248.054 s ± 5.569 s [User: 67.410 s, System: 169.412 s] Range (min … max): 238.909 s … 257.384 s 10 runs ``` [ Other Info ] $ lsb_release -rd No LSB modules are available. Description: Ubuntu 24.04 LTS Release: 24.04 $ apt-cache policy dracut-install dracut-install:   Installed: 060+5-1ubuntu3   Candidate: 060+5-1ubuntu3   Version table:  *** 060+5-1ubuntu3 500         500 http://ports.ubuntu.com/ubuntu-ports noble/main arm64 Packages         100 /var/lib/dpkg/status [ Impact ] When compared to Ubuntu 23.10, creating intramfs files with update-initramfs takes 2 to 5 times more time on ARM devices. IIUC, dracut-install usage was added to initramfs-tools to speed up the process. But now its way slower. Even running update-initramfs on jammy, which doesn't use dracut-install, is way faster then the time taken on Noble. first bad commit - https://github.com/dracutdevs/dracut/commit/3de4c7313260fb600507c9b87f780390b874c870 Updating the initrd on a Raspberry Pi Zero 2W on Ubuntu 24.04 (noble) with initramfs-tools 0.142ubuntu25.1 takes over six minutes: ``` bdrung@zero2w:~$ sudo hyperfine --warmup 1 -r 10 "update-initramfs -u" Benchmark 1: update-initramfs -u   Time (mean ± σ): 402.751 s ± 5.592 s [User: 166.316 s, System: 228.909 s]   Range (min … max): 394.380 s … 411.445 s 10 runs ``` [ Test Plan ] 1. Measure `update-initramfs -u` before the update. 2. Log the content of the initrd before the update: `lsinitramfs /boot/initrd.img` 3. update dracut-install / initramfs-tools-core 4. Measure `update-initramfs -u`. It should be faster (the performance improvements on amd64 should be very small and might be within the measurement uncertainty). 5. Check with lsinitramfs that the content of the newly generated initrd hasn't changed. [ Where problems could occur ] The code that is responsible for including the kernel modules into the initrd is touched. Negative consequences could be that some needed kernel modules will not be included any more (should be covered by the test case) or that building new initrds will fail. The initramfs-tools fix changes how manual_add_modules behaves. `manual_add_modules` does not copy kernel modules, but queues them for being copied when the newly added function `apply_add_modules` is called. I checked all instances of calls to `manual_add_modules` for possible regressions (see comment #15). Only miniramfs needs to be adjusted to also call `apply_add_modules`. But this change could break consumers of the `manual_add_modules` function that are outside of the Ubuntu archive. I googled for `apply_add_modules` but found no public outside users. [ Benchmarks ] Stock noble on a Raspberry Pi Zero 2W: ``` bdrung@zero2w:~$ sudo hyperfine -r 5 "update-initramfs -u" Benchmark 1: update-initramfs -u   Time (mean ± σ): 415.664 s ± 6.015 s [User: 166.728 s, System: 232.523 s]   Range (min … max): 409.139 s … 422.632 s 5 runs ``` noble with dracut-install 060+5-1ubuntu3.1 (with linux 6.8.0-1006.6 on 2024-07-01): ``` bdrung@zero2w:~$ sudo hyperfine --warmup 1 -r 10 "update-initramfs -u" Benchmark 1: update-initramfs -u   Time (mean ± σ): 248.054 s ± 5.569 s [User: 67.410 s, System: 169.412 s]   Range (min … max): 238.909 s … 257.384 s 10 runs ``` [ Reduce manual_add_modules calls ] Besides making the dracut-install calls faster, group the dracut-install calls. Since the fix in oracular can cause regressions in custom hooks that rely on the current behavior, the SRU takes a safe approach which includes following packages (stating how many dracut-install calls are used): * cryptsetup: 2 -> 1 * lvm2: 8 -> 1 * thin-provisioning-tools: 3 -> 1 * open-iscsi: 9 -> 1 * cloud-initramfs-tools: 5 -> 1 dracut-install calls on a Raspberry Pi Zero 2W: | area | before | noble SRU | oracular | |--------------------------------------|--------|-----------|----------| | auto_add_modules + apply_add_modules | 8 | 5 | 5 | | calls by hooks + apply_add_modules | 42 | 20 | 2 | | hidden_dep_add_modules | 1 | 1 | 1 | | total | 51 | 26 | 8 | [ Other Info ] $ lsb_release -rd No LSB modules are available. Description: Ubuntu 24.04 LTS Release: 24.04 $ apt-cache policy dracut-install dracut-install:   Installed: 060+5-1ubuntu3   Candidate: 060+5-1ubuntu3   Version table:  *** 060+5-1ubuntu3 500         500 http://ports.ubuntu.com/ubuntu-ports noble/main arm64 Packages         100 /var/lib/dpkg/status
2024-07-02 19:59:26 Launchpad Janitor cloud-initramfs-tools (Ubuntu): status Fix Committed Fix Released
2024-07-05 08:26:59 Benjamin Drung initramfs-tools (Ubuntu Noble): status Incomplete New
2024-07-05 08:27:20 Benjamin Drung tags foundations-todo verification-done verification-done-noble verification-done verification-done-noble
2024-07-08 18:47:29 Benjamin Drung dracut (Ubuntu): status Fix Released Fix Committed
2024-07-08 18:47:41 Benjamin Drung dracut (Ubuntu Noble): status Fix Released New
2024-07-09 01:19:05 Launchpad Janitor dracut (Ubuntu): status Fix Committed Fix Released
2024-07-10 04:52:54 Chris Halse Rogers initramfs-tools (Ubuntu Noble): status New Fix Committed
2024-07-10 04:52:59 Chris Halse Rogers bug added subscriber Ubuntu Stable Release Updates Team
2024-07-10 04:53:06 Chris Halse Rogers tags verification-done verification-done-noble verification-needed verification-needed-noble
2024-07-10 06:38:36 Chris Halse Rogers cryptsetup (Ubuntu Noble): status New Fix Committed
2024-07-10 06:40:26 Chris Halse Rogers lvm2 (Ubuntu Noble): status New Fix Committed
2024-07-10 06:45:07 Chris Halse Rogers thin-provisioning-tools (Ubuntu Noble): status New Fix Committed
2024-07-10 06:48:52 Chris Halse Rogers open-iscsi (Ubuntu Noble): status New Fix Committed
2024-07-10 07:09:39 Chris Halse Rogers dracut (Ubuntu Noble): status New Fix Committed