[DRBD-user] online shrinking problem

Charles Tree pbb3576 at gmail.com
Thu Jun 7 11:13:38 CEST 2012

Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.


Hello,

I try to shrink a drbd device online. The documentation says:

"To shrink DRBD on-line, issue the following command *after* you have
shrunk the file system residing on top of it:

# drbdadm resize --size=<new-size> <resource>

You may use the usual multiplier suffixes for *<new-size>* (K, M, G etc.).
After you have shrunk DRBD, you may also shrink the containing block device
(if it supports shrinking)."

 cat /proc/drbd
version: 8.4.1 (api:1/proto:86-100)
GIT-hash: 91b4c048c1a0e06777b5f65d312b38d47abaea80 build by root at somehost,
2012-03-18 09:32:17

<snip>
 2: cs:Connected ro:Primary/Secondary ds:UpToDate/UpToDate C r-----
    ns:0 nr:0 dw:0 dr:3588 al:0 bm:0 lo:0 pe:0 ua:0 ap:0 ep:1 wo:b oos:0
<snip>

 drbdadm -V
DRBDADM_BUILDTAG=GIT-hash:\ 91b4c048c1a0e06777b5f65d312b38d47abaea80\
build\ by\ root at somehost\,\ 2012-03-18\ 09:32:08
DRBDADM_API_VERSION=1
DRBD_KERNEL_VERSION_CODE=0x080401
DRBDADM_VERSION_CODE=0x080401
DRBDADM_VERSION=8.4.1

 fdisk -l /dev/drbd2

Disk /dev/drbd2: 78.4 GB, 78380724224 bytes
255 heads, 63 sectors/track, 9529 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xa97119f5

      Device Boot      Start         End      Blocks   Id  System

No partitions at all, no filesystem either, as this is just a test for the
real resize of a live system.

The problem:

# drbdadm resize --size=60G r2
drbdadm: unrecognized option '--size'
try 'drbdadm help resize'

'drbdadm help resize' doesn't mention --size as possible option

I'd like to know how can I shrink my drbd device.

Thanks for your help.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linbit.com/pipermail/drbd-user/attachments/20120607/9320f4f4/attachment.htm>


More information about the drbd-user mailing list