Deutsch English Français Italiano |
<vhdhf3$ptqv$1@dont-email.me> View for Bookmarking (what is this?) Look up another Usenet article |
Path: ...!eternal-september.org!feeder2.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: "Steven G. Kargl" <sgk@REMOVEtroutmask.apl.washington.edu> Newsgroups: comp.unix.bsd.freebsd.misc Subject: Re: Are files overwritten in place by sftp? Date: Sun, 17 Nov 2024 19:50:59 -0000 (UTC) Organization: A noiseless patient Spider Lines: 25 Message-ID: <vhdhf3$ptqv$1@dont-email.me> References: <vhd948$nate$2@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Injection-Date: Sun, 17 Nov 2024 20:51:00 +0100 (CET) Injection-Info: dont-email.me; posting-host="206212796f0d1519f4d808029b434b11"; logging-data="849759"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/xN4DVuBvzMMcUPXiNGD28" User-Agent: Pan/0.145 (Duplicitous mercenary valetism; d7e168a git.gnome.org/pan2) Cancel-Lock: sha1:pYkxH2uKOm+MmeMEyJaD2Se5avo= Bytes: 2020 On Sun, 17 Nov 2024 17:28:40 +0000, bp wrote: > In the event one copies a file or directory over an existing > file or directory is the duplicate written to the same physical > blocks in storage, or are new physical blocks written with the > old blocks marked free? > > The situation in mind is using get -r to copy a remote directory, > then changing or adding a few files to the remote directory followed > by using get -r to get the directory a second time. Clearly, changed > files will require writing new blocks on the destination, but what > about files with unchanged paths and contents? > > The question is motivated by concerns about limited-life storage > media such as flash. From the description, it seems that you are looking for the net/rsync port. The first time it is executed, it will copy the directory. Additional invocations of rsync will only copy modified files. rsync also allows you to exclude files from being copied such as *.o which can change quite often. -- steve