Are OSS access logs regularly deleted?

Updated at:

Object Storage Service (OSS) does not regularly delete OSS access logs stored in buckets, while Simple Log Service regularly deletes OSS access logs stored in the Logstore based on the log retention period.

OSS access logs are stored and deleted based on the following rules:

  • OSS access logs stored in buckets: If you enable and configure logging for a source bucket, your OSS access logs are stored in the specified destination bucket. OSS does not regularly delete your log objects. You can configure lifecycle rules to delete log objects on a regular basis. For more information, see Configure lifecycle rules based on the last modified time.

  • OSS access logs stored in the Logstore: If you enable real-time log query, your OSS access logs are stored in the Logstore. Simple Log Service automatically deletes log data on a regular basis based on the log retention period. If data is inconsistent for two log queries, some logs may be automatically deleted by Simple Log Service because the specified retention period of logs ends. By default, Simple Log Service provides a free log retention period of seven days. If you want to retain OSS access logs for more than seven days, you can extend the retention period. For more information, see Modify the retention period of logs.