In the case of SD cards and hard drives, the older footage is overwritten by, the newer as soon as the storage maxes out completely. So, for example, if the SD card's storage allows one week's worth of recordings, at any point, you will only have the recordings taken in the last week. The overwriting can be prevented if you manage the storage well and keep deleting the videos that are not needed or transferring the ones that are into a more secure spot, such as a computer or a laptop. In doing so, you can always keep the space available for the new videos to be recorded and prevent the risk of overwriting.