Compiling very slow
Just installed slackware 14, switched to the generic-3.2.29 kernel and recompiled the kernel using generic-config per Alien Bob's instructions. Compiling the kernel TOOK 4 1/2 HRS. Tried searching here and google not much help, mostly very outdated info. any help will be appreciated.
|
Hmmm ...
I think it is kinda weird ... i think that one of the most heaviest thing to compile is the kernel. I used to compile it in 6 hours (of course it was an old bones P3 with 1 GB in ram (it's still working)). So i think it is normal, unless you have a great machine and a great processor with too much RAM. But i could be wrong. |
Since your CPU has two cores, you may get some speed gains by passing "-j3" to make, as in
Code:
make -j3 bzImage modules |
...
Thanks guys. I'll def. try passing -j3. for this compile.
|
I recompiled 3.2.29 and it took me about 16 minutes on a twin core 2Ghz turion cpu w/3G ram.
I have had the slow kernel compile problem with slamd64. It transpired the original (2.6.33?) kernel had every 32 bit bugfix, and no 64 bit acceleration compiled in. I emailed Fred Emmot and earnestly suggested forking the kernel and he obliged, which reduced kernel compile time to 15 minutes. You are not compiling every module for every card ever built, are you? Just what's in the box? You have memory, and swap in abundance? No strange bootup messages? |
...
Quote:
System specs in signature. 4GB mem 8GB swap. I don't think so, need to check dmesg though. Screen goes blank for a few seconds when booting up but thats about it other than the system seems a bit slugish |
3.2.30 built on 3.2.29 using Pat's 'generic' config
x86_64 Intel(R) Core(TM)2 Duo CPU E7400 @ 2.80GHz real 33m44.698s user 56m57.314s sys 6m35.024s Make -j2 is enough to keep both cpu's pegged at 100% as I build in /tmp (tmpfs) and there isn't any i/o wait to speak of. You can probably knock off a minute though as my script also runs a makepkg on it, which adds a little time. |
Thanks
Thanks guys, -j3 cut the compile time down to 2hrs. 15min.. Now to figure out which modules I can live w/o. :)
Its been a couple of minutes since I last played with Slack (10.2 I believe). Appreciate the quick responses guys. Take care. |
There are several things you can do to speed up a kernel compile but not much realistically.
"make -jX" flags are one of the most common but you can also try increasing the stack using "ulimit -s XXXXX" with a value like 32768 or another multiple thereof. This won't cut it down dramatically in time though. In fact it might only shave off a few seconds. Really, your CPU's overall power and cores will determine how well this works. Also, when using the make -jX flag only set the #X amount equal to the number of cores you have. If you go over even by one you'll end up with make using the swap more and more. If you want to know how long it will take visit the LFS project's page and see their Standard Build Unit (SBU) calculation. 1 SBU is equal to about 15 minutes on a Dual-Core 2.5 GHz AMD Athlon X2 CPU with 4GB RAM with the make -j2 flag enabled. The kernel takes at LEAST up to 5 times this amount to completely build. Calculate that out against a slower CPU, even with more cores and more RAM, and it will vary. |
Quote:
I will look into the LFS SBU. |
On paper, you and I have fairly similar boxes (AMD cpu, chipset, graphics). My time was for the command
time make which does the bulk of the work. If you're up over the hour, something's wrong. I have a 667Mhz bus (advertising spec) and a 7200 rpm drive (HP Compaq 6715S). There's nothing major wrong with Pat's generic kernel, if you have an initrd. One possibility that springs to mind is that you don't have the chipset driver in there, and you're not getting full speed out of the disk. Try your speed with this command sudo hdparm -tT /dev/sda Mine does 755MB/s cached and 61.57MB/s direct. If yours is a lot off that, that could be the issue. |
Think about this, it takes me 1 and 1/2 hrs to slackbuild (I suppose it did compiling...) the browser chromium, so taking 4 hrs and more for a core system seems ok to me.
Btw, just curious, is your machine running faster after you built your own kernel? |
Quote:
|
I also use -j with the number of cores I have mostly to be able to do other things while its compiling, like browsing the web, without major slowdown.
|
Quote:
If memory serves correctly, my pentium 3 machines used to to it in like 15 min, maybe a bit more. Admittedly I build custom kernels which are a lot smaller than distro kernels, but 2hrs 15min on a machine with two cores at 1900 MHz still doesn't sound right. |
All times are GMT -5. The time now is 01:09 AM. |