From unknown Mon Jun 16 23:38:04 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#8380 <8380@debbugs.gnu.org> To: bug#8380 <8380@debbugs.gnu.org> Subject: Status: "tar u" ignores files if archive modification time >= folder modification time Reply-To: bug#8380 <8380@debbugs.gnu.org> Date: Tue, 17 Jun 2025 06:38:04 +0000 retitle 8380 "tar u" ignores files if archive modification time >=3D folder= modification time reassign 8380 coreutils submitter 8380 Karsten Loesing severity 8380 normal tag 8380 notabug thanks From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 30 08:28:52 2011 Received: (at submit) by debbugs.gnu.org; 30 Mar 2011 12:28:52 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4uW2-0006fH-TN for submit@debbugs.gnu.org; Wed, 30 Mar 2011 08:28:51 -0400 Received: from eggs.gnu.org ([140.186.70.92]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4uHu-0006KV-EZ for submit@debbugs.gnu.org; Wed, 30 Mar 2011 08:14:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q4uHo-0007ZZ-8b for submit@debbugs.gnu.org; Wed, 30 Mar 2011 08:14:09 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,T_RP_MATCHES_RCVD,T_TO_NO_BRKTS_FREEMAIL autolearn=unavailable version=3.3.1 Received: from lists.gnu.org ([199.232.76.165]:52435) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q4uHo-0007ZV-6H for submit@debbugs.gnu.org; Wed, 30 Mar 2011 08:14:08 -0400 Received: from [140.186.70.92] (port=44438 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q4uHn-0007O3-19 for bug-coreutils@gnu.org; Wed, 30 Mar 2011 08:14:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q4uHl-0007Yf-Sq for bug-coreutils@gnu.org; Wed, 30 Mar 2011 08:14:06 -0400 Received: from mailout-de.gmx.net ([213.165.64.23]:33382) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1Q4uHl-0007Wz-IH for bug-coreutils@gnu.org; Wed, 30 Mar 2011 08:14:05 -0400 Received: (qmail invoked by alias); 30 Mar 2011 12:13:59 -0000 Received: from v37843.1blu.de (EHLO v37843.1blu.de) [88.84.145.243] by mail.gmx.net (mp063) with SMTP; 30 Mar 2011 14:13:59 +0200 X-Authenticated: #19820069 X-Provags-ID: V01U2FsdGVkX19e+rNlUuFe8u7crV3MpD08Lj0Z3gC6Ekw2KfN+Aj TQEBjn1QMB1nl8 Received: from karsten by v37843.1blu.de with local (Exim 4.69) (envelope-from ) id 1Q4uHe-0002aR-4E; Wed, 30 Mar 2011 14:13:58 +0200 Date: Wed, 30 Mar 2011 14:13:58 +0200 From: Karsten Loesing To: bug-coreutils@gnu.org Bcc: karsten.loesing@gmx.net Subject: "tar u" ignores files if archive modification time >= folder modification time Message-ID: <20110330121358.GA9312@v37843.1blu.de> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="82I3+IH0IqGh5yIs" Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) X-Y-GMX-Trusted: 0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 199.232.76.165 X-Spam-Score: -5.9 (-----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Wed, 30 Mar 2011 08:28:49 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -5.9 (-----) --82I3+IH0IqGh5yIs Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hello list, today I found that "tar u" doesn't update an archive unless the folder's modification time is newer than the archive's modification time. So, for example, creating a folder files/ with file-1, creating a test.tar from it, creating another file files/file-2, and updating test.tar won't add file-2 if this all happens in the same second. Even touching files/file-2 a few seconds later won't add it to the tarball if one tries to update it. The only way to add files/file-2 is to touch the files/ folder before updating the tarball. Please find the attached shell script for an example. I'm running "tar (GNU tar) 1.20", and I confirmed that "bsdtar 2.6.2 - libarchive 2.6.2" on Mac OS X 10.6 behaves differently. So, either this is a bug, or at least a documentation/usability problem. Thanks, Karsten --82I3+IH0IqGh5yIs Content-Type: application/x-sh Content-Disposition: attachment; filename="test-tar.sh" Content-Transfer-Encoding: quoted-printable #!/bin/sh=0A=0A# This script shows that "tar u" using tar (GNU tar) 1.20 do= esn't update=0A# an archive unless a folder's modification time is newer th= an the=0A# archive's modification time, even if the folder contains files t= hat are=0A# not contained in the archive or the files' modification time is= newer=0A# than the archive's modification time.=0A=0ATEST_DIR=3Dtar-test-r= un=0Aif [ -d $TEST_DIR ]; then rm -rf $TEST_DIR; fi=0Amkdir $TEST_DIR=0Acd = $TEST_DIR=0A=0Aecho "Creating files/file-1 and creating test.tar."=0Amkdir = files=0Add if=3D/dev/urandom of=3Dfiles/file-1 count=3D1 bs=3D200000 > /dev= /null 2>&1=0Atar cf test.tar files/=0Aecho "test.tar contains file-1 as exp= ected:"=0Atar tf test.tar=0A=0Aecho=0Aecho "Creating files/file-2 and updat= ing test.tar."=0Add if=3D/dev/urandom of=3Dfiles/file-2 count=3D1 bs=3D2000= 00 > /dev/null 2>&1=0Atar uf test.tar files/=0Aecho "test.tar should contai= n file-1 and file-2, but it doesn't:"=0Atar tf test.tar=0A=0Aecho=0Aecho "S= leeping 2 seconds, touching file-2, and updating test.tar again."=0Asleep 2= =0Atouch files/file-2=0Atar uf test.tar files/=0Aecho "test.tar should cont= ain file-1 and file-2, but it still doesn't:"=0Atar tf test.tar=0A=0Aecho= =0Aecho "Touching files/ and updating test.tar a third time."=0Atouch files= /=0Atar uf test.tar files/=0Aecho "Finally, test.tar now contains file-1 an= d file-2:"=0Atar tf test.tar=0A=0Acd ..=0Aexit=0A=0A --82I3+IH0IqGh5yIs-- From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 30 09:39:41 2011 Received: (at 8380-done) by debbugs.gnu.org; 30 Mar 2011 13:39:42 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4vcb-0008G7-Fu for submit@debbugs.gnu.org; Wed, 30 Mar 2011 09:39:41 -0400 Received: from mail1.slb.deg.dub.stisp.net ([84.203.253.98]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1Q4vcZ-0008Fu-HG for 8380-done@debbugs.gnu.org; Wed, 30 Mar 2011 09:39:40 -0400 Received: (qmail 74007 invoked from network); 30 Mar 2011 13:39:33 -0000 Received: from unknown (HELO ?192.168.2.25?) (84.203.137.218) by mail1.slb.deg.dub.stisp.net with SMTP; 30 Mar 2011 13:39:33 -0000 Message-ID: <4D93327C.6090106@draigBrady.com> Date: Wed, 30 Mar 2011 14:39:08 +0100 From: =?ISO-8859-1?Q?P=E1draig_Brady?= User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.8) Gecko/20100227 Thunderbird/3.0.3 MIME-Version: 1.0 To: 8380-done@debbugs.gnu.org Subject: Re: bug#8380: "tar u" ignores files if archive modification time >= folder modification time References: <20110330121358.GA9312@v37843.1blu.de> In-Reply-To: <20110330121358.GA9312@v37843.1blu.de> X-Enigmail-Version: 1.0.1 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.7 (--) X-Debbugs-Envelope-To: 8380-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.7 (--) tags 8380 + notabug I suggest you resend this to bug-tar@gnu.org cheers, Pádraig. From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 30 09:41:35 2011 Received: (at 8380) by debbugs.gnu.org; 30 Mar 2011 13:41:35 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4veQ-0008JB-Ml for submit@debbugs.gnu.org; Wed, 30 Mar 2011 09:41:35 -0400 Received: from mx1.redhat.com ([209.132.183.28]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4veN-0008Iw-Qd for 8380@debbugs.gnu.org; Wed, 30 Mar 2011 09:41:33 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p2UDfP8B000317 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 30 Mar 2011 09:41:25 -0400 Received: from [10.3.113.104] (ovpn-113-104.phx2.redhat.com [10.3.113.104]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p2UDfOjT000988; Wed, 30 Mar 2011 09:41:25 -0400 Message-ID: <4D933304.8060909@redhat.com> Date: Wed, 30 Mar 2011 07:41:24 -0600 From: Eric Blake Organization: Red Hat User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.15) Gecko/20110307 Fedora/3.1.9-0.39.b3pre.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.9 MIME-Version: 1.0 To: Karsten Loesing Subject: Re: bug#8380: "tar u" ignores files if archive modification time >= folder modification time References: <20110330121358.GA9312@v37843.1blu.de> In-Reply-To: <20110330121358.GA9312@v37843.1blu.de> X-Enigmail-Version: 1.1.2 OpenPGP: url=http://people.redhat.com/eblake/eblake.gpg Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="------------enigD62AE78C19B4D75FDE5BF831" X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-Spam-Score: -10.3 (----------) X-Debbugs-Envelope-To: 8380 Cc: 8380@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -10.3 (----------) This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigD62AE78C19B4D75FDE5BF831 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 03/30/2011 06:13 AM, Karsten Loesing wrote: > Hello list, >=20 > today I found that "tar u" doesn't update an archive unless the folder'= s > modification time is newer than the archive's modification time. Thanks for the report; however, this would better be reported to the bug-tar list, since tar is not part of GNU coreutils. --=20 Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org --------------enigD62AE78C19B4D75FDE5BF831 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/ iQEcBAEBCAAGBQJNkzMEAAoJEKeha0olJ0Nq/nwH/0d+/S06sXGMU0nmoyNZWjHk Q3XDO1dnfgd2tuZEryIBayZcjr/tUmB964pW19A0ndRXssf6osIE58ZBoclDQC4v KTHisI0G5DEdtm4b+hN3+KPWmyGTTp2TXdgBiDPlqIh0cOV3eDYktevW1hQTryRI baiA2hpnpsm3CK1y9gUz1MrGiCNj7yLyTCHxl3mGVx8I9RMQsJwY2uXwkohFVDX1 UjZCQojXyzS1bzAQOvmAPQEAgZk/WRB+6auf6AkKbl59yKcSQ8VJjy8vkRXI0Hn0 2Tqf/Te/Ocb9Yr9x2gk8PVQ7YGSGeMf2+a02yB3ksfiQnAJ3hSVFCXQ1MXinIjg= =LZPR -----END PGP SIGNATURE----- --------------enigD62AE78C19B4D75FDE5BF831-- From debbugs-submit-bounces@debbugs.gnu.org Wed Mar 30 09:44:55 2011 Received: (at control) by debbugs.gnu.org; 30 Mar 2011 13:44:55 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4vhf-0008Nq-3o for submit@debbugs.gnu.org; Wed, 30 Mar 2011 09:44:55 -0400 Received: from mx1.redhat.com ([209.132.183.28]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4vhc-0008Nd-CB for control@debbugs.gnu.org; Wed, 30 Mar 2011 09:44:53 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p2UDikRf004313 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 30 Mar 2011 09:44:46 -0400 Received: from [10.3.113.104] (ovpn-113-104.phx2.redhat.com [10.3.113.104]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p2UDijl3022306 for ; Wed, 30 Mar 2011 09:44:46 -0400 Message-ID: <4D9333CD.9090806@redhat.com> Date: Wed, 30 Mar 2011 07:44:45 -0600 From: Eric Blake Organization: Red Hat User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.15) Gecko/20110307 Fedora/3.1.9-0.39.b3pre.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.9 MIME-Version: 1.0 To: control@debbugs.gnu.org Subject: closeout X-Enigmail-Version: 1.1.2 OpenPGP: url=http://people.redhat.com/eblake/eblake.gpg Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="------------enig1077A6BD2152A8DFB1AF06AC" X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 X-Spam-Score: -10.3 (----------) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -10.3 (----------) This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig1077A6BD2152A8DFB1AF06AC Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable tag 8380 + notabug close 8380 thanks --=20 Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org --------------enig1077A6BD2152A8DFB1AF06AC Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/ iQEcBAEBCAAGBQJNkzPNAAoJEKeha0olJ0NqQGAH/0XzibvRpDNqLjYIyqt+aPdq iUR7CIS0ywFNIizmCdHvcdMqwxK1Z8RHLdftM5X9hodcleuKuyLLLuwGyMOuZDum J4SBOK/UPg8aSC0+LBN8secE0ylfgTzGM890UfkfVraLzdzdEBaMkemOQIw3DiUG 0aCaPRJLtQ8mFmT12gqshAykpkLuHWTiGkol16QbIxndyNKWx3tTkM0yd3+Lx6Mw gV9VrRhvqgl3h7mMlQZhMe5Io9mIRKZvcDSNjLShouXifwI7olWQ47MlHd7C5+DW ANjizTt8xc5IAWTnrRfbjni7XtgX2OmXSTK/HbjQVuHu34XVNsedjvsNHh3/OOI= =yACN -----END PGP SIGNATURE----- --------------enig1077A6BD2152A8DFB1AF06AC-- From unknown Mon Jun 16 23:38:04 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 28 Apr 2011 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator