def METHOD_NAME(self, timeout=60, step=0.25):
    if self.check_pid():
        logger.error("The application process is already started!")
        return False
    env = self._config.get_java_env()
    cmd = self._config.get_java_cmd()
    try:
        logger.trace("[%s] Forking now..." % os.getpid())
        pid = os.fork()
        if pid > 0:
            self._pid = None
            logger.trace(
                "[%s] Waiting for intermediate process to " "exit..." % os.getpid()
            )
            # prevent zombie process
            (waitpid, result) = os.waitpid(pid, 0)
            if result == 0:
                logger.debug("The JVM process has been started.")
                return True
            logger.error("Starting the JVM process did not succeed...")
            return False
    except OSError as e:
        logger.error("Forking subprocess failed: %d (%s)\n" % (e.errno, e.strerror))
        return
    logger.trace("[%s] Now in intermediate forked process..." % os.getpid())
    # decouple from parent environment
    os.chdir("/")
    os.setsid()
    os.umask(0o022)
    logger.debug(
        "Environment to be used when starting the JVM: %s"
        % " ".join(["%s='%s'" % (k, v) for k, v in env.items()])
    )
    logger.debug(
        "Command line to be used when starting the JVM: %s" % " ".join(cmd)
    )
    # start java subprocess (second fork)
    logger.trace("[%s] Starting the JVM..." % os.getpid())
    try:
        proc = subprocess.Popen(
            cmd,
            close_fds=True,
            cwd="/",
            env=env,
        )
    except OSError as ose:
        if ose.errno == errno.ENOENT:
            logger.error(
                "The java binary cannot be found in the default " "search path!"
            )
            logger.error(
                "By default, when starting the JVM, the "
                "environment is not preserved. If you don't set "
                "preserve_environment to true or specify PATH in "
                "preserve_environment or custom_environment in "
                "the m2ee section of your m2ee.yaml "
                "configuration file, the search path is likely a "
                "very basic default list like '/bin:/usr/bin'"
            )
            os._exit(1)
    # always write pid asap, so that monitoring can detect apps that should
    # be started but fail to do so
    self._pid = proc.pid
    logger.trace("[%s] Writing JVM pid to pidfile: %s" % (os.getpid(), self._pid))
    self._write_pidfile()
    # wait for m2ee to become available
    t = 0
    while t < timeout:
        sleep(step)
        dead = proc.poll()
        if dead is not None:
            logger.error("Java subprocess terminated with errorcode %s" % dead)
            logger.debug(
                "[%s] Doing unclean exit from intermediate "
                "process now." % os.getpid()
            )
            os._exit(1)
        if self.check_pid(proc.pid) and self._client.ping():
            break
        t += step
    if t >= timeout:
        logger.error("Timeout: Java subprocess takes too long to start.")
        logger.trace(
            "[%s] Doing unclean exit from intermediate process "
            "now." % os.getpid()
        )
        os._exit(1)
    logger.trace("[%s] Exiting intermediate process..." % os.getpid())
    os._exit(0)