HD Information

get

/v1/admin/system/hd_info

This API gets the Site's HD Information like Active OS Parition, HD Usagage etc.

Request

There are no request parameters for this operation.

Back to Top

Response

200 Response

Result OK

401 Response

Unauthorized - Request lacks valid authentication credentials.

403 Response

This request requires the client credentials to have administrator privileges.

405 Response

Invalid request method
Back to Top

Examples

Example of Accessing the API with cURL

The following example shows how to gets the Site's HD information like active OS parition, HD usage, etc. by submitting a GET request on the REST resource using cURL. If the request requires a timestamp, use the timestamp from the response of the /login API. For more information about cURL, see Use cURL.

curl -X GET \
    -b cookies.txt \
    "https://$IPADDR/v1/admin/system/hd_info"

Example of the Response Headers

The following shows an example of the response headers.

HTTP/1.1 200 OK
Date: Wed, 16 Dec 2020 23:00:45 GMT
Server: Apache/2.4.6 () OpenSSL/1.0.2k-fips mod_fcgid/2.3.9 PHP/5.4.40
Vary: Accept-Encoding
X-UA-Compatible: IE=Edge,chrome=1
Transfer-Encoding: chunked
Content-Type: application/json; charset=ISO-8859-1

Example of the Response Body

The following example shows the contents of the response body in JSON format.

{
"status": "success",
"data": [
    [
    {
        "hdInfo": [
        [
            {
            "Active OS partition": "73%"
            },
            {
            "/home/talariuser directory": "17%"
            },
            {
            "WANOp Cache": "0%"
            },
            {
            "ssdLife": 99
            },
            {
            "hdUsageViewDetails": [
                {
                "user_partition_string": "Active OS partition"
                },
                {
                "usage": "31 MB",
                "file_path": "/tmp",
                "acceptable_val": "100 MB",
                "percent": "31.00%"
                },
                {
                "usage": "1 MB",
                "file_path": "/var/lib/net-snmp/snmpd.conf",
                "acceptable_val": "3 MB",
                "percent": "33.33%"
                },
                {
                "usage": "544 MB",
                "file_path": "/var/log",
                "acceptable_val": "600 MB",
                "percent": "90.67%"
                },
                {
                "usage": "11 MB",
                "file_path": "/var/mail",
                "acceptable_val": "12 MB",
                "percent": "91.67%"
                },
                {
                "usage": "0 MB",
                "file_path": "/var/spool/mqueue-client",
                "acceptable_val": "3 MB",
                "percent": "0.00%"
                },
                {
                "usage": "2145 MB",
                "file_path": "System files",
                "acceptable_val": "2.4 GB",
                "percent": "87.28%"
                },
                {
                "home_partition_string": "/home/talariuser directory"
                },
                {
                "usage": "1 MB",
                "percent": "0.83%",
                "home_acceptable_usages": "120 MB",
                "home_file_path": "/home/talariuser/backup/cores"
                },
                {
                "usage": "349 MB",
                "percent": "69.80%",
                "home_acceptable_usages": "500 MB",
                "home_file_path": "/home/talariuser/backup/diagnostics"
                },
                {
                "usage": "1 MB",
                "percent": "50.00%",
                "home_acceptable_usages": "2 MB",
                "home_file_path": "/home/talariuser/log/init.log"
                },
                {
                "usage": "1 MB",
                "percent": "0.17%",
                "home_acceptable_usages": "575 MB",
                "home_file_path": "/home/talariuser/packet.pcap"
                },
                {
                "usage": "1 MB",
                "percent": "0.17%",
                "home_acceptable_usages": "575 MB",
                "home_file_path": "/home/talariuser/pcapture.cap"
                },
                {
                "usage": "1059 MB",
                "percent": "3.04%",
                "home_acceptable_usages": "34 GB",
                "home_file_path": "Change Management"
                },
                {
                "usage": "1002 MB",
                "percent": "15.42%",
                "home_acceptable_usages": "6500 MB",
                "home_file_path": "Oracle software"
                },
                {
                "usage": "581 MB",
                "percent": "",
                "home_acceptable_usages": "",
                "home_file_path": "service_chaining"
                },
                {
                "usage": "539 MB",
                "percent": "44.92%",
                "home_acceptable_usages": "1200 MB",
                "home_file_path": "T2_Events"
                },
                {
                "usage": "8125 MB",
                "percent": "61.04%",
                "home_acceptable_usages": "13 GB",
                "home_file_path": "T2_Stats & T2_Config"
                },
                {
                "WANOp Cache Size": "140GB",
                "Used_disk_Cache": "0GB"
                },
                [
                {
                    "df-l-output": [
                    {
                        "0-df": [
                        {
                            "filesystem": "devtmpfs"
                        },
                        {
                            "1kb": 16388512
                        },
                        {
                            "used": 0
                        },
                        {
                            "available": 16388512
                        },
                        {
                            "pctused": "0%"
                        },
                        {
                            "mountedon": "/dev"
                        }
                        ]
                    },
                    {
                        "1-df": [
                        {
                            "filesystem": "tmpfs"
                        },
                        {
                            "1kb": 16438536
                        },
                        {
                            "used": 0
                        },
                        {
                            "available": 16438536
                        },
                        {
                            "pctused": "0%"
                        },
                        {
                            "mountedon": "/dev/shm"
                        }
                        ]
                    },
                    {
                        "2-df": [
                        {
                            "filesystem": "tmpfs"
                        },
                        {
                            "1kb": 16438536
                        },
                        {
                            "used": 1204
                        },
                        {
                            "available": 16437332
                        },
                        {
                            "pctused": "1%"
                        },
                        {
                            "mountedon": "/run"
                        }
                        ]
                    },
                    {
                        "3-df": [
                        {
                            "filesystem": "tmpfs"
                        },
                        {
                            "1kb": 16438536
                        },
                        {
                            "used": 0
                        },
                        {
                            "available": 16438536
                        },
                        {
                            "pctused": "0%"
                        },
                        {
                            "mountedon": "/sys/fs/cgroup"
                        }
                        ]
                    },
                    {
                        "4-df": [
                        {
                            "filesystem": "/dev/sda3"
                        },
                        {
                            "1kb": 4030144
                        },
                        {
                            "used": 2805988
                        },
                        {
                            "available": 1014444
                        },
                        {
                            "pctused": "74%"
                        },
                        {
                            "mountedon": "/"
                        }
                        ]
                    },
                    {
                        "5-df": [
                        {
                            "filesystem": "/dev/sda1"
                        },
                        {
                            "1kb": 91099
                        },
                        {
                            "used": 1750
                        },
                        {
                            "available": 84434
                        },
                        {
                            "pctused": "3%"
                        },
                        {
                            "mountedon": "/grub"
                        }
                        ]
                    },
                    {
                        "6-df": [
                        {
                            "filesystem": "/dev/sda6"
                        },
                        {
                            "1kb": 222989620
                        },
                        {
                            "used": 11990624
                        },
                        {
                            "available": 199754372
                        },
                        {
                            "pctused": "6%"
                        },
                        {
                            "mountedon": "/home"
                        }
                        ]
                    },
                    {
                        "7-df": [
                        {
                            "filesystem": "tmpfs"
                        },
                        {
                            "1kb": 3287708
                        },
                        {
                            "used": 0
                        },
                        {
                            "available": 3287708
                        },
                        {
                            "pctused": "0%"
                        },
                        {
                            "mountedon": "/run/user/0"
                        }
                        ]
                    },
                    {
                        "8-df": [
                        {
                            "filesystem": "tmpfs"
                        },
                        {
                            "1kb": 3287708
                        },
                        {
                            "used": 0
                        },
                        {
                            "available": 3287708
                        },
                        {
                            "pctused": "0%"
                        },
                        {
                            "mountedon": "/run/user/1000"
                        }
                        ]
                    }
                    ]
                }
                ]
            ]
            }
        ]
        ]
    }
    ]
]
}
Back to Top