NetBSD-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: formating a large disk
derrick.lobo%givex.com@localhost (Derrick Lobo) writes:
>I googled this and could not find a solution to netbsd. I have 2 x 2Tb
>SATA disk that are setup as CCD and am trying to format the with newfs and
>keep getting errors.. I can format a drive if the partition is less than
>2Tb however need more space..
>Any hep will be appreciated.. did some googling and found solution for
>linux but none for netbsd
There are 3 ways to use a disk for a filesystem:
- give it a standard disklabel and use a partition like /dev/ccd0a.
This is limited to 2TB by the disklabel format, otherwise it is the
standard and can be used for anything.
- create a wedge.
You could use 'dkctl addwedge' to specify a part (or all) of the disk
and use it as a dynamically created /dev/dkX device. But that's gone
as soon as you boot the machine.
You can use the gpt tool to create a GUID Partition Table on the ccd device.
Such partitions are automatically found when the kernel attaches a disk
device (like when you start the ccd device) and wedges are automatically
created for such GPT partitions.
wedges can be named and some tools can use these names instead of
the /dev/dkX device path. This is helpful, because the exact name
of the device is impossible to guess. With the name you can reference
it as NAME=wedgename in /etc/fstab and get it mounted.
- create a virtual disk with the device mapper.
The device mapper allows far more complicated mappings than a wedge.
That's why hardly anyone uses the dmsetup tool to create such mappings.
Like 'dkctl addwedge' the result is also only temporary.
Instead you use the LVM tools to label disks as 'physical volumes',
join one or more of these disks into a 'volume group' and the
partition it into 'logical volumes'. The logical volume appears
as a device node under /dev/device-mapper/ and has usually some
other symbolic links pointing to it. LVM labels and volumes aren't
automatically detected by the kernel like wedges or disklabel partitions.
you need to start /etc/rc.d/lvm at boot time or run the 'lvm vgscan'
command manually.
If you really want you can label the ccd device as a 'physical volume'.
But since LVM has similar functionality to ccd, it is easier to make
each of your 2TB disks a 'physical volume' and join them into a volume
group.
So far neither ccd nor LVM is supported as a boot or root device.
Home |
Main Index |
Thread Index |
Old Index