bc-server

Server for maintaining and scheduling jobs.

Usage

bc-server [--cluster _name_] [--force] --data path [server][:port] ... bc-server --version bc-server --help

where
--cluster name of cluster to join. Default is beyondcron.
--data path location of the directory where BeyondCron stores its data.
--force start the server. This is required the first time that, the first server in a cluster is started. It is also required we performing a cluster cold start, and the server was not the last server in the cluster running.
server server name/s within the cluster. Default, the value of the environment variable BEYONDCRON_SERVER_NAMES.
port server port number. Default, the value of the environment variable BEYONDCRON_SERVER_PORT.
--version print the sever version.
--help print the server command options.

Environment variables

BEYONDCRON_ALERT_COMMAND Operating system command which is called when bc-server stops unexpectedly. This can be used for example to send an email or SMS message. When called, the following environment variables will be set:
BEYONDCRON_ALERT_REASON – description of error. e.g. “bc-server stopped unexpectedly” or “bc-server stopped after receiving signal 15”.
BEYONDCRON_DAEMONbc-server
BEYONDCRON_EXIT_CODE – exit code of bc-server
BEYONDCRON_OS_USER – operating system user name which bc-server was running under.
BEYONDCRON_CONFIG_SERVICE Name of the configuration service. If not defined BeyondCron will read startup variables from operating system environment variables.
BEYONDCRON_FORCE_START Force start bc-server if true.
bc-server can also be force started by touching the file /tmp/bc-server.force.start
JAVA_OPTS One or more JVM options. e.g. -Xms2T -Xmx2M
JDBC_CLASSPATH Location of one or more JDBC drivers, which are used when executing SQL jobs. BeyondCron includes drivers for MySQL and PostgreSQL databases.
LOG4J_CONFIGURATION_FILE Location of the log4j configuration file. If this file is named …/log4j2.yaml and does not exist, bc-server will create and populate it, with the bc-server defaults.

Startup variables

Startup variables can be set within a configuration service, or as operating systems environment variables. Startup variables will be read first from a configuration service if defined, and then from environment variables if not defined within the configuration service.

BEYONDCRON_CLUSTER_NAME Name of BeyondCron cluster to join. Default is beyondcron.
BEYONDCRON_CLUSTER_PASSWORD Password of cluster. If password is in the format file:filename, then the password will be read from filename. Default is a cluster specific random string.
BEYONDCRON_DATA_DIR Location of the data directory.
BEYONDCRON_SERVER_ADDRESS_IGNORE Space separated list of IP address prefixes. When searching for an address, ignore any addresses that begin with one of these prefixes. This can be useful, on servers with one or more management interfaces.
BEYONDCRON_SERVER_ADDRESS_IPV6 When searching for an address, prefer an IPv6 address. Default is false.
BEYONDCRON_SERVER_ADDRESS_PRIVATE When searching for an address, only chose a private network address. Default is true.
BEYONDCRON_SERVER_NAMES One or more space separated server[:port]s to connect to.
Default is a plumbed IP address that best matches the rules defined by the environment variables BEYONDCRON_SERVER_ADDRESS_PRIVATE, BEYONDCRON_SREVER_ADDRESS_IPV6 & BEYONDCRON_SERVER_ADDRESS_IGNORE.
BEYONDCRON_SERVER_PORT the server port number. Default is 5701.

where a parameter is defined on both the command line and as an environment/startup variable, the command line value will be used.

Configuration variables

Configuration variables are set within BeyondCron using the config commands.

beyondcron.protected.hosts one or more space separated host names to protect. These host names will be protected, if there no existing protected hosts. Default is localhost & 127.0.0.1
beyondcron.protected.users one or more space separated user names to protect. These user named will be protected, if there are no existing protected users. Default is root and the user that bc-server is running under.
beyondcron.status.service name of status service.
beyondcron.user.service name of user service.
beyondcron.guest.user.access enable guest user access if true. Default is false.
beyondcron.guest.user.name name of guest user. Default is guest.
beyondcron.guest.user.description description of guest user. Default is Guest user.
beyondcron.guest.user.password password of guest user. Default is guest.

Exit status

bc-server exits with 0 when shutdown/killed with the WINCH signal, 1 if an internal error occurred, or 2 if killed by a signal other than WINCH.

Services

Overview

Configuration
Status
User

See also

Reference