Viewing Raw Data
Scenarios
This topic describes how you can view the raw data saved in the OBS bucket by downloading metric data files.
This operation is only supported on Cloud Service Monitoring of the earlier version.
Prerequisites
- You have successfully configured data storage on Cloud Eye.
- You have installed Java and configured environment variables.
- You have downloaded the format conversion tool metric-transfer-merge.jar.
Procedure
- Log in to the management console.
- Click Service List in the upper left corner and select Cloud Eye.
- In the navigation pane, choose Cloud Service Monitoring. Click the name of the cloud service. On the displayed Details page, click Earlier Edition in the upper right corner.
- Locate the cloud service resource to be viewed and click the OBS bucket name in the Permanent Data Storage column.
Alternatively, in the navigation pane, choose Server Monitoring. Locate the ECS and select the specified OBS bucket in the Permanent Data Storage column.
- Select the metric data file you want to view in the OBS bucket. Based on the storage path of the metric data file, select OBS bucket name > CloudEye > Region > Year > Month > Day > Service type directory > Resource type directory. Click Download in the Operation column to download the file to the default path. To download the metric data file to a customized path, click Download As.
The metric data file is named in the following format:
Metric data file prefix_CloudEye_Region_Time when the log was uploaded to the OBS: year-month-dayThour-minute-secondZ_Randomly generated character.json.gz
Example: File Prefix_CloudEye_region_2016-05-30T16-20-56Z_21d36ced8c8af71e.json
- The OBS bucket name and trace file prefix are user-defined, and other parameters are automatically generated.
- Original metric data files are segment files of time granularity. The files include all metric data of a resource under the time segment. The metric data is stored in the JSON format.
- To facilitate your operations, Cloud Eye provides the format conversion and content combination tool. Using this tool, you can combine the files of several time slices in a specific resource into a time-staged file in the chronological order in the .csv format. In addition, you can use the tool to generate an independent time splice file for every metric of the resource in the .csv format.
- Access the cmd tool in the Windows system. Go to the folder where metric-transfer-merge.jar is located, run the java -jar metric-transfer-merge.jar j2c inputDirectory outputDirectory mergFileName command.
In the Linux system, run the java-jar metric-transfer-merge.jar inputDirectory outputDirectory mergFileName command in the shell command line.
- j2c is the command to convert JSON into CSV.
- inputDirectory is the directory to store the downloaded JSON files.
- outputDirectory is the directory to store the generated files.
- mergFileName is the name of the specified combined file for users. This parameter can be ignored because the tool will name the combined file as mergeResult.csv by default.
After running the java command, you can view the converted files in the outputDirectory directory. Each file corresponds to the data of one metric at all time points. mergeResult.csv is a large file generated by combining the data of all metrics. Figure 1 shows the content of the converted file.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot