summaryrefslogtreecommitdiffstats
path: root/booster
diff options
context:
space:
mode:
authorShehjar Tikoo <shehjart@gluster.com>2009-05-24 23:05:11 +0000
committerAnand V. Avati <avati@dev.gluster.com>2009-06-02 23:31:44 -0700
commiteac0ca0e1f1d536c812ee7bdfeedc3833964491a (patch)
tree0545a1ed51a412e8842cd0d0bbba64b79880b35c /booster
parentfa66ba98c38df70892cdcaffdca430dbfa472831 (diff)
booster: Clear up env var usage
Signed-off-by: Anand V. Avati <avati@dev.gluster.com>
Diffstat (limited to 'booster')
-rw-r--r--booster/src/booster.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/booster/src/booster.c b/booster/src/booster.c
index 264d677..40dac43 100644
--- a/booster/src/booster.c
+++ b/booster/src/booster.c
@@ -236,9 +236,19 @@ booster_get_process_fd ()
return real_dup (process_piped_fd);
}
+/* The following two define which file contains
+ * the FSTAB configuration for VMP-based usage.
+ */
#define DEFAULT_BOOSTER_CONF CONFDIR"/booster.conf"
#define BOOSTER_CONF_ENV_VAR "GLUSTERFS_BOOSTER_FSTAB"
+
+/* The following define which log file is used when
+ * using the old mount point bypass approach.
+ */
+#define BOOSTER_DEFAULT_LOG CONFDIR"/booster.log"
+#define BOOSTER_LOG_ENV_VAR "GLUSTERFS_BOOSTER_LOG"
+
static int32_t
booster_put_handle (booster_mount_table_t *table,
dev_t st_dev,
@@ -398,7 +408,10 @@ do_open (int fd, int flags, mode_t mode)
fseek (specfp, 0L, SEEK_SET);
- ctx.logfile = getenv (BOOSTER_CONF_ENV_VAR);
+ ctx.logfile = getenv (BOOSTER_LOG_ENV_VAR);
+ if (!ctx.logfile)
+ ctx.logfile = strdup (BOOSTER_DEFAULT_LOG);
+
ctx.specfp = specfp;
handle = glusterfs_init (&ctx);