Re: Using mount... (newbie-ness)

2003-02-22 Thread Josh Paetzel
On Sat, Feb 22, 2003 at 04:30:14PM -, 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
 [EMAIL PROTECTED]:/usr/obj/usr/src/sys/APHRODITE  i386
 
 aphrodite# dmesg (somewhat snipped)
 ad0: 19092MB WDC WD200EB-00BHF0 [38792/16/63] at ata0-master UDMA66
 ad1: 114473MB WDC WD1200BB-00CAA1 [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
 
 Can somebody please give me a clue?
 
 Many thanks!
 
 Chris Phillips
 

Did you newfs /dev/ad1s1e?

Josh

To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message


Re: Using mount... (newbie-ness)

2003-02-22 Thread Matthew Seaman
On Sat, Feb 22, 2003 at 04:30:14PM -, 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
 [EMAIL PROTECTED]:/usr/obj/usr/src/sys/APHRODITE  i386
 
 aphrodite# dmesg (somewhat snipped)
 ad0: 19092MB WDC WD200EB-00BHF0 [38792/16/63] at ata0-master UDMA66
 ad1: 114473MB WDC WD1200BB-00CAA1 [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 [EMAIL PROTECTED]
with unsubscribe freebsd-questions in the body of the message