* [linux-lvm] lvscan and df result differs
@ 2002-10-26 18:31 Magnus Sandberg
2002-10-28 3:07 ` Heinz J . Mauelshagen
0 siblings, 1 reply; 4+ messages in thread
From: Magnus Sandberg @ 2002-10-26 18:31 UTC (permalink / raw)
To: linux-lvm
I have just installed lvm on my debian testing server.
I have finally managed to create a PV on a maxtor
120G disk, the 'pvcreate' command complained about
a partitiontable being present even if there is no
table there.
--8<--
server:~# pvcreate --version
pvcreate: Logical Volume Manager 1.0.4
Heinz Mauelshagen, Sistina Software 02/05/2002 (IOP 10)
--8<--
I managed to get around that by using a v2 lvm command.
Is there a bug in 1.0.x's pvcreate?
I have also managed to create a VG a and a LV and that
seems to work. I have formatted the LV with ext3 and now
the strange thing is that lvscan reports:
--8<--
server:~# lvscan
lvscan -- ACTIVE "/dev/vg/lg" [114.49 GB]
lvscan -- 1 logical volumes with 114.49 GB total in 1 volume group
lvscan -- 1 active logical volumes
--8<--
But when using the filesystem df reports:
--8<--
Filesystem Size Used Avail Use% Mounted on
/dev/hde1 123GB 121GB 2.4GB 99% /store
/dev/vg/lg 122GB 121GB 0 100% /store2
--8<--
/dev/hde1 is also a 120G disk but with resierfs, ext3
takeing up more size is probably normal. But the actual
size on the lvm is 122G and as you can see I can fit
121G on the disk, so why is lvscan reporting ~115G?
Can i safetly use my lvm setup without running the risk
of losing data?
Thanks,
/Magnus
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [linux-lvm] lvscan and df result differs
2002-10-26 18:31 [linux-lvm] lvscan and df result differs Magnus Sandberg
@ 2002-10-28 3:07 ` Heinz J . Mauelshagen
2002-10-28 9:24 ` Magnus Sandberg
0 siblings, 1 reply; 4+ messages in thread
From: Heinz J . Mauelshagen @ 2002-10-28 3:07 UTC (permalink / raw)
To: linux-lvm
On Sun, Oct 27, 2002 at 01:30:01AM +0200, Magnus Sandberg wrote:
>
> I have just installed lvm on my debian testing server.
>
> I have finally managed to create a PV on a maxtor
> 120G disk, the 'pvcreate' command complained about
> a partitiontable being present even if there is no
> table there.
> --8<--
> server:~# pvcreate --version
> pvcreate: Logical Volume Manager 1.0.4
> Heinz Mauelshagen, Sistina Software 02/05/2002 (IOP 10)
> --8<--
> I managed to get around that by using a v2 lvm command.
> Is there a bug in 1.0.x's pvcreate?
Did you zero the partition table?
i.e. "dd if=/dev/zero of=/dev/YourWholeDisk count=1 bs=512"
v1 "pvcreate /dev/YourWholeDisk" should work fine then.
>
> I have also managed to create a VG a and a LV and that
> seems to work. I have formatted the LV with ext3 and now
> the strange thing is that lvscan reports:
> --8<--
> server:~# lvscan
> lvscan -- ACTIVE "/dev/vg/lg" [114.49 GB]
> lvscan -- 1 logical volumes with 114.49 GB total in 1 volume group
> lvscan -- 1 active logical volumes
> --8<--
> But when using the filesystem df reports:
> --8<--
> Filesystem Size Used Avail Use% Mounted on
> /dev/hde1 123GB 121GB 2.4GB 99% /store
> /dev/vg/lg 122GB 121GB 0 100% /store2
> --8<--
>
> /dev/hde1 is also a 120G disk but with resierfs, ext3
> takeing up more size is probably normal. But the actual
> size on the lvm is 122G and as you can see I can fit
> 121G on the disk, so why is lvscan reporting ~115G?
> Can i safetly use my lvm setup without running the risk
> of losing data?
Can't reproduce that with df 4.1 here :(
That's probably just the old divide by 1k or 1024 thing.
What does "df -k" say and how does it compare to the lvscan output?
>
>
> Thanks,
>
> /Magnus
>
>
> _______________________________________________
> linux-lvm mailing list
> linux-lvm@sistina.com
> http://lists.sistina.com/mailman/listinfo/linux-lvm
> read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/
--
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] 4+ messages in thread
* Re: [linux-lvm] lvscan and df result differs
2002-10-28 3:07 ` Heinz J . Mauelshagen
@ 2002-10-28 9:24 ` Magnus Sandberg
2002-10-28 9:38 ` James Hawtin
0 siblings, 1 reply; 4+ messages in thread
From: Magnus Sandberg @ 2002-10-28 9:24 UTC (permalink / raw)
To: linux-lvm
On Mon, 2002-10-28 at 10:03, Heinz J . Mauelshagen wrote:
> On Sun, Oct 27, 2002 at 01:30:01AM +0200, Magnus Sandberg wrote:
>
> Did you zero the partition table?
> i.e. "dd if=/dev/zero of=/dev/YourWholeDisk count=1 bs=512"
>
> v1 "pvcreate /dev/YourWholeDisk" should work fine then.
Yes I did, several times, I even rebooted to make sure the
table was reread.
> > /dev/hde1 is also a 120G disk but with resierfs, ext3
> > takeing up more size is probably normal. But the actual
> > size on the lvm is 122G and as you can see I can fit
> > 121G on the disk, so why is lvscan reporting ~115G?
> > Can i safetly use my lvm setup without running the risk
> > of losing data?
>
> Can't reproduce that with df 4.1 here :(
> That's probably just the old divide by 1k or 1024 thing.
Yes I suspected that but it stills scares me tad.
> What does "df -k" say and how does it compare to the lvscan output?
I'm using df 4.5.2, and df -k says:
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/vg/lg 118169924 117732724 0 100% /store2
and if using lvscan I get:
114.49*1000*1000 = 114490000
114.49*1024*1024 = 120051466,24
so with a few % off for the filesystem info it looks ok, But why is df
using Size and Used info from the filesystem and the Available ans Use%
info from the lvm-Volume?
/Magnus
--
Magnus Sandberg <magnus@switchbeat.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [linux-lvm] lvscan and df result differs
2002-10-28 9:24 ` Magnus Sandberg
@ 2002-10-28 9:38 ` James Hawtin
0 siblings, 0 replies; 4+ messages in thread
From: James Hawtin @ 2002-10-28 9:38 UTC (permalink / raw)
To: linux-lvm
Also don't forget lvm first takes off a little bit of your disk for
its own use then it rounds the disk to your extent size, one of
your extents is also reserved for future lvm use, so if you use an extent
size of 4 meg 4.3-8.29 (approx) could be "missing" from your disk.
James
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2002-10-28 9:38 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-10-26 18:31 [linux-lvm] lvscan and df result differs Magnus Sandberg
2002-10-28 3:07 ` Heinz J . Mauelshagen
2002-10-28 9:24 ` Magnus Sandberg
2002-10-28 9:38 ` James Hawtin
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.