Clearing Image Creation Caches in ModelArts Notebook
Run the ma-cli image prune command to clear image creation caches. This command is available only in ModelArts notebook instances.
$ ma-cli image prune -h Usage: ma-cli image prune [OPTIONS] Prune image build cache by image-building in Notebook. Example: # Prune image build cache ma-cli image prune Options: -ks, --keep-storage INTEGER Amount of disk space to keep for cache below this limit (in MB) (default: 0). -kd, --keep-duration TEXT Keep cache newer than this limit, support second(s), minute(m) and hour(h) (default: 0s). -v, --verbose Show more verbose output. -D, --debug Debug Mode. Shows full stack trace when error occurs. -h, -H, --help Show this message and exit.
| Parameter | Type | Mandatory | Description |
|---|---|---|---|
| -ks / --keep-storage | Int | No | Size of the cache to be retained, in MB. The default value is 0, indicating that all caches will be cleared. |
| -kd / --keep-duration | String | No | Whether to retain the latest caches and clear only historical caches. The unit can be s (second), m (minute), or h (hour). The default value is 0, indicating that all caches will be cleared. |
| -v / --verbose | Bool | No | Whether to display detailed information. This function is disabled by default. |
Examples
Retain 1 MB of image cache when clearing caches.
ma-cli image prune -ks 1

Last Article: Obtaining Image Creation Caches in ModelArts Notebook
Next Article: Registering SWR Images with ModelArts Image Management
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.