All of lore.kernel.org
 help / color / mirror / Atom feed
* shrink reiserfs
@ 2005-01-23 15:48 Jake Hawkes
  2005-01-23 17:11 ` Alex Zarochentsev
  0 siblings, 1 reply; 11+ messages in thread
From: Jake Hawkes @ 2005-01-23 15:48 UTC (permalink / raw)
  To: reiserfs-list

Hi.

resize_reiserfs says that there are already too many allocated blocks.

This isn't the exact error message, but I hope you get the idea.

jake@jacobh jake $ df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/hda4              38G  7.1G   31G  20% /
/dev/hda2              16G   15G  1.6G  91% /mnt/xp
none                  506M     0  506M   0% /dev/shm


so how can this be possible if it is only 20% used?

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: shrink reiserfs
  2005-01-23 15:48 shrink reiserfs Jake Hawkes
@ 2005-01-23 17:11 ` Alex Zarochentsev
       [not found]   ` <18298.62.135.89.53.1106502596.squirrel@mail.infinitylimited.net>
  0 siblings, 1 reply; 11+ messages in thread
From: Alex Zarochentsev @ 2005-01-23 17:11 UTC (permalink / raw)
  To: Jake Hawkes; +Cc: reiserfs-list

Hello,

On Sun, Jan 23, 2005 at 08:48:14AM -0700, Jake Hawkes wrote:
> Hi.
> 
>  resize_reiserfs says that there are already too many allocated blocks.

which resize_reiserfs command produces the error message?

> This isn't the exact error message, but I hope you get the idea.
> 
> jake@jacobh jake $ df -h
> Filesystem            Size  Used Avail Use% Mounted on
> /dev/hda4              38G  7.1G   31G  20% /
> /dev/hda2              16G   15G  1.6G  91% /mnt/xp
> none                  506M     0  506M   0% /dev/shm
> 
> 
> so how can this be possible if it is only 20% used?

the shrinker can't make the fs less than 7.1G in size.

-- 
Alex.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: shrink reiserfs
       [not found]   ` <18298.62.135.89.53.1106502596.squirrel@mail.infinitylimited.net>
@ 2005-01-23 19:07     ` Alex Zarochentsev
  2005-01-23 19:11       ` Spam
       [not found]       ` <18682.62.135.89.53.1106507496.squirrel@mail.infinitylimited.net>
  0 siblings, 2 replies; 11+ messages in thread
From: Alex Zarochentsev @ 2005-01-23 19:07 UTC (permalink / raw)
  To: Jake Hawkes; +Cc: reiserfs-list

On Sun, Jan 23, 2005 at 10:49:56AM -0700, Jake Hawkes wrote:
> Alex Zarochentsev said:
> > Hello,
> >
> > On Sun, Jan 23, 2005 at 08:48:14AM -0700, Jake Hawkes wrote:
> >> Hi.
> >>
> >>  resize_reiserfs says that there are already too many allocated blocks.
> >
> > which resize_reiserfs command produces the error message?
> 
> resize_reiserfs -v -s -1G /dev/hda4
> 
> and when that failed, I tried
> 
> resize_reiserfs -v -s -1M /dev/hda4

and it failed too?

which reiserfsprogs version are you using?  It is possible
that this bug is fixed already in the latest release of
reiserfsprogs (3.6.19).

> 
> >> jake@jacobh jake $ df -h
> >> Filesystem            Size  Used Avail Use% Mounted on
> >> /dev/hda4              38G  7.1G   31G  20% /
> >> /dev/hda2              16G   15G  1.6G  91% /mnt/xp
> >> none                  506M     0  506M   0% /dev/shm
> >>
> >>
> >> so how can this be possible if it is only 20% used?
> >
> > the shrinker can't make the fs less than 7.1G in size.
> 
> 
> I had to read that af ew times before I realised you were talking about my
> installation and not a general reiserfs issue :D
> 
> given the command above then, what can I do?

-- 
Alex.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: shrink reiserfs
  2005-01-23 19:07     ` Alex Zarochentsev
@ 2005-01-23 19:11       ` Spam
       [not found]       ` <18682.62.135.89.53.1106507496.squirrel@mail.infinitylimited.net>
  1 sibling, 0 replies; 11+ messages in thread
From: Spam @ 2005-01-23 19:11 UTC (permalink / raw)
  To: reiserfs-list

> On Sun, Jan 23, 2005 at 10:49:56AM -0700, Jake Hawkes wrote:
>> Alex Zarochentsev said:
>> > Hello,
>> >
>> > On Sun, Jan 23, 2005 at 08:48:14AM -0700, Jake Hawkes wrote:
>> >> Hi.
>> >>
>> >>  resize_reiserfs says that there are already too many allocated blocks.
>> >
>> > which resize_reiserfs command produces the error message?
>> 
>> resize_reiserfs -v -s -1G /dev/hda4
>> 
>> and when that failed, I tried
>> 
>> resize_reiserfs -v -s -1M /dev/hda4

> and it failed too?

> which reiserfsprogs version are you using?  It is possible
> that this bug is fixed already in the latest release of
> reiserfsprogs (3.6.19).

  Just a side-note. After upgrading to latest reiserfsprogs, then do a
  fsck before attempting to resize the filesystem.

  ~S

>> 
>> >> jake@jacobh jake $ df -h
>> >> Filesystem            Size  Used Avail Use% Mounted on
>> >> /dev/hda4              38G  7.1G   31G  20% /
>> >> /dev/hda2              16G   15G  1.6G  91% /mnt/xp
>> >> none                  506M     0  506M   0% /dev/shm
>> >>
>> >>
>> >> so how can this be possible if it is only 20% used?
>> >
>> > the shrinker can't make the fs less than 7.1G in size.
>> 
>> 
>> I had to read that af ew times before I realised you were talking about my
>> installation and not a general reiserfs issue :D
>> 
>> given the command above then, what can I do?




^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: shrink reiserfs
       [not found]       ` <18682.62.135.89.53.1106507496.squirrel@mail.infinitylimited.net>
@ 2005-01-23 19:49         ` Alex Zarochentsev
  2005-01-23 21:23           ` Alex Zarochentsev
  0 siblings, 1 reply; 11+ messages in thread
From: Alex Zarochentsev @ 2005-01-23 19:49 UTC (permalink / raw)
  To: Jake Hawkes; +Cc: reiserfs-list

On Sun, Jan 23, 2005 at 12:11:36PM -0700, Jake Hawkes wrote:
> Alex Zarochentsev said:
> > On Sun, Jan 23, 2005 at 10:49:56AM -0700, Jake Hawkes wrote:
> >> Alex Zarochentsev said:
> >> > Hello,
> >> >
> >> > On Sun, Jan 23, 2005 at 08:48:14AM -0700, Jake Hawkes wrote:
> >> >> Hi.
> >> >>
> >> >>  resize_reiserfs says that there are already too many allocated
> >> blocks.
> >> >
> >> > which resize_reiserfs command produces the error message?
> >>
> >> resize_reiserfs -v -s -1G /dev/hda4
> >>
> >> and when that failed, I tried
> >>
> >> resize_reiserfs -v -s -1M /dev/hda4
> >
> > and it failed too?
> 
> yep
> 
> 
> >
> > which reiserfsprogs version are you using?  It is possible
> > that this bug is fixed already in the latest release of
> > reiserfsprogs (3.6.19).
> 
> jacobh log # esearch reiserfsprogs
> [ Results for search key : reiserfsprogs ]
> [ Applications found : 1 ]
> 
> *  sys-fs/reiserfsprogs
>       Latest version available: 3.6.19
>       Latest version installed: 3.6.18
>       Size of downloaded files: [no/bad digest]
>       Homepage:    http://www.namesys.com/
>       Description: Reiserfs Utilities

yes, it see, new reiserfsprogs has this bug (v3.0.9 does not :-/) .

As a workaround  I suggest don't use relative values in current resizer.
please try resize_reiserfs -v -s 21G /dev/hda4 .

> I'm using 3.6.18

Thanks for the report.

-- 
Alex.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: shrink reiserfs
  2005-01-23 19:49         ` Alex Zarochentsev
@ 2005-01-23 21:23           ` Alex Zarochentsev
  2005-01-23 21:53             ` Jake Hawkes
  0 siblings, 1 reply; 11+ messages in thread
From: Alex Zarochentsev @ 2005-01-23 21:23 UTC (permalink / raw)
  To: Jake Hawkes; +Cc: reiserfs-list

On Sun, Jan 23, 2005 at 10:49:18PM +0300, Alex Zarochentcev wrote:
> On Sun, Jan 23, 2005 at 12:11:36PM -0700, Jake Hawkes wrote:
> > Alex Zarochentsev said:
> > > On Sun, Jan 23, 2005 at 10:49:56AM -0700, Jake Hawkes wrote:
> > >> Alex Zarochentsev said:
> > >> > Hello,
> > >> >
> > >> > On Sun, Jan 23, 2005 at 08:48:14AM -0700, Jake Hawkes wrote:
> > >> >> Hi.
> > >> >>
> > >> >>  resize_reiserfs says that there are already too many allocated
> > >> blocks.
> > >> >
> > >> > which resize_reiserfs command produces the error message?
> > >>
> > >> resize_reiserfs -v -s -1G /dev/hda4
> > >>
> > >> and when that failed, I tried
> > >>
> > >> resize_reiserfs -v -s -1M /dev/hda4
> > >
> > > and it failed too?
> > 
> > yep
> > 
> > 
> > >
> > > which reiserfsprogs version are you using?  It is possible
> > > that this bug is fixed already in the latest release of
> > > reiserfsprogs (3.6.19).
> > 
> > jacobh log # esearch reiserfsprogs
> > [ Results for search key : reiserfsprogs ]
> > [ Applications found : 1 ]
> > 
> > *  sys-fs/reiserfsprogs
> >       Latest version available: 3.6.19
> >       Latest version installed: 3.6.18
> >       Size of downloaded files: [no/bad digest]
> >       Homepage:    http://www.namesys.com/
> >       Description: Reiserfs Utilities
> 
> yes, it see, new reiserfsprogs has this bug (v3.0.9 does not :-/) .

oops, i can't reproduce the bug anymore, seems i forgot '-' in  
"-s -1G" option in my first resize attempt.  3.6.19, 3.6.18 work well
for me.

> As a workaround  I suggest don't use relative values in current resizer.
> please try resize_reiserfs -v -s 21G /dev/hda4 .
> 
> > I'm using 3.6.18
> 
> Thanks for the report.
> 
> -- 
> Alex.

-- 
Alex.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: shrink reiserfs
  2005-01-23 21:23           ` Alex Zarochentsev
@ 2005-01-23 21:53             ` Jake Hawkes
  2005-01-24  6:46               ` David Masover
       [not found]               ` <41F64DA7.2070502@nauticom.net>
  0 siblings, 2 replies; 11+ messages in thread
From: Jake Hawkes @ 2005-01-23 21:53 UTC (permalink / raw)
  To: Alex Zarochentsev; +Cc: reiserfs-list

Alex Zarochentsev said:

> oops, i can't reproduce the bug anymore, seems i forgot '-' in
> "-s -1G" option in my first resize attempt.  3.6.19, 3.6.18 work well
> for me.


well - I upgraded and set an exact size to reize to, and it worked fine,
so I can only assume that I messed up the command line args somehow.

My next question, can I grow a reiserfs filesystem backwards in the
partition?

I have resized my filesystem, and deleted and re-created my partition
accordingly.

Disk /dev/hda: 60.0 GB, 60011642880 bytes
255 heads, 63 sectors/track, 7296 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/hda1               1           6       48163+   6  FAT16
/dev/hda2   *           7        2074    16611210    7  HPFS/NTFS
/dev/hda3            2437        2439       24097+  83  Linux [boot-ext3]
/dev/hda4            2440        4398    15735667+  83  Linux [ reiser ]


I'd like to delete partition 3 & 4, and create a new partition from 2437
to 4398, and then grow the reiserfs filesystem to fill it, only, its going
to be lower/before the filesystem.

I thought there might be a vagur chance the reiser being advanced enough
might be able to handle this.

If not, then I'm kinda stuck with a spotty partition table and I'g going
to have pull the drive and start hauling around disk images and stuff,
which I'd like to avoid.

Here's hoping.

-Jake


p.s. thanks heaps for your responses mate =)

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: shrink reiserfs
  2005-01-23 21:53             ` Jake Hawkes
@ 2005-01-24  6:46               ` David Masover
       [not found]               ` <41F64DA7.2070502@nauticom.net>
  1 sibling, 0 replies; 11+ messages in thread
From: David Masover @ 2005-01-24  6:46 UTC (permalink / raw)
  To: jake; +Cc: Alex Zarochentsev, reiserfs-list

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1



Jake Hawkes wrote:
[...]
| My next question, can I grow a reiserfs filesystem backwards in the
| partition?

Don't think so, but I wouldn't know.

[...]
| If not, then I'm kinda stuck with a spotty partition table and I'g going
| to have pull the drive and start hauling around disk images and stuff,
| which I'd like to avoid.

How full is the fs?  If less than half-full, you could try this (for
example):

| free space | reiserfs partition |

shrink fs and partition to less than half:

| free space | reiser | free spac |

make new partition to the "right" of old partition:

| free space | reiser | new parti |

dd from reiserfs to new partition:

| free space | reiser | reiserfs  |

delete old reiserfs partition:

| free space          | reiserfs  |

make new partition

| new partition       | reiserfs  |

dd old reiserfs to new partition

| reiserfs partition  | reiserfs  |

delete old partition, expand new partition and fs

| reiserfs partition              |




This could clearly be much easier to follow, but it illustrates two points:

- - If your disk is not full, you can almost always get from your current
partition scheme to any new one without completely backing up /
reformatting (no pulling the drive, no installing a new backup drive, etc.)

- - Sometimes, the workaround for a missing feature literally takes more
time than writing the feature or buying new hardware.

Disclaimer:  this may not be such a time, and my comments may just stem
from my wish that reiser4 had a repacker and online
resizer/shrinker/grow-forward/backward feature.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iQIVAwUBQfSZyHgHNmZLgCUhAQJRSA/+P2f5U/BNhaXjm3Q15gBYiuhOur2jbWw0
+LOYpFN2+zLYWFNmTIt7ypHshXF+Qejt55cwvPF/aLG4pWsTcwVYtVYWti8El7/y
lhLiu6b/AeEnBBMyOHqZ4VyBdalR7JzftGU0n0gBcTKTFC3eaWYlMIcSEprnIpEw
KIrpsteUn5vaF5Z9yLBG40GDi6l+c/LH3nzdOw+rlTtjwhhBdVvV9SSbQYwY+jaS
QbW/7hlImrOuhDrgGUTo+ne7TYnJvn3ZtDztXpeTskpNGs7UHE+7yLQxwgBIg3ma
R14ToHnnTbXftQwyq/H7Dcv3qQP7tuO+IqAbd9QCBVtA+pOv5yYqpodmjtU6FJd3
uINrO1aMRfsX772lcbyiJHo70H2ksZAOODCYD/Id7I6s3qWYxr8kpHgiL8az8Mpn
3sVbmKfZSPuM34vYlrLh1P2So3A3L8ZROYaciUvEyKeE0Gpbpq7bxrTSeRTfSrzI
W2ZP2GpI9pxzXigeghK/B/UcLvkgNU7n61o3yGkinJJjoUdjb7Ymfo4g1r5wN7Px
FKSrsvCz4J0x6NsV1bBE3pLdnb9Cf8gqnhxNVc/R2ftVtDKlmJTokMx8/UxAe//T
uaX/5M1R0cNIWzVUDQ+oNiTeeZhKf9EMyQkyqdUW84ES+fw5Hoqge4jz/kZYAP7E
6T2GGLHyiUc=
=TudP
-----END PGP SIGNATURE-----

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: shrink reiserfs
       [not found]               ` <41F64DA7.2070502@nauticom.net>
@ 2005-01-28 15:52                 ` Jake Hawkes
  2005-01-30  0:42                   ` David Masover
  0 siblings, 1 reply; 11+ messages in thread
From: Jake Hawkes @ 2005-01-28 15:52 UTC (permalink / raw)
  To: Chet Hosey; +Cc: reiserfs-list

Chet Hosey said:
> A quick perusal of GNU parted's manual gives me the impression that it
> can move partitions about the disk:
>
> http://www.gnu.org/software/parted/manual/html_chapter/parted_2.html#SEC20
>
> I've not used parted, but rather than dropping $25 on PartitionMagic on
> Amazon (or much more in a retail outlet), you could give it a shot.
>
> If you try it, it might be nice if you let all us (and those searching
> the archives) how it went
>
>

It seems that it doesn't want to try to move a reiser partition.  Oh well.

I took David Masover's suggestion, and did some fancy footwork.

First thing I did was realise what hda1 was used for.  this was the table
before I started messing around:

   Device Boot      Start         End      Blocks   Id  System
/dev/hda1               1           6       48163+   6  FAT16
/dev/hda2   *           7        2074    16611210    7  HPFS/NTFS
/dev/hda3            2437        2439       24097+  83  Linux [boot-ext3]
/dev/hda4            2440        4398    15735667+  83  Linux [ reiser ]

I had a look on hda1 and realised it was a "special" Dell system recovery
partition, with various diagnostic programs on it.  And it had free space
- so it became my boot partition.

So, I deleted hda3, shrank hda4 as far as possible, created a new hda3
*after* hda4, dd'd hda4 -> hda3.

Some advice for those wanting to do this again:

 - reboot after every step, to check that you haven't messed something up,
especially if after writing a new partition, fdisk say "Kernel will
continue to use old partition table".

 - do one thing at a time, dont try to do too many steps at once.  You
will not save time in the long run.

 - always have an alternative boot media handy (I use the gentoo live CD)

 - be very familiar (ie, dont rely on man pages or web pages) with your
tools, especially resize_reiserfs, grub, mount etc

 - dont do what I did and gamble that your laptop battery will have enough
juice to do all the steps, especially if you are in Frankfurt airport
with no power outlets :)

End Result: good so far.  I haven't completely finished yet, still to do
are finalising the grub install, and creating the new FAT partition to
share data between windows and linux.

Thanks for the advice guys!

-Jake

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: shrink reiserfs
  2005-01-28 15:52                 ` Jake Hawkes
@ 2005-01-30  0:42                   ` David Masover
  2005-01-30 17:25                     ` Jake Hawkes
  0 siblings, 1 reply; 11+ messages in thread
From: David Masover @ 2005-01-30  0:42 UTC (permalink / raw)
  To: jake; +Cc: Chet Hosey, reiserfs-list

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Jake Hawkes wrote:
[...]
|  - reboot after every step, to check that you haven't messed something up,
| especially if after writing a new partition, fdisk say "Kernel will
| continue to use old partition table".

Only if that happens.  And it will only happen if you are using the disk
in question, so...

[...]
|  - always have an alternative boot media handy (I use the gentoo live CD)

I'd use it in the first place, to avoid having to reboot after fdisk.
And I'd use cfdisk.  Less chance for mistakes.

|  - be very familiar (ie, dont rely on man pages or web pages) with your
| tools, especially resize_reiserfs, grub, mount etc

It's good to have such documentation available, whether or not you know
resize_reiserfs by heart.  The important thing is to train yourself to
always look at the doc, and never guess, especially when a typo can mean
your disk.

| End Result: good so far.  I haven't completely finished yet, still to do
| are finalising the grub install, and creating the new FAT partition to
| share data between windows and linux.

I'm curious why windows would be needed on a laptop.  I only use it for
games.  But maybe your laptop is better than mine.

And btw, when I mess with my laptop partitions, I usually tar up
everything and dump it to my desktop.  Just make sure the boot cd has
ethernet support.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iQIVAwUBQfwth3gHNmZLgCUhAQJTlRAAiL1GrZ0qAAQUmreveCM+AgtMoifecDgR
AyPE4gv6Ah7MUsb7QluDdnGXe83YDqhnJEdIm67Iaxie0zVKWb7F5utQgzrBV7lg
oY7aE7UpS1c6wQ9cNkUnfYIq4gc851J8kSTG+vO/sZIkvAxg+zp/dz/ZQa1ED+6u
WxwFNkoXNq60DYg8taseVFJiy9E6jN1aM+DPsrvitgKfnjfC5xGXT62yST/So5Ua
+RJTQTh+UANps3T+tubZsp/+OcH9V+mFXgGXX985ABWUjG1KX6HPSnjttkIhvvIS
X+KNyXjJTH/QKW/r9xeNYXafV359GwRxxHZJuxesq8cofh5PYLg5p98FwxLHUbiY
iI7pqJpDDkm4JHAa0k6c2EZyh02Iaj5vb9RbDK9p9kPSCke0cXYeyExAnCVOUDtf
agNDpkC2Q9Nm+s0AsxkJX1BiLB0hGz54NAbJvfIHhxF/PgmTVCEOGjDNWoc0cAll
uwc7OZK9Jv96ybuaxeDmNlLLz0iy8dK4lAh3VKw6vIA565fYGhAqFopwfcU3axqK
VMTcnfq4BrmVWQnZXdX2OPPuSwss7cbYbdjoV5So8U0X5/V62QeJhGskvm8prJA9
7n/ebxGnGGQt++u8B9gIlRuT+ndZcj01k4/y3YM9Yw/inOF8bSHCjPF2B2wCGNNF
yKb+jPeBRRM=
=TdWu
-----END PGP SIGNATURE-----

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: shrink reiserfs
  2005-01-30  0:42                   ` David Masover
@ 2005-01-30 17:25                     ` Jake Hawkes
  0 siblings, 0 replies; 11+ messages in thread
From: Jake Hawkes @ 2005-01-30 17:25 UTC (permalink / raw)
  To: David Masover; +Cc: reiserfs-list

David Masover said:
>
> I'm curious why windows would be needed on a laptop.  I only use it for
> games.  But maybe your laptop is better than mine.
>

Work VPN. :)

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2005-01-30 17:25 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-01-23 15:48 shrink reiserfs Jake Hawkes
2005-01-23 17:11 ` Alex Zarochentsev
     [not found]   ` <18298.62.135.89.53.1106502596.squirrel@mail.infinitylimited.net>
2005-01-23 19:07     ` Alex Zarochentsev
2005-01-23 19:11       ` Spam
     [not found]       ` <18682.62.135.89.53.1106507496.squirrel@mail.infinitylimited.net>
2005-01-23 19:49         ` Alex Zarochentsev
2005-01-23 21:23           ` Alex Zarochentsev
2005-01-23 21:53             ` Jake Hawkes
2005-01-24  6:46               ` David Masover
     [not found]               ` <41F64DA7.2070502@nauticom.net>
2005-01-28 15:52                 ` Jake Hawkes
2005-01-30  0:42                   ` David Masover
2005-01-30 17:25                     ` Jake Hawkes

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.