For example:
have ocfs2 mounted volume as storage on proxmox.
ocfs2 volume have next blocksize
and volume on barmetal storage and hdd/ssd have 512 or 4096 bytes blocksize.
After create container, created image have partition with blocksize: 512 bytes
That is not good for align and have penalties on write:
512 -> 4096 -> 512
or
How to setup blocksize for containers on create?
have ocfs2 mounted volume as storage on proxmox.
ocfs2 volume have next blocksize
Code:
/sbin/tunefs.ocfs2 -Q 'blocksize: %B\nclustersize: %T\n' /dev/sdd1
blocksize: 4096
clustersize: 4096
After create container, created image have partition with blocksize: 512 bytes
That is not good for align and have penalties on write:
512 -> 4096 -> 512
Code:
fdisk -l /data1/images/100/vm-100-disk-1.raw
Disk /data1/images/100/vm-100-disk-1.raw: 8 GiB, 8589934592 bytes, 16777216 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x9bf7d5ca
Device Boot Start End Sectors Size Id Type
/data1/images/100/vm-100-disk-1.raw1 * 2048 16775167 16773120 8G 83 Linux
Code:
fdisk -l /dev/mapper/vg01-vm--104--disk--1
Disk /dev/mapper/vg01-vm--104--disk--1: 50 GiB, 53687091200 bytes, 104857600 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
How to setup blocksize for containers on create?