Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 4 May 2010 05:20:03 GMT
From:      "Andrey V. Elsukov" <bu7cher@yandex.ru>
To:        freebsd-bugs@FreeBSD.org
Subject:   Re: misc/146277: gpart add -s 128M creates 1GB partition on 4k	sectorsize disk
Message-ID:  <201005040520.o445K3Lw026231@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR misc/146277; it has been noted by GNATS.

From: "Andrey V. Elsukov" <bu7cher@yandex.ru>
To: Jeremy Faulkner <gldisater@gmail.com>
Cc: freebsd-gnats-submit@FreeBSD.org, 
 Marcel Moolenaar <marcel@FreeBSD.org>
Subject: Re: misc/146277: gpart add -s 128M creates 1GB partition on 4k	sectorsize
 disk
Date: Tue, 04 May 2010 08:59:13 +0400

 On 04.05.2010 4:24, Jeremy Faulkner wrote:
 >> Description:
 > When using gpart to create a GPT partition on a device that has a sector size of 4k it will
 > create a partition that is much larger than requested. It appears to be using 512 sector size to
 > calculate the number of sectors to allocate even when the sector size is not 512.
 >> How-To-Repeat:
 > gnop create -S 4k<disk or partition> gpart create -s GPT<gnop'd disk or partition> gpart add -s
 > 512M -t freebsd-swap<gnop'd disk or partition>
 >
 > gpart will create a 4GB partition instead of a 512M partition
 
 This is known issue. When gpart(8) parses arguments it doesn't know about medium's sector size.
 
 -- 
 WBR, Andrey V. Elsukov



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201005040520.o445K3Lw026231>