{"id":18513117,"url":"https://github.com/vmware/vrops-export","last_synced_at":"2025-08-21T07:32:26.012Z","repository":{"id":23773069,"uuid":"98456568","full_name":"vmware/vrops-export","owner":"vmware","description":"vRealize Operations Export Tool","archived":false,"fork":false,"pushed_at":"2024-10-03T18:43:12.000Z","size":8097,"stargazers_count":37,"open_issues_count":18,"forks_count":16,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-04-08T06:42:03.364Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vmware.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE-OF-CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-07-26T19:03:36.000Z","updated_at":"2024-11-04T08:03:20.000Z","dependencies_parsed_at":"2023-01-13T23:51:05.280Z","dependency_job_id":"1e78251c-7807-4269-aaee-2e37d989ff18","html_url":"https://github.com/vmware/vrops-export","commit_stats":null,"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/vmware/vrops-export","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vmware%2Fvrops-export","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vmware%2Fvrops-export/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vmware%2Fvrops-export/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vmware%2Fvrops-export/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vmware","download_url":"https://codeload.github.com/vmware/vrops-export/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vmware%2Fvrops-export/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271444276,"owners_count":24760764,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-21T02:00:08.990Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-06T15:36:33.382Z","updated_at":"2025-08-21T07:32:25.692Z","avatar_url":"https://github.com/vmware.png","language":"Java","readme":"# vrops-export\n\nSimple utility for exporting data from vRealize Operations.\n\n## Description\n\nA simple command-line data export tool for vRealize Operations. Currently, the tool supports CVS, JSON, ElasticSearch,\nWavefront and SQL, but additional output formats are planned.\n\n# Installation\n\nThe tool can be installed from pre-built binaries or built from source. If you're unclear what \"building from source\"\nmeans, you probably want to use the binaries. Building from source is mainly for people who like to change the code and\ncontribute to the project.\n\n## Installing the binaries\n\n### Prerequisites\n\n* Java JDK 1.8 installed on the machine where you plan to run the tool\n* vRealize Operations 6.3 or higher\n\n### Installation on Linux, Mac or other UNIX-like OS\n\n1. Download the binaries from here: https://github.com/vmware/vrops-export/releases\n2. Unzip the files:\n\n```\nmkdir ~/vrops-export\ncd ~/vrops-export\nunzip vrops-export-\u003cversion\u003e-bin.zip\ncd vrops-export-\u003cversion\u003e/bin\n```\n\n3. Make the start script runnable\n\n```\nchmod +x exporttool.sh\n```\n\n4. Run it!\n\n```\n./exporttool.sh -d ../samples/vmfields.yaml -u admin -p password -H https://my.vrops.host\n```\n\n### Installation on Windows\n\n1. Download the binaries from here: https://github.com/vmware/vrops-export/releases\n2. Unzip the files into a directory of your choice, e.g. c:\\\\vropsexport\n3. Open a command window and cd into the directory you created, e.g.\n\n```\ncd c:\\vropsexport\n```\n\n4. Cd into the bin directory\n\n```\ncd bin\n```\n\n5. Runt the tool\n\n```\nexporttool.bat -d ..\\samples\\vmfields.yaml -u admin -p password -H https://my.vrops.host\n```\n\n## Building from source\n\n### Prerequisites\n\n* Java JDK 1.8 installed on the machine where you plan to run the tool\n* vRealize Operations 6.3 or higher\n* Maven 3.3.3 or higher\n\n### Build\n\n1. Get from git\n\n```\ngit init # Only needed of you haven't already initialized a git repo in the directory \ngit clone https://github.com/vmware/vrops-export.git\n```\n\n2. Build the code\n\n```\ncd vrops-export\nmvn package\n```\n\n3. Run it!\n\n```\ncd target\nchmod +x exporttool.sh\n./exporttool.sh -d ../samples/vmfields.yaml -u admin -p password -H https://my.vrops.host -i\n```\n\n## Command syntax\n\n```\nusage: exporttool [-d \u003carg\u003e] [--dumprest] [-e \u003carg\u003e] [-F \u003carg\u003e] [-G \u003carg\u003e]\n       [-H \u003carg\u003e] [-h] [-i] [-l \u003carg\u003e] [-m \u003carg\u003e] [-n \u003carg\u003e]\n       [--no-sniextension] [-o \u003carg\u003e] [-P \u003carg\u003e] [-p \u003carg\u003e] [-q] [-r\n       \u003carg\u003e] [-R \u003carg\u003e] [--resfetch \u003carg\u003e] [-s \u003carg\u003e] [-S] [-t \u003carg\u003e] [-T\n       \u003carg\u003e] [--trustpass \u003carg\u003e] [-u \u003carg\u003e] [-v]\nExports vRealize Operations Metrics\n -A,--adapter-kinds          List adapter kinds\n -d,--definition \u003carg\u003e       Path to definition file\n    --dumprest               Dump rest calls to output\n -e,--end \u003carg\u003e              Time period end (date format in definition\n                             file)\n -F,--list-fields \u003carg\u003e      Print name and keys of all fields to stdout\n -G,--generate \u003carg\u003e         Generate template definition for resource\n                             type\n -H,--host \u003carg\u003e             URL to vRealize Operations Host\n -h,--help                   Print a short help text\n -i,--ignore-cert            Trust any cert (DEPRECATED!)\n -l,--lookback \u003carg\u003e         Lookback time\n -m,--max-rows \u003carg\u003e         Maximum number of rows to fetch\n                             (default=1000*thread count)\n -n,--namequery \u003carg\u003e        Name query\n    --no-sniextension        Disable SNI extension. May be needed for very\n                             old SSL implementations\n -o,--output \u003carg\u003e           Output file\n -P,--parent \u003carg\u003e           Parent resource (ResourceKind:resourceName)\n -p,--password \u003carg\u003e         Password\n -q,--quiet                  Quiet mode (no progress counter)\n -r,--refreshtoken \u003carg\u003e     Refresh token\n -R,--resource-kinds \u003carg\u003e   List resource kinds\n    --resfetch \u003carg\u003e         Resource fetch count (default=1000)\n -s,--start \u003carg\u003e            Time period start (date format in definition\n                             file)\n -S,--streaming              True streaming processing. Faster but less\n                             reliable\n -t,--threads \u003carg\u003e          Number of parallel processing threads\n                             (default=10)\n -T,--truststore \u003carg\u003e       Truststore filename\n    --trustpass \u003carg\u003e        Truststore password (default=changeit)\n -u,--username \u003carg\u003e         Username\n -v,--verbose                Print debug and timing information\n ```\n\n### Certificate and trust management\n\nAs of version 2.1.0, the -i option has been deprecated for security reasons. Instead, the tool will prompt the user when\nit encounters an untrusted certificate. If the user chooses to trust the certificate, it is stored in a personal\ntruststore and reused next time the tool is executed against that host. By default, the trusted certs are stored in\n$HOME/.vropsexport/truststore, but the location can be overridden using the -T flag.\n\n### TLS handshake issues\n\nIn some cases, especially with very old SSL/TLS implementations, you may see name verification errors. To remedy this,\nplease try the --no-sniextension command-line argument.\n\n### Authentication\n\nThe vrops-export tool uses the local authentication source by default. Other sources can be specified by using the \"\nusername@source\" syntax. Be aware that in the case of e.g. Active Directory, the string after the @-sign should be the\nname of the *authentication source* and not that of the Active Directory domain.\n\n### Support for vRealize Operations Cloud\n\nAs of version 3.2.0, vRealize Operations Cloud is supported. To export data from a cloud instance, use the following API\nendpoind URLs as arguments to the `-H` option:\n\nUnited States:\n`https://www.mgmt.cloud.vmware.com/vrops-cloud/suite-api`\n\nAll other countries:\n`https://\u003ccountry\u003e.www.mgmt.cloud.vmware.com/vrops-cloud/suite-api`\nWhere `country` is the country code of your API endpoint. Should match the country code in your browser URL when\ninteracting with vRealize Operations Cloud.\n\nUse the `-r` option to log in using a refresh token/API token.\n\n### Notes:\n\n* Start and end dates will use the date format specified in the definition file. Since dates tend to contain spaces and\n  special characters, you probably want to put dates within double quotes (\").\n* If you're unsure of what the metric names are, use the -F option to print the metric names and keys for a specific\n  resource type, e.g. -F VirtualMachine\n* The -l (lookback) parameter is an alternative to the start and end dates. It sets the end date to the current time and\n  goes back as far as you specify. You specify it as a number and a unit, e.g. 24h for 24 hours back. Valid unit are\n  d=days, h=hours, m=minutes, s=seconds.\n* The -P flag restricts the export to objects sharing a specified parent. Parents must be specified as resource kind and\n  resource name, for example HostSystem:esxi-01 if you want to export only VMs on the host named \"esxi-01\".\n\n## Definition file\n\nThe details on what fields to export and how to treat them is expressed in the definition file. This file follows the\nYAML format. Here is an example of a definition file:\n\n ```\nresourceType: VirtualMachine                     # The resource type we're exporting\nrollupType: AVG                                  # Rollup type: AVG, MAX, MIN, SUM, LATEST, COUNT\nrollupMinutes: 5                                 # Time scale granularity in minutes\ndateFormat: yyyy-MM-dd HH:mm:ss                  # Date format. See http://tinyurl.com/pscdf9g\nfields:                                          # A list of fields\n# CPU fields\n  - alias: cpuDemand                             # Name of the field in the output\n    metric: cpu|demandPct                        # Reference to a metric field in vR Ops\n  - alias: cpuReady\n    metric: cpu|readyPct\n  - alias: cpuCostop\n    metric: cpu|costopPct\n# Memory fields\n  - alias: memDemand\n    metric: mem|object.demand\n  - alias: memSwapOut\n    metric: mem|swapoutRate_average\n  - alias: memSwapIn\n    metric: mem|swapinRate_average\n # Storage fields\n  - alias: storageDemandKbps\n    metric: storage|demandKBps\n # Network fields\n  - alias: netBytesRx\n    metric: net|bytesRx_average\n  - alias: netBytesTx\n    metric: net|bytesTx_average\n # Host CPU\n  - alias: hostCPUDemand\n    metric: $parent:HostSystem.cpu|demandmhz\t# Reference to a metric in the parent. \n # Guest OS\n  - alias: guestOS\n    prop: config|guestFullName\t\t\t# Reference to a property (as opposed to metric)\n # Host CPU type\n  - alias: hostCPUType\n    prop: $parent:HostSystem.cpu|cpuModel\t\t# Reference to a metric in a parent\n # A vCenter tag\n  - alias: costcenter\n    tag: costcenter\n```\n\n### Global directives\n\n* resourceType: Name of the resource type (e.g. VirtualMachine)\n* rollupType: Type of data aggregation. Valid values are MAX, MIN, AVG, SUM, LATEST.\n* rollupMinutes: Number of minutes in each bucket for rollup. E.g. ```rollupType: \"AVG\"``` and ```rollupMinutes: 5```\n  generates 5-minute averages.\n* dateFormat: Format to use when specifying and displaying dates.\n  See http://docs.oracle.com/javase/8/docs/api/java/text/SimpleDateFormat.html for a description of the format. In\n  addition, the format string```\"%E\"``` will cause the tool to output raw epoch milliseconds as dates.\n* outputFormat: Specifies the output format. Valid values are ```csv```, ```json```, ```wavefront``` and ```sql```.\n* align: Aligns the timestamps to a specified granularity (in seconds). For example, if an align value of 300 is\n  specified, all timestamps will be aligned to the nearest 5 minutes. Note that only the time stamps are changed.\n  Interpolation is not yet supported.\n* allMetrics: Exports all metrics for every resource. This option is intended mainly for the JSON output format and will\n  most likely not work for table-oriented outputs, such as CSV and SQL. If specified, the ```fields``` attribute is\n  ignored.\n  \n### Field properties\n* alias: The name of the field as it will appear in the output\n* prop: Name of a property on the resource from which the value is fetched.\n* metric: Name of a metric on the resource from which the value is fetched.\n* tag: Name of a vCenter tag category on the resource from which the value is fetched.\n\n### Special properties in the definition file\n\nThere are a number of special properties that are always available for use in a properties file for getting things like\nparent resources and resource names.\n\n* $resId - Internal ID of the current resource.\n* $resName - Resource name of the current resource\n* $parent - Reference to a parent resource.\n\n### Referencing parent resources\n\nThe syntax for referencing parent resources is as follows:\n\n```\n$parent:\u003cParent Kind\u003e.\u003cmetric or property\u003e\n``` \n\nFor example:\n\n```\n$parent:HostSystem.cpu|demandmhz\n``` \n\nNotice that you can stack several $parent keywords. For example, this gets the total CPU demand of a parent cluster\nbased on a VM:\n\n```\n$parent:HostSystem.$parent:ClusterComputeResource.cpu|demandmhz\n```\n\n## Exporting to SQL\n\nThe tool supports exporting to a SQL database. For details, please refer to [this document](docs/sql.md)\n\n## Exporting to Wavefront\n\nFor information on exporting to Wavefront, please refer to [this document](docs/wavefront.md)\n\n## Exporting to JSON\n\nFor information on exporting to JSON, please refer to [this document](docs/json.md)\n\n# Known issues\n\n* Very long time ranges in combination with small interval sizes can cause the server to prematurely close the\n  connection, resulting in NoHttpResponseExceptions to be thrown. If this happens, consider shortening the time range.\n  This seems to happen mostly when exporting over a slow connection.\n* Only one parent resource type is supported. This will be fixed in a future release.\n\n# Contributing to the code\n\nContributing with code and new ideas is encouraged! If you have a great idea for a new or improved feature, please file\na feature request under the \"issues\" tab in Github. \n \n\n\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvmware%2Fvrops-export","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvmware%2Fvrops-export","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvmware%2Fvrops-export/lists"}