I read both the FAQ section and the growfs(8) man page but I am not
yet confident that what I want to do is supported / safe.

http://www.openbsd.org/faq/faq14.html#GrowPartition

I started with a number of partitions and a bunch of free space.  I
later needed the free space and allocated a /project partition that
went to the end of my disk.  More recently, I emptied the /data
partition immediately prior.  Now I would like to use growfs(8) to
merge this unused space with the /project partition without losing any
of the existing data.

See disklabel output below.  I have only grown partitions "down",
never in the other direction.  Am I being overly paranoid?

Thanks.

--david

[david@apu2 ~]$ doas disklabel sd0
# /dev/rsd0c:
type: SCSI
disk: SCSI disk
label: SATA SSD
duid: dab5be6fe5a0d623
flags:
bytes/sector: 512
sectors/track: 63
tracks/cylinder: 255
sectors/cylinder: 16065
cylinders: 7297
total sectors: 117231408
boundstart: 64
boundend: 117226305
drivedata: 0

16 partitions:
#                size           offset  fstype [fsize bsize   cpg]
  a:          2104448               64  4.2BSD   2048 16384 12958 # /
  b:          8385933          2104512    swap                    # none
  c:        117231408                0  unused
  d:          8401952         10490464  4.2BSD   2048 16384 12958 # /tmp
  e:          8385952         18892416  4.2BSD   2048 16384 12958 # /var
  f:          4192960         27278368  4.2BSD   2048 16384 12958 # /usr
  g:          2088448         31471328  4.2BSD   2048 16384 12958 # /usr/X11R6
  h:          6281424         33559776  4.2BSD   2048 16384 38128 # /usr/local
  i:          6297440         39841216  4.2BSD   2048 16384 12958 # /usr/ports
  j:          2088448         46138656  4.2BSD   2048 16384 12958 # /home
  k:         16771872         48227104  4.2BSD   2048 16384 12958 # /data
  l:         52227328         64998976  4.2BSD   2048 16384 12958 # /project

Reply via email to