generic: test MADV_POPULATE_READ with IO errors
[xfstests-dev.git] / tests / generic / 488
1 #! /bin/bash
2 # SPDX-License-Identifier: GPL-2.0
3 # Copyright (c) 2018 Omar Sandoval.  All Rights Reserved.
4 #
5 # FS QA Test 488
6 #
7 # Test having many file descriptors referring to deleted files open. Regression
8 # test for patch "Btrfs: fix ENOSPC caused by orphan items reservations".
9 #
10 . ./common/preamble
11 _begin_fstest auto quick
12
13 . ./common/filter
14
15 _supported_fs generic
16 _require_scratch
17 _require_test_program "multi_open_unlink"
18
19 _scratch_mkfs_sized $((1024 * 1024 * 1024)) >> $seqres.full 2>&1
20 _scratch_mount
21
22 test_file="$SCRATCH_MNT/$seq"
23
24 ulimit -n $((16 * 1024))
25 # ~10000 files on a 1 GB filesystem should be no problem.
26 $here/src/multi_open_unlink -f $SCRATCH_MNT/$seq -n 10000 -s 0
27
28 echo "Silence is golden"
29
30 status=0
31 exit