a3470f
From b13aa33a408b8ca85b306be9c8dbadaff4ed7c64 Mon Sep 17 00:00:00 2001
a3470f
From: Pranith Kumar K <pkarampu@redhat.com>
a3470f
Date: Mon, 8 Jan 2018 11:53:17 +0530
a3470f
Subject: [PATCH 122/128] tests: Use /dev/urandom instead of /dev/random for dd
a3470f
a3470f
If there's not enough entropy in the system then reading /dev/random would take
a3470f
a significant time since it would take a long time for the /dev/random buffers
a3470f
to get full as is desired in this dd run.
a3470f
Milind found that this test file takes almost a 1000 seconds or more to pass
a3470f
instead of just a minute because of this.
a3470f
a3470f
>BUG: 1431955
a3470f
>Change-Id: I9145b17f77f09d0ab71816ae249c69b8fe14c1a5
a3470f
>Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
a3470f
Upstream Patch: https://review.gluster.org/#/c/19160/
a3470f
a3470f
BUG: 1509810
a3470f
Change-Id: I9145b17f77f09d0ab71816ae249c69b8fe14c1a5
a3470f
Signed-off-by: Sunil Kumar Acharya <sheggodu@redhat.com>
a3470f
Reviewed-on: https://code.engineering.redhat.com/gerrit/127405
a3470f
Tested-by: RHGS Build Bot <nigelb@redhat.com>
a3470f
Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
a3470f
---
a3470f
 tests/basic/ec/ec-fix-openfd.t | 2 +-
a3470f
 1 file changed, 1 insertion(+), 1 deletion(-)
a3470f
a3470f
diff --git a/tests/basic/ec/ec-fix-openfd.t b/tests/basic/ec/ec-fix-openfd.t
a3470f
index b62fbf4..c32f933 100644
a3470f
--- a/tests/basic/ec/ec-fix-openfd.t
a3470f
+++ b/tests/basic/ec/ec-fix-openfd.t
a3470f
@@ -43,7 +43,7 @@ EXPECT "1" get_fd_count $V0 $H0 $B0/${V0}1 test_file
a3470f
 EXPECT "1" get_fd_count $V0 $H0 $B0/${V0}2 test_file
a3470f
 
a3470f
 #Write to file
a3470f
-dd iflag=fullblock if=/dev/random bs=1024 count=2 >&$fd 2>/dev/null
a3470f
+dd iflag=fullblock if=/dev/urandom bs=1024 count=2 >&$fd 2>/dev/null
a3470f
 
a3470f
 #Test the fd count
a3470f
 EXPECT "1" get_fd_count $V0 $H0 $B0/${V0}0 test_file
a3470f
-- 
a3470f
1.8.3.1
a3470f