OpenBSD

I've been using OpenBSD for many years (started with 2.x). I've donated equipment to them and am listed on the donations page.

Why OpenBSD?

Security! while other OSs may be easier to use, I know that installing the latest version of OpenBSD is going to give me a secure system.
If I need to open an inbound connection to the big-bad-internet, if that system that has information on it I'd rather not have public, I'll make sure it's running OpenBSD.
Other than hardware upgrades (and the occasional wrong lead unplug problem) the servers just stay up. My personal best was over 1000 days for a public web server (Apache got patched and restarted a few times, but the main box didn't need rebooting).

Big disk support

I started this page, because I couldn't find very much information about big disk support on OpenBSD. My home server is mainly used as a music and picture server, and it's disks were starting to get full, so it was time to increase the disk size. Currently it's got two 2.0TB drives and one 1.0TB drive in it. With the price of 2.5TB and 3.0TB disks coming down (<15,000 yen for a 3.0TB Hitachi HDS72303 drive in Akihabara) it was time to upgrade.

Normally I just plug the new drive into a USB->SATA adapter, and use "cp -Rp", "dd", or "rsync -av" to copy the data across, but the USB->SATA adapter wouldn't address past the 2^32 sector (so about 2.2TB). I spent ages messing with fdisk (and gpart on a FreeBSD live disc), but couldn't get it to work.
So I fired up an old experimental system of mine, which is running OpenBSD4.6, but I'd expect this to work on later releases as well.
I use the existing boot drive (1.5TB) and connected this as the second drive to the on-board SATA adapter, it's an old shuttle system with a "VIA VT6420 SATA" SATA adapter, but I think it will work on most supported SATA adapters.
On boot up the BIOS see it as a 800G drive (2^32 sectors is 2200G, so it's showing the additional 1565560706 sectors)
I just used "fdisk -a {drive}" to initialise the MBR. It claimed the same as the BIOS, 1565560706 sectors, so not a good start.
I then used "disklabel -E {drive}" to set the OpenBSD slices. After some experimentation, here is what I did:
# disklabel -E wd1
Label editor (enter '?' for help at any prompt)
> e
Changing device parameters for /dev/rwd1c:
disk type: [ESDI]
label name: [Hitachi HDS72303]
sectors/track: [63]
tracks/cylinder: [255]
sectors/cylinder: [16065]
number of cylinders: [364801]
total sectors: [5860533168]
rpm: [3600]
interleave: [1]
> b
Starting sector: [0]
Size ('*' for entire disk): [0] *
> p
OpenBSD area: 0-5860533168; size: 5860533168; free: 5860533168
# size offset fstype [fsize bsize cpg]
c: 5860533168 0 unused

I added a couple of drives (a 1TB as 'a' and a 1.8TB as 'd'), then write, then quit, then initialised the new slices.
Notes:

Note: If you want to use the whole drive, then be careful about the block size. Using the default block/fragment size means that fsck will fail, because it can't allocate enough memory (more than 700M required). It's not a physical memory or swap space issue, it exceeds the per-process limit.
To avoid this I used a bigger block/fragment size. Here is the command line I used:
newfs -O 2 -b 32768 -f 4096 -g 8000000 /dev/{device}
-b = block size
-f = fragment size
-g = average file size





Homepage.
This page was lasted updated on Friday, 29-Jul-2011 06:49:35 BST

This content comes from a hidden element on this page.

The inline option preserves bound JavaScript events and changes, and it puts the content back where it came from when it is closed.

Click me, it will be preserved!

If you try to open a new Colorbox while it is already open, it will update itself with the new content.

Updating Content Example:
Click here to load new content