Language Selection

English French German Italian Portuguese Spanish

bash shell script: copy only files modifed after specified date

Filed under
HowTos

I’ve mentioned a few times lately that I’m working on my backup plan for GNU/Linux. I started by looking at great free software tools like Samba’s rsync and GNU Tar, and I don’t think I need to look much further than them. There is also GNU Cpio, which I haven’t really investigated yet.

I may have more to say later about my rsync and tar adventures, but for today here’s something I came up with to emulate a feature of a tool I had in Windows that I couldn’t find how to do with existing tools in GNU. The xcopy DOS command lets you recursively copy files modified after a certain date by using the /D:date option.

your questions:

Why would you want to do this? Well, one reason would be for offsite backups. I regularly store backup discs in a bank safe deposit box. I then occasionally want to copy changed files from the last dropoff, encrypt them, and send to my gmail account or carry around on a USB thumb drive. I’d like to have a lightweight way to do this that didn’t rely on a system of incremental backups.

Doesn’t tar take care of this with the --after-date option? Yes, but...

More Here.

More in Tux Machines

Games for GNU/Linux

Today in Techrights

Why OpenStack is the wrong cloud for Red Hat to be building its future on

Just because one can make money from OpenStack doesn't mean one should. Red Hat, on its recent earnings call, gladly assumed the title of "Red Hat of OpenStack," meaning the "vendor that does certification and confidently allow[s] both hardware and software vendors to participate in the ecosystem." In a similar vein, I've called OpenStack Red Hat's "Linux moment," a chance to productize the growing cloud movement. Read more

Linux 4.10.7

I'm announcing the release of the 4.10.7 kernel. All users of the 4.10 kernel series must upgrade. The updated 4.10.y git tree can be found at: git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-4.10.y and can be browsed at the normal kernel.org git web browser: http://git.kernel.org/?p=linux/kernel/git/stable/linux-st... Read more Also: Linux 4.9.19 Linux 4.4.58