This topic describes the parameters that you can set when you ship logs from Log Service to OSS and store the log data in the JSON format. For more information, see Ship logs to OSS.

The following table lists the compression types and storage addresses of OSS files.

Compression type File extension Example
Uncompressed None oss://oss-shipper-shenzhen/ecs_test/2016/01/26/20/54_1453812893059571256_937
SNAPPY .snappy oss://oss-shipper-shenzhen/ecs_test/2016/01/26/20/54_1453812893059571256_937.snappy

Uncompressed

Each file consists of multiple logs. Each line of the file is a log in the JSON format. An example is provided as follows:

{"__time__":1453809242,"__topic__":"","__source__":"10.170. ***.***","ip":"10.200. **.***","time":"26/Jan/2016:19:54:02 +0800","url":"POST
              /PutData? Category=YunOsAccountOpLog&AccessKeyId=<yourAccessKeyId>&Date=Fri%2C%2028%20Jun%202013%2006%3A53%3A30%20GMT&Topic=raw&Signature=<yourSignature>
              HTTP/1.1","status":"200","user-agent":"aliyun-sdk-java"}

SNAPPY compression

You can use the following methods to decompress the package and obtain the original files.

For more information, see Snappy compression.

  • C++ library
  • Java library
  • Decompression tools for Linux
  • Decompression methods in Python