How to change SMP affinity of an IRQ on Ubuntu domU inside Xen XCP?
- by Alexander Gladysh
I'd like to change IRQ SMP affinity for reasons, outlined in this question: CPU0 is swamped with eth1 interrupts
But I can't — I see Input/output error when I try to write to /proc/irq/*/smp_affinity.
Please point me to the HOWTO on the matter. (A formal reference on /proc/irq/*/ would be cool as well.)
Gory details:
Note that this is a VM inside an Ubuntu-based Xen XCP host.
$ uname -a
Linux MYHOST 2.6.38-15-virtual #59-Ubuntu SMP Fri Apr 27 16:40:18 UTC 2012 i686 i686 i386 GNU/Linux
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 11.04
Release: 11.04
Codename: natty
$ sudo cat /proc/irq/*/smp_affinity
01
01
01
01
01
80
80
80
80
80
80
40
40
40
40
40
40
20
20
20
20
20
20
10
10
10
10
10
10
08
08
08
08
08
08
04
04
04
04
04
04
02
02
02
02
02
02
01
01
01
01
01
01
Update. The error details:
$ N=$(grep -c processor /proc/cpuinfo)
$ echo $N
8
$ printf %x $((2**N-1))
ff
$ printf %x $((2**N-1)) | sudo tee /proc/irq/*/smp_affinity
fftee: /proc/irq/288/smp_affinity: Input/output error
tee: /proc/irq/289/smp_affinity: Input/output error
tee: /proc/irq/290/smp_affinity: Input/output error
tee: /proc/irq/291/smp_affinity: Input/output error
tee: /proc/irq/292/smp_affinity: Input/output error
tee: /proc/irq/293/smp_affinity: Input/output error
tee: /proc/irq/294/smp_affinity: Input/output error
tee: /proc/irq/295/smp_affinity: Input/output error
tee: /proc/irq/296/smp_affinity: Input/output error
tee: /proc/irq/297/smp_affinity: Input/output error
tee: /proc/irq/298/smp_affinity: Input/output error
tee: /proc/irq/299/smp_affinity: Input/output error
tee: /proc/irq/300/smp_affinity: Input/output error
tee: /proc/irq/301/smp_affinity: Input/output error
tee: /proc/irq/302/smp_affinity: Input/output error
tee: /proc/irq/303/smp_affinity: Input/output error
tee: /proc/irq/304/smp_affinity: Input/output error
tee: /proc/irq/305/smp_affinity: Input/output error
tee: /proc/irq/306/smp_affinity: Input/output error
tee: /proc/irq/307/smp_affinity: Input/output error
tee: /proc/irq/308/smp_affinity: Input/output error
tee: /proc/irq/309/smp_affinity: Input/output error
tee: /proc/irq/310/smp_affinity: Input/output error
tee: /proc/irq/311/smp_affinity: Input/output error
tee: /proc/irq/312/smp_affinity: Input/output error
tee: /proc/irq/313/smp_affinity: Input/output error
tee: /proc/irq/314/smp_affinity: Input/output error
tee: /proc/irq/315/smp_affinity: Input/output error
tee: /proc/irq/316/smp_affinity: Input/output error
tee: /proc/irq/317/smp_affinity: Input/output error
tee: /proc/irq/318/smp_affinity: Input/output error
tee: /proc/irq/319/smp_affinity: Input/output error
tee: /proc/irq/320/smp_affinity: Input/output error
tee: /proc/irq/321/smp_affinity: Input/output error
tee: /proc/irq/322/smp_affinity: Input/output error
tee: /proc/irq/323/smp_affinity: Input/output error
tee: /proc/irq/324/smp_affinity: Input/output error
tee: /proc/irq/325/smp_affinity: Input/output error
tee: /proc/irq/326/smp_affinity: Input/output error
tee: /proc/irq/327/smp_affinity: Input/output error
tee: /proc/irq/328/smp_affinity: Input/output error
tee: /proc/irq/329/smp_affinity: Input/output error
tee: /proc/irq/330/smp_affinity: Input/output error
tee: /proc/irq/331/smp_affinity: Input/output error
tee: /proc/irq/332/smp_affinity: Input/output error
tee: /proc/irq/333/smp_affinity: Input/output error
tee: /proc/irq/334/smp_affinity: Input/output error
tee: /proc/irq/335/smp_affinity: Input/output error
Update. irqbalance is running:
$ sudo service irqbalance status
irqbalance start/running, process 560