missing hard drive space... ?

hey guys, ok first ill appreciate any and all help, im a windows guy trying to learn linux, but in a hard way… basically, i rent a server from 1and1 and have a linux install on it, and its supposed to have a 250gig hard drive. im running suse11.4 with plesk 10.4.4(im not to fond of plesk>:() they put the webserver files under a partition that only allows 3.99gigs, which makes no sense to me, and i found out how to move the website folder to a new partition that would allow more space, but i cant seem to find it. from the terminal i can type df -h and this is what i show

Filesystem Size Used Avail Use% Mounted on
rootfs 3.7G 298M 3.4G 8% /
devtmpfs 984M 132K 984M 1% /dev
tmpfs 988M 4.0K 988M 1% /dev/shm
/dev/md1 3.7G 298M 3.4G 8% /
/dev/mapper/vg00-usr 4.0G 1.3G 2.8G 32% /usr
/dev/mapper/vg00-var 4.0G 179M 3.9G 5% /var
/dev/mapper/vg00-home
4.0G 33M 4.0G 1% /home
/dev/mapper/vg00-srv 4.0G 72M 4.0G 2% /srv

ok so where is the rest of the 250gigs? next i typed in fdisk and i got a message way to long to post, bunch of information, ill show a snippit of what i think was important.

Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders, total 488397168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x370f431a

Device Boot Start End Blocks Id System
/dev/sda1 63 7823654 3911796 fd Linux raid autodetect
/dev/sda2 7823655 11743514 1959930 82 Linux swap / Solaris
/dev/sda3 11743515 488392064 238324275 fd Linux raid autodetect

Disk /dev/md1: 4005 MB, 4005560320 bytes
2 heads, 4 sectors/track, 977920 cylinders, total 7823360 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/md1 doesn’t contain a valid partition table

Disk /dev/md3: 244.0 GB, 244043939840 bytes
2 heads, 4 sectors/track, 59581040 cylinders, total 476648320 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/md3 doesn’t contain a valid partition table

and it lists more folders and size limits… now i didnt install this its automated from 1and1, and im wondering why there is the doesnt contain a valid partition table error showing up? and why if under ( fdisk ), it shows the md3 244gig hdd, but under ( df -h ) it does not? sorry for how long this was, hopefully this is an easy fix… thanks gt

What type of access do you have to the server? What does pvscan, vgscan show? It may very well be that the space is there, however, they didn’t size the logical volume (lv) accordingly.

On Thu, 19 Apr 2012 02:26:02 +0000, gt8684 wrote:

> ok so where is the rest of the 250gigs? next i typed in fdisk and i got
> a message way to long to post, bunch of information, ill show a snippit
> of what i think was important.
>
> Disk /dev/sda: 250.1 GB, 250059350016 bytes

/dev/sda is the storage device in question. /dev/md* are not hard disks
(I want to say they’re ‘memory devices’, ie, a sort of temporary ramdisk
sort of thing stored in memory)

fdisk -l /dev/sda should show you the allocation currently in use:

Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders, total 488397168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x370f431a

Device Boot Start End Blocks Id System
/dev/sda1 63 7823654 3911796 fd Linux raid
/dev/sda2 7823655 11743514 1959930 82 Linux swap
/dev/sda3 11743515 488392064 238324275 fd Linux raid

I don’t see this info in your mounted filesystems - so you should ask the
hosting provider why these partitions aren’t mounted anywhere.

Jim


Jim Henderson
openSUSE Forums Administrator
Forum Use Terms & Conditions at http://tinyurl.com/openSUSE-T-C

On 2012-04-19 06:33, Jim Henderson wrote:
> On Thu, 19 Apr 2012 02:26:02 +0000, gt8684 wrote:

>> Disk /dev/sda: 250.1 GB, 250059350016 bytes
>
> /dev/sda is the storage device in question. /dev/md* are not hard disks
> (I want to say they’re ‘memory devices’, ie, a sort of temporary ramdisk
> sort of thing stored in memory)

Isn’t “vg” indicative of LVM? A logical group? If so, devices can be grown.


Cheers / Saludos,

Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)

@OP: please post any output between CODE tags, makes it much more readable.

AFAIK /dev/md* are not memory devices, but parts of a RAID. But, no time to check right now, glad to be corrected if I’m wrong.

Yes, there’s both RAID and LVM.

Lines like this indicate the presence of a RAID system controlled by mdadm:

/dev/md1 3.7G 298M 3.4G 8% /

Lines like this indicate the prescence of LVM volumes:

/dev/mapper/vg00-usr 4.0G 1.3G 2.8G 32% /usr

To find out what the RAID configuration is, run

cat /proc/mdstat

To learn more about RAID, look at https://raid.wiki.kernel.org/ and the
man page for mdadm

To find out what the LVM configuration is, run

pvscan
lvscan
lvscan

To learn more about LVM, look at http://tldp.org/HOWTO/LVM-HOWTO/

But as a first step, if you post the output of the four commands listed
above, we should be able to figure out exactly what’s there.

Cheers, Dave

Dave Howorth wrote:
> To find out what the LVM configuration is, run
>
> pvscan
> lvscan
> lvscan

OOPS!

That should be:

pvscan
vgscan
lvscan

(the order doesn’t matter)

ok wow, thank you for all the help dont think ive even been in a forum where so many people jump in with help. ok so i have full access to the computer, currently running putty shell client and connected as root. and im sorry, i should have said it, but yes there is a raid system on it for backup perposes, but only for back ups according to my provider, so i only am supposed to have access to a 250gig spread. i ran all the commands y’all asked for, here are the results.

cat /proc/mdstat
Personalities : [raid1] [raid0] [raid10] [raid6] [raid5] [raid4]
md3 : active raid1 sdb3[0] sda3[1]
      238324160 blocks [2/2] [UU]

md1 : active raid1 sda1[0] sdb1[1]
      3911680 blocks [2/2] [UU]

unused devices: <none>
pvscan
PV /dev/md3   VG vg00   lvm2 [227.28 GiB / 211.28 GiB free]
Total: 1 [227.28 GiB] / in use: 1 [227.28 GiB] / in no VG: 0 [0   ]
vgscan
Reading all physical volumes.  This may take a while...
Found volume group "vg00" using metadata type lvm2
lvscan
  ACTIVE            '/dev/vg00/usr' [4.00 GiB] inherit
  ACTIVE            '/dev/vg00/var' [4.00 GiB] inherit
  ACTIVE            '/dev/vg00/home' [4.00 GiB] inherit
  ACTIVE            '/dev/vg00/srv' [4.00 GiB] inherit

again, thanks guys, really appreciate it
gt

gt8684 wrote:
> ok wow, thank you for all the help dont think ive even been in a forum
> where so many people jump in with help. ok so i have full access to the
> computer,

In that case, you might be able to start yast:

ssh -X -l root 1+1-server
yast2

Then look for the disk partitioner application and within that you’ll
see buttons on the left for RAID and LVM management (IIRC the LVM one is
called volume management). It may be quicker and easier to use that than
loads of command lines.

> currently running putty shell client and connected as root.
> and im sorry, i should have said it, but yes there is a raid system on
> it for backup perposes, but only for back ups according to my provider,
> so i only am supposed to have access to a 250gig spread. i ran all the
> commands y’all asked for, here are the results.
>
>
> Code:
> --------------------
> cat /proc/mdstat
> Personalities : [raid1] [raid0] [raid10] [raid6] [raid5] [raid4]
> md3 : active raid1 sdb3[0] sda3[1]
> 238324160 blocks [2/2] [UU]
>
> md1 : active raid1 sda1[0] sdb1[1]
> 3911680 blocks [2/2] [UU]
>
> unused devices: <none>
> --------------------

So there are two RAIDS. md1, we know already is mounted a the root
filesystem.

md3 we see below is used for LVM and is 227 GB:

> Code:
> --------------------
> pvscan
> PV /dev/md3 VG vg00 lvm2 [227.28 GiB / 211.28 GiB free]
> Total: 1 [227.28 GiB] / in use: 1 [227.28 GiB] / in no VG: 0 [0 ]
> --------------------

There’s just the one volume group:

> Code:
> --------------------
> vgscan
> Reading all physical volumes. This may take a while…
> Found volume group “vg00” using metadata type lvm2
> --------------------

and that contains several logical volumes, each of which is rather small:

> Code:
> --------------------
> lvscan
> ACTIVE ‘/dev/vg00/usr’ [4.00 GiB] inherit
> ACTIVE ‘/dev/vg00/var’ [4.00 GiB] inherit
> ACTIVE ‘/dev/vg00/home’ [4.00 GiB] inherit
> ACTIVE ‘/dev/vg00/srv’ [4.00 GiB] inherit
> --------------------

To make them bigger, do something like

lvextend -L+50G /dev/vg00/srv (or whichever filesystem)

to make the LV bigger and then resize the filesystem that is using it.
Somebody else will have to tell you how to do that for ext3, which I
think you said you were using.

> again, thanks guys, really appreciate it

good luck

ok thanks, i think we are making some progress, i read these posts, and found a few online in other places, and i was able to extend the system using

lvextend -L+50G /dev/vg00/srv 

and with that i got this

 lvscan
  ACTIVE            '/dev/vg00/usr' [4.00 GiB] inherit
  ACTIVE            '/dev/vg00/var' [4.00 GiB] inherit
  ACTIVE            '/dev/vg00/home' [4.00 GiB] inherit
  ACTIVE            '/dev/vg00/srv' [54.00 GiB] inherit

ok good right? but, the system only see’s 4gig still. so did some reading up and found that i need to use the resize2fs in order to extend. sounds easy enough. but im getting errors on it…

resize2fs -p /dev/mapper/vg00-srv
resize2fs 1.41.14 (22-Dec-2010)
resize2fs: Bad magic number in super-block while trying to open /dev/mapper/vg00-srv
Couldn't find valid filesystem superblock.

everywhere i read this is the last step and its supposed to work… well its got me hung up… i hope someone see’s the easy answer… lol. thanks guys

woohooo!!! much appreciated guys!! really, i got in yast, wow, what an application, even for me, it was easy, i mean just simple reading and understanding of where things are. i could almost throw windows away :smiley: lol thanks again guys!!!

i was also able to find an updater program in there that allowed me to update the o/s… easy!

gt8684 wrote:
> ok good right? but, the system only see’s 4gig still. so did some
> reading up and found that i need to use the resize2fs in order to
> extend. sounds easy enough. but im getting errors on it…
>
> Code:
> --------------------
> resize2fs -p /dev/mapper/vg00-srv
> resize2fs 1.41.14 (22-Dec-2010)
> resize2fs: Bad magic number in super-block while trying to open /dev/mapper/vg00-srv
> Couldn’t find valid filesystem superblock.
> --------------------
>
> everywhere i read this is the last step and its supposed to work…
> well its got me hung up… i hope someone see’s the easy answer… lol.
> thanks guys

I’m guessing it should have been

resize2fs -p /dev/vg00/srv

but I suppose from your next message that you got everything sorted
using yast?

i did try the resize2fs with a few different directorys and all came back with the same error… but yes sir yast solved all my problems, and easily allowed me to allocate the remaining free space to the /srv partition… which i belive if where everything server related is being stored, so thats perfect, thanks again guys, appreciate it more than you know…

gt8684 wrote:
> i did try the resize2fs with a few different directorys and all came
> back with the same error…

Hmm, it needs the name of the device on which the filesystem is
installed, rather than a directory name. You can probably find what the
correct name was by looking in the yast log.

> but yes sir yast solved all my problems, and
> easily allowed me to allocate the remaining free space to the /srv
> partition… which i belive if where everything server related is being
> stored, so thats perfect, thanks again guys, appreciate it more than you
> know…

Good to know. With LVM, it’s often better to allocate space as you need
it. If you allocate it all to /srv, you might later find that you want
another GB or two in one of the other filesystems but no longer have it.

On 2012-04-20 15:47, Dave Howorth wrote:
> Good to know. With LVM, it’s often better to allocate space as you need
> it. If you allocate it all to /srv, you might later find that you want
> another GB or two in one of the other filesystems but no longer have it.

Yes, that’s the idea of LVM. Else, you would not use LVM at all but fixed
partitions. Less hassle.


Cheers / Saludos,

Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)