View Single Post
      12-09-2017, 02:18 PM   #6
Nezil
Major
Nezil's Avatar
1403
Rep
1,466
Posts

Drives: LCI '18 6MT M2
Join Date: Jul 2017
Location: San Francisco Bay Area

iTrader: (0)

OK, a little update to the script...

I quickly found that I was filling up the disk I was using to save files to, and was having to go and manually delete the older files, which is of course annoying.

I have enough disk space for just over 2 weeks of regular driving. I'm sure a long trip would result in more data, but I do have some wiggle room on the disk, so decided on 14 days of backups.

I inserted the following lines just after the section that sorts the list of files, before the while loop. This way it doesn't delete files older than 14 days if the dashcam isn't connected at all.

Code:
#           delete dashcam files over 14 days to prevent over filling the disk
            find "$rootpath" -mtime +14 -delete
__________________
2018 ///M2 LCI, LBB, 6MT...

Current Performance Mods:
CSF FMIC, ER CP, Fabspeed Cat, Aquamist WMI, GFB DV+, NGK 97506, BM3 (Stage 2 93 OTS), CDV delete, UCP, M2C/M3/M4 Strut Brace, M3/M4 Reinforcement Rings
Appreciate 0