char *client_name = NULL;
/*
- * If we specify cluser name, the rados_create2
+ * If we specify cluster name, the rados_create2
* will not assume 'client.'. name is considered
* as a full type.id namestr
*/
goto failed_open;
}
+ if (!td->o.odirect) {
+ /*
+ * ensure cache enables writeback/around mode unless explicitly
+ * configured for writethrough mode
+ */
+ r = rbd_flush(rbd->image);
+ if (r < 0) {
+ log_info("rbd: failed to issue initial flush\n");
+ }
+ }
+
if (!_fio_rbd_setup_poll(rbd))
goto failed_poll;
/* taken from "net" engine. Pretend we deal with files,
* even if we do not have any ideas about files.
- * The size of the RBD is set instead of a artificial file.
+ * The size of the RBD is set instead of an artificial file.
*/
if (!td->files_index) {
add_file(td, td->o.filename ? : "rbd", 0, 0);