$ bin/alluxio ttl add --path /s3/small_interval/ --time 5sWarning: You are setting TTL policy to 5s. This TTL is too small. Note that expired cache are scanned and evicted every 1h. Please consider making this TTL larger with `bin/alluxio ttl update` command.
Added alluxioPath=/s3/small_interval/ and time=5s
$ bin/alluxio ttl update --path /s3/test_folder/ --time 30minUpdated alluxioPath=/s3/test_folder/ and time=30min$ bin/alluxio ttl update --path /s3/test_folder/ --time 5sWarning: You are setting TTL policy to 5s. This TTL is too small. Note that expired cache are scanned and evicted every 1h. Please consider making this TTL larger with `bin/alluxio ttl update` command.
Updated alluxioPath=/s3/test_folder/ and time=5s
删除 TTL 规则
该命令用于从 ETCD 中删除 TTL 策略。下面是一些示例:
$ bin/alluxio ttl remove --path /s3/test_folderRemoved TTL policy for alluxioPath=/s3/test_folder/
列出所有 TTL 规则
该命令将列出所有有效的 TTL 策略:
$ bin/alluxio ttl listListing all TTL policiesThe ttl policy table is empty.$ bin/alluxio ttl listListing all TTL policies/s3/test.csv/ TTL: 1 hour/s3/test_2.csv/ TTL: 30 seconds
$ bin/alluxio ttl triggerForce triggering all workers to scan their cache with TTL rules.Successfully scheduled on-demand TTL evictions.# If two workers are already in the middle of a regular scan$ bin/alluxio ttl triggerForce triggering all workers to scan their cache with TTL rules.2 workers are already scanningSuccessfully scheduled on-demand TTL evictions.