| Linux - Server This forum is for the discussion of Linux Software used in a server related context. |
| 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.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
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.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
09-09-2009, 06:16 AM
|
#1
|
|
LQ Newbie
Registered: Jan 2005
Posts: 18
Rep:
|
Reducing the size of a device in an existing RAID set/Seagate formatting problem
Alternate Heading: Unable to use opensuse partitioner to fully format a Seagate 1Tb drive
OK. Swapped over a motherboard to increase the number of slots available for hard drives so that I could expand my raid array (4 X 1Tb drives).
Discovered I had no thermal paste so all delayed for 24 hours while I bought some, miscalculated on rebuild and had to reinstall OpenSuse but in the end system is now up and running.
Unfortunately when I formatted my new 1Tb drive (Seagate) it formats to 931.50 Gb while the other 4 drives formatted to 931.51 Gb (they are WD).
I'm now in the position that when I try to add this new drive I get :
mdadm: /dev/sdc1 not large enough to join array
Is there any way I can resize the existing devices down to 931.50 Gb so that I can add in the new drive without having to restore the array?
Last edited by horde; 09-22-2009 at 03:53 AM.
Reason: put my last edit in the wrong spot
|
|
|
|
09-10-2009, 12:49 AM
|
#2
|
|
Guru
Registered: Aug 2004
Location: Brisbane
Distribution: Centos 6.4, Centos 5.9
Posts: 15,000
|
fdisk is your friend
|
|
|
|
09-10-2009, 05:03 AM
|
#3
|
|
LQ Newbie
Registered: Jan 2005
Posts: 18
Original Poster
Rep:
|
At the moment fdisk is only a relatively close neighbour.
How can I make it my friend? To increase the size of the formatted Seagate drive or to reduce the size of the other devices? Is that possible with the RAID assembled?
|
|
|
|
09-12-2009, 02:30 AM
|
#4
|
|
LQ Newbie
Registered: Jan 2005
Posts: 18
Original Poster
Rep:
|
Just in case soeone gets into the same position that I was. FDISK did eventually become my froend - still not sure why the advice was so enigmatic.
My problem:
WHen creating a partition on my new 1Tb Seagate drive openSUSE YAST created a partition of size 953.50Gb when I set it to create the maximum partition. Previousely it had created partitions of 953.51Gb on 4 1Tb WD drives I had bought so when I tried to add this new device to the array I received:
mdadm: /dev/sdc1 not large enough to join array
My solution:
Running fdisk -l gave me:
The first entry repeated 4 times for each of the raid devices
Disk /dev/sdb: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x000655ae
Device Boot Start End Blocks Id System
/dev/sdb1 1 121601 976760001 fd Linux raid autodetect
and this for the new device:
Disk /dev/sdc: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x000b7001
Device Boot Start End Blocks Id System
/dev/sdc1 2 121601 976752000 fd Linux raid autodetect
Saw the starting in Cylcinder 2 and thought I'd manually create the device in YAST rather than just setting it to max. Unfortunately YAST/partitioner refused toallow parameters 1 -> 122601.
So decided use my new best friend :
# fdisk /dev/sdc
The number of cylinders for this disk is set to 121601.
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)
Command (m for help): p
Disk /dev/sdc: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x000b7001
Device Boot Start End Blocks Id System
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-121601, default 1): 1
Last cylinder, +cylinders or +size{K,M,G} (1-121601, default 121601): 121601
Command (m for help): t
Selected partition 1
Hex code (type L to list codes): fd
Changed system type of partition 1 to fd (Linux raid autodetect)
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
Then it showed in partitioner as 953.51Gb - all was ok with the world.
(just to finish off the raid expand:
# mdadm /dev/md1 -a /dev/sdc1
mdadm: added /dev/sdc1
# mdadm --grow /dev/md1 --raid-devices=5
mdadm: Need to backup 1536K of critical section..
mdadm: ... critical section passed.
.... and the long wait starts
|
|
|
|
09-14-2009, 12:29 AM
|
#5
|
|
Guru
Registered: Aug 2004
Location: Brisbane
Distribution: Centos 6.4, Centos 5.9
Posts: 15,000
|
I was probably in a hurry and got the impression you knew enough to figure the rest out ,... as you did.
Good one

|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 01:40 PM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|