nixCraft Linux Forum

nixCraft

Linux Tech Support Forum

Partition

This is a discussion on Partition within the Getting started tutorials forums, part of the Linux Getting Started category; Hi all I've a 9 GB SCSI disk, i want to create a fixed partion of 512MB but if i ...


Go Back   nixCraft Linux Forum > Linux Getting Started > Getting started tutorials

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 10-21-2007, 06:42 AM
Member
User
 
Join Date: Jul 2006
Posts: 48
Rep Power: 0
asim.mcp
Angry Partition

Hi all

I've a 9 GB SCSI disk, i want to create a fixed partion of 512MB but if i define 512 it create a partion of size 509.97 but i need it to be fixed at 512MB, so can anyone tell me how should be i define to create a fixed partion?


Regards
Asim
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 10-24-2007, 03:05 PM
Junior Member
User
 
Join Date: Sep 2007
Location: Mumbai
My distro: Fedora,CentOS,Redhat,FreeBSD
Posts: 15
Rep Power: 0
aaru is on a distinguished road
Send a message via Yahoo to aaru Send a message via Skype™ to aaru
Cool

Hi,

If you create any partition, by default it ll take 5% of the filesystem blocks reserved for the super-user.This avoids fragmentation, andallows root-owned daemons, such as syslogd(, to continue to function correctly after non-privileged processes are prevented from writing to the filesystem.

If you do not want this then you have to specify the following option at the time of filesystem creation.

#mke2fs -m reserved-blocks-percentage /dev/hda1

Note:

refer man page of mke2fs
__________________
thanks,
aaru
Reply With Quote
  #3 (permalink)  
Old 12-20-2007, 05:28 PM
Junior Member
User
 
Join Date: Jul 2007
My distro: Debian
Posts: 8
Rep Power: 0
vimalgoel is on a distinguished road
Default

if you are using fdisk to create the file system, so try to use 512M to create 512 MB partition.
Reply With Quote
  #4 (permalink)  
Old 03-24-2008, 05:16 PM
Member
User
 
Join Date: Mar 2008
My distro: Debian, Slackware, LFS
Posts: 83
Rep Power: 1
Tux-Idiot is on a distinguished road
Default

damn you stumped me again with that question.
when you run mkfs.filesystem_extn viz. mkfs.ext2 or mkfs.ext3 and pass the switch -v you will see mkfs will allocate some blocks for the inode tables. and inode tables is where the file system is indexed. inode table is like house door number which tells the io where to seek the file. thus if your partition size is 512 MiB? and you are trying to have 512 MiB as space for that file system? then either set the size/resize of that partition to 550+ MiB. even if you use jffs which is nice when space is a pinch else try ext2 and set the block size normal which is 512 or ext3 with block size 1k, you will still need to sacrifice some space for the creation of the inode tables.
you really got me stumped. because you can never have the cake and eat it.
thus if you think you use fdisk and make a 512 mb partition and also want to have 512 mb space? be my guest.


aaru you became my guest:
#mke2fs -m reserved-blocks-percentage /dev/hda1

Note:

refer man page of mke2fs
i will buy you some beer. please also run dumpfs -v and debugfs -v and show me how you got 512 MB space of a 512 MB space parition against that /dev/drive_map_device_partition_number.
Reply With Quote
  #5 (permalink)  
Old 03-24-2008, 05:20 PM
Member
User
 
Join Date: Mar 2008
My distro: Debian, Slackware, LFS
Posts: 83
Rep Power: 1
Tux-Idiot is on a distinguished road
Default

Quote:
Originally Posted by vimalgoel View Post
if you are using fdisk to create the file system, so try to use 512M to create 512 MB partition.
impossible! i can lay a 50 US $ bet right now! if you do this. 512*1024*8==512*1204*8
p.s. you may use gparted or kparted and expand/resize that 509.97 mb to 512 mb using the mouse. squeek!
Reply With Quote
  #6 (permalink)  
Old 03-24-2008, 05:23 PM
Member
User
 
Join Date: Mar 2008
My distro: Debian, Slackware, LFS
Posts: 83
Rep Power: 1
Tux-Idiot is on a distinguished road
Default

Quote:
Originally Posted by Tux-Idiot View Post
impossible! i can lay a 50 US $ bet right now! if you do this. 512*1024*8==512*1204*8
p.s. you may use gparted or kparted and expand/resize that 509.97 mb to 512 mb using the mouse. squeek!
:s/512*1024==512*1204/ 512*1024==512*1024
"512*1024==512*1024"
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

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 On
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
Linux boot partition ramjimh Linux software 1 03-24-2008 06:48 PM
partition resize myfoot XEN 1 12-03-2007 09:43 PM
mounting within an already mounted partition scytale Linux software 2 08-17-2007 09:36 PM
backup lvm partition chimu Linux software 1 12-21-2006 02:29 AM
Deleted SWAP partition sonaikar Linux software 1 02-05-2005 06:20 PM


All times are GMT +5.5. The time now is 05:11 PM.


Powered by vBulletin® Version 3.7.3 - Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36