[SOLVED] Partiotioing a 6TB hadr drive using parted-getting error when running mklabel
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Partiotioing a 6TB hadr drive using parted-getting error when running mklabel
Hello all,
I have a 6TB USB drive attached to a redhat server. I am trying to create a 3TB partition on it. I am trying to use parted as with fdisk we cannot create partitions more than 2TB.
When i run parted and execute the command mklabel GPT, i get the below error:
# parted /dev/sdb
Warning: Device /dev/sdb has a logical sector size of 4096. Not all parts of GNU Parted support this at the moment, and the working code is HIGHLY EXPERIMENTAL.
GNU Parted 1.8.1
Using /dev/sdb
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) mklabel gpt
Error: Invalid argument during write on /dev/sdb
Retry/Ignore/Cancel? Cancel
(parted) q
$ parted --version
parted (GNU parted) 3.2
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Written by <http://git.debian.org/?p=parted/parted.git;a=blob_plain;f=AUTHORS>.
since you're using a Redhat server, you should update your system from the repositories.
That parted version 1.8.1 suggests that the server is running RHEL 5, which will go EOL in less than 2 years (March, 2017), and that is the most recent version available for RHEL 5. Looks like you've got hardware that just isn't well supported in RHEL 5. You might be able to work around the problem by connecting the disk to another, newer system for partitioning.
Thank you for the reply. As i see 1.8 version is the latest version for parted on RHEL5.
Can i try to use fdisk instead of parted to create a partition less than 1TB on a 6TB hard drive? When i run fdisk /dev/sdb and create a partition of size 250 GB (256000MB), it is creating a default partition os size 69 GB irrespective of how much size i specify while creating the partition? Please advice.
# fdisk /dev/sdb
Note: sector size is 4096 (not 512)
The number of cylinders for this disk is set to 91199.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)
WARNING: The size of this disk is 6.0 TB (6001140957184 bytes).
DOS partition table format can not be used on drives for volumes
larger than 2.2 TB (2199023255040 bytes). Use parted(1) and GUID
partition table format (GPT).
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-91199, default 1): 1
Last cylinder or +size or +sizeM or +sizeK (1-91199, default 91199): +256000M
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
I mounted the partition /dev/sdb1 on /mnt/backups. See below. The space is showing as 69GB.
I believe that the RHEL 5 version of fisdk is not GPT-aware and is limited to an MS-DOS partition table. An MS-DOS partition table cannot address any part of the disk beyond 2 TiB, so you would be wasting about 2/3 of that 6 TB disk.
# fdisk /dev/sdb
Note: sector size is 4096 (not 512)
I read that as 4096 logical / 4096 physical. I'm not sure the kernel in RHEL 5 even supports a 4096-byte logical sector size. You are getting way beyond what that old OS was intended to handle. Since this is RHEL and you presumably have a subscription, I suggest you call Red Hat and ask.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.