From owner-freebsd-questions@FreeBSD.ORG Tue Sep 13 14:53:26 2005 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0E94A16A41F for ; Tue, 13 Sep 2005 14:53:26 +0000 (GMT) (envelope-from x.chantry@wanadoo.fr) Received: from smtp11.wanadoo.fr (smtp11.wanadoo.fr [193.252.22.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3E02443D4C for ; Tue, 13 Sep 2005 14:53:24 +0000 (GMT) (envelope-from x.chantry@wanadoo.fr) Received: from me-wanadoo.net (localhost [127.0.0.1]) by mwinf1106.wanadoo.fr (SMTP Server) with ESMTP id BCC241C0008F for ; Tue, 13 Sep 2005 16:53:23 +0200 (CEST) Received: from ibm.maison (AFontenayssB-151-1-48-227.w82-121.abo.wanadoo.fr [82.121.93.227]) by mwinf1106.wanadoo.fr (SMTP Server) with SMTP id 8A1B01C000AF for ; Tue, 13 Sep 2005 16:53:23 +0200 (CEST) X-ME-UUID: 20050913145323565.8A1B01C000AF@mwinf1106.wanadoo.fr Date: Tue, 13 Sep 2005 16:53:22 +0200 From: Chantry Xavier To: freebsd-questions@freebsd.org Message-Id: <20050913165322.42db8a7b.x.chantry@wanadoo.fr> X-Mailer: Sylpheed version 2.0.1 (GTK+ 2.6.10; i686-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: cp fails copying file from ext2 partition 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: Tue, 13 Sep 2005 14:53:26 -0000 Hi, I've an external usb hard drive using ext2 filesystem, mounted in /mnt/usb (/dev/da0s1 on /mnt/usb (ext2fs, local)). I can't copy any non empty files from the ext2 partition to somewhere else (the ext2 partition itself or my local freebsd filesystem). # cd /mnt/usb # echo "foo" > file # cp file file2 cp: file: Invalid argument cp creates an empty file2 instead of a file containing "foo". If the source file is empty, cp creates an empty target file without displaying any errors. I tried with another ext2 partition I had on a local hard disk, it failed the same way. Note that mv works just fine, so as a workaround, I can move the file to my local hard disk, then copy it again to the ext2 partition. midnight commander works just fine too, I guess it isnt using cp directly, maybe cpio. Output of uname -a : FreeBSD mybox.maison 6.0-BETA4 FreeBSD 6.0-BETA4 #3: Sun Sep 11 18:01:53 CEST 2005 xav@mybox.maison:/usr/obj/usr/src/sys/MYKERNEL i386 Cheers, Xav