search for: getsz

Displaying 15 results from an estimated 15 matches for "getsz".

Did you mean: gets
2012 Mar 19
16
LV resize encrypted volume
...rting the new extended size to the PV domU even though dom0 is well aware of the new size. I''ve rebooted domU (not dom0 yet as that''s running a lot of other domU''s). The LV I tried to resize is encrypted. Resizing unencrypted volumes works as expected. dom0:~# blockdev --getsz /dev/d/lv3 1258291200 domU:~# blockdev --getsz /dev/sdc1 1048576000 Any suggestions? regards, Jan
2019 Feb 25
7
Problem with mdadm, raid1 and automatically adds any disk to raid
...ke, yet I wanted the mirrored. Here starts my problem, I cannot get rid of the /dev/mdX no matter what I do (try to do). I tried to delete the MDX, I removed the disks by failing them, then removing each array md0, md1 and md2. I also did dd if=/dev/zero of=/dev/sdX bs=512 seek=$(($(blockdev --getsz /dev/sdX)-1024)) count=1024 dd if=/dev/zero of=/dev/sdX bs=512 count=1024 mdadm --zero-superblock /dev/sdX Then I wiped each partition of the drives using fdisk. Now every time I start fdisk to setup a new set of partitions I see in /var/log/messages as soon as I hit "W" in fdisk:...
2014 Nov 23
0
[PATCH 2/3] New API: guestfs_blockdev_setra: Adjust readahead for filesystems and devices.
...} int do_blockdev_getbsz (const char *device) { - return (int) call_blockdev (device, "--getbsz", 0, 1); + return (int) call_blockdev (device, "--getbsz", -1, 1); } int @@ -128,23 +138,23 @@ do_blockdev_setbsz (const char *device, int blocksize) int64_t do_blockdev_getsz (const char *device) { - return call_blockdev (device, "--getsz", 0, 1); + return call_blockdev (device, "--getsz", -1, 1); } int64_t do_blockdev_getsize64 (const char *device) { - return call_blockdev (device, "--getsize64", 0, 1); + return call_blockdev (d...
2020 Feb 10
2
Re: [RFC] lib: allow to specify physical/logical block size for disks
...n be relevant for the alignment of disk data. We don't have an API to get this one. logical_block_size: The logical block size the disk will report to the guest OS. For Linux this would be the value returned by the BLKSSZGET ioctl and describes the smallest units for disk I/O. We have blockdev-getsz API to get this value. How do they use. If your HDD has physical block size = 4096 you might want make I/O request equals to (or multiple) this value. Otherwise you might hit performance penalty. I think, the same is valid for virtual disk image which is located on physical storage with 4K physica...
2014 Nov 23
7
[PATCH 0/3] patches needed for virt-bmap
See http://rwmj.wordpress.com/2014/11/23/mapping-files-to-disk/
2014 Nov 24
2
[PATCH v2 0/2] patches needed for virt-bmap
Does *not* incorporate changes suggested by Pino yet. Rich.
2013 Oct 28
0
[PATCH] xfstests: add generic/320 to test fsync() on directories V2
...is program; if not, write the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +# +# +# common functions for setting up and tearing down a dmflakey device + +FLAKEY_ALLOW_WRITES=0 +FLAKEY_DROP_WRITES=1 + +_init_flakey() +{ + local BLK_DEV_SIZE=`blockdev --getsz $SCRATCH_DEV` + FLAKEY_DEV=/dev/mapper/flakey-test + FLAKEY_TABLE="0 $BLK_DEV_SIZE flakey $SCRATCH_DEV 0 180 0" + FLAKEY_TABLE_DROP="0 $BLK_DEV_SIZE flakey $SCRATCH_DEV 0 0 180 1 drop_writes" + $DMSETUP_PROG create flakey-test --table "$FLAKEY_TABLE" || \ + _fatal &qu...
2020 Feb 10
0
Re: [RFC] lib: allow to specify physical/logical block size for disks
...t of disk data. We don't have an API > to get this one. > > logical_block_size: The logical block size the disk will report to the > guest OS. For Linux this would be the value returned by the BLKSSZGET > ioctl and describes the smallest units for disk I/O. We have > blockdev-getsz API to get this value. Interestingly parted uses BLKSSZGET (logical_block_size), but does not use BLKPBSZGET (physical_block_size), so I guess that fits with my observations. > How do they use. If your HDD has physical block size = 4096 you might > want make I/O request equals to (or multip...
2019 Feb 26
0
Problem with mdadm, raid1 and automatically adds any disk to raid
On 2/24/19 9:01 PM, Jobst Schmalenbach wrote: > I tried to delete the MDX, I removed the disks by failing them, then removing each array md0, md1 and md2. > I also did > > dd if=/dev/zero of=/dev/sdX bs=512 seek=$(($(blockdev --getsz /dev/sdX)-1024)) count=1024 Clearing the initial sectors doesn't do anything to clear the data in the partitions.? They don't become blank just because you remove them. Partition your drives, and then use "wipefs -a /dev/sd{b,c}{1,2,3}" > I do NOT WANT this to happen, it...
2019 Feb 25
0
Problem with mdadm, raid1 and automatically adds any disk to raid
...> Here starts my problem, I cannot get rid of the /dev/mdX no matter what I do (try to do). > > I tried to delete the MDX, I removed the disks by failing them, then removing each array md0, md1 and md2. > I also did > > dd if=/dev/zero of=/dev/sdX bs=512 seek=$(($(blockdev --getsz /dev/sdX)-1024)) count=1024 > dd if=/dev/zero of=/dev/sdX bs=512 count=1024 > mdadm --zero-superblock /dev/sdX > > Then I wiped each partition of the drives using fdisk. The superblock is a property of each partition, not just of the whole disk. So I believe you need to do: mdad...
2019 Feb 25
0
Problem with mdadm, raid1 and automatically adds any disk to raid
...ere starts my problem, I cannot get rid of the /dev/mdX no matter what I > do (try to do). > > I tried to delete the MDX, I removed the disks by failing them, then > removing each array md0, md1 and md2. > I also did > > dd if=/dev/zero of=/dev/sdX bs=512 seek=$(($(blockdev --getsz > /dev/sdX)-1024)) count=1024 I didn't check but are you really sure you're cleaning up the end of the drive? Maybe you should clean the end of every partition first because metadata may be written there. > dd if=/dev/zero of=/dev/sdX bs=512 count=1024 > mdadm --zero-superblo...
2013 Nov 15
7
[PATCH 1/2] xfstests: add generic/321 to test fsync() on directories V2
...ronment, filters and checks . ./common/rc . ./common/filter +. ./common/dmflakey # real QA test starts here _supported_fs generic @@ -63,49 +60,12 @@ _require_dm_flakey [ -x $here/src/fsync-tester ] || _notrun "fsync-tester not build" rm -f $seqres.full -BLK_DEV_SIZE=`blockdev --getsz $SCRATCH_DEV` -FLAKEY_DEV=/dev/mapper/flakey-test SEED=1 testfile=$SCRATCH_MNT/$seq.fsync -FLAKEY_TABLE="0 $BLK_DEV_SIZE flakey $SCRATCH_DEV 0 180 0" -FLAKEY_TABLE_DROP="0 $BLK_DEV_SIZE flakey $SCRATCH_DEV 0 0 180 1 drop_writes" -_TEST_OPTIONS="" - -_mount_flakey() -...
2019 Feb 26
2
Problem with mdadm, raid1 and automatically adds any disk to raid
> On 2/24/19 9:01 PM, Jobst Schmalenbach wrote: >> I tried to delete the MDX, I removed the disks by failing them, then >> removing each array md0, md1 and md2. >> I also did >> >> dd if=/dev/zero of=/dev/sdX bs=512 seek=$(($(blockdev --getsz >> /dev/sdX)-1024)) count=1024 > > > Clearing the initial sectors doesn't do anything to clear the data in > the partitions.? They don't become blank just because you remove them. > > Partition your drives, and then use "wipefs -a /dev/sd{b,c}{1,2,3}" >...
2020 Feb 07
8
[RFC] lib: allow to specify physical/logical block size for disks
From: Nikolay Ivanets <stenavin@gmail.com> I faced with situation where libguestfs cannot recognize partitions on a disk image which was partitioned on a system with "4K native" sector size support. In order to fix the issue we need to allow users to specify desired physical and/or logical block size per drive basis. It is definitely not a complete patch but rather a way to
2009 Aug 12
23
[PATCH 0/23] factor and const-correctness
This started as a simple warning-elimination change. I'll get back to that series shortly ;-) It turned into a factorization and constification exercise during which I got a taste of ocaml. Thanks to Rich Jones for help with a few snippets in generator.ml. The overall result is that many previously-manually-maintained bits from daemon/*.c functions are now hoisted into the automatically-