From owner-freebsd-questions@FreeBSD.ORG Sat Dec 25 00:57:58 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5A1A7106566B for ; Sat, 25 Dec 2010 00:57:58 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by mx1.freebsd.org (Postfix) with ESMTP id DBA0C8FC17 for ; Sat, 25 Dec 2010 00:57:57 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1PWISH-0003US-4v for freebsd-questions@freebsd.org; Sat, 25 Dec 2010 01:57:53 +0100 Received: from ip72-210-73-134.mc.at.cox.net ([72.210.73.134]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 25 Dec 2010 01:57:53 +0100 Received: from jvk-list by ip72-210-73-134.mc.at.cox.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 25 Dec 2010 01:57:53 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-questions@freebsd.org From: Joe Kraft Followup-To: gmane.os.freebsd.questions Date: Fri, 24 Dec 2010 19:57:41 -0500 Lines: 41 Message-ID: References: <201012242042.21257.ken@mthelicon.com> Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: ip72-210-73-134.mc.at.cox.net User-Agent: KNode/4.4.7 Subject: Re: cpio misunderstanding? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Dec 2010 00:57:58 -0000 Pegasus Mc Cleaft wrote: >> If I try to run it manually on one of the files that fails, I get this: >> >> slug# echo "/usr/local/freesbie-fs/libexec/ld-elf.so.1" | cpio -dump -l >> -v /usr/local/freesbie-clone >> >> /usr/local/freesbie-clone/usr/local/freesbie-fs/libexec/ld-elf.so.1 >> >> cpio: Can't create '/usr/local/freesbie-clone/usr/local/freesbie- >> fs/libexec/ld-elf.so.1': Operation not permitted >> 0 blocks >> >> >> I can use cp to copy the file, so I don't understand what's going on >> here. Does anyone have any ideas? > > I don't know if this is your problem, but whenever I see that "Operation > not permitted" error I start to suspect file flags. You might want to > check for extra flags put on the source file or destination directory and > see if anything weird had been set on it. > > You can look at the flags with the command "ls -lao". You may also want > to do a "man chflags" and read the manual page there. > OK, now I know what's going on. I just don't know why. The immutable flag was set on all these files, if you clear it cpio will happily copy them to the new directory. I'm guessing it's a change in how the installation copies the files with the schg intact, I ran into a discussion about that from 2008. The original FreeSBIE scripts were based on FBSD 6.2 and maybe never ran into this issue. I don't quite get why this works this way though. I understand the immutable flag will keep the file itself from being changed, deleted or moved. But I don't see in any documentation that the immutable flag will not allow a file to be copied. I did note that when using the 'cp' command it cleared the immutable bit on the new file instead of keeping it, but at least it makes the copy. Joe.