Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I stumbled across this command about a week ago on my DFM 4.0 Linux server:
/usr/bin/dfmapi
I was investigating options for running API commands against my DFM server and thought this command might be a command line method of doing this. For example, let's say I wanted to pause performance advisor data collection via this API call:
perf-disable-data-collection
I found that if I run the dfmapi command with the API call as the first arguement, it results in a successful output:
# /usr/bin/dfmapi perf-disable-object-update
Testing: perf-disable-object-update() Success
{
}
This dfmapi command appears to be totally undocumented as I can't find any reference to it on the NOW site, this community, the DFM guides or google.
Can someone confirm that I'm using it correctly? Thanks.
-Dave
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dave -
APIs are documented in the SDK, which can be downloaded from the communities. Here is an example:
perf-disable-object-update (supported) | [top] |
Disables any modification to DFM performance advisor views, counter groups and object instances.
Errno Description EINTERNALERROR EAPIERROR EACCESSDENIED EDATABASEERROR
See: http://communities.netapp.com/docs/DOC-1152 for more details.
- Rick -
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You're using it correctly. It takes the command line arguments, formats them into an API request and sends the request to the server. Run "dfmapi -?" and it's got a pretty good description of how to use it.
It was written to make scripting using APIs easier. Among other things, you can send it raw XML on stdin and it will spit out the raw XML response on stdout. Our Rapid Responses Engineering team wanted to be able to do things like this:
echo '<dfm-version/>' | ssh my-dfm-station dfmapi | parse_dfm_version.pl
They wanted to run this from some other system and use ssh certificates to secure the connection. Other API invocation tools (like the SDK) require you to put a user name and password in the script itself.
As Rick pointed out, the actual APIs are documented in the SDK documentation.
-- Pete
