Fill a disk with more recent files

2022-04-27 Thread Andrea Venturoli
Hello. Suppose I have a large storage of files and a smaller disk (backup). I need to copy as much as I can from source to target and I want the most recent files. Before I start scripting and reinvent the wheel, is there some tool already? bye & Thanks av.

Re: Fill a disk with more recent files

2022-04-27 Thread Tomek CEDRO
On Wed, Apr 27, 2022 at 9:48 AM Andrea Venturoli wrote: > Hello. > Suppose I have a large storage of files and a smaller disk (backup). > I need to copy as much as I can from source to target and I want the > most recent files. > Before I start scripting and reinvent the wheel, is there some tool

Re: Fill a disk with more recent files

2022-04-27 Thread Andrea Venturoli
On 4/27/22 09:51, Tomek CEDRO wrote: On Wed, Apr 27, 2022 at 9:48 AM Andrea Venturoli wrote: Hello. Suppose I have a large storage of files and a smaller disk (backup). I need to copy as much as I can from source to target and I want the most recent files. Before I start scripting and reinven

Re: Fill a disk with more recent files

2022-04-27 Thread Tomek CEDRO
On Wed, Apr 27, 2022 at 10:09 AM Andrea Venturoli wrote: > On 4/27/22 09:51, Tomek CEDRO wrote: > > On Wed, Apr 27, 2022 at 9:48 AM Andrea Venturoli wrote: > >> Hello. > >> Suppose I have a large storage of files and a smaller disk (backup). > >> I need to copy as much as I can from source to tar

Re: Fill a disk with more recent files

2022-04-27 Thread Andrea Venturoli
On 4/27/22 11:50, Tomek CEDRO wrote: If you want to enforce particular sort order you will have to call rsync from another tool. Probably ls / find, sort, then rsync, maybe a dedicated Python script. Sure, this was what I was thinking. I just wanted to avoid doing this if it already existed.

Re: Fill a disk with more recent files

2022-04-27 Thread Chris
On 2022-04-27 00:47, Andrea Venturoli wrote: Hello. Suppose I have a large storage of files and a smaller disk (backup). I need to copy as much as I can from source to target and I want the most recent files. Before I start scripting and reinvent the wheel, is there some tool already? If I'm

Re: Fill a disk with more recent files

2022-04-27 Thread Andrea Venturoli
On 4/27/22 17:11, Chris wrote: On 2022-04-27 00:47, Andrea Venturoli wrote: Hello. Suppose I have a large storage of files and a smaller disk (backup). I need to copy as much as I can from source to target and I want the most recent files. Before I start scripting and reinvent the wheel, i

FreeBSD ports you maintain which are out of date

2022-04-27 Thread portscout
Dear port maintainer, The portscout new distfile checker has detected that one or more of your ports appears to be out of date. Please take the opportunity to check each of the ports listed below, and if possible and appropriate, submit/commit an update. If any ports have already been updated, you

Re: Fill a disk with more recent files

2022-04-27 Thread Andrea Venturoli
On 4/27/22 18:29, Guido Falsi wrote: net/unison has options to check same named files and keep the most recent one Thanks, but this is not what I need. I mean, unless I understood wrong, unison will intelligently copy everything, as rsync does. I only need a partial copy (up to a space full

Re: Fill a disk with more recent files

2022-04-27 Thread Sysadmin Lists
With a source disk containing x-amount of space, and a backup disk containing y-amount of space, where x > y, to back up files from x, newest first, until disk y is full, it's as simple as a bash-loop where you specify date ranges on each iteration: for days in {1..30}; do find source/ -type f -

Re: Fill a disk with more recent files

2022-04-27 Thread Peter Beckman
I feel like `ls` or `find` and some creative sorting after the fact would do it. ls -laRrt sort of works, but it doesn't output subdirectory files in order. find doesn't have any sorting. You could use the `ls` flag `-D format`: When printing in the long (-l) format, use format to form