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

today's leftovers

Proposed: A Tainted Performance State For The Linux Kernel

Similar to the kernel states of having a tainted kernel for using binary blob kernel modules or unsigned modules, a new tainting method has been proposed for warning the user about potentially adverse kernel performance. Dave Hansen of Intel has proposed a new "TAINT_PERFORMANCE" for the kernel that would proactively print a warning message about not using the kernel for any performance measurements. Dave explained in his RFC announcement, "I have more than once myself been the victim of an accidentally-enabled kernel configuration option being mistaken for a true performance problem. I'm sure I've also taken profiles or performance measurements and assumed they were real-world when really I was measuring the performance with an option that nobody turns on in production. A warning like this late in boot will help remind folks when these kinds of things are enabled." Read more

Scientific Linux 7.0 x86_64 BETA 3

Fermilab's intention is to continue the development and support of Scientific Linux and refine its focus as an operating system for scientific computing. Today we are announcing a beta release of Scientific Linux 7. We continue to develop a stable process for generating and distributing Scientific Linux, with the intent that Scientific Linux remains the same high quality operating system the community has come to expect. Please do not install Pre-Release software in your production environment. Read more

Ubuntu 14.10 (Utopic Unicorn) Now Features Linux Kernel 3.16.1

"The Utopic kernel has been rebased to the first v3.16.1 upstream stable kernel and uploaded to the archive, ie. linux-3.16.0-9.14. Please test and let us know your results," says Canonical's Joseph Salisbury, after the latest Ubuntu Kernel Team meeting. Read more