From owner-freebsd-current@FreeBSD.ORG Fri Jul 17 00:12:34 2009 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CBC2F10656DC; Fri, 17 Jul 2009 00:12:34 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from esa-annu.mail.uoguelph.ca (esa-annu.mail.uoguelph.ca [131.104.91.36]) by mx1.freebsd.org (Postfix) with ESMTP id 6E3578FC15; Fri, 17 Jul 2009 00:12:34 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApoEAOteX0qDaFvH/2dsb2JhbADSAoQNBYFA X-IronPort-AV: E=Sophos;i="4.42,414,1243828800"; d="scan'208";a="39627617" Received: from danube.cs.uoguelph.ca ([131.104.91.199]) by esa-annu-pri.mail.uoguelph.ca with ESMTP; 16 Jul 2009 20:12:33 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by danube.cs.uoguelph.ca (Postfix) with ESMTP id B53F61084613; Thu, 16 Jul 2009 20:12:33 -0400 (EDT) X-Virus-Scanned: amavisd-new at danube.cs.uoguelph.ca Received: from danube.cs.uoguelph.ca ([127.0.0.1]) by localhost (danube.cs.uoguelph.ca [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tkV0oeV8mosV; Thu, 16 Jul 2009 20:12:32 -0400 (EDT) Received: from muncher.cs.uoguelph.ca (muncher.cs.uoguelph.ca [131.104.91.102]) by danube.cs.uoguelph.ca (Postfix) with ESMTP id 354FD108460E; Thu, 16 Jul 2009 20:12:32 -0400 (EDT) Received: from localhost (rmacklem@localhost) by muncher.cs.uoguelph.ca (8.11.7p3+Sun/8.11.6) with ESMTP id n6H0FTI11873; Thu, 16 Jul 2009 20:15:29 -0400 (EDT) X-Authentication-Warning: muncher.cs.uoguelph.ca: rmacklem owned process doing -bs Date: Thu, 16 Jul 2009 20:15:29 -0400 (EDT) From: Rick Macklem X-X-Sender: rmacklem@muncher.cs.uoguelph.ca To: Anonymous In-Reply-To: <86zlb45px8.fsf@gmail.com> Message-ID: References: <86zlb45px8.fsf@gmail.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: Rick Macklem , freebsd-current@freebsd.org Subject: Re: [newnfs/client] SIGINFO aborts transfer and produces `permission denied' X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Jul 2009 00:12:35 -0000 On Fri, 17 Jul 2009, Anonymous wrote: > Let's populate /blah with 50Mb files and send SIGINFO to cp(1) process while > copying it over nfsv3. > > # uname -vm > FreeBSD 8.0-BETA1 #0: Sat Jul 4 03:55:14 UTC 2009 > root@almeida.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386 > > # mkdir /blah > # truncate -s50m /blah/foo_1 > # truncate -s50m /blah/foo_2 > # truncate -s50m /blah/foo_3 > > # echo /usr >/etc/exports > # /etc/rc.d/nfsd onestart > # mount -t newnfs -o nfsv3 0:/blah /mnt > > # cp -R /mnt /aaa > [type ^T several times] > load: 0.81 cmd: cp 2305 [runnable] 1.86r 0.00u 0.62s 9% 1304k > /mnt/foo_1 -> /aaa/foo_1 25% > load: 0.90 cmd: cp 2305 [runnable] 2.43r 0.00u 0.80s 9% 1304k > /mnt/foo_1 -> /aaa/foo_1 32% > load: 0.90 cmd: cp 2305 [runnable] 2.59r 0.00u 0.85s 19% 1304k > /mnt/foo_1 -> /aaa/foo_1 34% > load: 0.90 cmd: cp 2305 [runnable] 2.76r 0.01u 0.89s 19% 1304k > /mnt/foo_1 -> /aaa/foo_1 36% > load: 0.90 cmd: cp 2305 [runnable] 2.96r 0.02u 0.94s 19% 1304k > /mnt/foo_1 -> /aaa/foo_1 39% > load: 0.90 cmd: cp 2305 [runnable] 3.14r 0.02u 1.00s 19% 1304k > /mnt/foo_1 -> /aaa/foo_1 41% > load: 0.90 cmd: cp 2305 [newnfsreq] 3.30r 0.02u 1.05s 19% 1304k > load: 0.90 cmd: cp 2305 [runnable] 3.47r 0.02u 1.08s 19% 1304k > load: 0.90 cmd: cp 2305 [runnable] 3.62r 0.02u 1.11s 19% 1304k > load: 0.90 cmd: cp 2305 [runnable] 3.81r 0.02u 1.14s 19% 1304k > load: 0.90 cmd: cp 2305 [runnable] 3.98r 0.02u 1.17s 19% 1304k > load: 0.90 cmd: cp 2305 [runnable] 4.29r 0.02u 1.22s 19% 1304k > load: 1.23 cmd: cp 2305 [runnable] 4.84r 0.02u 1.35s 19% 1304k > load: 1.23 cmd: cp 2305 [runnable] 5.19r 0.02u 1.49s 19% 1304k > load: 1.23 cmd: cp 2305 [runnable] 5.52r 0.02u 1.63s 19% 1304k > load: 1.23 cmd: cp 2305 [runnable] 6.12r 0.02u 1.88s 19% 1304k > load: 1.23 cmd: cp 2305 [runnable] 6.52r 0.02u 2.05s 19% 1304k > load: 1.23 cmd: cp 2305 [runnable] 6.89r 0.02u 2.19s 19% 1304k > load: 1.69 cmd: cp 2305 [runnable] 7.40r 0.02u 2.40s 29% 1304k > load: 1.69 cmd: cp 2305 [runnable] 7.76r 0.02u 2.55s 29% 1304k > load: 1.69 cmd: cp 2305 [runnable] 8.11r 0.02u 2.70s 29% 1304k > cp: /mnt/foo_1: Permission denied > cp: /mnt/foo_2: Permission denied > cp: /mnt/foo_3: Permission denied > > This one should be slightly harder to reproduce. And depending on timing > between each ^T keypress error message can differ, e.g. `Bad address' or > `Input/output error'. Of course not all files end up in /aaa > > # ls -l /aaa > total 32912 > -rw-r--r-- 1 root wheel 33685504 Jul 16 20:26 foo_1 > (this file is from different attempt, not that was aborted around 41%) > > It affects both foreground and background processes. So, to abort copying > one can also try running > > # pkill -INFO cp > > several times. I haven't found any other signal that affect copying > (tried SIGURG, SIGCONT, SIGCHLD, SIGIO, SIGWINCH). > > Known? Or am I the only one having a bad habit typing ^T too often? > Kostik recently checked in some changes related to signal handling, but I haven't yet had time to clone that for the experimental client. If the problem doesn't occur for the regular client, then I'll guess that cloning his changes to the experimental client will fix it. rick