| To: | linux-btrfs@xxxxxxxxxxxxxxx, xfs@xxxxxxxxxxx |
|---|---|
| Subject: | [btrfs-progs] Btrfs quotas testing |
| From: | Hemanth Kumar <hemanthkumar51@xxxxxxxxx> |
| Date: | Fri, 15 Feb 2013 18:15:24 +0530 |
| Cc: | skjmca51@xxxxxxxxx, ganeshkumar14@xxxxxxxxx, kirantpatil@xxxxxxxxx, praneethu.u@xxxxxxxxx, chethan.casey@xxxxxxxxx, sensille@xxxxxxx, bo.li.liu@xxxxxxxxxx, hugo@xxxxxxxxxxxxx, sandeen@xxxxxxxxxx, Hemanth Kumar <hemanthkumar51@xxxxxxxxx> |
| Delivered-to: | xfs@xxxxxxxxxxx |
| Dkim-signature: | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer; bh=40+G5LFdFi7YRHaLeIfqgMI7DhwLSfQ5XRHFwZjz4bU=; b=w5FJjmsfq3/Vtf7hKL/eYQdJ2GRVUsl44aoDn+r3okJDcDPVYDi4Zg43jOGa4jVROe k2M3teVD2gMpL5/ucmuDO6jvirbHjIsmyVRT7CN/WiknVTA/M6T6P5sO//9/ZFJqf1mB grUeypAqG+a9a4cYyMfGxpakNZ0Rny3YLInzXQi1GrKCsCTBjq2VCSx+jYZT31QWA/l4 8AIIvqFIN797fm6iCRA6gJLHqRa0a02Jer20uP2cAt8HrolqgOU1bcG54+FnaIHAdVWv 8ZTHrm3z/AWSp4P79heCgrAwvb/u6PeHRngmzGT1O1A98V1s4mNTisdaHXy4ipD2U6lC RikA== |
Signed-off-by: Hemanth Kumar <hemanthkumar51@xxxxxxxxx>
---
quotas.sh | 30 ++++++++++++++++++++++++++++++
1 file changed, 30 insertions(+)
create mode 100644 quotas.sh
diff --git a/quotas.sh b/quotas.sh
new file mode 100644
index 0000000..7e64578
--- /dev/null
+++ b/quotas.sh
@@ -0,0 +1,30 @@
+#! /bin/bash
+# Btrfs quotas test case
+# Hi all,
+# This is shell script to test the quotas feature of Btrfs
+# I created Btrfs filesystem on a new
+# partition, then activated quota management ('btrfs quota enable'), and
+# created a few subvolumes.
+# I have lmited the quota to 2mb and tried filling it
+# its working as expected
+
+
+cleanup()
+{
+ btrfs subvolume delete $TEST_DIR/vol1
+ btrfs subvolume disable $TEST_DIR
+}
+
+#trap "_cleanup ; exit \$status" 0 1 2 3 15
+
+btrfs quota enable $TEST_DIR
+echo "quota enabled on $TEST_DEV"
+btrfs subvolume create $TEST_DIR/vol1
+echo "vol1 created"
+btrfs qgroup show $TEST_DIR
+btrfs qgroup limit 2m $TEST_DIR/vol1
+echo "qgroup limited to 2mb"
+dd if=$TEST_DEV of=$TEST_DIR/vol1/file1 bs=3M count=1
+echo "tried to write 3m worth data"
+cleanup
+exit
--
1.8.1.2
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: [test] comments removed, Hemanth Kumar |
|---|---|
| Next by Date: | [btrfs-progs] testing btrfs hierarchical quotas, Hemanth Kumar |
| Previous by Thread: | Request., Cham Tao Soon |
| Next by Thread: | Re: [btrfs-progs] Btrfs quotas testing, Ben Myers |
| Indexes: | [Date] [Thread] [Top] [All Lists] |