[vox-tech] resizing harddrive

Samuel Merritt vox-tech@lists.lugod.org
Thu, 27 Feb 2003 23:47:59 -0800


--zaRBsRFn0XYhEU69
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Thu, Feb 27, 2003 at 10:26:40PM -0800, Ryan wrote:
> okay so after backing everything up for 4 hours I did what you said:
>=20
> The partition is indeed bigger, but not was large as I had expected. It s=
ays I
> only have about 36GB free. Here is a df

When Linux says "gigabyte", it means 2^30 bytes. When hard drive
manufacturers say "gigabyte", they mean 10^9 bytes.=20

You say this is labeled as a 40 GB drive; those are marketing gigabytes.
To convert to "real"* gigabytes, multiply by 10^9/2^30 and get 37.25
gigabytes. Your filesystem has 36.97 GB worth of blocks for data, and
the rest goes to overhead.=20

Looks like the resize worked just fine to me.=20

* There's some contention over this; I say a real gigabyte is 2^30
bytes.=20
=20
> Filesystem           1k-blocks      Used Available Use% Mounted on
> /dev/hdb1             38769320     32828  36782588   1% /home/media
>=20
> -ryan
>=20
>=20
> ----- Original Message -----
> From: "Mike Simons" <msimons@moria.simons-clan.com>
> To: <vox-tech@lists.lugod.org>
> Sent: Thursday, February 27, 2003 4:15 PM
> Subject: Re: [vox-tech] resizing harddrive
>=20
>=20
> > On Thu, Feb 27, 2003 at 02:52:48PM -0800, ryan wrote:
> > > this but the drive is a 40GB slave that I'm using to
> > > store mpegs and such. All those commands worked and here is the outpu=
t.
> >
> > Very good... the output explained what's happening.
> >
> >   It turns out that Linux has no problem accessing all of the
> > drive.
> >
> > ## Disk /dev/hdb: 255 heads, 63 sectors, 4865 cylinders
> > ## Units =3D cylinders of 16065 * 512 bytes
> > ##
> > ##    Device Boot    Start       End    Blocks   Id  System
> > ## /dev/hdb1             1      4111  33021576   83  Linux
> >
> >   The problem is the partition that was made didn't use all of the
> > 4865 cylinders that are available.  It only used the first 4111.
> >
> >   If you can move all of your important data off the drive...
> > then umount the partition and do the following with a Linux fdisk
> > command:
> >
> > fdisk /dev/hdb
> > =3D
> > d
> > 1
> > n
> > p
> > 1
> >
> >
> > w
> > =3D
> >
> > which will
> >   d =3D Delete, 1 =3D partition 1.
> >   n =3D New, p =3D Primary partition, 1 =3D partition 1.
> >   return =3D start at the first cylinder, return =3D end at the last cy=
linder,
> >   w =3D write the partition.
> >
> > once that is done:
> > =3D=3D=3D
> > mke2fs -j -b 4096 -i 16384 /dev/hdb1
> > =3D=3D=3D
> >
> >   Should make a new ext3 filesystem on that partition.  with blocksize
> > 4096 bytes per block, and a few fewer inodes since you are storing large
> > files on it.
> >
> >   Then mount your partition again... it should be bigger.
> >
> >   Run a "df" before and after those steps... if the partition isn't big=
ger
> > afterwards let me know and send the df output.
> >
> >   If you can't move your files off the drive (not enough space), then
> > back them up somewhere, tell me what filesystem type you have on the
> > partition, and I'll suggest a way to resize the filesystem without recr=
eation.
> >
> >     Good Luck,
> >       Mike
> > _______________________________________________
> > vox-tech mailing list
> > vox-tech@lists.lugod.org
> > http://lists.lugod.org/mailman/listinfo/vox-tech
> >
>=20
> _______________________________________________
> vox-tech mailing list
> vox-tech@lists.lugod.org
> http://lists.lugod.org/mailman/listinfo/vox-tech

--=20
Samuel Merritt
OpenPGP key is at http://meat.andcheese.org/~spam/spam_at_andcheese_dot_org=
.asc
Information about PGP can be found at http://www.mindspring.com/~aegreene/p=
gp/

--zaRBsRFn0XYhEU69
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)

iD8DBQE+XxQvW3tuPJ1t7wURAtW3AJ9xzDegSrdFjEvucijiKwLCCp7YeACfXdAx
MJBJ4iYWI5QRcBTO+tnGV60=
=DgEM
-----END PGP SIGNATURE-----

--zaRBsRFn0XYhEU69--