Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在编写一个工具,我需要收集一些关于运行 Linux 系统的信息,而不是那些可以从sysinfo./proc/用于执行此操作的 API,或者我应该只编写为我执行此操作并将结果传递给我的 C 程序的函数或脚本?
sysinfo
/proc/
proc文件系统就是API:你读取伪文件来获取数据。这可以用任何编程语言完成,包括 C。
proc