LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   unable to format a 6TB partition (https://www.linuxquestions.org/questions/linux-server-73/unable-to-format-a-6tb-partition-540027/)

dustymugs 03-23-2007 05:20 PM

unable to format a 6TB partition
 
I'm hoping someone can point me to what I am doing wrong. Some info first about the server:

- Slackware 11
- 2.6.21-rc4 SMP kernel with flags...
- CONFIG_EFI_PARTITION=y
- CONFIG_LBD=y
- raid is an Areca Arc-1260 controller with 15x 500GB SATA HDD
- 2 volumes created, one 40GB (/dev/sda) and the other ~6.5TB (/dev/sdb)
- base system is installed in /dev/sda (/, /usr, /home, etc)

I have attempted to use parted for the 6.5TB volume with the following:

root@hydra:~# parted /dev/sdb

(parted) mklabel gpt

(parted) mkpartfs primary ext2 0 6460GB

(parted) print
Model: Areca DATA (scsi)
Disk /dev/sdb: 6460GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number Start End Size File system Name Flags
1 17.4kB 6460GB 6460GB ext2


(parted) quit

I'm pretty sure that I'm using parted write and the final output from parted seems right.

If I try to use mkfs to build an ext3 filesystem, I always get an error...

root@hydra:~# mkfs.ext3 /dev/sdb1
mke2fs 1.38 (30-Jun-2005)
Could not stat /dev/sdb1 --- No such file or directory

The device apparently does not exist; did you specify it correctly?

I get the same error for xfs...

root@hydra:~# mkfs.xfs /dev/sdb1
Cannot stat /dev/sdb1: No such file or directory

If I cat /proc/partitions...

root@hydra:~# cat /proc/partitions
major minor #blocks name

8 0 39060736 sda
8 1 1004031 sda1
8 2 1004062 sda2
8 3 1 sda3
8 5 4008186 sda5
8 6 8008371 sda6
8 7 1004031 sda7
8 8 24025176 sda8
8 16 6308590080 sdb
8 17 6308590046 sdb1

So, any ideas? Any help would be appreciated. If I can't figure this out, I may try replacing one 6.5TB volume with several 1.99TB volumes and use md to stripe them but I would rather do it this way.

Thanks,
dustymugs

xcoldfyrex 03-23-2007 07:17 PM

ext2 has a max size of 2TH

syg00 03-23-2007 08:47 PM

Quote:

Originally Posted by xcoldfyrex
ext2 has a max size of 2TH

Methinks you are talking filesize - the OP is talking filesystem size.

Maybe a re-boot (yeah, I know it's a server). What does /etc/mtab have to say about things ???.

Quakeboy02 03-23-2007 09:17 PM

Do you have "Support For Large Block Devices" configured in your kernel? You need that for devices larger than 2TB.

Quote:

CONFIG_LBD:
Say Y here if you want to attach large (bigger than 2TB) discs to
your machine, or if you want to have a raid or loopback device
bigger than 2TB. Otherwise say N.
Added:
Oh, duh, never mind. I missed that in your post.

Petro P 03-23-2007 09:47 PM

Have you tried formatting it using dd? I'm trying to apply the principle of KISS (Keep it simple, stupid!), and dd is about as simple as it gets.

Code:

# dd if=/dev/zero of=/dev/sdaX
Where /dev/sdaX is your hard drive device or partition that you want to format. This will basically zero out the whole drive and check for bad sectors while it's doing it.

There's a flag you can add to dd to specify exactly how many bytes to write which might be helpful, 'man dd' for more info. Hope this helps.

Petro.

dustymugs 03-24-2007 05:26 PM

Thanks for all the suggestions. I did reboot the server (it's not live yet due to this issue) and checked /etc/mtab (/dev/sdb1 wasn't there).

I zeroed out /dev/sdb to start on a new slate. This took forever (~16 hours). After that, I retried parted but this time using mkpartfs instead of mkpart

root@hydra:~# parted /dev/sdb
(parted) mklabel gpt
(parted) mkpartfs data ext2 0 6459996
(parted) print
Model: Areca DATA (scsi)
Disk /dev/sdb: 6460GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number Start End Size File system Name Flags
1 17.4kB 6460GB 6460GB ext2

(parted) quit

Now that there is a partition and a filesystem, I tried to mount /dev/sdb1 to the same errors as before...

root@hydra:~# mount /dev/sdb1 /mnt
mount: special device /dev/sdb1 does not exist

I've been thinking about this and have wondered if this could be caused by userland utilities? Basically, can the userland utilities from the stock Slackware 11 distro support LBA 64 (16 byte CDB)?

Thanks for all the help thus far! I have also been thinking about trying a 64-bit Linux distro as the server is using Opterons.

Quakeboy02 03-24-2007 05:35 PM

I've never used parted, but where in that do do you actually create /dev/sdb1? I only see a reference to /dev/sdb.

ADDED --- Have you tried a baby step yet? Try creating just a 1GB partition on the drive with fdisk and make a filesystem on it with mkfs.ext3 to see if that works.

dustymugs 03-26-2007 07:13 PM

Thanks guys for all your help. I finally got linux to use the 6TB partition, though my path to it was long. In the end, I think there was a security issue in /dev that prevented the stub from being made.

Thanks again

Quakeboy02 03-26-2007 07:32 PM

Are you going to tell us how you got it worked out?

dustymugs 03-26-2007 08:02 PM

Sure, I can tell how I figured it out. Since I couldn't get linux to put a filesystem on /dev/sdb1 though I ran parted correctly (and constantly got the 'unknown special block device /dev/sdb1' error), I tested to see if the controller itself was being wierd. So after disassembling the server to connect a new hard drive separate from the array, I installed Windows 2003 SP1 to make sure the controller card worked. If Windows didn't like it, that would mean an RMA back to the vendor.

But since windows did like the 6.5TB partition, I knew my slackware install wasn't playing right. After ripping out the windows drive, I loaded up Slax to provide a baseline from which I could compare everything related to system configuration. I basically ended up diffing /etc, /dev, /proc and /sys. Thats when I noticed the permission settings for /dev was completely different from Slax to my install.

At that point, I redid the slackware install rather than deal with changing permissions. After the reinstall, I followed the steps as outlined in my first post and everything worked. As of now, the 6.5TB (still /dev/sdb1) is now an xfs filesystem, mounts cleanly and is about to receive a whole lot of satellite imagery. Next step, openMosix...

Again, thanks for all the helpful advice.

Petro P 03-26-2007 09:14 PM

Glad to hear it worked out for you.


All times are GMT -5. The time now is 02:10 PM.