* [linux-lvm] LVM questions & problems.
@ 2001-05-07 1:05 Rupert Heesom
2001-05-07 10:28 ` Heinz J. Mauelshagen
0 siblings, 1 reply; 5+ messages in thread
From: Rupert Heesom @ 2001-05-07 1:05 UTC (permalink / raw)
To: linux-lvm
I'm practicing doing some LVM commands, and am coming up with some
problems -
Most disconcerting is that when I try to create a directory in the LV, I
get the following error - (this does not happen all the time, but almost
all the time 99%) -
[root@localhost Tmp]# mkdir test1
mkdir: cannot create directory `test1': Input/output error
Creating normal files on the LV is not a problem.
Also, the figures in the following outputs don't seem to make sense to
me -
287Mb of space taken on my LV lvol1 (shown using du -h).
LV lvol1 - shows all 75 logical extends taken, I'm assuming filling up
the 300Mb LV size.
LV Size 300 MB
Current LE 75
Allocated LE 75
PV shows too many physical extends used for the proportion of disk space
used. -
Total PE 76
Free PE 1
PVdisplay shows too many physical extents used again
Total PE 76
Free PE 1
Allocated PE 75
----------------------------------------
LVM command outputs
-------------------
[root@localhost Tmp]# lvdisplay /dev/vg/lvol1
lvdisplay
--- Logical volume ---
LV Name /dev/vg/lvol1
VG Name vg
LV Write Access read/write
LV Status available
LV # 1
# open 1
LV Size 300 MB
Current LE 75
Allocated LE 75
Allocation next free
Read ahead sectors 120
Block device 58:0
[root@localhost Tmp]# pvdisplay /dev/sdb1
pvdisplay
--- Physical volume ---
PV Name /dev/sdb1
VG Name vg
PV Size 305.89 MB / NOT usable 1.89 MB [LVM: 121 KB]
PV# 1
PV Status available
Allocatable yes
Cur LV 1
PE Size (KByte) 4096
Total PE 76
Free PE 1
Allocated PE 75
PV UUID wm3nGp-pEem-0byC-3JOs-OFs4-3kv2-EkPxaK
[root@localhost Tmp]# vgdisplay
vgdisplay
--- Volume group ---
VG Name vg
VG Access read/write
VG Status available/resizable
VG # 0
MAX LV 256
Cur LV 1
Open LV 1
MAX LV Size 255.99 GB
Max PV 256
Cur PV 1
Act PV 1
VG Size 304 MB
PE Size 4 MB
Total PE 76
Alloc PE / Size 75 / 300 MB
Free PE / Size 1 / 4 MB
VG UUID 0ZyZNT-53L9-tAFJ-GCa4-1Zr5-nZli-IFIbIP
--
regs
rupert
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [linux-lvm] LVM questions & problems.
2001-05-07 1:05 [linux-lvm] LVM questions & problems Rupert Heesom
@ 2001-05-07 10:28 ` Heinz J. Mauelshagen
2001-05-07 15:57 ` Rupert Heesom
0 siblings, 1 reply; 5+ messages in thread
From: Heinz J. Mauelshagen @ 2001-05-07 10:28 UTC (permalink / raw)
To: linux-lvm
On Sun, May 06, 2001 at 09:05:13PM -0400, Rupert Heesom wrote:
> I'm practicing doing some LVM commands, and am coming up with some
> problems -
>
> Most disconcerting is that when I try to create a directory in the LV, I
> get the following error - (this does not happen all the time, but almost
> all the time 99%) -
>
> [root@localhost Tmp]# mkdir test1
> mkdir: cannot create directory `test1': Input/output error
You didn't metion, if the filesystem is still in a sane state.
Did you check your syslog for "accessess beyond the end of the device"
which indicate fs related problems?
If so: did you run fsck to fix those and did you retest?
>
> Creating normal files on the LV is not a problem.
>
> Also, the figures in the following outputs don't seem to make sense to
> me -
>
> 287Mb of space taken on my LV lvol1 (shown using du -h).
du is a filesystem tool which tells you how much space is used
from the fs perspective.
The LV tools provide information from the underlying block device being
exposed by the LVM to the filesytem or other users (like databases etc.).
>
> LV lvol1 - shows all 75 logical extends taken, I'm assuming filling up
> the 300Mb LV size.
>
> LV Size 300 MB
> Current LE 75
> Allocated LE 75
O.k.
That shows, that you have a 300M logical volume, which you said above.
vgdisplay on your volume group gives you (beside other information)
the size of the physical extents (PEs) which is 4M by default.
You can change that in order to address bigger configurations with
"vgcreate -s". Please see "man vgcreate" for further details.
>
>
> PV shows too many physical extends used for the proportion of disk space
> used. -
>
> Total PE 76
> Free PE 1
That's ok because you allocated 75PEs which are 300M based on
4M PE size.
>
> PVdisplay shows too many physical extents used again
>
> Total PE 76
> Free PE 1
> Allocated PE 75
Same as above.
Please have a look at the LVM howto at www.sistina.com/lvm
for further hints on LVM usage.
Regards,
Heinz -- The LVM Guy --
>
>
> ----------------------------------------
>
> LVM command outputs
> -------------------
>
> [root@localhost Tmp]# lvdisplay /dev/vg/lvol1
> lvdisplay
> --- Logical volume ---
> LV Name /dev/vg/lvol1
> VG Name vg
> LV Write Access read/write
> LV Status available
> LV # 1
> # open 1
> LV Size 300 MB
> Current LE 75
> Allocated LE 75
> Allocation next free
> Read ahead sectors 120
> Block device 58:0
>
>
> [root@localhost Tmp]# pvdisplay /dev/sdb1
> pvdisplay
> --- Physical volume ---
> PV Name /dev/sdb1
> VG Name vg
> PV Size 305.89 MB / NOT usable 1.89 MB [LVM: 121 KB]
> PV# 1
> PV Status available
> Allocatable yes
> Cur LV 1
> PE Size (KByte) 4096
> Total PE 76
> Free PE 1
> Allocated PE 75
> PV UUID wm3nGp-pEem-0byC-3JOs-OFs4-3kv2-EkPxaK
>
>
> [root@localhost Tmp]# vgdisplay
> vgdisplay
> --- Volume group ---
> VG Name vg
> VG Access read/write
> VG Status available/resizable
> VG # 0
> MAX LV 256
> Cur LV 1
> Open LV 1
> MAX LV Size 255.99 GB
> Max PV 256
> Cur PV 1
> Act PV 1
> VG Size 304 MB
> PE Size 4 MB
> Total PE 76
> Alloc PE / Size 75 / 300 MB
> Free PE / Size 1 / 4 MB
> VG UUID 0ZyZNT-53L9-tAFJ-GCa4-1Zr5-nZli-IFIbIP
>
>
> --
> regs
> rupert
>
> _______________________________________________
> linux-lvm mailing list
> linux-lvm@sistina.com
> http://lists.sistina.com/mailman/listinfo/linux-lvm
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Heinz Mauelshagen Sistina Software Inc.
Senior Consultant/Developer Am Sonnenhang 11
56242 Marienrachdorf
Germany
Mauelshagen@Sistina.com +49 2626 141200
FAX 924446
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [linux-lvm] LVM questions & problems.
2001-05-07 10:28 ` Heinz J. Mauelshagen
@ 2001-05-07 15:57 ` Rupert Heesom
2001-05-08 9:45 ` Heinz J. Mauelshagen
0 siblings, 1 reply; 5+ messages in thread
From: Rupert Heesom @ 2001-05-07 15:57 UTC (permalink / raw)
To: linux-lvm
On 07 May 2001 10:28:44 +0000, Heinz J. Mauelshagen wrote:
> On Sun, May 06, 2001 at 09:05:13PM -0400, Rupert Heesom wrote:
> > I'm practicing doing some LVM commands, and am coming up with some
> > problems -
> >
> > Most disconcerting is that when I try to create a directory in the LV, I
> > get the following error - (this does not happen all the time, but almost
> > all the time 99%) -
> >
> > [root@localhost Tmp]# mkdir test1
> > mkdir: cannot create directory `test1': Input/output error
>
> You didn't metion, if the filesystem is still in a sane state.
>
> Did you check your syslog for "accessess beyond the end of the device"
> which indicate fs related problems?
Well, looking at my syslog after mounting my lvol, I saw the following
msg -
"May 7 11:51:26 localhost kernel: EXT2-fs warning: mounting fs with
errors, running e2fsck is recommended"
I also saw previous errors which you asked about (lots of them) -
"itmap: Cannot read inode bitmap - block_group = 3, inode_bitmap = 98307
May 6 14:44:13 localhost kernel: attempt to access beyond end of
device...."
I have realised what my base problem is.... I have reduced the LV size,
but not reduced the Ext2 filesystem. For some reason I thought that
resizing the LV was sufficient. Looking further at the HOWTO, and other
web docs has enlightened me further.
It seems I will try to learn how to use teh e2fsadm util. BTW one of
the utils seems to be commercial from Powerquest. I have the v4 of
Partition Magic already. I know it resizes ext2 filesystems, but as far
as I know needs to be run from within windows (it's been a long time
since I've used it last). Are the utils such as e2fsadm sufficient /
good enough without the commercial PM util?
--
regs
rupert
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [linux-lvm] LVM questions & problems.
2001-05-07 15:57 ` Rupert Heesom
@ 2001-05-08 9:45 ` Heinz J. Mauelshagen
2001-05-08 16:25 ` Andreas Dilger
0 siblings, 1 reply; 5+ messages in thread
From: Heinz J. Mauelshagen @ 2001-05-08 9:45 UTC (permalink / raw)
To: linux-lvm
On Mon, May 07, 2001 at 11:57:03AM -0400, Rupert Heesom wrote:
> On 07 May 2001 10:28:44 +0000, Heinz J. Mauelshagen wrote:
> > On Sun, May 06, 2001 at 09:05:13PM -0400, Rupert Heesom wrote:
> > > I'm practicing doing some LVM commands, and am coming up with some
> > > problems -
> > >
> > > Most disconcerting is that when I try to create a directory in the LV, I
> > > get the following error - (this does not happen all the time, but almost
> > > all the time 99%) -
> > >
> > > [root@localhost Tmp]# mkdir test1
> > > mkdir: cannot create directory `test1': Input/output error
> >
> > You didn't metion, if the filesystem is still in a sane state.
> >
> > Did you check your syslog for "accessess beyond the end of the device"
> > which indicate fs related problems?
>
> Well, looking at my syslog after mounting my lvol, I saw the following
> msg -
>
> "May 7 11:51:26 localhost kernel: EXT2-fs warning: mounting fs with
> errors, running e2fsck is recommended"
>
> I also saw previous errors which you asked about (lots of them) -
>
> "itmap: Cannot read inode bitmap - block_group = 3, inode_bitmap = 98307
> May 6 14:44:13 localhost kernel: attempt to access beyond end of
> device...."
>
> I have realised what my base problem is.... I have reduced the LV size,
> but not reduced the Ext2 filesystem. For some reason I thought that
> resizing the LV was sufficient.
It likely will be at some point in time in the future.
Triggering the fs resize when a LN gets resized is a TODO item :-)
> Looking further at the HOWTO, and other
> web docs has enlightened me further.
>
> It seems I will try to learn how to use teh e2fsadm util. BTW one of
> the utils seems to be commercial from Powerquest. I have the v4 of
> Partition Magic already. I know it resizes ext2 filesystems, but as far
> as I know needs to be run from within windows (it's been a long time
> since I've used it last). Are the utils such as e2fsadm sufficient /
> good enough without the commercial PM util?
You need to get the resize2fs tool (by Ted Ts'o and Powerquest) in order
to run e2fsadm.
e2fsadm basically is a wrapper which runs either
e2fsck;lvextend;resize2fs
or
e2fsck;resize2fs;lvreduce
resize2fs might already be contained in your distribution.
If not so, use for eg. ftpsearch.lycos.com to figure piles of spaces
where to get it.
>
> --
> regs
> rupert
>
> _______________________________________________
> linux-lvm mailing list
> linux-lvm@sistina.com
> http://lists.sistina.com/mailman/listinfo/linux-lvm
--
Regards,
Heinz -- The LVM Guy --
*** Software bugs are stupid.
Nevertheless it needs not so stupid people to solve them ***
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Heinz Mauelshagen Sistina Software Inc.
Senior Consultant/Developer Am Sonnenhang 11
56242 Marienrachdorf
Germany
Mauelshagen@Sistina.com +49 2626 141200
FAX 924446
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [linux-lvm] LVM questions & problems.
2001-05-08 9:45 ` Heinz J. Mauelshagen
@ 2001-05-08 16:25 ` Andreas Dilger
0 siblings, 0 replies; 5+ messages in thread
From: Andreas Dilger @ 2001-05-08 16:25 UTC (permalink / raw)
To: linux-lvm
Heinz writes:
> On Mon, May 07, 2001 at 11:57:03AM -0400, Rupert Heesom wrote:
> > It seems I will try to learn how to use teh e2fsadm util. BTW one of
> > the utils seems to be commercial from Powerquest. I have the v4 of
> > Partition Magic already. I know it resizes ext2 filesystems, but as far
> > as I know needs to be run from within windows (it's been a long time
> > since I've used it last). Are the utils such as e2fsadm sufficient /
> > good enough without the commercial PM util?
>
> You need to get the resize2fs tool (by Ted Ts'o and Powerquest) in order
> to run e2fsadm.
>
> resize2fs might already be contained in your distribution.
If you have e2fsprogs 1.19 then it contains resize2fs. The deal Ted had
with Powerquest is that resize2fs would become GPL after 2 years or so.
The e2fsadm program can use ext2resize (http://ext2resize.sourceforge.net)
instead of resize2fs. If you patch your kernel with the ext2online patch,
then you can even use e2fsadm to grow the LV and ext2 filesystem without
unmounting it.
Cheers, Andreas
--
Andreas Dilger \ "If a man ate a pound of pasta and a pound of antipasto,
\ would they cancel out, leaving him still hungry?"
http://www-mddsp.enel.ucalgary.ca/People/adilger/ -- Dogbert
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2001-05-08 16:25 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-05-07 1:05 [linux-lvm] LVM questions & problems Rupert Heesom
2001-05-07 10:28 ` Heinz J. Mauelshagen
2001-05-07 15:57 ` Rupert Heesom
2001-05-08 9:45 ` Heinz J. Mauelshagen
2001-05-08 16:25 ` Andreas Dilger
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.