Windows 性能计数器移植到 Linux、HP-UX 和 AIX

发布于 2024-07-05 15:21:20 字数 285 浏览 10 评论 0原文

我们实现了仅在 Windows 上可用的服务器应用程序。 现在我们也想将其移植到 Linux、HP-UX 和 AIX。 该应用程序通过 Windows 性能监视器中的性能计数器提供内部统计信息。

更准确地说:应用程序是一个数据库,我们希望向管理员提供连接用户数量或执行请求数量等信息。 所以这些是“新”信息,是我们的应用程序专有的。 但我们希望让它们在操作系统提供 CPU 等信息的同一环境中可用。目标是使管理员能够轻松读取它们。

Linux、HP-UX 和 AIX 下合适且常用的性能监视器是什么?

We implemented a server application available on Windows only. Now we like to port it to Linux, HP-UX and AIX, too. This application provides internal statistics through performance counters into the Windows Performance Monitor.

To be more precise: The application is a data base, and we like to provide information like number of connected users or number of requests executed to the administrator. So these are "new" information, proprietary to our application. But we like to make them available in the same environment where the operating system delivers information like the CPU, etc. The goal is to make them easily readable for the administrator.

What is the appropriate and commonly used performance monitor under Linux, HP-UX and AIX?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

明明#如月 2024-07-12 15:21:20

我想说:这取决于您想要监控的性能。 使用的CPU时间? 免费内存? 磁盘IO? 你的冰箱里有多少啤酒……

但不管怎样,你都可以查看 /proc 下面的任何文件。 我不确定 HP 的情况,但至少 Linux 和 AIX 应该有该树(如果它没有在内核编译时停用)。

I would say: that depends on which performance you want to monitor. Used CPU time? Free RAM? Disk IO? Number of beers in your freezer...

But regardless of this you can look at any files below /proc. I'm not sure for HP, but at least Linux and AIX should have that tree (if it's not deactivated at kernel compile time).

绝影如岚 2024-07-12 15:21:20

管理是大多数操作系统的不同之处。 因此,所有操作系统之间通用的工具并不多。

此外,Unix 工具遵循单进程单一责任习惯用法,其中一个工具获取 CPU 信息,另一个工具获取内存等。

我在 Unix 世界中见过的唯一可以在一个地方获取所有这些信息的工具是 top。 几乎所有系统管理员都熟悉这个工具,并且适用于您感兴趣的所有操作系统。它还具有开源的额外优势。 您可以简单地扩展此工具来公开您感兴趣的计数器并将其与您的应用程序一起发送。

另一种方法可能是通过 SNMP 公开您的计数器,并将其留给某些第三方 SNMP 工具(例如 HP open view),该工具可以收集并呈现一致的视图以及其他管理信息。 这可能是一个更具进取性的解决方案,可能会吸引营销人员。

我还想说,编写一个独立的控制台工具是一个好主意,管理员可以从他们自定义的自制脚本中使用该工具(有许多超级人类管理员/超额报酬的员工可以做到这一点)。

我认为,所有这些都将是满足您需求的健康解决方案。

Management is where most OSes depart from one another. For this reason there are not many tools that are common between all the OSes.

Additionally, Unix tools follow the single process single responsibility idiom where one tool gets cpu info, another gets memory etc.

The only tool i have seen in the Unix world that gets all this info in one place is top. Almost all sys admins are familiar with this tool and works on all the flavors of OSes you are interested in. It also has the additional advantage of being open source. You could simply extend this tool to expose the counters you are interested in and ship it along with your application.

Another way to do this might be to expose your counters through SNMP and leave it to some third party SNMP tool like HP open view that can collect and present a consistent view along with other management info. This might be a more enterprisy solution, which might appeal to the marketing folks.

I would also say its a good idea to write a standalone console tool that admins can use from their custom home grown scripts (there are many firsm out there with super human admins / over paid it staff that does this).

All together would be a healthy solution for your requirement i think.

善良天后 2024-07-12 15:21:20

用于此类数据的最标准的 unix 工具是 *stat(iostat、vmstat、netstat)工具和 sar。 在 Linux 上,您可以在 /proc 中找到所有这些信息,但大多数 Unix 上没有 /proc 很好地填充您要查找的内容。 上述工具非常标准化,可用于收集您需要的数据。

The most standard unix tools for such data are the *stat (iostat, vmstat, netstat) tools and sar. On Linux you'll find all this information in /proc, but most Unixes don't have /proc nicely filled with what you are looking for. The mentioned tools are quite standardized and can be used to gather the data you need.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文