Shutdown Process

This is a NuoDB Manager command. See NuoDB Manager.

Description

Stop a specific database process (TE, SM, or SSM). If there are no connections or all connections are idle, the process proceeds to shut down. If there are active connections, the shutdown occurs after they have completed, or when the timeout (shutdownTimeout, softShutdownTimeout) has expired. Shutting down gracefully means that existing requests and connections are allowed to gracefully complete while no new requests and/or connections are accepted. By default the graceful property is true and allowNonDurable is false. This means the process shuts down gracefully and you are not allowed to stop a process if doing so would result in a database without a storage manager (SM).

Syntax

shutdown process 
    host host_name 
    pid process_id 
    [ graceful { true | false } ]
    [ allowNonDurable { true | false } ]
    [ timeout timeout_value ] 
    [ softTimeout soft_timeout_value ]

Parameters

Useful Properties

shutdownTimeout

softShutdownTimeout

See NuoDB Manager Properties.

Interactive Example

Shutdown a TE on one host, 52.24.143.83 (pid 32362). Observe a new TE process starts (pid 32400):

nuodb [domain] > show domain summary
 
Hosts:
[broker] * ec2-52-24-143-83.us-west-2.compute.amazonaws.com/52.24.143.83:48004 (us-west-2) CONNECTED
[broker] ip-172-31-13-183/52.24.2.248:48004 (us-west-2) CONNECTED
[broker] ip-172-31-14-56/52.24.98.113:48004 (us-west-2) CONNECTED
 
Database: test4, template [Minimally Redundant] MET, processes [2 TE, 2 SM], ACTIVE
[SM] ip-172-31-14-171/52.24.143.83:48005 (us-west-2) [ pid = 32336 ] [ nodeId = 1 ] RUNNING
[TE] ip-172-31-14-171/52.24.143.83:48006 (us-west-2) [ pid = 32362 ] [ nodeId = 3 ] RUNNING
[SM] ip-172-31-13-183/52.24.2.248:48005 (us-west-2) [ pid = 23155 ] [ nodeId = 2 ] RUNNING
[TE] ip-172-31-14-56/52.24.98.113:48005 (us-west-2) [ pid = 15345 ] [ nodeId = 4 ] RUNNING
 
nuodb [domain] > shutdown process
Host: 52.24.143.83
Process ID: 32362
Shutdown gracefully (optional): 
Shutdown even if database would become non-durable (optional): 
Timeout (ms/s/m/h/d/w) (optional): 
Remote process shutdown timeout (ms/s/m/h/d/w) (optional): 
Process shutdown cleanly
nuodb [domain] > show domain summary
 
Hosts:
[broker] * ec2-52-24-143-83.us-west-2.compute.amazonaws.com/52.24.143.83:48004 (us-west-2) CONNECTED
[broker] ip-172-31-13-183/52.24.2.248:48004 (us-west-2) CONNECTED
[broker] ip-172-31-14-56/52.24.98.113:48004 (us-west-2) CONNECTED
 
Database: test4, template [Minimally Redundant] MET, processes [2 TE, 2 SM], ACTIVE
[SM] ip-172-31-14-171/52.24.143.83:48005 (us-west-2) [ pid = 32336 ] [ nodeId = 1 ] RUNNING
[TE] ip-172-31-14-171/52.24.143.83:48006 (us-west-2) [ pid = 32400 ] [ nodeId = 5 ] RUNNING
[SM] ip-172-31-13-183/52.24.2.248:48005 (us-west-2) [ pid = 23155 ] [ nodeId = 2 ] RUNNING
[TE] ip-172-31-14-56/52.24.98.113:48005 (us-west-2) [ pid = 15345 ] [ nodeId = 4 ] RUNNING

Scripting Example

The same shutdown process command can be executed with --command as follows:

nuodbmgr --broker host --password password \
    --command "shutdown process host 52.24.143.83 pid 32362"