serviced

NAME

serviced - a container-based management system

SYNTAX

serviced [global options] command [command options] [arguments...]

DESCRIPTION

serviced is an open-source, application service orchestrator based on Docker.

GLOBAL OPTIONS

--docker-registry Master-Hostname:5000
The local Docker registry to use. The value of Master-Hostname is the hostname of the master host, not its IP address.
--static-ip IP-Address [--static-ip IP-Address]
One or more static IP addresses for a serviced instance to advertise. Static IP addresses are declared in service definition templates, but must be passed to an instance with this option.
--endpoint Host:Port
The serviced RPC endpoint. The value of Host is the hostname or IP address of the master host. The default value of Port is 4979. NOTE: For release 1.0, only port 4979 is supported.
--outbound IP-Address
The outbound IP address.
--uiport :Port
The port on which this serviced instance listens for HTTPS requests. The default value is 443, unless SERVICED_UI_PORT is set in the configuration file.
--listen :Port
The serviced RPC endpoint on the local host. The default value of Port is 4979. NOTE: For release 1.0, only port 4979 is supported.
--docker-dns Option [--docker-dns Option]
One or more DNS configuration flags for Docker to use when starting containers.
--master
Run the application services scheduler and other internal services.
--agent
Run application services scheduled by the master.
--mux Port
The multiplexer port. The default value is 22250, unless SERVICED_MUX_PORT is set in the configuration file.
--var Path
The location in which serviced stores application data. The default value is $SERVICED_HOME/var, unless SERVICED_VARPATH is set in the configuration file.
--keyfile Path
The path of a TLS key file. The default value is $TMPDIR/zenoss_key.[0-9]+, unless SERVICED_KEY_FILE is set in the configuration file.
--certfile Path
The path of a TLS certificate file. The default value is $TMPDIR/zenoss_cert.[0-9]+, unless SERVICED_CERT_FILE is set in the configuration file.
--zk Host:Port [--zk Host:Port]
One or more ZooKeeper endpoints. The value of Host is the hostname or IP address of the ZooKeeper host. The default value of Port is 2181. If multiple endpoints are specified, serviced will try each in turn until it connects to a working server.
--mount Option [--mount Option]
One or more bind mounts for a container. The syntax for Option is DOCKER_IMAGE,HOST_PATH[,CONTAINER_PATH].
--fstype Driver
The driver for the underlying file system where application data is stored (by default, /opt/serviced/var). The supported drivers are rsync and btrfs. The default value is rsync, unless SERVICED_FS_TYPE is set in the configuration file.
--alias Alias [--alias Alias]
One or more DNS aliases to associate with a container.
--es-startup-timeout Duration
The number of seconds to wait for Elasticsearch to complete its startup. The default value is 600 seconds (10 minutes).
--max-container-age Duration
The number of seconds to wait before removing a stopped container. The default value is 86400 seconds (24 hours), unless SERVICED_MAX_CONTAINER_AGE is set in the configuration file.
--max-dfs-timeout Duration
The number of seconds to wait for a snapshot to complete. The default value is 300 seconds (5 minutes).
--virtual-address-subnet Subnet
The 16-bit private subnet to use for virtual IPv4 addresses. The default value is 10.3, unless SERVICED_VIRTUAL_ADDRESS_SUBNET is set in the configuration file.
--master-pool-id Pool-ID
The name of the resource pool to which the serviced instance configured as master belongs. The default value of Pool-ID is default.
--admin-group Group
The name of the Linux group on the serviced master host whose members are authorized to use the serviced web interface. On Ubuntu systems, the default value of Group is sudo; on RHEL/CentOS systems, the default is wheel. If SERVICED_VIRTUAL_ADDRESS_SUBNET is set in the configuration file, its value is used instead of the default.
--report-stats
Enable reporting statistics in a container.
--host-stats Host:Port
The endpoint of the OpenTSDB reader daemon, for serviced statistics. The default value of Host is the IP address of the master host, and the default value of Port is 8443. If SERVICED_STATS_PORT is set in the configuration file, its value is used instead of the default endpoint.
--stats-period Duration
The number of seconds to wait between polls (health checks) of hosts in resource pools. The default value of Duration is 10, unless SERVICED_STATS_PERIOD is set in the configuration file.
--mc-username User
The username of the OpenTSDB account that MetricConsumer uses gain access to data stored by serviced.
--mc-password Password
The password of the OpenTSDB account that MetricConsumer uses gain access to data stored by serviced.
--cpuprofile
Instructs a container to write its CPU profile to a file.
--isvcs-env Option [--isvcs-env Option]
Arguments to pass to internal services. The default value is no arguments, unless SERVICED_ISVCS_ENV_[0-9]+ is set in the configuration file.
--debug-port Port
The port on which serviced listens for HTTP requests for the Go profiler. The default value of Port is 6006, unless SERVICED_DEBUG_PORT is set in the configuration file. To stop listening for requests, set the value to -1.
--max-rpc-clients Count
The maximum number of clients the serviced RPC endpoint supports. The default value is 3, unless SERVICED_MAX_RPC_CLIENTS is set in the configuration file.
--rpc-dial-timeout Duration
The number of seconds serviced waits before giving up on attempts to connect to the RPC endpoint on the master host.
--logtostderr
Write log messages to STDERR instead of the system log.
--alsologtostderr
Write log messages to STDERR as well as the system log.
--logstashurl Host:Port
The logstash endpoint to which log data are sent. The default value of Host is the IP address of the master host, and the default value of Port is 5042. If SERVICED_LOG_ADDRESS is set in the configuration file, its value is used instead of the default endpoint.
--logstash-es Host:Port
The administrative endpoint of the logstash service. The default value of Host is the IP address of the master host, and the default value of Port is 9100. If SERVICED_LOGSTASH_ES is set in the configuration file, its value is used instead of the default endpoint.
--logstash-max-days Duration
The maximum number of days to keep data in the logstash server before purging it. The default value of Duration is 1, unless SERVICED_LOGSTASH_MAX_DAYS is set in the configuration file. When this argument and --logstash-max-size are used at the same time, both conditions are evaluated and enforced.
--logstash-max-size Quantity
The maximum amount of logstash data to keep, in gigabytes. The default value of Quantity is 10, unless SERVICED_LOGSTASH_MAX_SIZE is set in the configuration file. When this argument and --logstash-max-days are used at the same time, both conditions are evaluated and enforced.
--v Level
The relative amount of INFO messages serviced writes to the system log. The value of Level may be 0 (minimum) to 5 (maximum). The default value is 0, unless SERVICED_LOG_LEVEL is set in the configuration file.
--stderrthreshold Level
Write log messages at or above Level to STDERR, in addition to the system log. The value of Level may be 0 (INFO), 1 (WARNING), 2 (ERROR), or 3 (FATAL). The default value is 2.
--vmodule
Module-specific logging. For more information, refer to the Google Logging documentation.
--log_backtrace_at File:Line
Emit a stack trace when logging hits the specified line and file.
--version
Display minimal version information about the serviced binary. To display additional information, use the serviced version command.
[--help|--h]
Display help information.

COMMANDS

backup
Copy all templates and services into a tar archive file.
docker
Administer Docker.
[help|h]
Display a global or command-specific help message.
host
Administer hosts.
log
Administer logs.
metric
Administer metrics.
pool
Administer resource pools.
restore
Reconstruct templates and services from a a tar archive file created with backup.
script
Administer services.
service
Administer services.
snapshot
Administer snapshots.
template
Administer templates.
version
Display serviced version information.

INVOCATION

Service (daemon) control commands include start, stop and reload. The reload command sends SIGHUP to the daemon, which restarts all internal services except ZooKeeper.

  • RHEL/CentOS: sudo systemctl [start|stop|reload] serviced
  • Ubuntu: sudo [start|stop|reload] serviced

MISCELLANEOUS

Sending SIGUSR1 to the serviced process toggles the log level between 0 and 2.

To attach to a container running on a remote host, log in to the container from the serviced master host. If you are running a Linux shell on an agent host, specify the --endpoint option in the serviced invocation.

serviced relies on Docker, and some administration procedures include docker commands. However, commands that manipulate containers directly, such as docker pause, should not be used when serviced is running.

ENVIRONMENT

SERVICED_HOME
The install path of serviced. The default value is /opt/serviced.

FILES

/etc/default/serviced