-
Notifications
You must be signed in to change notification settings - Fork 102
How to Manage Disk Space
Manage free disk space when storage is limited.
Disk space management is primarily designed for smaller size SD cards or for video files where file recycling is not used. Using this disk space management feature will reduce the chance of filling the storage device and causing Raspbian system problems due to lack of space. If you are saving to an external device with a large capacity then you may not want to use this feature. Also disk space checking will slow down motion tracking and timelapse functions.
Disk space management is controlled from the config.py file per the following settings.
SPACE_MEDIA_DIR = '/home/pi/pi-timolo/media' # Default= '/home/pi/pi-timolo/media' Starting point for directory walk
SPACE_TIMER_HOURS = 0 # Default= 0 0=off or specify hours frequency to perform free disk space check
SPACE_TARGET_MB = 500 # Default= 500 Target Free space in MB Required.
SPACE_TARGET_EXT = 'jpg' # Default= 'jpg' File extension to Delete Oldest Files
To turn on disk space management set spaceTimerHrs to number of hours to check disk space. If you just want to check disk space every day set SPACE_TIMER_HOURS = 24. this will check once a day and delete the oldest SPACE_TARGET_EXT files in the SPACE_MEDIA_DIR folder tree until the required SPACE_TARGET_MB is reached. Only 25 percent of total files will be deleted in one session.
If you do not want files deleted you may wish to archive files to a local network share or rclone remote storage name using rclone.
- Wiki Home
- Introduction
- Prerequisites
- Install or Upgrade
- Run pi-timolo from a drive mnt
- Customize config.py
- Panoramic Images
- user_motion_code.py
- Align Camera Motion Area
- Schedule StartAt
- Basic Troubleshooting
- Tuning Variable Settings
- menubox.sh
- Web Server View Files
- Make Timelapse Video
- Join or Convert h264 to MP4
- Run on Boot
- Setup & Run shutdown.py
- Rclone Media Sync
- watch-app.sh Usage
- Plugins Usage
- Mount USB Storage
- Mount Network Share
- Auto SubFolder Creation
- Manage Disk Space
- Utilities Summary
- GitHub Repo
gdrive is no longer default.