LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Laptop and Netbook
User Name
Password
Linux - Laptop and Netbook Having a problem installing or configuring Linux on your laptop? Need help running Linux on your netbook? This forum is for you. This forum is for any topics relating to Linux and either traditional laptops or netbooks (such as the Asus EEE PC, Everex CloudBook or MSI Wind).

Notices


Reply
  Search this Thread
Old 11-26-2010, 06:44 PM   #1
siawash
Member
 
Registered: Jun 2004
Location: Ireland
Distribution: Zorin 6
Posts: 589

Rep: Reputation: 32
Disk usage


Hello, I am a bit baffled by the partitions I just created. I have two internal drives sda and sdb. sda has 250 gig capacity with sdb 350 gig. I have windows on sda and Ubuntu 10 for laptops on sdb. I thought I created a five gig swap on sdb1 and a 100 gig as root on sdb2 and 250 gig /home partition on sdb3.

I also have an external drive sdc.

Here is what fdisk shows

<code>
sudo /sbin/fdisk -l
[sudo] password for siawacsh:

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

Device Boot Start End Blocks Id System
/dev/sda1 * 1 26 204800 7 HPFS/NTFS
Partition 1 does not end on cylinder boundary.
/dev/sda2 26 30402 243991552 7 HPFS/NTFS

Disk /dev/sdb: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x06abc06d

Device Boot Start End Blocks Id System
/dev/sdb1 1 729 5855661 82 Linux swap / Solaris
/dev/sdb2 730 1945 9764864 83 Linux
/dev/sdb3 1945 38914 296948736 83 Linux

Disk /dev/sdc: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b66d6

Device Boot Start End Blocks Id System
/dev/sdc1 1 19457 156288321 83 Linux


</code>

The strange thing is when I use du command which shows total size of sdb2 as 9.2 gigs and total size of sdb3 as 276 gigs.Can someone throw some light on this?

<code>

du -hf
du: invalid option -- 'f'
Try `du --help' for more information.
siawacsh@siawacsh-laptop:~$ df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sdb2 9.2G 2.6G 6.2G 30% /
none 3.0G 388K 3.0G 1% /dev
none 3.0G 100K 3.0G 1% /dev/shm
none 3.0G 84K 3.0G 1% /var/run
none 3.0G 0 3.0G 0% /var/lock
none 3.0G 0 3.0G 0% /lib/init/rw
/dev/sdb3 279G 1.9G 263G 1% /home
/dev/sdc1 147G 3.3G 137G 3% /media/b3a20778-5b78-487e-9aa7-145bbe772964
/dev/sdc1 147G 3.3G 137G 3% /home/siawacsh/myhome


</code>

<code>


df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sdb2 9.2G 2.8G 6.0G 32% /
none 3.0G 388K 3.0G 1% /dev
none 3.0G 100K 3.0G 1% /dev/shm
none 3.0G 108K 3.0G 1% /var/run
none 3.0G 0 3.0G 0% /var/lock
none 3.0G 0 3.0G 0% /lib/init/rw
/dev/sdb3 279G 1.9G 263G 1% /home
/dev/sdc1 147G 3.3G 137G 3% /media/b3a20778-5b78-487e-9aa7-145bbe772964
/dev/sdc1 147G 3.3G 137G 3% /home/siawacsh/myhome
/dev/sda1 200M 29M 172M 15% /media/System



</code>
 
Old 11-26-2010, 07:28 PM   #2
Soadyheid
Senior Member
 
Registered: Aug 2010
Location: Near Edinburgh, Scotland
Distribution: Cinnamon Mint 20.1 (Laptop) and 20.2 (Desktop)
Posts: 1,672

Rep: Reputation: 486Reputation: 486Reputation: 486Reputation: 486Reputation: 486
Code:
Filesystem Size Used Avail Use% Mounted on
/dev/sdb2 9.2G 2.6G 6.2G 30% /

/dev/sdb3 279G 1.9G 263G 1% /home
Hmmm... This doesn't quite match what you say you set the partitions up like. Have you checked what the drive looks like with GParted or are you doing everything with the command line?

Quote:
I thought I created a five gig swap on sdb1
Why did you create a 5Gb swap partition? How much physical memory do you have in your system? 5Gb seems far too much to me. Check out your system usage with System Monitor under System > Administration. Unless you're running some heavy memory resident stuff you probably won't use swap at all. It certainly shouldn't be greater than your physical memory size and would probably only be used for core dumps in the event of a crash.

My

Play Bonny!
 
Old 11-26-2010, 07:38 PM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,126

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
df shows the filesystem - seems to agree with fdisk. What you have is what you have - they can be resized in need. Use the gparted liveCD.

As for swap, what about hibernation ?.
 
Old 11-26-2010, 08:32 PM   #4
siawash
Member
 
Registered: Jun 2004
Location: Ireland
Distribution: Zorin 6
Posts: 589

Original Poster
Rep: Reputation: 32
Thanks guys. I opted for a reinstall and repartitioned. I was missing a zero when specifying the size of root partition. The system describes it in MB's instead GB. Now I have 76 GB hdb2 and 238 GB hdb3 as described by gparted. But df gives a different reading. My swap size reflects the actual size of my physical memory.

df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sdb2 70G 2.8G 64G 5% /
none 3.0G 388K 3.0G 1% /dev
none 3.0G 476K 3.0G 1% /dev/shm
none 3.0G 108K 3.0G 1% /var/run
none 3.0G 0 3.0G 0% /var/lock
none 3.0G 0 3.0G 0% /lib/init/rw
/dev/sdb3 219G 204M 208G 1% /home
/dev/sdc1 147G 3.3G 137G 3% /media/b3a20778-5b78-487e-9aa7-145bbe772964
 
Old 11-26-2010, 08:53 PM   #5
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,126

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
Quote:
Originally Posted by siawash View Post
Now I have 76 GB hdb2 and 238 GB hdb3 as described by gparted. But df gives a different reading.
Probably gibibyte versus gigabyte. See wikipedia
 
Old 11-27-2010, 11:08 AM   #6
Soadyheid
Senior Member
 
Registered: Aug 2010
Location: Near Edinburgh, Scotland
Distribution: Cinnamon Mint 20.1 (Laptop) and 20.2 (Desktop)
Posts: 1,672

Rep: Reputation: 486Reputation: 486Reputation: 486Reputation: 486Reputation: 486
@syg00
Quote:
As for swap, what about hibernation ?
Interesting, I didn't think this was one of swap spaces uses, see below.

Quote:
Hibernation is a feature of many computer operating systems where the contents of RAM are written to non-volatile storage such as a hard disk, as a file or on a separate partition, before powering off the computer.
Source: Wikipedia, Hibernation (Computing)

I thought the contents of RAM were just stored as a file though Wikipedia DOES say that different systems use different methods.

Play Bonny!

Last edited by Soadyheid; 11-27-2010 at 11:09 AM.
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Disk Usage Analyzer reports too much disk space? ler0nldb2 Linux - Newbie 1 09-12-2009 10:27 AM
Disk usage ak.lokesh Linux - Newbie 4 02-20-2009 04:11 PM
disk usage ?? sachinh Linux - General 3 11-16-2007 01:03 PM
AS 2.1 disk usage buck2bcr Red Hat 4 03-23-2004 09:50 AM
101% disk usage on an empty disk tsiuser Linux - Software 3 01-28-2004 06:24 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Laptop and Netbook

All times are GMT -5. The time now is 12:15 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration