From owner-freebsd-questions Sat May 23 15:12:53 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id PAA10053 for freebsd-questions-outgoing; Sat, 23 May 1998 15:12:53 -0700 (PDT) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from lucy.bedford.net (lucy.bedford.net [206.99.145.54]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id PAA10024 for ; Sat, 23 May 1998 15:12:47 -0700 (PDT) (envelope-from listread@lucy.bedford.net) Received: (from listread@localhost) by lucy.bedford.net (8.8.8/8.8.8) id RAA29055; Sat, 23 May 1998 17:25:25 -0400 (EDT) (envelope-from listread) Message-Id: <199805232125.RAA29055@lucy.bedford.net> Subject: Re: Mounting another local disk In-Reply-To: from Ken Seggerman at "May 23, 98 01:40:26 pm" To: suleyman@echonyc.com (Ken Seggerman) Date: Sat, 23 May 1998 17:25:25 -0400 (EDT) Cc: freebsd-questions@FreeBSD.ORG Reply-to: djv@bedford.net From: CyberPeasant X-Mailer: ELM [version 2.4ME+ PL38 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Ken Seggerman wrote: > I have two hard disks, the first, /dev/rdw0 is 2GB and has Windows 95 and > FreeBSD 2.2.2 on it, in that order. > > The second /dev/rdw0 is 4GB and has FreeBSD 2.2.5 and Widnows NT on it. > > Now that I have 2.2.5 up and running, the FreeBSD 2.2.2 slice on /dev/rdw0 > is sort of wasted space. I intend at some point to get a hold of Partition > Magic and give the space back to Windows95. > > In the mean time, I would like to mount the 2.2.2 file system from 2.2.5, > but I am having a hard time with the mount command. > > I am assuming that what I want to do is perfectly do-able, but that I just > don't have the syntax to do so. > > #mkdir /disk1 > # mount -t ufs /dev/rwd0 /disk1 > /dev/rwd0 on /disk1: Block device required Yeah, r... is a raw device. > > > an fdisk of /dev/rwd0 looks like this: > > Warning: BIOS sector numbering starts with sector 1 > Information from DOS bootblock is: > The data for partition 1 is: > sysid 6,(Primary 'big' DOS (> 32MB)) > start 63, size 2927169 (1429 Meg), flag 0 > beg: cyl 0/ sector 1/ head 1; > end: cyl 362/ sector 63/ head 127 > The data for partition 2 is: > sysid 5,(Extended DOS) > start 4193280, size 798336 (389 Meg), flag 0 > beg: cyl 520/ sector 1/ head 0; > end: cyl 618/ sector 63/ head 127 > The data for partition 3 is: > sysid 165,(FreeBSD/NetBSD/386BSD) > start 2927232, size 1266048 (618 Meg), flag 0 > beg: cyl 363/ sector 1/ head 0; > end: cyl 519/ sector 63/ head 127 > The data for partition 4 is: > > > Thanks > Looks like your BSD partition is slice 3. So your mount command is going to look like: mount /dev/wd0s3X /disk1 Problem is, we need a value for X here, to pick the BSD partition within the slice. (ie a,b,c,d,.....) To list these partitons, use "disklabel". disklabel /dev/rwd0s3 Output will include at its end a description of the partitions: 8 partitions: # size offset fstype [fsize bsize bps/cpg] a: 131072 0 4.2BSD 0 0 0 # (Cyl. 0 - 8*) b: 262144 131072 swap # (Cyl. 8*- 24*) c: 2088450 0 unused 0 0 # (Cyl. 0 - 129) e: 144585 393216 4.2BSD 0 0 0 # (Cyl. 24*- 33) f: 1204875 537801 4.2BSD 0 0 0 # (Cyl. 33*- 108) g: 345774 1742676 4.2BSD 0 0 0 # (Cyl. 108*- 129*) [root@castor /root]# (from a disk of mine). so, to mount partitiion "e" of slice 3, mount /dev/wd0s3e /disk1 To mount other partitions, maybe make other mount points, or mount on a point brought in with a mount. (Confusing...) That disk just listed is my "root" disk: a is the / partition, b is swap, c is "whole slice" (not to be mounted), d is undefined, e is /var, f is /usr and g is /home To mount that whole thing on a mount point, I would do: mount /dev/wd0s3a /disk1 mount /dev/wd0s3e /disk1/var mount /dev/wd0s3f /disk1/usr mount /dev/wd0s3g /disk1/home Dave -- Is the true purpose of Unix its use, or its administration? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message