**NOTE** January 2022 - Changes to Gstreamer and Pipewire packages from PackmanPlease read the following thread about the current changes
-
how to speed up initrd at boot
I'm trying to diagnose my boot time, and discovered that the largest share is taken by initrd.
This is the output of systemd-analyze
Code:
Startup finished in 4.356s (kernel) + 1min 32.790s (initrd) + 40.040s (userspace) = 2min 17.186s
Are these values normal or could be improved? If possible, I'd like to speed up the whole process.
-
Re: how to speed up initrd at boot
Try systemd-analyze blame to see which processes ar taking the time
-
Re: how to speed up initrd at boot
 Originally Posted by sekhemty
I'm trying to diagnose my boot time, and discovered that the largest share is taken by initrd.
This is the output of systemd-analyze
Code:
Startup finished in 4.356s (kernel) + 1min 32.790s (initrd) + 40.040s (userspace) = 2min 17.186s
Are these values normal or could be improved? If possible, I'd like to speed up the whole process.
Hi
Not normal at all.... should only be 2-3 seconds, I see around 5 seconds on the raspberry pi3.
A slow or failing disk maybe?
Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
If you find this post helpful and are logged into the web interface,
please show your appreciation and click on the star below... Thanks!
-
Re: how to speed up initrd at boot
*freeze down my back* I hope not...
this is the SMART report
Code:
smartctl 6.5 2016-05-07 r4318 [x86_64-linux-4.9.10-1-default] (SUSE RPM)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF READ SMART DATA SECTION ===
SMART Attributes Data Structure revision number: 16
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME FLAG VALUE WORST THRESH TYPE UPDATED WHEN_FAILED RAW_VALUE
1 Raw_Read_Error_Rate 0x002f 200 200 051 Pre-fail Always - 1
3 Spin_Up_Time 0x0027 180 176 021 Pre-fail Always - 1966
4 Start_Stop_Count 0x0032 098 098 000 Old_age Always - 2696
5 Reallocated_Sector_Ct 0x0033 200 200 140 Pre-fail Always - 0
7 Seek_Error_Rate 0x002e 100 253 000 Old_age Always - 0
9 Power_On_Hours 0x0032 079 079 000 Old_age Always - 15914
10 Spin_Retry_Count 0x0032 100 100 051 Old_age Always - 0
11 Calibration_Retry_Count 0x0032 100 100 000 Old_age Always - 0
12 Power_Cycle_Count 0x0032 098 098 000 Old_age Always - 2671
192 Power-Off_Retract_Count 0x0032 200 200 000 Old_age Always - 249
193 Load_Cycle_Count 0x0032 160 160 000 Old_age Always - 122929
194 Temperature_Celsius 0x0022 099 088 000 Old_age Always - 48
196 Reallocated_Event_Count 0x0032 200 200 000 Old_age Always - 0
197 Current_Pending_Sector 0x0032 200 200 000 Old_age Always - 0
198 Offline_Uncorrectable 0x0030 100 253 000 Old_age Offline - 0
199 UDMA_CRC_Error_Count 0x0032 200 200 000 Old_age Always - 0
200 Multi_Zone_Error_Rate 0x0008 200 200 051 Old_age Offline - 0
-
Re: how to speed up initrd at boot
 Originally Posted by sekhemty
I'm trying to diagnose my boot time, and discovered that the largest share is taken by initrd.
This is the output of systemd-analyze
Code:
Startup finished in 4.356s (kernel) + 1min 32.790s (initrd) + 40.040s (userspace) = 2min 17.186s
Are these values normal or could be improved? If possible, I'd like to speed up the whole process.
For comparison, I see:
Code:
Startup finished in 55us (firmware) + 23us (loader) + 1.224s (kernel) + 15.834s (initrd) + 18.487s (userspace) = 35.547s
That's already slow. But most of my "initrd" time will be how long it takes me to type in the encryption key (using an encrypted LVM).
openSUSE Leap 15.4; KDE Plasma 5.24.4;
testing Tumbleweed.
-
Re: how to speed up initrd at boot
without output from "systemd-analyze blame" there can be no diagnosis
-
Re: how to speed up initrd at boot
without output from "systemd-analyze blame" there can be no diagnosis
My problem is with initrd, AFAIK systemd and its processes and services are loaded after initrd has finished; afaik "systemd-analyze blame" can't help with initrd.
Anyway, here is the output:
Code:
15.883s nmb.service
10.337s apparmor.service
9.186s dev-sda5.device
8.771s systemd-udev-settle.service
8.007s systemd-journal-flush.service
7.280s libvirtd.service
6.769s SuSEfirewall2.service
6.389s SuSEfirewall2_init.service
4.831s ntpd.service
4.683s ModemManager.service
4.126s postfix.service
3.747s display-manager.service
2.940s cups.service
2.884s systemd-udevd.service
2.400s systemd-fsck@dev-disk-by\x2duuid-490f1cc3\x2d4911\x2d45a8\x2da7f0\x2da5f4f707554a.service
2.331s smb.service
2.182s lvm2-activation-net.service
2.141s rc-local.service
2.141s nscd.service
1.798s rpcbind.service
1.699s systemd-vconsole-setup.service
1.487s NetworkManager.service
1.265s polkit.service
966ms plymouth-read-write.service
810ms upower.service
778ms wpa_supplicant.service
713ms tmp.mount
711ms systemd-tmpfiles-setup-dev.service
685ms systemd-remount-fs.service
670ms sys-kernel-debug.mount
620ms boot-grub2-i386\x2dpc.mount
571ms var-lib-mysql.mount
528ms dev-mqueue.mount
525ms dev-hugepages.mount
513ms udisks2.service
509ms avahi-daemon.service
508ms var-lib-machines.mount
459ms opt.mount
405ms var-log.mount
378ms var-lib-libvirt-images.mount
356ms boot-grub2-x86_64\x2defi.mount
344ms dev-disk-by\x2duuid-bab51854\x2dd247\x2d4166\x2d90cc\x2d2b9041e5c199.swap
337ms var-lib-mariadb.mount
336ms var-lib-pgsql.mount
332ms systemd-udev-root-symlink.service
332ms var-lib-mailman.mount
332ms var-lib-mailman.mount
327ms lvm2-activation-early.service
305ms var-lib-named.mount
303ms systemd-random-seed.service
299ms var-tmp.mount
296ms systemd-udev-trigger.service
292ms var-cache.mount
282ms dracut-shutdown.service
280ms auditd.service
276ms srv.mount
275ms systemd-logind.service
270ms home.mount
268ms systemd-backlight@backlight:acpi_video0.service
266ms systemd-sysctl.service
199ms mcelog.service
195ms usr-local.mount
193ms systemd-tmpfiles-setup.service
192ms user@1000.service
180ms systemd-user-sessions.service
162ms var-spool.mount
154ms var-opt.mount
150ms systemd-journald.service
140ms rtkit-daemon.service
132ms systemd-rfkill.service
132ms \x2esnapshots.mount
124ms systemd-modules-load.service
121ms var-crash.mount
109ms systemd-fsck-root.service
74ms systemd-tmpfiles-clean.service
57ms plymouth-start.service
19ms lvm2-activation.service
16ms systemd-update-utmp.service
8ms kmod-static-nodes.service
8ms sys-fs-fuse-connections.mount
7ms alsa-restore.service
6ms systemd-update-utmp-runlevel.service
3ms var-run.mount
-
Re: how to speed up initrd at boot
my apologies - you are correct i should read more carefully, i saw the conversation moving to disk issues before getting data. this would be better handled by the more experienced, but would journal not have info from initrd stage (with directives for logging level)?
-
Re: how to speed up initrd at boot
Okay, try this:
Code:
ls -lh /boot/vmlinuz-* /boot/initrd-*
then
Code:
rpm -qf /lib/mkinitrd/scripts/setup-* | sort -u
"Take a Walk on a Sunny Day, Greet everyone along the way, and Make Somebody Smile, Today"
— Gerry Jack Macks"Walk On A Sunny Day" GerryJackMacks.net
-
Re: how to speed up initrd at boot
 Originally Posted by Fraser_Bell
Okay, try this:
Code:
ls -lh /boot/vmlinuz-* /boot/initrd-*
then
Code:
rpm -qf /lib/mkinitrd/scripts/setup-* | sort -u
Hi
The other one is;
Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
If you find this post helpful and are logged into the web interface,
please show your appreciation and click on the star below... Thanks!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|