Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:Marvin1973:pcs
ocfs2-test
0002-backup_super-fix-hard-code-for-blocksize.p...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0002-backup_super-fix-hard-code-for-blocksize.patch of Package ocfs2-test
From 43a8141b39c08061249c19d6b4104312cfd85b1a Mon Sep 17 00:00:00 2001 From: Gang He <ghe@suse.com> Date: Fri, 1 May 2020 13:39:02 +0800 Subject: [PATCH 2/2] backup_super: fix hard code for blocksize Fix hard code for blocksize in volume_small_test() function, since there are 4094 logic block size devices. We should use the inputed block size parameter. --- programs/backup_super/test_backup_super.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/programs/backup_super/test_backup_super.sh b/programs/backup_super/test_backup_super.sh index 3542a21..72da871 100755 --- a/programs/backup_super/test_backup_super.sh +++ b/programs/backup_super/test_backup_super.sh @@ -363,7 +363,7 @@ function volume_small_test() #generate a tmp vol size which is less than 1G local tmp_vol_size=`expr $RANDOM \* $FIRST_BACKUP_OFF / 32767` - local tmp_block_count=`expr $tmp_vol_size / 1024` + local tmp_block_count=`expr $tmp_vol_size / $blocksize` #If block count is too small, mkfs will failed. if [ `expr $tmp_block_count` -lt 20000 ]; then tmp_block_count=20000 @@ -371,7 +371,7 @@ function volume_small_test() # Since tunefs will return 0, we need to grep # the output of stderr and find what we want. - echo "y" |${MKFS_BIN} -b 1K -C 4K ${DEVICE} -N 4 --no-backup-super $tmp_block_count \ + echo "y" |${MKFS_BIN} -b $blocksize -C 4K ${DEVICE} -N 4 --no-backup-super $tmp_block_count \ --cluster-stack=${CLUSTER_STACK} --cluster-name=${CLUSTER_NAME} err=`${TUNEFS_BIN} --backup-super ${DEVICE} 2>&1` echo $err|grep "too small to contain backup superblocks" -- 2.12.3
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor