NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Problem with gpt partitioning in NetBSD-5.0.2 amd64



I have tested some more with disks in pass-through mode => no problems
when creating disklabels or gpt tables. I discovered that I might have
to create a MBR with sysid 238 and then run the gpt commands to create
partitions. But now when going back to the RAID5 array I'm stuck with:

server1# fdisk
sd0                                                            
Disk: /dev/rsd0d
NetBSD disklabel disk geometry:
cylinders: 72660, heads: 252, sectors/track: 480 (120960 sectors/cylinder)
total sectors: 199126528

BIOS disk geometry:
cylinders: 1024, heads: 1, sectors/track: 8 (8 sectors/cylinder)
total sectors: 8789061120

Partition table:
0: GPT Protective MBR (sysid 238)
    start 20, size 199126508 (97230 MB, Cyls 2/0/5-24890815)
        PBR is not bootable: Bad magic number (0x0000)
1: <UNUSED>
2: <UNUSED>
3: <UNUSED>
Bootselector disabled.
No active partition.
server1# gpt show sd0
gpt: unable to open device 'rsd0d': Invalid argument

Why cannot I execute any gpt commands? All the /dev/sd0? and /dev/rsd0?
devices are there.

/Peter

On 03/31/2010 05:02 PM, Christos Zoulas wrote:
> In article <4BB235BA.8000309%kerwien.homeip.net@localhost>,
> Peter Kerwien  <peter%kerwien.homeip.net@localhost> wrote:
>   
>> Hi,
>>
>> I have created a RAID5 array called sd0 with the following size etc:
>>
>> sd0 at scsibus0 target 0 lun 0: <Areca, Volume Set #0, R001> disk fixed
>> sd0: 4190 GB, 72660 cyl, 252 head, 480 sec, 512 bytes/sect x 8789061120
>> sectors
>>
>> I have been able to create a gpt partition of the whole array, created a
>> wedge and format it with newfs. But now, after some experiments, I am
>> trying to do that again. But always fails at the creation of the gpt
>> table: it is too small.
>>
>> # gpt destroy sd0                                                      
>> # gpt create sd0
>> # gpt show sd0
>>   start    size  index  contents
>>       0       1         PMBR
>>       1       1         Pri GPT header
>>       2      32         Pri GPT table
>>      34  204733        
>>  204767      32         Sec GPT table
>>  204799       1         Sec GPT header
>>
>> I have tried to "erase" the disk with a couple of different dd commands.
>> But it seems that gpt says that my disk is equal the amount of zeros
>> that i write with the dd command. Zeroing a 4T disk will not be ver
>> fast. What am I doing wrong? How do I erase the disk so gpt can again
>> utilize my entire disk?
>>
>> When it worked I use the following commands:
>>
>> # gpt destroy sd0
>> # gpt create sd0
>> # gpt add -t ufs sd0
>> # dkctl sd0d addwedge dk0 34 8789061053 ffs
>> # newfs -O2 -s -64m rdk0
>>     
> I think that gpt is putting a signature at the end of the drive and perhaps
> you have to zap this.
>
> christos
>
>   


Home | Main Index | Thread Index | Old Index