From owner-freebsd-stable@FreeBSD.ORG Thu Sep 22 15:21:43 2011 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CA4B3106566B for ; Thu, 22 Sep 2011 15:21:43 +0000 (UTC) (envelope-from cochard@gmail.com) Received: from mail-qy0-f182.google.com (mail-qy0-f182.google.com [209.85.216.182]) by mx1.freebsd.org (Postfix) with ESMTP id 887C28FC18 for ; Thu, 22 Sep 2011 15:21:43 +0000 (UTC) Received: by qyk4 with SMTP id 4so3092468qyk.13 for ; Thu, 22 Sep 2011 08:21:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:sender:from:date:x-google-sender-auth:message-id :subject:to:content-type; bh=mTmZkfmVESuJ6PCocb4Pkinc/ewAe6lJejAB69Mq26c=; b=sGpVRjcomXxk0x5f+VctctacEcdCKDolO/DLag9C3OvkA1FskALG1G5AkVFOwvx3u5 cxBBKTfwOygqVnO+sBQ7L5N8coXaHTnE+W13aVRxM4VC3lHlcgI//z0b64lXDfQiXIRS TAAi6mF1QnUtAzK0TN+mTbNw/R2kjE/OPadkY= Received: by 10.229.28.201 with SMTP id n9mr1758668qcc.68.1316703282100; Thu, 22 Sep 2011 07:54:42 -0700 (PDT) MIME-Version: 1.0 Sender: cochard@gmail.com Received: by 10.229.80.13 with HTTP; Thu, 22 Sep 2011 07:54:22 -0700 (PDT) From: =?ISO-8859-1?Q?Olivier_Cochard=2DLabb=E9?= Date: Thu, 22 Sep 2011 16:54:22 +0200 X-Google-Sender-Auth: 5riPtvK32iK4F3H-AyjE0KLOZQM Message-ID: To: freebsd-stable@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Subject: cpio and directory owner preservation behaviour X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 22 Sep 2011 15:21:43 -0000 Hi all, I meet a problem with cpio and I would to know if it's a normal behaviour or a bug. I would to save some files and create directories if needed with owner and permission kept. here is an example with net/quagga: I would to save /usr/local/etc/quagga/ripd.conf and creating needed directory in /tmp [root@R3]/#ls -alh /usr/local/etc | grep quagga drwxr-xr-x 2 quagga quagga 512B Sep 22 15:28 quagga [root@R3]/#ls -alh /usr/local/etc/quagga/ripd.conf -rw------- 1 quagga quagga 134B Sep 22 15:28 quagga/ripd.conf [root@R3]/#(cd /usr/local/etc; find . -name ripd.conf -type f | cpio -dumpv /tmp/) The file owner and permission for ripd.conf is keept: [root@R3]/#ls -alh /tmp/quagga/ripd.conf -rw------- 1 quagga quagga 134B Sep 22 15:28 /tmp/quagga/ripd.conf But not the directory owner that is changed to root:wheel [root@R3]/#ls -alh /tmp | grep quagga drwxr-xr-x 2 root wheel 512B Sep 22 16:41 quagga Is a cpio bug ? Thanks, Olivier