Thomas-Tsai / partclone

Partclone provides utilities to backup a partition smartly and it is designed for higher compatibility of the file system by using existing library.
GNU General Public License v2.0
306 stars 104 forks source link

Basic f2fs test fails due to 64 MiB rather 100 MB floppy.raw #208

Closed robert-scheck closed 1 year ago

robert-scheck commented 1 year ago

Reproducible with Fedora Rawhide and f2fs-tools-1.14.0-5.fc37:

FAIL: f2fs
==========
Basic f2fs test
==========================
create raw file floppy.raw
    dd if=/dev/zero of=floppy.raw bs=1024 count=65536
65536+0 records in
65536+0 records out
67108864 bytes (67 MB, 64 MiB) copied, 0.231924 s, 289 MB/s
format floppy.raw as f2fs raw partition
    /usr/sbin/mkfs.f2fs  floppy.raw
    F2FS-tools: mkfs.f2fs Ver: 1.14.0 (2020-08-24)
Info: Disable heap-based policy
Info: Debug level = 0
Info: Trim is enabled
Info: Segments per section = 1
Info: Sections per zone = 1
Info: sector size = 512
Info: total sectors = 131072 (64 MB)
Info: zone aligned segment0 blkaddr: 512
Info: format version with
  "Linux version 6.0.10-300.fc37.x86_64 (mockbuild@bkernel01.iad2.fedoraproject.org) (gcc (GCC) 12.2.1 20221121 (Red Hat 12.2.1-4), GNU ld version 2.38-25.fc37) #1 SMP PREEMPT_DYNAMIC Sat Nov 26 16:55:13 UTC 2022"
Info: [floppy.raw] Discarding device
Info: Overprovision ratio = 35.000%
Info: Overprovision segments = 16 (GC reserved = 13)
Info: format successful
clone floppy.raw to floppy.img
    ../src/partclone.f2fs -d -c -s floppy.raw -O floppy.img -F -L test.log -a 1 -k 17
Partclone v0.3.20 http://partclone.org
Starting to clone device (floppy.raw) to image (floppy.img)
You are not logged as root. You may have "access denied" errors when working.
Reading Super Block
f2fsclone.c: f2fs_get_device_info fail
Calculating bitmap... Please wait... 
f2fsclone.c: f2fs_get_device_info fail

Elapsed: 00:00:01, Remaining: 00:00:00, Completed: 100.00%
Total Time: 00:00:01, 100.00% completed!
done!
File system:  F2FS
Device size:   67.1 MB = 16384 Blocks
Space in use:  27.3 MB = 6656 Blocks
Free Space:    39.8 MB = 9728 Blocks
Block size:   4096 Byte

Elapsed: 00:00:01, Remaining: 00:01:39, Completed:   1.00%,   0.00byte/min,

current block:          0, total block:      16384, Complete:   0.00%

Elapsed: 00:00:02, Remaining: 00:00:00, Completed: 100.00%, Rate: 503.56MB/min,

current block:       5633, total block:      16384, Complete: 100.00%
Total Time: 00:00:02, Ave. Rate:  503.6MB/min, 100.00% completed!
Syncing... OK!
Partclone successfully cloned the device (floppy.raw) to the image (floppy.img)
Cloned successfully.
Error: Min volume size supported is 104857600
Error: Min volume size supported is 104857600
do image checking
    ../src/partclone.chkimg -s floppy.img -L test.log
Partclone v0.3.20 http://partclone.org
Starting to check image (floppy.img)
Calculating bitmap... Please wait...
done!
File system:  F2FS
Device size:   67.1 MB = 16384 Blocks
Space in use:  27.3 MB = 6656 Blocks
Free Space:    39.8 MB = 9728 Blocks
Block size:   4096 Byte

Elapsed: 00:00:01, Remaining: 00:01:39, Completed:   1.00%,   0.00byte/min,

current block:          0, total block:      16384, Complete:   0.00%

Elapsed: 00:00:02, Remaining: 00:00:00, Completed: 100.00%, Rate: 503.56MB/min,

current block:       5633, total block:      16384, Complete: 100.00%
Total Time: 00:00:02, Ave. Rate:  503.6MB/min, 100.00% completed!
Partclone successfully checked the image (floppy.img)
Checked successfully.
create raw file floppy.raw for restore
    dd if=/dev/zero of=floppy.raw bs=1024 count=65536
65536+0 records in
65536+0 records out
67108864 bytes (67 MB, 64 MiB) copied, 0.293571 s, 229 MB/s
restore floppy.img to floppy.raw
    ../src/partclone.restore -s floppy.img -O floppy.raw -C -F -L test.log
Partclone v0.3.20 http://partclone.org
Starting to restore image (floppy.img) to device (floppy.raw)
You are not logged as root. You may have "access denied" errors when working.
Calculating bitmap... Please wait...
done!
File system:  F2FS
Device size:   67.1 MB = 16384 Blocks
Space in use:  27.3 MB = 6656 Blocks
Free Space:    39.8 MB = 9728 Blocks
Block size:   4096 Byte

Elapsed: 00:00:01, Remaining: 00:01:39, Completed:   1.00%,   0.00byte/min,

current block:          0, total block:      16384, Complete:   0.00%

Elapsed: 00:00:02, Remaining: 00:00:00, Completed: 100.00%, Rate: 503.56MB/min,

current block:       5633, total block:      16384, Complete: 100.00%
Total Time: 00:00:02, Ave. Rate:  503.6MB/min, 100.00% completed!
Syncing... OK!
Partclone successfully restored the image (floppy.img) to the device (floppy.raw)
Cloned successfully.
    dd if=/dev/zero of=floppy_restore.raw bs=1024 count=65536
65536+0 records in
65536+0 records out
67108864 bytes (67 MB, 64 MiB) copied, 0.242404 s, 277 MB/s
direct clone floppy.raw to floppy_restore.raw
    ../src/partclone.f2fs -d -b -s floppy.raw -O floppy_restore.raw -L test.log
Partclone v0.3.20 http://partclone.org
Starting to back up device(floppy.raw) to device(floppy_restore.raw)
You are not logged as root. You may have "access denied" errors when working.
Warning, you are doing restore to non-block device(floppy_restore.raw)?
Reading Super Block
f2fsclone.c: f2fs_get_device_info fail
Partclone fail, please check test.log !
Error: Min volume size supported is 104857600
FAIL f2fs.test (exit status: 1)