]> git.proxmox.com Git - librados2-perl.git/commitdiff
add simple test script
authorDietmar Maurer <dietmar@proxmox.com>
Thu, 16 Jan 2014 11:45:58 +0000 (12:45 +0100)
committerDietmar Maurer <dietmar@proxmox.com>
Thu, 16 Jan 2014 11:45:58 +0000 (12:45 +0100)
test.pl [new file with mode: 0755]

diff --git a/test.pl b/test.pl
new file mode 100755 (executable)
index 0000000..e194953
--- /dev/null
+++ b/test.pl
@@ -0,0 +1,22 @@
+#!/usr/bin/perl 
+
+use lib '.';
+use strict;
+use warnings;
+use JSON;
+
+use Data::Dumper;
+
+use PVE::RADOS;
+
+print "TEST1\n";
+my $rados = PVE::RADOS::new();
+print "TEST2\n";
+
+my $res = $rados->mon_command({ prefix => 'mon dump', format => 'json' });
+print Dumper($res);
+$res = $rados->mon_command({ prefix => 'mon dump', format => 'json' });
+print Dumper($res);
+
+my $stat = $rados->cluster_stat;
+print Dumper($stat);