You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
895 B
28 lines
895 B
7 years ago
|
From 1d7890db7ed4ef236103812a6b9fac0d86691154 Mon Sep 17 00:00:00 2001
|
||
|
From: Petr Holasek <pholasek@redhat.com>
|
||
|
Date: Wed, 10 Dec 2014 18:00:02 +0100
|
||
|
Subject: [PATCH] Warning when irqbalance hasn't root privileges
|
||
|
|
||
|
Signed-off-by: Petr Holasek <pholasek@redhat.com>
|
||
|
---
|
||
|
irqbalance.c | 3 +++
|
||
|
1 file changed, 3 insertions(+)
|
||
|
|
||
|
diff --git a/irqbalance.c b/irqbalance.c
|
||
|
index f22ecfb..bb8c3da 100644
|
||
|
--- a/irqbalance.c
|
||
|
+++ b/irqbalance.c
|
||
|
@@ -288,6 +288,9 @@ int main(int argc, char** argv)
|
||
|
} else
|
||
|
log(TO_CONSOLE, LOG_INFO, "This machine seems not NUMA capable.\n");
|
||
|
|
||
|
+ if (geteuid() != 0)
|
||
|
+ log(TO_ALL, LOG_WARNING, "Irqbalance hasn't been executed under root privileges, thus it won't in fact balance interrupts.\n");
|
||
|
+
|
||
|
if (banscript) {
|
||
|
char *note = "Please note that --banscript is deprecated, please use --policyscript instead";
|
||
|
log(TO_ALL, LOG_WARNING, "%s\n", note);
|
||
|
--
|
||
|
2.1.0
|
||
|
|