ceph/qa/workunits/fs/snaps/snaptest-hardlink.sh
Ramana Raja a232d273c1 qa/workunits/fs/snaps: allow tests to be run
... filesystems other than 'cephfs'.

It is not required to set  'allow_new_snaps' to True to allow snapshot
to be created on a filesystem. Remove that setting.

Remove 'fs/snaps/snaptest-0.sh' that is racy when running in parallel on
an another client that mounted the same file system. Include a similar
test in qa/tasks/cephfs/test_snapshots.py

Signed-off-by: Ramana Raja <rraja@redhat.com>
2020-11-20 13:23:21 +05:30

26 lines
295 B
Bash
Executable File

#!/bin/sh -x
set -e
mkdir 1 2
echo asdf >1/file1
echo asdf >1/file2
ln 1/file1 2/file1
ln 1/file2 2/file2
mkdir 2/.snap/s1
echo qwer >1/file1
grep asdf 2/.snap/s1/file1
rm -f 1/file2
grep asdf 2/.snap/s1/file2
rm -f 2/file2
grep asdf 2/.snap/s1/file2
rmdir 2/.snap/s1
rm -rf 1 2
echo OK