8.0-RELEASE and "dangerously dedicated" disks

Jerry McAllister jerrymc at msu.edu
Tue Dec 1 21:22:43 UTC 2009


On Tue, Dec 01, 2009 at 07:59:42AM -0500, Maxim Khitrov wrote:

> On Sat, Nov 28, 2009 at 12:28 PM, Peggy Wilkins <enlil65 at gmail.com> wrote:
> > Can someone elaborate on what exactly this statement in the 8.0
> > detailed release notes means?
> >
> > http://www.freebsd.org/releases/8.0R/relnotes-detailed.html#FS
> >
> >> 2.2.5 File Systems
> >>
> >> ???dangerously dedicated??? mode for the UFS file system is no longer supported.
> >>
> >>  Important: Such disks will need to be reformatted to work with this release.
> >
> > Due to history I won't go into, all my production (currently
> > 7.2-RELEASE) systems are installed onto "dangerously dedicated" disks.
> >  What exactly do I need to do to upgrade them to 8.0?  (I'm not asking
> > for an upgrade procedure, I'm familiar with that, but rather, how this
> > change impacts the upgrade.)  I think that the suggestion that the
> > disks need to be reformatted is extreme and I hope something less
> > extreme will suffice.
> >
> > Also, just to be clear, does this statement refer to boot disks, data
> > disks, or both?
> >
> > It doesn't make sense to me that "dangerously dedicated" could have an
> > impact on UFS filesystems specifically.  A partition table is just a
> > partition table, regardless of what filesystems might be written on
> > disks, yes?  Am I misunderstanding something here?

I don't know why it would have an affect, but they say it does.

I take this to mean that any disk that is created without slice
and partition within slice needs to be redone.    Probably it can all
be done in sysinstall, but you can do it with fdisk/bsdlabel/newfs.

It does not matter if it is a boot disk or just a data disk.  It
is whether or not it has a (one or more, up to 4) slice defined
and within the slice[s] partitions defined which are turned in to
filesystems.   You can tell by the dev names in /etc/fstab.

If they have the full device name  /dev/da0s1a, ... da0s1h, they
are NOT dangerously dedicated and you should not have to worry.

If the machine is dual booted with some MS thing as the other OS, then
it is very unlikely that they are dangerously dedicated.

But, if they are like  /dev/da0  or  /dev/da0s1  (but with no 'a, b..h')
then they are dangerously dedicated and you need to convert them.

First you would have to back up the contents of the disk, partition
by partition (mountable filesystem by mountable filesystem) however
you have it.   Since it is 'dangerously dedicated' it is likely you
have a single filesystem per disk that needs backing up.    
Check out that backup to make sure it is readable.   There is no
going back.   The backup can be done to tape or USB external disk
or network or any other media that will not be affected, has room
and can be written and read from the FreeBSD system.

Then, boot a FreeBSD system that does not have the disk in question mounted.
Probably you will need to use a 'fixit' image from the install CDs.

Just for example, lets say, once your are booted, the disk to be
converted shows up as /dev/ad1 and that it was all in one file system
and that you want it to continue to be all in one file system.

Do the following:
(This makes a bootable drive and bootable partition with 
the standard FreeBSD MBR)
(The dd-s just make sure old stuff is cleared)


  dd if=/dev/zero of=/dev/ad1 bs=512 count=1025
  fdisk -BI ad1
  dd if=/dev/zero of=/dev/ad1s1 bs=512 count=1025
  bsdlabel -w -B ad1s1
  bsdlabel -e ad1s1

The last bsdlabel command will bring up an edit screen.
I suggest that you make at least some swap on this disk.
So, you will want partition 'b' for swap and partition 'a' for
everything else.  Edit the partition label so it looks like:

  # /dev/ad0s3:
  8 partitions:
  #        size   offset    fstype   [fsize bsize bps/cpg]
    a: 87295322        0    4.2BSD    2048 16384 49160
    b:        *        *      swap
    c: 89867610        0    unused       0     0     # "raw" part, don't edit

Those sizes are just an example.  Use sizes that fit your disk.
Using a * as the last size means it will use all remaining disk
and the * in offset means it will calculate it properly.
Of course, don't do anything to the 'c' line.

Once that is done, newfs the partition to make a filesystem.

  newfs /dev/ad1s1a

Note that fdisk and bsdlabel do not need the full path.  They figure
it out.   But, the last I knew, newfs still does.    Probably the
defaults on newfs will work just fine.   If you have huge numbers 
of tiny files you might want to adjust '-i' bytes per inode to increase
number of inodes.  You might also want to turn on softupdates with '-U'.


////jerry


> >
> > Thanks for helping to clear up my confusion...
> >
> > plw
> 
> Peggy,
> 
> Were you able to find an answer for this? I also have a number of
> servers and firewalls that use dangerously dedicated disks (boot and
> data). I don't see why UFS would care if it's mounted from ad1a vs.
> ad1s1a.
> 
> - Max
> _______________________________________________
> freebsd-questions at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to "freebsd-questions-unsubscribe at freebsd.org"
> 


More information about the freebsd-questions mailing list