From owner-freebsd-geom@FreeBSD.ORG Wed Apr 27 16:38:18 2011 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 475CB1065670 for ; Wed, 27 Apr 2011 16:38:18 +0000 (UTC) (envelope-from gcubfg-freebsd-geom@m.gmane.org) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by mx1.freebsd.org (Postfix) with ESMTP id F34948FC0A for ; Wed, 27 Apr 2011 16:38:17 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1QF7kl-0002E5-Pv for freebsd-geom@freebsd.org; Wed, 27 Apr 2011 18:38:15 +0200 Received: from dtmd-4db2f6a1.pool.mediaways.net ([77.178.246.161]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 27 Apr 2011 18:38:15 +0200 Received: from christian.baer by dtmd-4db2f6a1.pool.mediaways.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 27 Apr 2011 18:38:15 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-geom@freebsd.org From: Christian Baer Date: Wed, 27 Apr 2011 18:37:59 +0200 Lines: 40 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: dtmd-4db2f6a1.pool.mediaways.net User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.16) Gecko/20101125 Lightning/1.0b1 Thunderbird/3.0.11 Subject: 4K sectors on the drive, bigger sectors for geli and newfs? X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Apr 2011 16:38:18 -0000 Hi folks! A few days ago I installed a new drive that I would like to encrypt with geli. It's one of the new ones with 4K sectors which means I have to partition it differently than the older drives I have. What I did so far: gpart create -s gpt /dev/ad6 gpart add -b 2048 -t freebsd-ufs /dev/ad6 That should align the partition correctly. pjd wrote in a post, that geli uses more than one key for larger file systems, so I am quite happy to create a single (2TB) partion and file system. Due to the nature of the files that will mostly be stored on the drive (digital photographs in raw format), my newfs will look something like this (my idea): newfs -L raw -O ufs2 -U -f 4096 -b 32768 -i 2097152 /dev/ad6p1.eli An inode every 2^21 bytes should do fine. Most of the files on the drive (I expect something like 90%) will be 7MB or larger. Any objections so far? Would it make sense to make the frags and blocks even larger? Considering that, I'm wondering how to init geli, especially using the -s option. geli init -e aes-xts -l 256 -s $NUMBER /dev/ad6p1 It stands to reason that $NUMBER should not be smaller than 4096 bytes since the drive itself doesn't have anything smaller to offer. :-) What would be a good value? 4096 or 32768 or something else? What does this default to? Best regards, Chris