Is there something like WMI for Linux?

2019-01-22 08:49发布

I like the whole WMI concept, and I could really make use of it under Linux (in some scripts). Is there something like that for Linux systems?

标签: linux wmi
6条回答
小情绪 Triste *
2楼-- · 2019-01-22 09:07

Maybe it could be helpful for you. Have a look at this post: http://www.aldeid.com/wiki/Wmic-linux

查看更多
一夜七次
3楼-- · 2019-01-22 09:19

OpenLMI seems to be designed for exactly that purpose... It provides instrumentation to monitor and control Linux-based servers.

There is also WBEM agents for GNU/Linux (like OpenPegasus).

It actually seems that OpenLMI uses Pegasus as the external interface.

查看更多
不美不萌又怎样
4楼-- · 2019-01-22 09:24

I beg to differ, but YES, there is. Get FWTS and run

fwts wmi -

And you will see how is it implemented and what is possible to read/modify.

More here: https://wiki.ubuntu.com/Kernel/Reference/WMI

查看更多
Juvenile、少年°
5楼-- · 2019-01-22 09:30

Windows Management Instrumentation (WMI) is Microsoft's implementation of the WBEM (Web Based Enterprise Management) standard from the Distributed Management Task Force. These standards are available and used in several flavors of *nix systems. Just as an example, here is a SourceForge project that enables WBEM on Linux systems. There is a standard called CIM (Common Information Model) which is described by the DTMF as follows:

CIM provides a common definition of management information for systems, networks, applications and services, and allows for vendor extensions. CIM's common definitions enable vendors to exchange semantically rich management information between systems throughout the network.

查看更多
我想做一个坏孩纸
6楼-- · 2019-01-22 09:30

Take a look at the /proc interfaces. You can get a lot of system information there. There are also many excellent utilities for gathering system information. The sysstat packages are always one of the first things I install these days.

Edit: You can always query SNMP as well. There is a lot of information exposed by default.

查看更多
▲ chillily
7楼-- · 2019-01-22 09:31

Not really. Are you using WMI to get system parameters, or to query processes, or to change configuration, or monitor for system events, or what?

The kernel exposes a lot of information and tunable knobs via the /proc and /sys filesystems. No query language, just a organized hierarchy of directories and files. Some of these files are read-only, read-write, or write-only; some of them are pollable.

Some services may have custom clients to query and update configuration on the fly -- chrony's chronyc comes to mind, but even the very most basic init has initctl. Newer services like HAL can be introspected and manipulated over D-Bus.

查看更多
登录 后发表回答