You are not logged in.

#1 2009-03-10 17:59:27

Mogger
Member
From: Sweden
Registered: 2008-12-07
Posts: 153
Website

[SOLVED] Slow boot after upgrade

Since the last pacman -Syu, my netbook takes a considerable longer time to boot Arch: when X starts, I get a blank screen for a couple of seconds before the mouse cursor shows up. Needless to say, I suspected that something was wrong with xorg, so I tried to start it manually with the startx command. Surprise, xorg starts up "immediately" (as in 1-2 seconds).

Next try. I unbackgrounded all daemons in /etc/rc.conf (thought something might slow everything down) and disabled kdm. Here comes the next surprise. When I've entered my name in TTY1 and pressed Enter, I have to wait a couple of seconds (as in: unusual long time) before it asks for my password.

So what could be the cause of all of this?

/etc/rc.conf (removed comments)

LOCALE="en_US.utf8"
HARDWARECLOCK="UTC"
USEDIRECTISA="no"
TIMEZONE="Europe/Stockholm"
KEYMAP="se-lat6"
CONSOLEFONT=
CONSOLEMAP=
USECOLOR="yes"
MOD_AUTOLOAD="yes"
MODULES=(acpi_cpufreq cpufreq_ondemand cpufreq_powersave sky2 ath5k !ath_hal !ath_pci !wlan !snd-mixer-oss snd-pcm-oss !snd-hwdep !snd-page-alloc !snd-pcm !snd-timer !snd snd-hda-intel soundcore !bluetooth !uhci_hcd)

USELVM="no"

HOSTNAME="archer"

eth0="dhcp"
INTERFACES=(!eth0)

gateway="default gw 192.168.0.1"
ROUTES=(!gateway)

DAEMONS=(syslog-ng hal fam !network !netfs !crond wicd preload cpufreq kdm)

(I usually background wicd, preload and cpufreq)

~/.xinitrc is empty and shouldn't have anything to do with the problem.

I recently removed some hooks in /etc/mkinitcpio.conf, but shouldn't that just speed things up?

HOOKS="base udev autodetect sata filesystems"

uname -a

Linux archer 2.6.28-ARCH #1 SMP PREEMPT Sun Feb 22 11:03:50 UTC 2009 i686 Intel(R) Atom(TM) CPU N270 @ 1.60GHz GenuineIntel GNU/Linux

bootchart
bootchart.png?w=100

Last edited by Mogger (2009-03-11 13:00:48)

Offline

#2 2009-03-10 21:13:22

Lone_Wolf
Forum Moderator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 12,027

Re: [SOLVED] Slow boot after upgrade

Your bootchart shows udevd active from 5 seconds until 25 seconds .

A recent change in udev module loading made archlinux boot process a lot faster.
Unfortunately when you blacklist modules it slows down the udev part considerably.

On my system : udev time with pcspkr blacklisted : 20 seconds !
udev time without any blacklisting : 2 seconds !

Do you really need to blacklist those 3 modules ?

Last edited by Lone_Wolf (2009-03-10 21:14:59)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

#3 2009-03-11 12:33:01

Mogger
Member
From: Sweden
Registered: 2008-12-07
Posts: 153
Website

Re: [SOLVED] Slow boot after upgrade

Thanks for the suggestion Lone_Wolf - I didn't know blacklisted modules would make make such a significant difference in terms of boot time.

I removed all blacklists and gained 3 s according to bootchart. However, this is nothing compared to my "blank screen before Xorg starts up" problem, with still persist - this takes about 20 seconds!

Any other suggestions? My bootchart looks pretty much the same (with udevd active from 4 s to 22 s) even after I removed the !s in my MODULES array.

Offline

#4 2009-03-11 12:58:34

Mogger
Member
From: Sweden
Registered: 2008-12-07
Posts: 153
Website

Re: [SOLVED] Slow boot after upgrade

OK, seems like I found the culprit: preload.

It seems like I shouldn't manually load MODULES at all, if udev can take care of it. I tried to boot with preload bang:ed and an empty MODULES array, with the result: a boot time of 20 s (according to bootchart) and without the long delay before X is started. Hooray!

Now I need to examine which modules I have to add manually and if I can load preload without slowing down the boot up that much.
...Wait, wasn't I supposed to study today?

-
Edit: So, I decided that preload wasn't worth the extra boot time (~ 20 s). I also backgrounded some modules and changed the MODULES array.

New bootchart
bootchart1.png?w=100

/etc/rc.conf

LOCALE="en_US.utf8"
HARDWARECLOCK="UTC"
USEDIRECTISA="no"
TIMEZONE="Europe/Stockholm"
KEYMAP="se-lat6"
CONSOLEFONT=
CONSOLEMAP=
USECOLOR="yes"

MOD_AUTOLOAD="yes"
MODULES=(acpi_cpufreq cpufreq_ondemand cpufreq_powersave snd_pcm_oss)

USELVM="no"

HOSTNAME="archer"

eth0="dhcp"
INTERFACES=(!eth0)

gateway="default gw 192.168.0.1"
ROUTES=(!gateway)

DAEMONS=(syslog-ng @hal @fam @crond @wicd @cpufreq)

(Now using /etc/inittab to load KDM).

Last edited by Mogger (2009-03-11 14:50:19)

Offline

Board footer

Powered by FluxBB