AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / server / 问题 / 76146
Accepted
Stéphane
Stéphane
Asked: 2009-10-20 14:19:20 +0800 CST2009-10-20 14:19:20 +0800 CST 2009-10-20 14:19:20 +0800 CST

我如何判断 irqbalance 是否在做任何事情?

  • 772

我查看了提到在 SMP 系统上安装 irqbalance ( http://www.irqbalance.org/ ) 的 linux 服务器调整文档。我现在在四核系统上查看它,虽然“ps axf”可以告诉我它正在运行,但我没有看到任何关于它是否/如何影响系统的统计数据或信息。

有谁知道在哪里看?

linux
  • 3 3 个回答
  • 14311 Views

3 个回答

  • Voted
  1. LapTop006
    2009-10-21T05:57:26+08:002009-10-21T05:57:26+08:00

    根据 evildeed 的回答运行sudo cat /proc/irq/*/smp_affinity应该告诉你。如果您得到更多答案,那么它应该可以工作。

    由于输出是位掩码的整数变换,因此对于非程序员类型可能很难理解。

    例如:

    • 绑定到 cpu0 - 1
    • 绑定到 cpu1 - 2
    • 绑定到 cpu0 和/或 cpu1 - 3
    • 绑定到 cpu3,4,7 - 282
    • 5
  2. matt
    2009-10-21T08:08:31+08:002009-10-21T08:08:31+08:00

    您可以通过执行 cat /proc/interrupts 并查看您尝试隔离的进程是否在应该运行您的高优先级进程的处理器上创建中断来大致了解它是否在做任何事情。

    • 5
  3. Best Answer
    evildead
    2009-10-20T15:05:48+08:002009-10-20T15:05:48+08:00

    在源代码中,他们引用了 /proc 几次。也许你在那里找到你的答案。root@[/usr/local/src/irqbalance-0.55]egrep -ri "proc|sys" *

    activate.c:                     sprintf(buf, "/proc/irq/%i/smp_affinity", irq->number);
    cpumask.h: * set of CPU's in a system, one bit position per CPU number.
    cpumask.h: * The following particular system cpumasks and operations manage
    cpumask.h: *  be plugged in at anytime during the life of that system boot.
    cpumask.h:int highest_possible_processor_id(void);
    cputree.c: * This file contains the code to construct and manipulate a hierarchy of processors,
    cputree.c: * cache domains and processor cores.
    cputree.c:#include <sys/types.h>
    cputree.c:      dir = opendir("/sys/devices/system/cpu");
    cputree.c:                      sprintf(new_path, "/sys/devices/system/cpu/%s", entry->d_name);
    irqbalance.c:#include <sys/time.h>
    irqbalance.c:   /* On single core UP systems irqbalance obviously has no work to do */
    irqbalance.c:   /* On dual core/hyperthreading shared cache systems just do a one shot setup */
    irqbalance.c:   parse_proc_interrupts();
    irqbalance.c:   parse_proc_interrupts();
    irqbalance.c:           parse_proc_interrupts();
    irqbalance.c:           /* cope with cpu hotplug -- detected during /proc/interrupts parsing */
    irqbalance.h:extern void parse_proc_interrupts(void);
    irqlist.c:#include <sys/types.h>
    irqlist.c: * This function classifies and reads various things from /proc about a specific irq
    irqlist.c:      sprintf(buf, "/proc/irq/%i", number);
    irqlist.c:                      sprintf(buf, "/proc/irq/%i/smp_affinity", number);
    Makefile:LIBS=bitmap.o irqbalance.o cputree.o  procinterrupts.o irqlist.o placement.o activate.o network.o powermode.o numa.o classify.o
    network.c:#include <sys/ioctl.h>
    network.c:        sprintf(buffer,"/sys/bus/pci/devices/%s/irq", driver.bus_info);
    network.c:      file = fopen("/proc/net/dev", "r");
    numa.c:#include <sys/types.h>
    numa.c: dir = opendir("/sys/bus/pci/devices");
    numa.c:         sprintf(line,"/sys/bus/pci/devices/%s/irq", entry->d_name);
    numa.c:         sprintf(line,"/sys/bus/pci/devices/%s/class", entry->d_name);
    numa.c:         sprintf(line,"/sys/bus/pci/devices/%s/local_cpus", entry->d_name);
    numa.c: * Ethernet gets the type via /proc/net/dev; in addition down'd interfaces
    powermode.c:    file = fopen("/proc/stat", "r");
    powermode.c:    dummy = strtoull(c, &c, 10); /* system */
    procinterrupts.c:void parse_proc_interrupts(void)
    procinterrupts.c:       file = fopen("/proc/interrupts", "r");
    
    • 3

相关问题

  • Linux 主机到主机迁移

  • 如何在 Linux 机器上找到有关硬件的详细信息?

  • 如何在 Linux 下监控每个进程的网络 I/O 使用情况?

  • 在 RHEL4 上修改 CUPS 中的现有打印机设置

  • 为本地网络中的名称解析添加自定义 dns 条目

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    从 IP 地址解析主机名

    • 8 个回答
  • Marko Smith

    如何按大小对 du -h 输出进行排序

    • 30 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    Windows 中执行反向 DNS 查找的命令行实用程序是什么?

    • 14 个回答
  • Marko Smith

    如何检查 Windows 机器上的端口是否被阻塞?

    • 4 个回答
  • Marko Smith

    我应该打开哪个端口以允许远程桌面?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    MikeN 在 Nginx 中,如何在维护子域的同时将所有 http 请求重写为 https? 2009-09-22 06:04:43 +0800 CST
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    0x89 bash中的双方括号和单方括号有什么区别? 2009-08-10 13:11:51 +0800 CST
  • Martin Hope
    kch 如何更改我的私钥密码? 2009-08-06 21:37:57 +0800 CST
  • Martin Hope
    Kyle Brandt IPv4 子网如何工作? 2009-08-05 06:05:31 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve