From owner-freebsd-questions Sat Feb 22 13: 9:34 2003 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 2B39C37B401 for ; Sat, 22 Feb 2003 13:09:32 -0800 (PST) Received: from smtp.infracaninophile.co.uk (happy-idiot-talk.infracaninophile.co.uk [81.2.69.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id 636E943F3F for ; Sat, 22 Feb 2003 13:09:30 -0800 (PST) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost [127.0.0.1]) by smtp.infracaninophile.co.uk (8.12.7/8.12.7) with ESMTP id h1ML9O5U008090 for ; Sat, 22 Feb 2003 21:09:24 GMT (envelope-from matthew@happy-idiot-talk.infracaninophile.co.uk) Received: (from matthew@localhost) by happy-idiot-talk.infracaninophile.co.uk (8.12.7/8.12.7/Submit) id h1ML9OZ5008089 for FreeBSD-Questions@FreeBSD.ORG; Sat, 22 Feb 2003 21:09:24 GMT Date: Sat, 22 Feb 2003 21:09:24 +0000 From: Matthew Seaman To: FreeBSD - Questions Subject: Re: Using mount... (newbie-ness) Message-ID: <20030222210924.GA7546@happy-idiot-talk.infracaninophi> Mail-Followup-To: Matthew Seaman , FreeBSD - Questions References: <001301c2da8f$ad810ed0$1508060a@furrie.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <001301c2da8f$ad810ed0$1508060a@furrie.net> User-Agent: Mutt/1.5.3i X-Spam-Status: No, hits=-2.7 required=5.0 tests=IN_REP_TO,QUOTED_EMAIL_TEXT,REFERENCES,SPAM_PHRASE_03_05, USER_AGENT,USER_AGENT_MUTT version=2.44 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sat, Feb 22, 2003 at 04:30:14PM -0000, Chris Phillips wrote: > Hi, > > I have read man mount & googled lots but I am at a loss as how to mount > the 2 partitions on my 2nd hard disk. > > I've created 2 new partitions on it: /dev/ad1s1b (swap) and /dev/ad1s1e > /data (ufs) > > Ideally, I'd like to mount both the swap & the /data partition, then use > "mount -p" to give me the correct format of the required /etc/fstab > entries... I am stumbling at the first step unfortunately :-( > > aphrodite# uname -a > FreeBSD aphrodite.furrie.net 4.8-PRERELEASE FreeBSD 4.8-PRERELEASE #1: > Thu Feb 20 23:27:51 GMT 2003 > furrie@aphrodite.furrie.net:/usr/obj/usr/src/sys/APHRODITE i386 > > aphrodite# dmesg (somewhat snipped) > ad0: 19092MB [38792/16/63] at ata0-master UDMA66 > ad1: 114473MB [232581/16/63] at ata0-slave UDMA66 > Mounting root from ufs:/dev/ad0s1a > > aphrodite# mount /dev/ad1s1e /data > mount: /dev/ad1s1e on /data: incorrect super block > Right. First of all, swap partitions aren't "mounted" as such. You just have to tell the system to start swapping onto the partition: # swapon /dev/ad1s1b To make that happen automatically on reboots, add a line like so to /etc/fstab: /dev/ad1s1b none swap sw 0 0 In order to mount your /data partition, either you need to tell the mount command all the parameters it needs: # mount -t ufs -o rw /dev/ad1s1e /data or you need to enter the equivalent data into /fstab so that mount can look up what it needs to know there. There are some other fields in fstab that 'mount -p' will give default values, but that you'll probably want to set to something useful. Try something like this in fstab: /dev/ad1s1e /data ufs rw 2 2 Oh, and do make sure you've created a filesystem on the partition before you try and mount it.. # newfs /dev/ad1s1e Cheers, Matthew -- Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way PGP: http://www.infracaninophile.co.uk/pgpkey Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message