def METHOD_NAME():
    script_name = os.path.basename(__file__)
    initLogger(script_name)
    global start_time
    if sys.argv[1] == "--update":
        if not os.path.exists(GCRON_TASKS):
            # Create a flag in /var/run/gluster which indicates that this
            # node doesn't have access to GCRON_TASKS right now, so that
            # when the mount is available and GCRON_TASKS is available
            # the flag will tell this routine to reload GCRON_CROND_TASK
            try:
                f = os.open(GCRON_RELOAD_FLAG,
                            os.O_CREAT | os.O_NONBLOCK, 0o644)
                os.close(f)
            except OSError as e:
                if errno != EEXIST:
                    log.error("Failed to create %s : %s",
                              GCRON_RELOAD_FLAG, e)
                    output("Failed to create %s. Error: %s"
                           % (GCRON_RELOAD_FLAG, e))
            return
        if not os.path.exists(GCRON_CROND_TASK):
            return
        # As GCRON_TASKS exists now, we should check if GCRON_RELOAD_FLAG
        # also exists. If so we should touch GCRON_CROND_TASK and remove
        # the GCRON_RELOAD_FLAG
        if os.path.exists(GCRON_RELOAD_FLAG):
            try:
                os.remove(GCRON_RELOAD_FLAG);
                process = subprocess.Popen(["touch", "-h", GCRON_CROND_TASK],
                                           stdout=subprocess.PIPE,
                                           stderr=subprocess.PIPE)
                out, err = process.communicate()
                if process.returncode != 0:
                    log.error("Failed to touch %s. Error: %s.",
                              GCRON_CROND_TASK, err)
            except (IOError, OSError) as e:
                log.error("Failed to touch %s. Error: %s.",
                          GCRON_CROND_TASK, e)
            return
        if os.lstat(GCRON_TASKS).st_mtime > \
           os.lstat(GCRON_CROND_TASK).st_mtime:
            try:
                process = subprocess.Popen(["touch", "-h", GCRON_CROND_TASK],
                                           stdout=subprocess.PIPE,
                                           stderr=subprocess.PIPE)
                out, err = process.communicate()
                if process.returncode != 0:
                    log.error("Failed to touch %s. Error: %s.",
                              GCRON_CROND_TASK, err)
            except IOError as e:
                log.error("Failed to touch %s. Error: %s.",
                          GCRON_CROND_TASK, e)
        return
    volname = sys.argv[1]
    jobname = sys.argv[2]
    locking_file = os.path.join(LOCK_FILE_DIR, jobname)
    log.debug("locking_file = %s", locking_file)
    log.debug("volname = %s", volname)
    log.debug("jobname = %s", jobname)
    start_time = int(time.time())
    doJob("Scheduled-" + jobname + "-" + volname, locking_file, takeSnap, volname)