Skip to contentSkip to conversation

loop device broken in 2.4.6-pre5

DISCUSSION [email protected] 1 participant 1 message Jun 26, 2001

lore
Share & tools
lore
#0 lore raw
Quoted 6 lines · Rogier Wolff
Quoted 2 lines

But why 1024?
(Or make the set blocksize ioctl also work on loop devices.)

I thought the change was a "quick hack" that would make stuff work (page cache?) near the end of the file. That would mean that this kind of "quick hack" won't work.

I am not sure I can parse your sentence.
But:

# blockdev --getbsz /dev/loop1
0
# dd if=/dev/zero of=tenbl bs=1024 count=10
10+0 records in
10+0 records out
# losetup /dev/loop1 tenbl
# blockdev --getbsz /dev/loop1
4096
# dd if=/dev/zero of=/dev/loop1 bs=1024 count=10
dd: writing `/dev/loop1': No space left on device
9+0 records in
8+0 records out
# blockdev --setbsz 2048 /dev/loop1
# blockdev --getbsz /dev/loop1
2048
# dd if=/dev/zero of=/dev/loop1 bs=1024 count=10
10+0 records in
10+0 records out
#

Andries