From owner-freebsd-fs@FreeBSD.ORG Sun Oct 23 06:45:29 2005 Return-Path: X-Original-To: freebsd-fs@FreeBSD.org Delivered-To: freebsd-fs@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7B93816A41F for ; Sun, 23 Oct 2005 06:45:29 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailout2.pacific.net.au (mailout2.pacific.net.au [61.8.0.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id D1F3443D45 for ; Sun, 23 Oct 2005 06:45:28 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailproxy1.pacific.net.au (mailproxy1.pacific.net.au [61.8.0.86]) by mailout2.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id j9N6jQER028829; Sun, 23 Oct 2005 16:45:26 +1000 Received: from katana.zip.com.au (katana.zip.com.au [61.8.7.246]) by mailproxy1.pacific.net.au (8.13.4/8.13.4/Debian-3) with ESMTP id j9N6jNp4001404; Sun, 23 Oct 2005 16:45:25 +1000 Date: Sun, 23 Oct 2005 16:45:24 +1000 (EST) From: Bruce Evans X-X-Sender: bde@delplex.bde.org To: Vulpes Velox In-Reply-To: <20051022162026.59e66eb6@vixen42.vulpes> Message-ID: <20051023150814.S11053@delplex.bde.org> References: <20051022162026.59e66eb6@vixen42.vulpes> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: freebsd-fs@FreeBSD.org Subject: Re: newfs_msdos oddity X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 23 Oct 2005 06:45:29 -0000 On Sat, 22 Oct 2005, Vulpes Velox wrote: > Running into one odd problem with Windows 2000. Apparently Windows > 2000 can read and install to a partition formated with FAT32 by > FreeBSD, but it can't boot it. > > Any one seen any thing odd like this before or have any suggestions? newfs_msdos was broken by GEOM. Try upgrading to FreeBSD-4 or determining the broken parameters manually and setting them on the command line: -o hidden (IIRC, this is just the offset of the subdevice relative to the whole disk; the latter should be given by a DICOGMEDIAOFFSET ioctl). newfs_msdos now almost always gets this wrong. -h heads -u track-size All utilities that deal with BIOS geometries are similarly broken and need similar workarounds. They need the BIOS geometry, but the kernel now only returns the firmware geometry. > I am installing it to a secondary drive in that box. Geometry problems probably only affect booting. In my tests, all versions of DOS and Windows tested (from DOS 4.01 to W95) had no problems recognizing or chkdsking the GEOMed file systems created by newfs_msdos, but I don't remember testing booting and may have done it only for floppies. At least some versions of DOS and/or Windows silently fix up the broken parameters if you run something like "sys d:" to make the disk bootable. This may give another workaround (or show that the bug is unreleated). FreeBSD fsck_msdosfs neither fixes nor finds the broken parameters. The commit log for the commit that cemented the breakage is: % RCS file: /home/ncvs/src/sbin/newfs_msdos/newfs_msdos.c,v % Working file: newfs_msdos.c % head: 1.20 % ---------------------------- % revision 1.19 % date: 2002/11/03 08:54:46; author: scottl; state: Exp; lines: +51 -85 % Bring newfs_msdos into the GEOM world. Totally rewrite and simplify % getdiskinfo(). For the fixed-disk case, bpb->hid probably isn't % handled correctly, but I'm not sure if this is a serious problem since % the primary use of this program is to format floppy disks. % % Reviewed by: phk % ---------------------------- getdiskinfo() actually needed considerable complications to work with GEOM. XML must be parsed to determine the number of hidden sectors, and the old kernel code for guessing the BIOS geometry from the DOS partition table and new or old kernel code for reading DOS partition tables must be cloned. For the fixed-disk case, bpb->hid isn't handled correctly with probablility 1-epsilon (bp->hid == 0 is only correct for the dangerously dedicated case, but WinDOS doesn't support this). The primary use of this program probably isn't to format floppy disks. I think its main use is now for flash disks. I last used it on a DVD+RW dangerously dedicated), and before that for running fs benchmarks on a FreeBSD partition on an ATA disk. Bruce From owner-freebsd-fs@FreeBSD.ORG Tue Oct 25 10:34:41 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4858716A420 for ; Tue, 25 Oct 2005 10:34:41 +0000 (GMT) (envelope-from deepak_nai@yahoo.com) Received: from web34614.mail.mud.yahoo.com (web34614.mail.mud.yahoo.com [209.191.68.148]) by mx1.FreeBSD.org (Postfix) with SMTP id 9D96A43D46 for ; Tue, 25 Oct 2005 10:34:40 +0000 (GMT) (envelope-from deepak_nai@yahoo.com) Received: (qmail 50507 invoked by uid 60001); 25 Oct 2005 10:34:40 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:Received:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=kFK2tKQmdMQmLYT9Shq+z3mkW8YJuTXnVQ8X0KxXKKo84ZBP17R6OM3zJwkYYva8woA4iID9/9Amba5tJjMuDMKut0ckAG76CQPC3jwXXVM0Vnc7OdW90MiQ2haapS+Le21WGe5SlJ/IyeEj14VwZkpndBUytgZPHP82z43KCbE= ; Message-ID: <20051025103440.50505.qmail@web34614.mail.mud.yahoo.com> Received: from [202.149.214.46] by web34614.mail.mud.yahoo.com via HTTP; Tue, 25 Oct 2005 11:34:40 BST Date: Tue, 25 Oct 2005 11:34:40 +0100 (BST) From: Deepak Naidu To: freebsd-questions@freebsd.org, freebsd-fs@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Cc: Subject: FileSystem Full error in FreeBSD 5.4-Release even if the partition is not full X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 25 Oct 2005 10:34:41 -0000 Hi, I dont know ? all the errors are bouncing on my FreeBSD mail server. A month ago I have ported my mail server from Linux to FreeBSD 5.4-Release. I get the below error in my /var/log/messages regarding the filesystem being full, whereas it is not full. Filesystem is not full at all, then why I am getting this error message, did any one faced this issue. Oct 25 14:58:30 kernel: pid 60077 (perl5.8.6), uid 125 inumber 50855 on /var/spool/MailScanner/incoming: filesystem full Oct 25 14:58:30 kernel: pid 60198 (perl5.8.6), uid 125 inumber 1051 on /var/spool/MailScanner/incoming: filesystem full Oct 25 14:58:30 kernel: pid 60151 (perl5.8.6), uid 125 inumber 50857 on /var/spool/MailScanner/incoming: filesystem full and also /var/spool filesystem ful error. #df -h Filesystem Size Used Avail Capacity Mounted on /dev/da0s1a 9.7G 576M 8.3G 6% / devfs 1.0K 1.0K 0B 100% /dev /dev/da0s1g 13G 4.2G 7.7G 35% /usr /dev/da0s1d 9.7G 232M 8.7G 3% /var /dev/da0s1e 19G 1.5G 16G 9% /var/log /dev/da0s1f 9.7G 968M 8.0G 11% /var/spool /dev/md1 1.4G 175M 1.1G 13% /var/spool/MailScanner/incoming devfs 1.0K 1.0K 0B 100% /var/named/dev #mount /dev/da0s1a on / (ufs, local) devfs on /dev (devfs, local) /dev/da0s1g on /usr (ufs, local, soft-updates) /dev/da0s1d on /var (ufs, local, soft-updates) /dev/da0s1e on /var/log (ufs, local, noatime, soft-updates) /dev/da0s1f on /var/spool (ufs, local, noatime, soft-updates) /dev/md1 on /var/spool/MailScanner/incoming (ufs, local, noatime, soft-updates) devfs on /var/named/dev (devfs, local) Is this a bug or anything falat. Cheers, Deepak Naidu. ___________________________________________________________ Yahoo! Messenger - NEW crystal clear PC to PC calling worldwide with voicemail http://uk.messenger.yahoo.com From owner-freebsd-fs@FreeBSD.ORG Tue Oct 25 11:47:44 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9F7B916A41F; Tue, 25 Oct 2005 11:47:44 +0000 (GMT) (envelope-from anderson@centtech.com) Received: from mh1.centtech.com (moat3.centtech.com [207.200.51.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3A7EF43D4C; Tue, 25 Oct 2005 11:47:43 +0000 (GMT) (envelope-from anderson@centtech.com) Received: from [10.177.171.220] (neutrino.centtech.com [10.177.171.220]) by mh1.centtech.com (8.13.1/8.13.1) with ESMTP id j9PBlgui070286; Tue, 25 Oct 2005 06:47:42 -0500 (CDT) (envelope-from anderson@centtech.com) Message-ID: <435E1B46.4030804@centtech.com> Date: Tue, 25 Oct 2005 06:47:18 -0500 From: Eric Anderson User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.12) Gecko/20051021 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Deepak Naidu References: <20051025103440.50505.qmail@web34614.mail.mud.yahoo.com> In-Reply-To: <20051025103440.50505.qmail@web34614.mail.mud.yahoo.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV 0.82/1146/Thu Oct 20 23:36:48 2005 on mh1.centtech.com X-Virus-Status: Clean Cc: freebsd-fs@freebsd.org, freebsd-questions@freebsd.org Subject: Re: FileSystem Full error in FreeBSD 5.4-Release even if the partition is not full X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 25 Oct 2005 11:47:44 -0000 Deepak Naidu wrote: > Hi, > > I dont know ? all the errors are bouncing on my > FreeBSD mail server. A month ago I have ported my > mail server from Linux to FreeBSD 5.4-Release. > > I get the below error in my /var/log/messages > regarding the filesystem being full, whereas it is not > full. > > Filesystem is not full at all, then why I am getting > this error message, did any one faced this issue. Can you send the output of df -i? I bet you ran out of inodes. Eric -- ------------------------------------------------------------------------ Eric Anderson Sr. Systems Administrator Centaur Technology Anything that works is better than anything that doesn't. ------------------------------------------------------------------------ From owner-freebsd-fs@FreeBSD.ORG Tue Oct 25 14:38:36 2005 Return-Path: X-Original-To: freebsd-fs@FreeBSD.ORG Delivered-To: freebsd-fs@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DB91B16A420 for ; Tue, 25 Oct 2005 14:38:36 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (lurza.secnetix.de [83.120.8.8]) by mx1.FreeBSD.org (Postfix) with ESMTP id D9E3B43D68 for ; Tue, 25 Oct 2005 14:38:30 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (ilclej@localhost [127.0.0.1]) by lurza.secnetix.de (8.13.1/8.13.1) with ESMTP id j9PEcSZL044586 for ; Tue, 25 Oct 2005 16:38:28 +0200 (CEST) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.13.1/8.13.1/Submit) id j9PEcSpc044585; Tue, 25 Oct 2005 16:38:28 +0200 (CEST) (envelope-from olli) Date: Tue, 25 Oct 2005 16:38:28 +0200 (CEST) Message-Id: <200510251438.j9PEcSpc044585@lurza.secnetix.de> From: Oliver Fromme To: freebsd-fs@FreeBSD.ORG In-Reply-To: X-Newsgroups: list.freebsd-fs User-Agent: tin/1.5.4-20000523 ("1959") (UNIX) (FreeBSD/4.11-RELEASE (i386)) Cc: Subject: Re: FileSystem Full error in FreeBSD 5.4-Release even if the partition is not full X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-fs@FreeBSD.ORG List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 25 Oct 2005 14:38:37 -0000 Deepak Naidu wrote: > I dont know ? all the errors are bouncing on my > FreeBSD mail server. A month ago I have ported my > mail server from Linux to FreeBSD 5.4-Release. > > I get the below error in my /var/log/messages > regarding the filesystem being full, whereas it is not > full. > > Filesystem is not full at all, then why I am getting > this error message, did any one faced this issue. > > > Oct 25 14:58:30 kernel: pid 60077 (perl5.8.6), uid 125 > inumber 50855 on /var/spool/MailScanner/incoming: > filesystem full If it says it is full, then it is full, probably. :-) > #df -h Try "df -i" -- what does it say? Best regards Oliver -- Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. "If Java had true garbage collection, most programs would delete themselves upon execution." -- Robert Sewell From owner-freebsd-fs@FreeBSD.ORG Wed Oct 26 03:10:38 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0E67F16A41F for ; Wed, 26 Oct 2005 03:10:38 +0000 (GMT) (envelope-from esheri3@tiger.towson.edu) Received: from mail3.towson.edu (mail3.towson.edu [136.160.180.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id A7CDA43D46 for ; Wed, 26 Oct 2005 03:10:37 +0000 (GMT) (envelope-from esheri3@tiger.towson.edu) Received: from tiger.towson.edu (tiger.towson.edu [136.160.180.166]) by mail3.towson.edu (8.13.4/8.13.4) with ESMTP id j9Q3AYQr015199 for ; Tue, 25 Oct 2005 23:10:34 -0400 (EDT) From: "Eric Sheridan" To: freebsd-fs@freebsd.org Date: Tue, 25 Oct 2005 23:10:34 -0400 Message-Id: <20051026025920.M65847@tiger.towson.edu> X-Mailer: Open WebMail 2.10 20030617 X-OriginatingIP: 69.143.98.150 (esheri3) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 X-Spam-Score: -2.303 () BAYES_00,DNS_FROM_RFC_WHOIS X-Spam-Status: No X-Scanned-By: MIMEDefang 2.52 on 10.4.0.41 Subject: UFS Inode Direct Blocks X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 Oct 2005 03:10:38 -0000 Hello Everyone: My name is Eric and I am working on a project which traverses the inodes of the disk in order to map out the file system. I am able to read in the superblock with the SBLOCK_UFS2 offset. I am able to read in any disk inode using the following offsets: ib = fsbtodb(superblock, itod(superblock, i_num)); lseek(fd, ib*DEV_BSIZE, SEEK_SET); read(fd, buffer, sizeof(buffer)); d = (struct ufs2_dinode *)buffer + itoo(superblock, i_num); *Note* I have defines for the itoo and itod to appropriate ino_to_*'s However, given the dinode, I do not know how to seek to the direct blocks of the dinode. My question is how do I seek to these direct blocks stored in di_db[] using all of these available macros? What is stored in these data blocks? If the inode represents a directory, then do the data blocks contain "struct ufs2_direct"s? If I am able to get file names from directory inodes, then I will be able to map out every file on the system. This is my first post, so I appologize for being either too vague or too verbose. Thank you everyone in advance for your help. -Eric Sheridan From owner-freebsd-fs@FreeBSD.ORG Wed Oct 26 06:29:31 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6569316A41F for ; Wed, 26 Oct 2005 06:29:31 +0000 (GMT) (envelope-from maxsec@gmail.com) Received: from xproxy.gmail.com (xproxy.gmail.com [66.249.82.200]) by mx1.FreeBSD.org (Postfix) with ESMTP id 26ABD43D4C for ; Wed, 26 Oct 2005 06:29:29 +0000 (GMT) (envelope-from maxsec@gmail.com) Received: by xproxy.gmail.com with SMTP id t13so179996wxc for ; Tue, 25 Oct 2005 23:29:29 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=MWpdFQq6nSVsZ5ZQ7uwxu3PVJd6iYsjPZ5p9itppFfSwKLsIcAP49yJhdto54Y4RmkUvdNpiJRKnL3OHhMTzWSyaP56ftzuOokmoRURYp1Bi82NmJmv7YclbZafQu4/EKb56RKCfwtp2R7YTMoIEl0ynfFMquDwYgVEHA57Q0ag= Received: by 10.64.180.16 with SMTP id c16mr413882qbf; Tue, 25 Oct 2005 23:29:29 -0700 (PDT) Received: by 10.64.209.20 with HTTP; Tue, 25 Oct 2005 23:29:29 -0700 (PDT) Message-ID: <72cf361e0510252329h60689e49udb78e3ba84699f6@mail.gmail.com> Date: Wed, 26 Oct 2005 07:29:29 +0100 From: Martin Hepworth To: Deepak Naidu In-Reply-To: <20051025103440.50505.qmail@web34614.mail.mud.yahoo.com> MIME-Version: 1.0 References: <20051025103440.50505.qmail@web34614.mail.mud.yahoo.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-fs@freebsd.org, freebsd-questions@freebsd.org Subject: Re: FileSystem Full error in FreeBSD 5.4-Release even if the partition is not full X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 Oct 2005 06:29:31 -0000 Hi Deepak check the inodes as others have suggested..... the /var/spool/MailScanner/incoming is should be empty (or nearly). This is just the work area for MS and should have much in there at all apart from the batches it's working right now.. MIght be worth check with me a JPK etc on the MS list .... -- Martin (at yet another email address) On 10/25/05, Deepak Naidu wrote: > > Hi, > > I dont know ? all the errors are bouncing on my > FreeBSD mail server. A month ago I have ported my > mail server from Linux to FreeBSD 5.4-Release. > > I get the below error in my /var/log/messages > regarding the filesystem being full, whereas it is not > full. > > Filesystem is not full at all, then why I am getting > this error message, did any one faced this issue. > > > Oct 25 14:58:30 kernel: pid 60077 (perl5.8.6), uid 125 > inumber 50855 on /var/spool/MailScanner/incoming: > filesystem full > > Oct 25 14:58:30 kernel: pid 60198 (perl5.8.6), uid 125 > inumber 1051 on /var/spool/MailScanner/incoming: > filesystem full > > Oct 25 14:58:30 kernel: pid 60151 (perl5.8.6), uid 125 > inumber 50857 on /var/spool/MailScanner/incoming: > filesystem full > > and also /var/spool filesystem ful error. > > #df -h > Filesystem Size Used Avail Capacity Mounted on > /dev/da0s1a 9.7G 576M 8.3G 6% / > devfs 1.0K 1.0K 0B 100% /dev > /dev/da0s1g 13G 4.2G 7.7G 35% /usr > /dev/da0s1d 9.7G 232M 8.7G 3% /var > /dev/da0s1e 19G 1.5G 16G 9% /var/log > /dev/da0s1f 9.7G 968M 8.0G 11% /var/spool > /dev/md1 1.4G 175M 1.1G 13% > /var/spool/MailScanner/incoming > devfs 1.0K 1.0K 0B 100% /var/named/dev > > > #mount > /dev/da0s1a on / (ufs, local) > devfs on /dev (devfs, local) > /dev/da0s1g on /usr (ufs, local, soft-updates) > /dev/da0s1d on /var (ufs, local, soft-updates) > /dev/da0s1e on /var/log (ufs, local, noatime, > soft-updates) > /dev/da0s1f on /var/spool (ufs, local, noatime, > soft-updates) > /dev/md1 on /var/spool/MailScanner/incoming (ufs, > local, noatime, soft-updates) > devfs on /var/named/dev (devfs, local) > > Is this a bug or anything falat. > > > Cheers, > Deepak Naidu. > > > > > > ___________________________________________________________ > Yahoo! Messenger - NEW crystal clear PC to PC calling worldwide with > voicemail http://uk.messenger.yahoo.com > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to " > freebsd-questions-unsubscribe@freebsd.org" > From owner-freebsd-fs@FreeBSD.ORG Wed Oct 26 14:23:18 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B460616A41F for ; Wed, 26 Oct 2005 14:23:18 +0000 (GMT) (envelope-from scottl@samsco.org) Received: from pooker.samsco.org (pooker.samsco.org [168.103.85.57]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0F83B43D46 for ; Wed, 26 Oct 2005 14:23:17 +0000 (GMT) (envelope-from scottl@samsco.org) Received: from [192.168.254.14] (imini.samsco.home [192.168.254.14]) (authenticated bits=0) by pooker.samsco.org (8.13.4/8.13.4) with ESMTP id j9QENGR8013579; Wed, 26 Oct 2005 08:23:16 -0600 (MDT) (envelope-from scottl@samsco.org) Message-ID: <435F9154.6040505@samsco.org> Date: Wed, 26 Oct 2005 08:23:16 -0600 From: Scott Long User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.7.7) Gecko/20050416 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Eric Sheridan References: <20051026025920.M65847@tiger.towson.edu> In-Reply-To: <20051026025920.M65847@tiger.towson.edu> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.4 required=3.8 tests=ALL_TRUSTED autolearn=failed version=3.1.0 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on pooker.samsco.org Cc: freebsd-fs@freebsd.org Subject: Re: UFS Inode Direct Blocks X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 Oct 2005 14:23:18 -0000 Eric Sheridan wrote: > Hello Everyone: > > My name is Eric and I am working on a project which traverses the inodes of > the disk in order to map out the file system. I am able to read in the > superblock with the SBLOCK_UFS2 offset. I am able to read in any disk inode > using the following offsets: > > ib = fsbtodb(superblock, itod(superblock, i_num)); > lseek(fd, ib*DEV_BSIZE, SEEK_SET); > read(fd, buffer, sizeof(buffer)); > d = (struct ufs2_dinode *)buffer + itoo(superblock, i_num); > > *Note* I have defines for the itoo and itod to appropriate ino_to_*'s > > However, given the dinode, I do not know how to seek to the direct blocks of > the dinode. My question is how do I seek to these direct blocks stored in > di_db[] using all of these available macros? What is stored in these data > blocks? If the inode represents a directory, then do the data blocks contain > "struct ufs2_direct"s? If I am able to get file names from directory inodes, > then I will be able to map out every file on the system. This is my first > post, so I appologize for being either too vague or too verbose. Thank you > everyone in advance for your help. > > -Eric Sheridan I'd highly recommend picking up a copy of 'The Design and Implementation of the FreeBSD 5.2 Operating System' by McKusick and Neville-Neil. Amoung other things, it contains about 50 high-quality pages on the design and operation of the UFS/FFS filesystem. But, to answer your specific questions: The direct block pointers in the inode contain block numbers that hold data. Reading these block numbers from the disk will return file data. The indirect block pointer points to a block on the disk which contains block pointers for data. You read this block, then you read each block pointed to inside of it to get data. The double indirect block pointer points to a block that contains a bunch of indirect blocks that contain pointers to data. The triple indirect block pointer ..... I don't recall what macros or subroutines can be used to simplify this, but you might want to look at the sources for libufs and fsck for hints. For directory data blocks, yes they contain an array of ufs2_dirent structures. Be aware when it comes to mapping out the filenames that multiple dirent structures might point to the same inode. This is a feature of the filesystem and is how hard-links work. Scott From owner-freebsd-fs@FreeBSD.ORG Thu Oct 27 20:02:24 2005 Return-Path: X-Original-To: fs@freebsd.org Delivered-To: freebsd-fs@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9264116A420 for ; Thu, 27 Oct 2005 20:02:24 +0000 (GMT) (envelope-from rick@snowhite.cis.uoguelph.ca) Received: from dargo.cs.uoguelph.ca (dargo.cs.uoguelph.ca [131.104.96.159]) by mx1.FreeBSD.org (Postfix) with ESMTP id D76DD43D45 for ; Thu, 27 Oct 2005 20:02:23 +0000 (GMT) (envelope-from rick@snowhite.cis.uoguelph.ca) Received: from snowhite.cis.uoguelph.ca (snowhite.cis.uoguelph.ca [131.104.48.1]) by dargo.cs.uoguelph.ca (8.13.1/8.13.1) with ESMTP id j9RK2MJR018402 for ; Thu, 27 Oct 2005 16:02:22 -0400 Received: (from rick@localhost) by snowhite.cis.uoguelph.ca (8.9.3/8.9.3) id QAA12616 for fs@freebsd.org; Thu, 27 Oct 2005 16:03:31 -0400 (EDT) Date: Thu, 27 Oct 2005 16:03:31 -0400 (EDT) From: rick@snowhite.cis.uoguelph.ca Message-Id: <200510272003.QAA12616@snowhite.cis.uoguelph.ca> To: fs@freebsd.org X-Scanned-By: MIMEDefang 2.52 on 131.104.96.159 Cc: Subject: FreeBSD5.4 nfsv4 server patch X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 Oct 2005 20:02:24 -0000 I've just put a patch on the ftp site at: ftp.cis.uoguelph.ca/pub/nfsv4/FreeBSD5.4-patch1.diffc that fixes the NFSVOPISLOCKED() macro to avoid panics and some fixes courtesy of Mr. Jeremy Mika, so that it will build on amd64. (Jeremy, the only part of this patch of interest to you is the NFSVOPISLOCKED() macro change.) Thanks Jeremy, rick ps: These changes will be in the FreeBSD6 tarball I'll create shortly after the FreeBSD6.0-Release1 is out. From owner-freebsd-fs@FreeBSD.ORG Sat Oct 29 18:59:41 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3A48016A41F for ; Sat, 29 Oct 2005 18:59:41 +0000 (GMT) (envelope-from gbenhaim@gmail.com) Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.198]) by mx1.FreeBSD.org (Postfix) with ESMTP id CDA8E43D45 for ; Sat, 29 Oct 2005 18:59:40 +0000 (GMT) (envelope-from gbenhaim@gmail.com) Received: by zproxy.gmail.com with SMTP id x3so627176nzd for ; Sat, 29 Oct 2005 11:59:38 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type; b=WuHFpUmP9z/3DEuDFJttCijA0hEa+w33ncuiRv+3k/l9GEDT0nwcW8YKhZIdTXLxGoKzL0XPlMzFInx+OIR7QaHzlSl4N0zwXNZm3ZkGSsOkNfKml7R4W6Qnc+VsXKAPGyYYvsLC/pp+6nGL6YFJc5ep1wkPtpPD7Mj2TVBdSXI= Received: by 10.37.15.73 with SMTP id s73mr1610897nzi; Sat, 29 Oct 2005 11:59:37 -0700 (PDT) Received: by 10.36.65.15 with HTTP; Sat, 29 Oct 2005 11:59:37 -0700 (PDT) Message-ID: Date: Sat, 29 Oct 2005 20:59:37 +0200 From: Gal Ben-Haim To: freebsd-fs@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: disklabel recovery X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Oct 2005 18:59:41 -0000 Hello, Im running FreeBSD 5.4 I accedently enabled swap on /dev/ad2s1c (raw label), this destroyed my disklabel, the data is still on the disk (after doing 'cat' on the /dev device). When I try to mount the filesystem I get: the mount is successful, but when I 'ls' the mount point I get bad file descriptor. I tried to create a new label with 'sysinstall', but the label which is created seems to be with invalid values. I tried running scan_ffs, after it read all the blocks on the disk it outputs 'input/output error. is there any way to reconstruct the label properly or access atleast some o= f the files ? From owner-freebsd-fs@FreeBSD.ORG Sat Oct 29 19:26:58 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B5A8916A420 for ; Sat, 29 Oct 2005 19:26:58 +0000 (GMT) (envelope-from arne_woerner@yahoo.com) Received: from web30310.mail.mud.yahoo.com (web30310.mail.mud.yahoo.com [68.142.200.103]) by mx1.FreeBSD.org (Postfix) with SMTP id 42F6843D45 for ; Sat, 29 Oct 2005 19:26:58 +0000 (GMT) (envelope-from arne_woerner@yahoo.com) Received: (qmail 26516 invoked by uid 60001); 29 Oct 2005 19:26:57 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:Received:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=iNSz+zQNo4/dse94qr9nhCcOP5PchGcjLL7cJ/AogKo2Zzo+fN9NrM1c6VAFsJkm0WckUbG3G98RFqTl8voNu6I1iz4JUCluOn9WbknrgtdLLkI9UB+9IGPdz4m8qOSucOWBiHUZmgQxVgOxImWIpVEeTvAFAeDFBxw8eFuFdIM= ; Message-ID: <20051029192657.26514.qmail@web30310.mail.mud.yahoo.com> Received: from [213.54.83.70] by web30310.mail.mud.yahoo.com via HTTP; Sat, 29 Oct 2005 12:26:57 PDT Date: Sat, 29 Oct 2005 12:26:57 -0700 (PDT) From: Arne "Wörner" To: Gal Ben-Haim , freebsd-fs@freebsd.org In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Cc: Subject: Re: disklabel recovery X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Oct 2005 19:26:58 -0000 --- Gal Ben-Haim wrote: > Im running FreeBSD 5.4 > I accedently enabled swap on /dev/ad2s1c (raw label), this > destroyed my disklabel, > Hmm... Maybe it overwrote some other areas, too? > When I try to mount the filesystem I get: the mount is > successful, > So "mount" thinks, that the filesystem is clean... Can you copy the whole disc to another disc? Maybe you should do a fsck on that file system (WARNING: THIS COULD CAUSE MORE DAMAGE TO THE FILESYSTEM!!!)? > I tried to create a new label with 'sysinstall', but the label > which is created seems to be with invalid values. > Hmm... Do you remember the old layout (roughly)? -Arne __________________________________ Yahoo! FareChase: Search multiple travel sites in one click. http://farechase.yahoo.com From owner-freebsd-fs@FreeBSD.ORG Sat Oct 29 19:42:23 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0650C16A420 for ; Sat, 29 Oct 2005 19:42:23 +0000 (GMT) (envelope-from gbenhaim@gmail.com) Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.204]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4BC4E43D46 for ; Sat, 29 Oct 2005 19:42:22 +0000 (GMT) (envelope-from gbenhaim@gmail.com) Received: by zproxy.gmail.com with SMTP id x3so630887nzd for ; Sat, 29 Oct 2005 12:42:19 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=X1y1uCl71TouBoWmBlC1puEJ+Cg+qM8BGfqRTAYOMfDsx2o9H11x+Zel1OdfbL8zXJumErbGdLFmPHuWLgErPdLZn1QiGvvw3kwHN2KCle60p/np5wnrQk5+PO8XyJ9U4pu/sB7Go8oj02KiOw6wjVNV54fZMiG2Cm6sS7VnH9w= Received: by 10.36.250.51 with SMTP id x51mr1659654nzh; Sat, 29 Oct 2005 12:42:19 -0700 (PDT) Received: by 10.36.65.15 with HTTP; Sat, 29 Oct 2005 12:42:19 -0700 (PDT) Message-ID: Date: Sat, 29 Oct 2005 21:42:19 +0200 From: Gal Ben-Haim To: freebsd-fs@freebsd.org In-Reply-To: <20051029192657.26514.qmail@web30310.mail.mud.yahoo.com> MIME-Version: 1.0 References: <20051029192657.26514.qmail@web30310.mail.mud.yahoo.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Re: disklabel recovery X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Oct 2005 19:42:23 -0000 i can see the data with 'cat /dev/ad2' but I can't do much with it. fdisk shows the partition properly (1 partition of the entire disk). I need to rebuild the disklabel from scratch somehow, it was only one partition on one slice. I have the old layout written.. On 10/29/05, Arne W=F6rner wrote: > > --- Gal Ben-Haim wrote: > > Im running FreeBSD 5.4 > > I accedently enabled swap on /dev/ad2s1c (raw label), this > > destroyed my disklabel, > > > Hmm... Maybe it overwrote some other areas, too? > > > When I try to mount the filesystem I get: the mount is > > successful, > > > So "mount" thinks, that the filesystem is clean... > Can you copy the whole disc to another disc? > Maybe you should do a fsck on that file system (WARNING: THIS > COULD CAUSE MORE DAMAGE TO THE FILESYSTEM!!!)? > > > I tried to create a new label with 'sysinstall', but the label > > which is created seems to be with invalid values. > > > Hmm... Do you remember the old layout (roughly)? > > -Arne > > > > > __________________________________ > Yahoo! FareChase: Search multiple travel sites in one click. > http://farechase.yahoo.com > -- Gal Ben-Haim, gbenhaim@gmail.com From owner-freebsd-fs@FreeBSD.ORG Sat Oct 29 20:40:19 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1D4A416A41F for ; Sat, 29 Oct 2005 20:40:19 +0000 (GMT) (envelope-from arne_woerner@yahoo.com) Received: from web30302.mail.mud.yahoo.com (web30302.mail.mud.yahoo.com [68.142.200.95]) by mx1.FreeBSD.org (Postfix) with SMTP id 7C17443D78 for ; Sat, 29 Oct 2005 20:40:06 +0000 (GMT) (envelope-from arne_woerner@yahoo.com) Received: (qmail 82847 invoked by uid 60001); 29 Oct 2005 20:40:05 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:Received:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=SDCXA/XWI0BKs6RmVBVr6w/EFFFcVhXbevnOtd2eyS42gv+j1ozh20i3QPUGMecHAHSwkLmFFzbPPKWqrnir5ae10Bsi+De1GkmwxsWbkV8l5m9z7ONsTHEPHQ8xAaCCERNzKH77qt+yVs5YjqgCF9YBV2yFZbaaleSfaQOz4jA= ; Message-ID: <20051029204005.82845.qmail@web30302.mail.mud.yahoo.com> Received: from [213.54.83.70] by web30302.mail.mud.yahoo.com via HTTP; Sat, 29 Oct 2005 13:40:05 PDT Date: Sat, 29 Oct 2005 13:40:05 -0700 (PDT) From: Arne "Wörner" To: Gal Ben-Haim , freebsd-fs@freebsd.org In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Cc: Subject: Re: disklabel recovery X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Oct 2005 20:40:19 -0000 --- Gal Ben-Haim wrote: > fdisk shows the partition properly (1 partition of the entire > disk). > That is expected, because the partition table should be outside the partitions... > I need to rebuild the disklabel from scratch somehow, it was > only one partition on one slice. > I have the old layout written.. > Ok... Then I would copy the damaged slice to another filesystem. e. g.: # dd if=/dev/ad2s1 of=/root/shoot.img Then I would do a fsck e. g.: # fsck /dev/ad2s1a The fsck should make the file system usable again. BUT: FSCK IS QUITE RUDE POSSIBLY... Some filenames might be lost, so that there will be some files in /lost+found (as far as I understood that procedure). -Arne __________________________________ Yahoo! FareChase: Search multiple travel sites in one click. http://farechase.yahoo.com From owner-freebsd-fs@FreeBSD.ORG Sat Oct 29 20:44:42 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 28E5616A41F for ; Sat, 29 Oct 2005 20:44:42 +0000 (GMT) (envelope-from gbenhaim@gmail.com) Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id A9A8343D45 for ; Sat, 29 Oct 2005 20:44:41 +0000 (GMT) (envelope-from gbenhaim@gmail.com) Received: by zproxy.gmail.com with SMTP id x3so635615nzd for ; Sat, 29 Oct 2005 13:44:41 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=U2j/rjL7K5DcLs4QkvtfPWhV8K9gGnnOIhbNXt9RLMwJxhvuJcAV9cPiEbQ0gcGvQbeOvUpFOImWVJ+zzH8t7yKR2nLnlOjNkiEAt70XzPdblwHNrQzLmgKXGEUJ0VFTYqhFyn9AnBHyO5Q0Xud44/8xxZupudtHFjkzPPrJQZE= Received: by 10.36.222.75 with SMTP id u75mr1681967nzg; Sat, 29 Oct 2005 13:44:41 -0700 (PDT) Received: by 10.36.65.15 with HTTP; Sat, 29 Oct 2005 13:44:41 -0700 (PDT) Message-ID: Date: Sat, 29 Oct 2005 22:44:41 +0200 From: Gal Ben-Haim To: freebsd-fs@freebsd.org In-Reply-To: <20051029204005.82845.qmail@web30302.mail.mud.yahoo.com> MIME-Version: 1.0 References: <20051029204005.82845.qmail@web30302.mail.mud.yahoo.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Re: disklabel recovery X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Oct 2005 20:44:42 -0000 but how do I rebuild the disklabel ? On 10/29/05, Arne W=F6rner wrote: > > --- Gal Ben-Haim wrote: > > fdisk shows the partition properly (1 partition of the entire > > disk). > > > That is expected, because the partition table should be outside > the partitions... > > > I need to rebuild the disklabel from scratch somehow, it was > > only one partition on one slice. > > I have the old layout written.. > > > Ok... > > Then I would copy the damaged slice to another filesystem. > e. g.: > # dd if=3D/dev/ad2s1 of=3D/root/shoot.img > > Then I would do a fsck > e. g.: > # fsck /dev/ad2s1a > > The fsck should make the file system usable again. > BUT: FSCK IS QUITE RUDE POSSIBLY... Some filenames might be lost, > so that there will be some files in /lost+found (as far as I > understood that procedure). > > -Arne > > > > > __________________________________ > Yahoo! FareChase: Search multiple travel sites in one click. > http://farechase.yahoo.com > -- Gal Ben-Haim, gbenhaim@gmail.com From owner-freebsd-fs@FreeBSD.ORG Sat Oct 29 20:56:22 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 555EF16A41F for ; Sat, 29 Oct 2005 20:56:22 +0000 (GMT) (envelope-from arne_woerner@yahoo.com) Received: from web30307.mail.mud.yahoo.com (web30307.mail.mud.yahoo.com [68.142.200.100]) by mx1.FreeBSD.org (Postfix) with SMTP id D490743D46 for ; Sat, 29 Oct 2005 20:56:21 +0000 (GMT) (envelope-from arne_woerner@yahoo.com) Received: (qmail 34582 invoked by uid 60001); 29 Oct 2005 20:56:21 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:Received:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=o8O3D6aOn5TT5Q3413wXa7pX1OgFPa4XW0YFgLqzMwEOEPuTp0bNB1xevTen+sMbrcpJUvBPvgoUbywVeFdqVQ9fYTBvzry0t+h7ITAsro+yGUiPb3T89NejsRuVRy85tZgMszmqmXDZ0T8WBuZB8lNY/jtg9GMtLeSHb01cL34= ; Message-ID: <20051029205621.34580.qmail@web30307.mail.mud.yahoo.com> Received: from [213.54.83.70] by web30307.mail.mud.yahoo.com via HTTP; Sat, 29 Oct 2005 13:56:20 PDT Date: Sat, 29 Oct 2005 13:56:20 -0700 (PDT) From: Arne "Wörner" To: Gal Ben-Haim , freebsd-fs@freebsd.org In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Cc: Subject: Re: disklabel recovery X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Oct 2005 20:56:22 -0000 --- Gal Ben-Haim wrote: > but how do I rebuild the disklabel ? > Hmm... What is the output of # bsdlabel /dev/ad2s1 ? Usually you could edit the disklabel with # bsdlabel -e /dev/ad2s1 You should leave slice "c" untouched and make "a" start at sector 16 and as big as possible -Arne __________________________________ Yahoo! FareChase: Search multiple travel sites in one click. http://farechase.yahoo.com From owner-freebsd-fs@FreeBSD.ORG Sat Oct 29 22:26:44 2005 Return-Path: X-Original-To: freebsd-fs@FreeBSD.ORG Delivered-To: freebsd-fs@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 96F2016A41F for ; Sat, 29 Oct 2005 22:26:44 +0000 (GMT) (envelope-from jp@devnull.cz) Received: from mail.mynet.cz (mail.mynet.cz [195.122.208.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0BDC343D46 for ; Sat, 29 Oct 2005 22:26:43 +0000 (GMT) (envelope-from jp@devnull.cz) Received: from [192.168.1.29] (r2g242.chello.upc.cz [62.245.70.242]) by mail.mynet.cz (8.12.11/8.12.11) with ESMTP id j9TMUcK7076168 (version=TLSv1/SSLv3 cipher=DHE-DSS-AES256-SHA bits=256 verify=NO) for ; Sun, 30 Oct 2005 00:30:39 +0200 (CEST) (envelope-from jp@devnull.cz) Date: Sun, 30 Oct 2005 00:26:35 +0200 (CEST) From: Jan Pechanec X-X-Sender: jp@axxem.in.idc.cz To: FreeBSD FS Mailing List Message-ID: <20051030000603.C11574@axxem.in.idc.cz> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: Subject: initial writes with soft-updates X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Oct 2005 22:26:44 -0000 hello all, could you please shed some light on this situation? When I create many files at once with soft updates enabled, I can see some initial writes (8 in this example) during the 1st second of the operation. After that, it's silent till the next sync() - which is expected. the whole operation takes 4-5 seconds on my not brand-new 500MHz machine so I just cannot understand those first writes. I know how soft updates work and that's why I can't understand it. The system is 5.3-RELEASE-p23, 128 MB RAM with 70 MB free at least, load is nearly zero - just the test running (load averages: 0.15, 0.03, 0.01). I don't think it's about version, I have to be missing something about soft updates, just don't know what it is. When I try it with just a few files (< 10), there is no immediate write. I'm looking into soft updates chapter of McKusick's book on FreeBSD right now and cannot find an answer there either. # time for i in `jot 1000`; do touch file-$i; done real 0m4.676s user 0m0.677s sys 0m3.931s # iostat -c 100 -d ad0 14.25 8 0.11 0.00 0 0.00 0.00 0 0.00 0.00 0 0.00 0.00 0 0.00 0.00 0 0.00 0.00 0 0.00 0.00 0 0.00 please CC: on me, I'm not already a member of this list. thank you, j. -- Jan Pechanec http://www.devnull.cz