]> git.sur5r.net Git - bacula/bacula/blobdiff - regress/tests/big-files-test
regress: add function to create many dirs
[bacula/bacula] / regress / tests / big-files-test
index 04c543bb403d341c07c305d8b89de2ba293aafa3..ff5f5fb3f9082f65904913e2d8f84807755cce80 100755 (executable)
@@ -16,14 +16,15 @@ copy_test_confs
 
 echo "${cwd}/many-files" >${cwd}/tmp/file-list
 if [ ! -f ${cwd}/many-files/100000file100000 ]; then
-    mkdir ${cwd}/many-files
+    mkdir -p ${cwd}/many-files
     cd ${cwd}/many-files
-    print_debug "Creating files..."
-    time perl -e 'for($i=0; $i < 2000000; $i++) {open(FP, ">${i}file${i}") or die "$!"; print FP "$i\n"; close(FP); print "." if ($i%10000);}'
+    print_debug "Creating 2000000 files..."
+    time perl -e 'for($i=0; $i < 2000000; $i++) {open(FP, ">${i}file${i}") or die "$!"; print FP "$i\n"; close(FP); print "\r$i   " if ($i%10000);}'
 fi
 
-sed "s%# Label Format%  Label Format%" ${cwd}/bin/bacula-dir.conf > ${cwd}/tmp/1
-sed "s%Type = Backup%Type = Backup; Accurate = yes" ${cwd}/tmp/1 > ${cwd}/bin/bacula-dir.conf
+sed 's%# Label Format%  Label Format%' ${cwd}/bin/bacula-dir.conf > ${cwd}/tmp/1
+# sed 's%Type = Backup%Type = Backup; Accurate = yes%' ${cwd}/tmp/1 > ${cwd}/bin/bacula-dir.conf
+sed 's%Type = Backup%Type = Backup%' ${cwd}/tmp/1 > ${cwd}/bin/bacula-dir.conf
 
 change_jobname MonsterFileSet $JobName
 start_test