~james-page/ubuntu/vivid/ceph/0.93

« back to all changes in this revision

Viewing changes to debian/patches/bug-8821.patch

  • Committer: Package Import Robot
  • Author(s): James Page
  • Date: 2014-07-30 10:15:40 UTC
  • mfrom: (0.1.29 sid)
  • Revision ID: package-import@ubuntu.com-20140730101540-b7gsn9jqkye4a5ty
Tags: 0.80.5-1
* New upstream stable release:
  - d/p/firefly-post-release.patch: Dropped, no longer required.
  - d/lib{rados2,cephfs1}.symbols: Update with new symbols.

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
 
31
31
--- a/src/common/config_opts.h
32
32
+++ b/src/common/config_opts.h
33
 
@@ -737,10 +737,10 @@
34
 
  * affected by rbd_default_order.
 
33
@@ -738,8 +738,8 @@ OPTION(rbd_localize_parent_reads, OPT_BO
35
34
  */
36
35
 OPTION(rbd_default_format, OPT_INT, 1)
37
36
 OPTION(rbd_default_order, OPT_INT, 22)
42
41
 OPTION(rbd_default_features, OPT_INT, 3) // 1 for layering, 3 for layering+stripingv2. only applies to format 2 images
43
42
 
44
43
 OPTION(nss_db_path, OPT_STR, "") // path to nss db
45
 
 
46
44
--- a/src/rbd.cc
47
45
+++ b/src/rbd.cc
48
 
@@ -2344,9 +2344,10 @@
49
 
 
 
46
@@ -2345,7 +2345,8 @@ int main(int argc, const char **argv)
50
47
   const char *poolname = NULL;
51
48
   uint64_t size = 0;  // in bytes
52
49
   int order = 0;
56
53
   int format = 1;
57
54
   uint64_t features = RBD_FEATURE_LAYERING;
58
55
   const char *imgname = NULL, *snapname = NULL, *destname = NULL,
59
 
     *dest_poolname = NULL, *dest_snapname = NULL, *path = NULL,
60
 
@@ -2358,9 +2359,9 @@
61
 
   long long stripe_unit = 0, stripe_count = 0;
 
56
@@ -2359,7 +2360,7 @@ int main(int argc, const char **argv)
62
57
   long long bench_io_size = 4096, bench_io_threads = 16, bench_bytes = 1 << 30;
63
58
   string bench_pattern = "seq";
64
59
 
67
62
   std::ostringstream err;
68
63
   long long sizell = 0;
69
64
   std::vector<const char*>::iterator i;
70
 
   for (i = args.begin(); i != args.end(); ) {
71
 
@@ -2374,15 +2375,17 @@
72
 
       return 0;
 
65
@@ -2375,13 +2376,15 @@ int main(int argc, const char **argv)
73
66
     } else if (ceph_argparse_flag(args, i, "--new-format", (char*)NULL)) {
74
67
       format = 2;
75
68
       format_specified = true;
88
81
     } else if (ceph_argparse_witharg(args, i, &val, "-p", "--pool", (char*)NULL)) {
89
82
       poolname = strdup(val.c_str());
90
83
     } else if (ceph_argparse_witharg(args, i, &val, "--dest-pool", (char*)NULL)) {
91
 
       dest_poolname = strdup(val.c_str());
92
 
@@ -2415,9 +2418,8 @@
93
 
     } else if (ceph_argparse_withlonglong(args, i, &bench_io_size, &err, "--io-size", (char*)NULL)) {
 
84
@@ -2416,7 +2419,6 @@ int main(int argc, const char **argv)
94
85
     } else if (ceph_argparse_withlonglong(args, i, &bench_io_threads, &err, "--io-threads", (char*)NULL)) {
95
86
     } else if (ceph_argparse_withlonglong(args, i, &bench_bytes, &err, "--io-total", (char*)NULL)) {
96
87
     } else if (ceph_argparse_witharg(args, i, &bench_pattern, &err, "--io-pattern", (char*)NULL)) {
98
89
     } else if (ceph_argparse_witharg(args, i, &val, "--path", (char*)NULL)) {
99
90
       path = strdup(val.c_str());
100
91
     } else if (ceph_argparse_witharg(args, i, &val, "--dest", (char*)NULL)) {
101
 
       destname = strdup(val.c_str());
102
 
@@ -2440,11 +2442,11 @@
103
 
       progress = false;
 
92
@@ -2441,9 +2443,9 @@ int main(int argc, const char **argv)
104
93
     } else if (ceph_argparse_flag(args, i , "--allow-shrink", (char *)NULL)) {
105
94
       resize_allow_shrink = true;
106
95
     } else if (ceph_argparse_witharg(args, i, &val, "--format", (char *) NULL)) {
113
102
        format = ret;
114
103
        format_specified = true;
115
104
        cerr << "rbd: using --format for specifying the rbd image format is"
116
 
             << " deprecated, use --image-format instead"
117
 
@@ -2556,8 +2558,19 @@
118
 
        break;
 
105
@@ -2557,6 +2559,17 @@ if (!set_conf_param(v, p1, p2, p3)) { \
119
106
     }
120
107
   }
121
108
 
133
120
   if (format_specified && opt_cmd != OPT_IMPORT && opt_cmd != OPT_CREATE) {
134
121
     cerr << "rbd: image format can only be set when "
135
122
         << "creating or importing an image" << std::endl;
136
 
     return EXIT_FAILURE;
137
123
--- /dev/null
138
124
+++ b/src/test/cli-integration/rbd/defaults.t
139
125
@@ -0,0 +1,214 @@