Tux

...making Linux just a little more fun!

Talkback:147/franci.html

[ In reference to "Booting Linux in Less Than 40 Seconds" in LG#147 ]

MNZ [mnzaki at gmail.com]


Sun, 3 Feb 2008 20:24:31 +0200

Hi TAG, I really enjoyed this article, just what I need! But there's only one problem, the DMA on the hard-disk. I've always used a very similar approach to the one mentioned in the article to set DMA on on my disks, the problem is INIT doesn't actually start when waking up from hibernation and so DMA is not set which makes reading the image (and booting, therefore) a very painfully long process. Any ideas on other ways to set DMA that don't involve INIT?

-- 
//MNZ\\


Top    Back


Ben Okopnik [ben at linuxgazette.net]


Sun, 3 Feb 2008 21:23:55 -0500

On Sun, Feb 03, 2008 at 08:24:31PM +0200, MNZ wrote:

> Hi TAG,
> I really enjoyed this article, just what I need! But there's only one
> problem, the DMA on the hard-disk. I've always used a very
> similar approach to the one mentioned in the article to set DMA
> on on my disks, the problem is INIT doesn't actually start when
> waking up from hibernation and so DMA is not set which makes
> reading the image (and booting, therefore) a very painfully long
> process. Any ideas on other ways to set DMA that don't involve
> INIT?

It's been quite a while since I've fiddled with hibernation, etc., but if I recall correctly, there's some kind of a script directory - /etc/apm/resume.d, maybe? - that allows you to put in scripts to be run at wakeup time. That should work.

-- 
* Ben Okopnik * Editor-in-Chief, Linux Gazette * http://LinuxGazette.NET *


Top    Back


MNZ [mnzaki at gmail.com]


Mon, 4 Feb 2008 09:03:02 +0200

On Feb 4, 2008 4:23 AM, Ben Okopnik <[email protected]> wrote:

> It's been quite a while since I've fiddled with hibernation, etc., but
> if I recall correctly, there's some kind of a script directory -
> /etc/apm/resume.d, maybe? - that allows you to put in scripts to be run
> at wakeup time. That should work.

I've gone through a bit of documentation and found an option to be passed in the script to run commands on resume, but that doesn't help as these are run AFTER wake up which means no DMA while loading the image from disk. The solution is on the kernel level as it has to be done before anything else is loaded. So I fiddled around the kernel config and found an option under "Device Drivers --> DMA Engine support" to automatically set DMA. Then you could pass "hda=autotune" as a kernel parameter to get the disks tuned to maximum performance.

Without this I was getting 3-4 minute boots which is worse than the normal (ie, no hibernation) now I get 30 second boots :-)

-- 
//MNZ\\


Top    Back


Kapil Hari Paranjape [kapil at imsc.res.in]


Mon, 4 Feb 2008 09:41:52 +0530

Hello,

This article suggests re-compiling the kernel in order to enable a feature that is "on-by-default" in most distribution kernels!

The stock kernel version of suspend is sometimes called "suspend1" whereas the one the author talks about is suspend2. There may be hardware out there for which the latter works better than the former but of late I have seen fewer and fewer systems of this type.

Now there is nothing wrong with compiling the kernel for fun, learning and profit. I just hope people aren't doing it because they think it is necessary :)

Regards,

Kapil. --


Top    Back


Amit Kumar Saha [amitsaha.in at gmail.com]


Mon, 4 Feb 2008 12:30:40 +0530

On 2/4/08, Kapil Hari Paranjape <[email protected]> wrote:

> Hello,
>
> This article suggests re-compiling the kernel in order to enable
> a feature that is "on-by-default" in most distribution kernels!

+1

I use it happily on Ubuntu 7.04.

Regards, Amit

-- 
Amit Kumar Saha
*NetBeans Community
Docs Coordinator*
Writer, Programmer, Researcher
http://amitsaha.in.googlepages.com
http://amitksaha.blogspot.com


Top    Back


MNZ [mnzaki at gmail.com]


Mon, 4 Feb 2008 10:00:38 +0200

On Feb 4, 2008 6:11 AM, Kapil Hari Paranjape <[email protected]> wrote:

> Hello,
>
> This article suggests re-compiling the kernel in order to enable
> a feature that is "on-by-default" in most distribution kernels!
>
> The stock kernel version of suspend is sometimes called "suspend1"
> whereas the one the author talks about is suspend2. There may be
> hardware out there for which the latter works better than the former
> but of late I have seen fewer and fewer systems of this type.

There's a comparison between the stock kernel's version and suspend2 at http://www.tuxonice.net/features

There seem to be a few extra features, but that's all. I didn't actually know that there was a "suspend1" compiled in by default. What's done is done ;-)

> Now there is nothing wrong with compiling the kernel for fun, learning
> and profit. I just hope people aren't doing it because they think it
> is necessary :)

Exactly! What better thing to do than compile a kernel early in the morning right before breakfast? It works up my appetite.

-- 
//MNZ\\


Top    Back