LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices



Reply
 
Search this Thread
Old 10-07-2013, 04:27 AM   #1
gaurav0918
LQ Newbie
 
Registered: Oct 2013
Location: NEW DELHI
Posts: 2

Rep: Reputation: Disabled
value out of range error on a disk with 40 GB FREE space


Hi,

I installed RHEL 6.0 OS on vmware with CREATE CUSTOM LAYOUT option. And I gave the space to different mount points as mentioned below:
/ 15360MB
/boot 200MB
/tmp 3072 MB
swap 1024 MB.

fdisk -cul command shows the disk size as 64.4 GB. But when I try to create partion of 10 GB with fdisk -cu command, it says "value out of range". When I created the partition with maximum possible space, it created the partion of 999 KB.

My question is where the remaining 40 GB space gone. And how can I create the partition of 10 GB space ?

Please see the sequence of the commands below:

[root@gauravclient Desktop]# fdisk -cul

Disk /dev/sda: 64.4 GB, 64424509440 bytes
255 heads, 63 sectors/track, 7832 cylinders, total 125829120 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: 0x0007fb86

Device Boot Start End Blocks Id System
/dev/sda1 * 2048 411647 204800 83 Linux
/dev/sda2 411648 31868927 15728640 83 Linux
/dev/sda3 31868928 36063231 2097152 83 Linux
/dev/sda4 36063232 125829119 44882944 5 Extended
/dev/sda5 36067328 38164479 1048576 82 Linux swap / Solaris
[root@gauravclient Desktop]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda2 15G 2.3G 12G 16% /
tmpfs 504M 100K 504M 1% /dev/shm
/dev/sda1 194M 24M 161M 13% /boot
/dev/sda3 2.0G 68M 1.9G 4% /tmp
/dev/sr0 2.8G 2.8G 0 100% /media/RHEL_6.0 i386 Disc 1

[root@gauravclient Desktop]#

[root@gauravclient Desktop]# fdisk -cu /dev/sda

Command (m for help): n
First sector (36065280-125829119, default 36065280):
Using default value 36065280
Last sector, +sectors or +size{K,M,G} (36065280-36067327, default 36067327): +10G
Value out of range.
Last sector, +sectors or +size{K,M,G} (36065280-36067327, default 36067327):
Using default value 36067327

Command (m for help): p

Disk /dev/sda: 64.4 GB, 64424509440 bytes
255 heads, 63 sectors/track, 7832 cylinders, total 125829120 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: 0x0007fb86

Device Boot Start End Blocks Id System
/dev/sda1 * 2048 411647 204800 83 Linux
/dev/sda2 411648 31868927 15728640 83 Linux
/dev/sda3 31868928 36063231 2097152 83 Linux
/dev/sda4 36063232 125829119 44882944 5 Extended
/dev/sda5 36067328 38164479 1048576 82 Linux swap / Solaris
/dev/sda6 36065280 36067326 1023+ 83 Linux

Partition table entries are not in disk order

Command (m for help): w
The partition table has been altered!

Calling ioctl() to re-read partition table.

WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
The kernel still uses the old table. The new table will be used at
the next reboot or after you run partprobe(8) or kpartx(8)
Syncing disks.
[root@gauravclient Desktop]# partx -a /dev/sda
BLKPG: Device or resource busy
error adding partition 1
BLKPG: Device or resource busy
error adding partition 2
BLKPG: Device or resource busy
error adding partition 3
BLKPG: Device or resource busy
error adding partition 4
BLKPG: Device or resource busy
error adding partition 5
[root@gauravclient Desktop]# mkdir /test
[root@gauravclient Desktop]# mkfs.ext4 /dev/sda6
mke2fs 1.41.12 (17-May-2010)
Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
Stride=0 blocks, Stripe width=0 blocks
128 inodes, 1020 blocks
51 blocks (5.00%) reserved for the super user
First data block=1
Maximum filesystem blocks=1048576
1 block group
8192 blocks per group, 8192 fragments per group
128 inodes per group

Writing inode tables: done

Filesystem too small for a journal
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 23 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
[root@gauravclient Desktop]# blkid /dev/sda6
/dev/sda6: UUID="f2acf882-697e-42b9-abb6-30eb15166ec8" TYPE="ext4"

[root@gauravclient Desktop]# vim /etc/fstab

[root@gauravclient Desktop]# mount -a

[root@gauravclient Desktop]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda2 15G 2.3G 12G 16% /
tmpfs 504M 264K 504M 1% /dev/shm
/dev/sda1 194M 24M 161M 13% /boot
/dev/sda3 2.0G 68M 1.9G 4% /tmp
/dev/sr0 2.8G 2.8G 0 100% /media/RHEL_6.0 i386 Disc 1
/dev/sda6 999K 17K 931K 2% /test

[root@gauravclient Desktop]#

Last edited by gaurav0918; 10-07-2013 at 05:41 AM.
 
Old 10-07-2013, 10:39 AM   #2
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: CentOS
Posts: 1,621

Rep: Reputation: 676Reputation: 676Reputation: 676Reputation: 676Reputation: 676Reputation: 676
You've got a small gap at the beginning of the extended partition due to your swap partition being offset by an extra 1MB, and fdisk is defaulting to start your new partition in that tiny 1MB space. You can just select a more appropriate starting location after the swap partition. A suitable starting location would be sector 38166528. Then you should have about 42GB available.

What I suggest, though, is to delete and re-create your swap partition to start at sector 36065280. That will get rid of that 1MB gap and avoid this problem in the future. (You will need to do a "swapoff -av" first, and afterward run "mkswap /dev/sda5" and "swapon -av".)
 
1 members found this post helpful.
  


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
RHEL 6 in VMWare - Always boots to the command line instead of GUI P.S.Shiva Linux - Newbie 8 09-25-2012 02:01 AM
[SOLVED] Oracle 11gR2 Installation on RHEL 6.2 with VMWARE Java 132 error th3n3d Linux - Newbie 2 06-05-2012 10:52 AM
[SOLVED] Fdisk Value out of range mail2vivek1 Linux - Newbie 7 03-20-2012 07:30 AM
Out of Range Error on Monitor - RHEL v.5 jthompson Linux - Hardware 3 10-04-2010 02:56 PM
fdisk in vmware phishintrip Linux - Software 6 07-25-2003 04:18 PM


All times are GMT -5. The time now is 03:10 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration