How Much Space Before 1st Partition?


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers How Much Space Before 1st Partition?
# 15  
Old 11-25-2014
1000kb is "drivermaker's megabytes", invented to inflate the apparent capacity of the drives they sell.
# 16  
Old 11-25-2014
Hey Guys, thanks for the reply about the block stuff...

So if I run the dd command(s) you gave I get this output below...

Up to 512-bytes:
Code:
# dd if=/dev/sdc bs=512 count=1 | od -c
1+0 records in
1+0 records out
0000000  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
*
512 bytes (512 B) copied0000660  \0  \0  \0  \0  \0  \0  \0  \0 006 311 003   U  \0  \0 200    
, 0.00276015 s, 185 kB/s
0000700   !  \0 203     004      \0  \b  \0  \0 004 330  \a  \0  \0   @
0000720   !     203  \0 301 212  \0 350  \a  \0  \v   / 326  \0  \0 003
0000740 372 212 202 376 377 307  \0 030 336  \0 310   1 017  \0  \0  \0
0000760  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0   U 252
0001000

All the way to 2048:
Code:
# dd if=/dev/sda bs=512 count=4 | od -c 
# dd if=/dev/sdc bs=512 count=4 | od -c 
0000000  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
4+0 records in
4+0 records out
*
2048 bytes (2.0 kB) copied0000660  \0  \0  \0  \0  \0  \0  \0  \0 006 311 003   U  \0  \0 200    
0000700   !  \0 203     004      \0  \b  \0  \0 004 330  \a  \0  \0   @
, 0.00280096 s, 731 kB/s
0000720   !     203  \0 301 212  \0 350  \a  \0  \v   / 326  \0  \0 003
0000740 372 212 202 376 377 307  \0 030 336  \0 310   1 017  \0  \0  \0
0000760  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0   U 252
0001000  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
*
0002000 321  \0       @  \0 200 220  \0  \0  \0  \0  \0   ,   t 220  \0
0002020       t 220  \0  \0   t 220  \0  \0  \0  \0  \0  \0  \0  \0  \0
0002040  \0   p 220  \0  \0 200  \0  \0  \0  \0  \0  \0 322  \0   `   @
0002060 314  \0   \ 004 002  \f   @   h  \0 300   ?   ? 002  \f   @   l
0002100  \0   0 374 003 002  \f   @   p 017 377 300  \0 002  \f   @   t
0002120   ? 360  \0  \0 002  \f   @   x  \0 377 363  \0 002  \f   @   |
0002140 017  \0  \0 303 002  \f   @ 200  \0  \0 003 377 002 016  \0 020
0002160 360  \0  \0 317 002 016  \0 030  \0 177  \0 177 002 016  \0 034
0002200  \0 177  \0 177 002  \f   @   `  \0  \0  \0 373  \0  \0  \0  \0
0002220  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
*
0004000

Is it safe to say here that the asterisks in the output above denote EMPTY space in that area of the disk..?

Also, so I'm clear on the sector/block size stuff.
If this below is the output for fdisk, and the START is 2048 and the UNIT size 512 bytes.
So for every "1 Unit" out of the 2048 START point, that would be: .5kb * 2048 = 1024 Kb... Is that right?
Code:
# fdisk -l /dev/sdc

Disk /dev/sdc: 7969 MB, 7969177600 bytes
255 heads, 63 sectors/track, 968 cylinders, total 15564800 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: 0x5503c906

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1   *        2048      516099      257026   83  Linux
/dev/sdc2          518144    14554890     7018373+  83  Linux
/dev/sdc3        14555136    15550919      497892   82  Linux swap / Solaris

Thanks Again for the help, much appreciated!

Thanks,
Matt
# 17  
Old 11-25-2014
Quote:
Originally Posted by RudiC
512 bytes = 1/2 kB
1024 bytes = 1 kB
This now is where discrepancies start:
1024 kB = 1 M?B (sometimes MiB)
1000 kB = 1 M?B
etc...
Oops! Smilie Made corrections
Sorry mrm5102

I'll try again. Smilie
Quote:
.5kb * 2048 = 1024 Kb... Is that right?
.5 * 2048 Kb = 1024 Kb... Is that right? Yes
.5kb(512 bytes) * 2048 = 1048576 bytes (1.048 Mb)

Last edited by ongoto; 11-25-2014 at 08:13 PM.. Reason: added quote
# 18  
Old 11-25-2014
Quote:
Originally Posted by mrm5102
...

Up to 512-bytes:
Code:
# dd if=/dev/sdc bs=512 count=1 | od -c
1+0 records in
1+0 records out
0000000  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
*
512 bytes (512 B) copied0000660  \0  \0  \0  \0  \0  \0  \0  \0 006 311 003   U  \0  \0 200    
, 0.00276015 s, 185 kB/s
0000700   !  \0 203     004      \0  \b  \0  \0 004 330  \a  \0  \0   @
0000720   !     203  \0 301 212  \0 350  \a  \0  \v   / 326  \0  \0 003
0000740 372 212 202 376 377 307  \0 030 336  \0 310   1 017  \0  \0  \0
0000760  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0   U 252
0001000

All the way to 2048:
Code:
# dd if=/dev/sda bs=512 count=4 | od -c 
# dd if=/dev/sdc bs=512 count=4 | od -c 
0000000  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
4+0 records in
4+0 records out
*
2048 bytes (2.0 kB) copied0000660  \0  \0  \0  \0  \0  \0  \0  \0 006 311 003   U  \0  \0 200    
0000700   !  \0 203     004      \0  \b  \0  \0 004 330  \a  \0  \0   @
, 0.00280096 s, 731 kB/s
0000720   !     203  \0 301 212  \0 350  \a  \0  \v   / 326  \0  \0 003
0000740 372 212 202 376 377 307  \0 030 336  \0 310   1 017  \0  \0  \0
0000760  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0   U 252
0001000  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
*
0002000 321  \0       @  \0 200 220  \0  \0  \0  \0  \0   ,   t 220  \0
0002020       t 220  \0  \0   t 220  \0  \0  \0  \0  \0  \0  \0  \0  \0
0002040  \0   p 220  \0  \0 200  \0  \0  \0  \0  \0  \0 322  \0   `   @
0002060 314  \0   \ 004 002  \f   @   h  \0 300   ?   ? 002  \f   @   l
0002100  \0   0 374 003 002  \f   @   p 017 377 300  \0 002  \f   @   t
0002120   ? 360  \0  \0 002  \f   @   x  \0 377 363  \0 002  \f   @   |
0002140 017  \0  \0 303 002  \f   @ 200  \0  \0 003 377 002 016  \0 020
0002160 360  \0  \0 317 002 016  \0 030  \0 177  \0 177 002 016  \0 034
0002200  \0 177  \0 177 002  \f   @   `  \0  \0  \0 373  \0  \0  \0  \0
0002220  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
*
0004000

Is it safe to say here that the asterisks in the output above denote EMPTY space in that area of the disk..?
No. There is no such thing as empty space on a character special file. The asterisk in the output from od means that the lines of output replaced by the asterisk are duplicates of the output shown on the line above. In this case, they all happen to be NUL bytes, but they could just as easily represent repeated occurrences of the characters "0123456789ABCDEF" (or any other sequence of 16 bytes).
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Red Hat

Allot free space from one partition to other

I have a RHEL 5.3 machine with the following partitions and free space: Free space on the partitions / : 74GB /boot : 81MB /var : 73GB /home : 37GB /icat : 758MB /opt : 1.5GB Now is it possible to allot a free space of some other partitions to /opt? I want around 100 GB more space... (4 Replies)
Discussion started by: omniok
4 Replies

2. Shell Programming and Scripting

How to consume all available space on partition?

Hi I'm doing some resilience testing and need to write a script to consume all of the available disk space on a partition and then to free it up again. This would need to be - Safe Dynamic, in that it calculates the free space prior to consuming it. I might want to go on to consume a... (7 Replies)
Discussion started by: bbq
7 Replies

3. Linux

How to increase root space from another partition?

Hi OS Experts I would like to increase root partition from another partition so that I can save more documents in Home and Desktop. whether it is possible without formating root partition if so please explain here is o/p of df -h Filesystem Size Used Avail Use% Mounted on /dev/sda9... (8 Replies)
Discussion started by: Akshay Hegde
8 Replies

4. Slackware

Ideal partition sizes of 17 gb space.

I am planning to install slack 13.37 on an old stand-alone PIII (512 mb ram) with 17 gb disk space. I need to keep lotsa pdf, chm type e-books for programming with few other misc. documents. I'm going to use this system for my personal use. It has no network but I browse internet with cable... (0 Replies)
Discussion started by: vectrum
0 Replies

5. UNIX for Dummies Questions & Answers

shifting space from one partition to other

hi My System is Sun Microsystems Inc. SunOS 5.10 Solaris Partition Info is /dev/vx/dsk/bootdg/var 27G 25G 1.2G 96% /var /dev/vx/dsk/bootdg/oravol 110G 54G 56G 49% /export/home I want to shift space 20G from /export/home to /var What should be the command ?? (2 Replies)
Discussion started by: kaushik02018
2 Replies

6. Red Hat

RHEL 5 supports only 2 TB space for a partition !

Dear Friends , I am using Redhat Ent Linux 5.0 with a EMC storage which HDD space is 4 TB. After Installing RHEL 5 , I get 4 TB space available but when I am going to create a partition then the OS show 2TB available space . I cannot create a partition above 2TB space . Is there any limitation... (3 Replies)
Discussion started by: shipon_97
3 Replies

7. UNIX for Dummies Questions & Answers

Best ways of increasing space on a partition

Hi, On one of our solaris servers, the root partition has filled up,(it was poorly sized in the first place), Does anyone have any advice about the best way to add space to a partition. I'm sure I've read how to do this somewhere before but just can't remember...:( A colleague has suggested... (1 Reply)
Discussion started by: kenny123m
1 Replies

8. Shell Programming and Scripting

Disk space for root partition

Hello, I am trying to monitor disk space for each node on the machine. I am able to get all individual nodes but for the '/' node. For example: df -k: bash-2.05b# df -k Filesystem 1K-blocks Used Available Use% Mounted on /dev/xxx 4127108 2415340 1502120 62% / /dev/yyy ... (3 Replies)
Discussion started by: chiru_h
3 Replies

9. UNIX for Advanced & Expert Users

moving space from one partition to another

How can I move some space allocated to one partition to another, i.e. from "/var" to "/" . Thanks! (4 Replies)
Discussion started by: jason6792
4 Replies

10. UNIX for Dummies Questions & Answers

Swap Partition Space

first of all, sorry about my english...I´m a spanish newbie to this marvelous OS and i have just a couple of doubts...u know? :-) 1) how big should my swap partition be if i installed debian 2.2r3 or FreeBSD 4.x on a AMD k7 1400Mhz with 512Mb of Random Access Memory? i heard that those OS... (1 Reply)
Discussion started by: I[X]ION
1 Replies
Login or Register to Ask a Question