From: Bela Lubkin <belal@sco.com> Subject: Re: Swapping a hd in 5.0.6 Date: Thu, 14 Nov 2002 09:33:41 GMT References: <20021108112935.A9421@egps.egps.com>
<20021109164949.05596@tegan.com>
<20021109193812.A24538@egps.egps.com>
<20021109204029.17968@tegan.com>
<20021110164846.A1171@egps.egps.com> Nachman Yaakov Ziskind wrote: > So, last night, while working from home, feeling dreary, pondering Tom's > admonition to make sure I was looking at the right drive (and darn it, I WAS > looking at the right drive), and then I saw it: > > Current Hard Disk Drive: /dev/rdsk/3s0 > > +-------------+----------+-----------+---------+---------+---------+ > | Partition | Status | Type | Start | End | Size | > +-------------+----------+-----------+---------+---------+---------+ > | 1 | Active | UNIX | 1 | 281774 | 281774 | > +-------------+----------+-----------+---------+---------+---------+ > > Total disk size: 2258025 tracks (256 reserved for masterboot and diagnostics) > > At which point, I noticed the "Total disk size:" DUH! Perhaps the 'tracks' it > is counting is not the same as the Start/End figures? I did some feverish > reading on the fdisk man page and decided that, no, tracks are tracks, and > fdisk is only looking at 12% of the drive. I selected "Use Entire > Disk for UNIX", and (after a scary warning) got: > > | 1 | Active | UNIX | 1 | 2257769 | 2257769 |
During the hot-swap episode, you caused a copy of the old disk's fdisk table to be written to the new disk. You did _not_ do anything to overwrite the new disk's proper geometry. fdisk tables are expressed in linear block numbers; in effect you laid down a table that gave partition #1 exactly as much space as it had on the old disk (and thus only a fraction of the new disk). (Actually, for SCSI disks, OpenServer only cares about the "sectors/track" and "heads" geometry parameters; it determines the "tracks" parameter by dividing total disk size by those two. So you could not have "damaged" the total disk size by writing a wrong parameter table.) > Which looked MUCH better. So, letting the dice roll, I ran divvy, and got the > same division table as before, with one small difference: > > 71111722 1K blocks for divisions, 8001 1K blocks reserved for the system > > Which I picked up on right away. :-) I thought I'd just expand the last block > of the first filesystem to 71111722, umount and mount, and away I'd go. > > But no, the filesystem stayed at 9gig in df -vk. Changing the boundaries of an HTFS filesystem doesn't have any effect on its internal structures, which tell it that it ends at the old boundary. If you have a house and you buy the vacant lot next door, it doesn't make your house any bigger -- you would have to build an addition or rip it down and build a bigger one. John DuBois has a utility for building that addition, at ftp://ftp.armory.com/pub/admin/chfssize (danger: this is a utility for People Who Know What They Are Doing And Have Made Good Backups). Otherwise you tear down and rebuild, as you did. > After more head scratching, I > decided to remove all the first division entirely, and reinput the numbers. What you wanted was divvy's "c[reate] Create a new file system on this division." choice. You probably used that, since changing boundaries does not automatically prompt divvy to create a filesystem. It didn't occur to you to just use "c[reate]", but it was obvious to you that after moving the boundaries you needed to do that.
> Much happier! Divvy declared: > > Making Filesystems > > and mkfs sat there for a most satisfying five or ten minutes, and I was now up > to 73gig, Woo-hoo! Yay! >Bela<
Have you tried Searching this site?
Unix/Linux/Mac OS X support by phone, email or on-site: Support Rates
This is a Unix/Linux resource website. It contains technical articles about Unix, Linux and general computing related subjects, opinion, news, help files, how-to's, tutorials and more. We appreciate comments and article submissions.
Many of the products and books I review are things I purchased for my own use. Some were given to me specifically for the purpose of reviewing them. I resell or can earn commissions from the sale of some of these items. Links within these pages may be affiliate links that pay me for referring you to them. That's mostly insignificant amounts of money; whenever it is not I have made my relationship plain. I also may own stock in companies mentioned here. If you have any question, please do feel free to contact me.
Specific links that take you to pages that allow you to purchase the item I reviewed are very likely to pay me a commission. Many of the books I review were given to me by the publishers specifically for the purpose of writing a review. These gifts and referral fees do not affect my opinions; I often give bad reviews anyway.
We use Google third-party advertising companies to serve ads when you visit our website. These companies may use information (not including your name, address, email address, or telephone number) about your visits to this and other websites in order to provide advertisements about goods and services of interest to you. If you would like more information about this practice and to know your choices about not having this information used by these companies, click here.
Click here to add your comments
Don't miss responses! Subscribe to Comments by RSS or by Email
Click here to add your comments
If you want a picture to show with your comment, go get a Gravatar