LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 10-15-2006, 09:25 PM   #1
carlosinfl
Senior Member
 
Registered: May 2004
Location: Orlando, FL
Distribution: Debian
Posts: 2,896

Rep: Reputation: 73
Missing 12GB of Disk Space?


OK - I just installed Debian. Here is the hardware.

2 x 250GB SATA Western Digital drivres

The drives are identical and running from a PCI RAID card in RAID1. After I did a bare install on Debian, I notice that I am missing 12GB of disk space.

Here you can see the drives are only seen as 228GB but that is OK since WD allocates space differently. My question is if my Debian install only used up 417MB's of space, where is the rest of the data. How do I only have 216 GB's if space available?

Code:
cwilliams@shark:~$ df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/sda1             228G  417M  216G   1% /
tmpfs                 252M     0  252M   0% /dev/shm
Here is how I partitioned the disk if this can help you answer my question...

Code:
Disk /dev/sda: 250.0 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       30213   242685891   83  Linux
/dev/sda2           30214       30401     1510110    5  Extended
/dev/sda5           30214       30401     1510078+  82  Linux swap / Solaris

Last edited by carlosinfl; 10-15-2006 at 09:29 PM.
 
Old 10-15-2006, 09:53 PM   #2
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 63
Using Ext3 for the filesystem? If so that is where your space went with the 5% reserved space (228*.05=11.40) when formatting to stop the partition from becoming full accidently.
 
Old 10-15-2006, 10:14 PM   #3
trickykid
Guru
 
Registered: Jan 2001
Posts: 24,133

Rep: Reputation: 199Reputation: 199
Quote:
Originally Posted by HappyTux
Using Ext3 for the filesystem? If so that is where your space went with the 5% reserved space (228*.05=11.40) when formatting to stop the partition from becoming full accidently.
Part of this is for the superblocks and how the drive is formatted as well. There has to be some type of information stored on the drive on how the filesystem is laid out, etc.

Take for instance, I have 124.5GB Hitachi drives, after formatting and filesystem creation with ext3, they come out to be about 114GB in available space.
 
Old 10-15-2006, 11:59 PM   #4
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 63
Quote:
Originally Posted by trickykid
Part of this is for the superblocks and how the drive is formatted as well. There has to be some type of information stored on the drive on how the filesystem is laid out, etc.

Take for instance, I have 124.5GB Hitachi drives, after formatting and filesystem creation with ext3, they come out to be about 114GB in available space.
Of course but I don't believe that is the case here in my little experiment I performed here on a spare machine it appears that df takes that into account already when giving the display size of the partition as you can see here my on HD.
Code:
Welcome to Knoppix!
root@0[~]# fdisk -l

Disk /dev/sda: 203.9 GB, 203928109056 bytes
255 heads, 63 sectors/track, 24792 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       24792   199141708+  83  Linux
Now with it formated ext3 defaults I end up with 187gb for final partition size, 129mb used for the journal and related files, finally only 178gb free on the partition ~=9gb loss which at 187*.05=9.35 for 5% reserved is well within rounding error for using human readable switch.
Code:
root@0[~]# mkfs.ext3 /dev/sda1
mke2fs 1.39-WIP (09-Apr-2006)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
24903680 inodes, 49785427 blocks
2489271 blocks (5.00%) reserved for the super user
First data block=0
1520 block groups
32768 blocks per group, 32768 fragments per group
16384 inodes per group
Superblock backups stored on blocks:
        32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
        4096000, 7962624, 11239424, 20480000, 23887872

Writing inode tables: done
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 37 mounts or
180 days, whichever comes first.  Use tune2fs -c or -i to override.
root@0[~]# mount /dev/sda1 /mnt/sda1
root@0[~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/root             2.5M   22K  2.4M   1% /
/ramdisk              799M  3.1M  796M   1% /ramdisk
/UNIONFS              2.7G  2.0G  796M  72% /UNIONFS
/dev/hdc              697M  697M     0 100% /cdrom
/dev/cloop            1.9G  1.9G     0 100% /KNOPPIX
/dev/sda1             187G  129M  178G   1% /media/sda1
Here is using 1% reserved same 187gb and 129mb with this time 185gb free ~=2gb loss 187*.01=1.87 is within rounding error for human readable switch again.
Code:
root@0[~]# umount /mnt/sda1
root@0[~]# mkfs.ext3 -m1 /dev/sda1
mke2fs 1.39-WIP (09-Apr-2006)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
24903680 inodes, 49785427 blocks
497854 blocks (1.00%) reserved for the super user
First data block=0
1520 block groups
32768 blocks per group, 32768 fragments per group
16384 inodes per group
Superblock backups stored on blocks:
        32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
        4096000, 7962624, 11239424, 20480000, 23887872

Writing inode tables: done
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 32 mounts or
180 days, whichever comes first.  Use tune2fs -c or -i to override.
root@0[~]# mount /dev/sda1 /mnt/sda1
root@0[~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/root             2.5M   22K  2.4M   1% /
/ramdisk              799M  3.1M  796M   1% /ramdisk
/UNIONFS              2.7G  2.0G  796M  72% /UNIONFS
/dev/hdc              697M  697M     0 100% /cdrom
/dev/cloop            1.9G  1.9G     0 100% /KNOPPIX
/dev/sda1             187G  129M  185G   1% /media/sda1
Now here using reiserfs you see the partition size loss for using ext3 I end up with 190gb for final partition size, 33mb for journal and related files and a df of 190gb so the formatting of ext3 uses up ~3gb making the partition format for its filesystem on my drive, which df already takes into account when determining the final size of the partition.
Code:
root@0[~]# umount /mnt/sda1
root@0[~]# mkfs.reiserfs  /dev/sda1
mkfs.reiserfs 3.6.19 (2003 www.namesys.com)

A pair of credits:
Many persons came to www.namesys.com/support.html,  and got a question answered
for $25, or just gave us a small donation there.

Alexander Zarochentcev  (zam)  wrote the high low priority locking code, online
resizer for V3 and V4, online repacker for V4, block allocation code, and major
parts of  the flush code,  and maintains the transaction manager code.  We give
him the stuff  that we know will be hard to debug,  or needs to be very cleanly
structured.


Guessing about desired format.. Kernel 2.6.17 is running.
Format 3.6 with standard journal
Count of blocks on the device: 49785424
Number of blocks consumed by mkreiserfs formatting process: 9731
Blocksize: 4096
Hash function used to sort names: "r5"
Journal Size 8193 blocks (first block 18)
Journal Max transaction length 1024
inode generation number: 0
UUID: 73281d84-bcc3-4413-8cf0-444d79f60fc6
ATTENTION: YOU SHOULD REBOOT AFTER FDISK!
        ALL DATA WILL BE LOST ON '/dev/sda1'!
Continue (y/n):y
Initializing journal - 0%....20%....40%....60%....80%....100%
Syncing..ok

Tell your friends to use a kernel based on 2.4.18 or later, and especially not a
kernel based on 2.4.9, when you use reiserFS. Have fun.

ReiserFS is successfully created on /dev/sda1.
root@0[~]# mount /dev/sda1 /mnt/sda1
root@0[~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/root             2.5M   22K  2.4M   1% /
/ramdisk              799M  3.3M  795M   1% /ramdisk
/UNIONFS              2.7G  2.0G  795M  72% /UNIONFS
/dev/hdc              697M  697M     0 100% /cdrom
/dev/cloop            1.9G  1.9G     0 100% /KNOPPIX
/dev/sda1             190G   33M  190G   1% /media/sda1
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
DF command: 12GB of memory's missing! C-RAF. Linux - Hardware 6 01-16-2006 06:48 PM
DF command: 12GB of memory's missing! C-RAF. Programming 10 01-16-2006 07:21 AM
missing disk space Ayman.mashal Linux - Software 4 06-16-2005 02:41 PM
I seem to be missing disk space... Brother Michael Linux - Newbie 13 12-07-2003 06:49 PM


All times are GMT -5. The time now is 02:02 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration