LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-17-2009, 01:31 AM   #1
vipi12
LQ Newbie
 
Registered: Sep 2009
Posts: 4

Rep: Reputation: 0
rescheduling interrupts in ubuntu 9.04


Hi all
I had a question -
How do i change kernel parameters to boot with noapic, or acpi turned off?
i couldnt find a explanatory tutorial on this
it would be helpful if smeone could either point out the correct way of doing this or point to a suitable link

thnx
 
Old 12-17-2009, 03:59 AM   #2
JohnGraham
Member
 
Registered: Oct 2009
Posts: 467

Rep: Reputation: 139Reputation: 139
When the Linux kernel boots, it is passed command-line arguments, just like any other program, by the bootloader, which for most distros is GRUB.

The configuration file for grub, sometimes /boot/grub/grub.conf and sometimes /boot/grub/menu.lst, can be used to specify the arguments to pass to the kernel at boot-time. For example, the entry for the default kernel on my system is:

Code:
title           Ubuntu 9.10, kernel 2.6.32-rc3 Default
uuid            58ebee0e-a1df-4ba0-9d6b-2989fd3677ad
kernel          /boot/vmlinuz root=UUID=58ebee0e-a1df-4ba0-9d6b-2989fd3677ad ro quiet vga=0x318  crashkernel=384M-2G:64M,2G-:128M
initrd          /boot/initrd.img
quiet
The line that starts with "kernel" specifies the location of the kernel to load (i.e. /boot/vmlinuz) and then the arguments to pass (i.e. root=UUID=58..., ro, quiet, vga=0x318 and crashkernel=384M...).

What you want to do is pass the argument "noapic" to the kernel by simply adding it to the appropriate line in the file.

(Edit: the next sentence is completely wrong - see post #4)
Note: make sure you pass fewer than 32 arguments on the command-line, or the kernel will panic.

You can also change the command-line at boot-time by pressing 'e' at the appropriate entry, and you'll then get the option to edit them to your heart's content.

It's always good to have a known-safe entry in your grub config you can use! Your best bet is probably to copy your first entry and modify that instead, so you can always choose the first one if things go awry!

Last edited by JohnGraham; 12-17-2009 at 06:40 AM.
 
Old 12-17-2009, 05:02 AM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,126

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
Quote:
Originally Posted by JohnGraham View Post
Note: make sure you pass fewer than 32 arguments on the command-line, or the kernel will panic.
Do you have a reference for this ?. I am aware of a (char) length restriction which appears to be 2048 for x86 with 2.6, but I hadn't heard of an argument (count) limitation.
 
Old 12-17-2009, 06:38 AM   #4
JohnGraham
Member
 
Registered: Oct 2009
Posts: 467

Rep: Reputation: 139Reputation: 139
Quote:
Originally Posted by syg00 View Post
Quote:
Note: make sure you pass fewer than 32 arguments on the command-line, or the kernel will panic.
Do you have a reference for this ?. I am aware of a (char) length restriction which appears to be 2048 for x86 with 2.6, but I hadn't heard of an argument (count) limitation.
As it happens, no. And now I'm glad you prompted me to look into this, as it looks like I'm just plain wrong. This is from Documentation/kernel-parameters.txt:

Code:
The number of kernel parameters is not limited, but the length of the
complete command line (parameters including spaces etc.) is limited to
a fixed number of characters. This limit depends on the architecture
and is between 256 and 4096 characters. It is defined in the file
./include/asm/setup.h as COMMAND_LINE_SIZE.
I *thought* I'd read it in some boot prompt how-to guide - not sure whether the article got it wrong or if I was just remembering something else entirely!

Sorry for any confusion!
 
Old 12-18-2009, 12:21 AM   #5
vipi12
LQ Newbie
 
Registered: Sep 2009
Posts: 4

Original Poster
Rep: Reputation: 0
okk..the reason i was trying(rather thinking) to do this was that I have a approx 500 wake ups from idle in intervals of 5 secs... Nd my power consumption is 20-30 watts nd a miserable battery life of 1 hr on a brand new laptop able to run for 4 hrs wen running on windows..
processor is 64 bit intel centrino but i am using 32 bit ubuntu 9.04 with it..
an excerpt of the powertop output is


Wakeups-from-idle per second : 403.2 interval: 2.0s
Power usage (ACPI estimate): 25.9W (1.4 hours)

Top causes for wakeups:
43.0% (214.5) <kernel IPI> : Rescheduling interrupts
25.2% (125.5) firefox : futex_wait (hrtimer_wakeup)
16.3% ( 81.5) <interrupt> : extra timer interrupt
4.1% ( 20.5) gnome-panel : schedule_hrtimeout_range (hrtimer_wakeup)
3.4% ( 17.0) firefox : schedule_hrtimeout_range (hrtimer_wakeup)
2.8% ( 14.0) <interrupt> : iwlagn
1.6% ( 8.0) <kernel core> : usb_hcd_poll_rh_status (rh_timer_func)
0.8% ( 4.0) Xorg : hrtimer_start (it_real_fn)
0.5% ( 2.5) gnome-terminal : schedule_hrtimeout_range (hrtimer_wakeup)
0.4% ( 2.0) multiload-apple : schedule_hrtimeout_range (hrtimer_wakeup)
0.3% ( 1.5) <kernel core> : neigh_table_init_no_netlink (neigh_periodic_timer)
0.2% ( 1.0) nautilus : do_nanosleep (hrtimer_wakeup)
0.2% ( 1.0) nautilus : schedule_hrtimeout_range (hrtimer_wakeup)
0.2% ( 1.0) cpufreq-applet : schedule_hrtimeout_range (hrtimer_wakeup)
0.1% ( 0.5) <interrupt> : PS/2 keyboard/mouse/touchpad
0.1% ( 0.5) <interrupt> : eth0
0.1% ( 0.5) gnome-terminal : do_nanosleep (hrtimer_wakeup)
0.1% ( 0.5) Xorg : schedule_hrtimeout_range (hrtimer_wakeup)
0.1% ( 0.5) gnome-power-man : schedule_hrtimeout_range (hrtimer_wakeup)
0.1% ( 0.5) pidgin : schedule_hrtimeout_range (hrtimer_wakeup)
0.1% ( 0.5) NetworkManager : e1000_intr_msi (e1000_watchdog)
0.1% ( 0.5) iwlagn : ieee80211_authenticate (ieee80211_sta_timer)
0.1% ( 0.5) mono : do_nanosleep (hrtimer_wakeup)



Can you suggest a way to set it right
thanks

Last edited by vipi12; 12-18-2009 at 12:26 AM.
 
Old 12-18-2009, 03:49 AM   #6
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,126

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
Do as JohnGraham suggests if you want to try noapic - ignore our side discussion.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Interrupts rhcohen Programming 5 12-21-2017 11:25 AM
Can anyone please explain about "Function call interrupts" entry in /proc/interrupts? cyclops.xmen Linux - Software 2 12-09-2009 12:13 PM
Need to stop kernel rescheduling richardapthorp Linux - Kernel 5 09-10-2009 11:35 AM
"Rescheduling interrupts" in powertop dmarti Linux - Laptop and Netbook 2 01-12-2009 07:14 PM
about interrupts eshwar_ind Programming 1 02-25-2004 12:38 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:16 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration