|
Key
This line was removed.
This word was removed. This word was added.
This line was added.
|
Changes (31)
View Page History...
{column}
Once Petals ESB Hazelcast Registry is installed through the Debian package, it can be started or stopped with two different ways:
* at system level: the Petals ESB Hazelcast Registry nodes are running with a dedicated system user '{{petals}}'. To use in production mode,
* at user level: the Petals ESB Hazelcast Registry nodes are running as a process of the user that launches them. To use in a development mode.
Startup and shutdown operations are realized through the script or command '{{petals-registry}}'. In following chapters we can find use-cases to explain how to use the script, and a reference guide about this script.
...
{section}
h1. Starting Petals ESB Hazelcast Registry
h2. Starting Petals ESB Hazelcast Registry at system level
h3. Automatic startup
The Petals ESB Hazelcast Registry package comes with an automatic startup script based on System V ({{initd}}) to automatically launch Petals ESB Hazelcast Registry nodes as system services when the host boots.
To start the Petals ESB Hazelcast Registry nodes, for example, launch the following command on a Ubuntu box:
{code}
cdeneux@sph-latitude-D630:~$ sudo service petals-registry start
cdeneux@sph-latitude-D630:~$ sudo service petals-registry start
...
{info}
It's not possible to automatically start a Petals ESB Hazelcast Registry node in debug mode. Use a manual startup.
{info}
{note}
{note}
The automatic startup starts all Petals ESB Hazelcast Registry nodes declared in the directory {{/etc/petals-registry/member-enable}}. So if you add a new Petals ESB Hazelcast Registry node in this directory, and use the command "{{service petals-registry start}}", all other Petals ESB registry Hazelcast Registry nodes will be also started, and as they are already started, errors will occurs.
{note}
h3. Manual startup
h3. Manual startup
A Petals ESB Hazelcast Registry node configured at system level (its configuration is located in {{/etc/petals-registry/member-available}}, and uses sub-directory {{/var/log/petals-registry}}) can be started using a manual startup, for example, to test its configuration. This startup is done using the same mechanism as a Petals ESB Hazelcast Registry node configured at user level, but using the system user '{{petals}}' to be compliant with ACL of the filesystem:
{code}
sudo -u petals petals-registry -c <node-configuration>
{code}
sudo -u petals petals-registry -c <node-configuration>
{code}
where {{<node-configuration>}} is the URL of the Petals ESB Hazelcast Registry node configuration (ie, URL locating the file {{member.properties}})
{quote}For example, to launch the default sample node
{code}
{code}
...
{note}
+Note 1:+ When manually starting a Petals ESB Hazelcast Registry node, it will be automatically stopped when closing your shell. Don't use this way to start a Petals ESB Hazelcast Registry node as a system service.
+Note 2:+ The command below uses the default JVM installed on your system. If it is not the right one, you can use a command line as following to specify the right JVM to use:
{code}
{code}
...
{note}
h2. Starting Petals Petals ESB Hazelcast Registry at user level
A Petals ESB Hazelcast Registry node configured at user level (its full configuration is located under the user's home directory) can be *only* started using a manual startup:
{code}
petals-registry -c <node-configuration>
{code}
petals-registry -c <node-configuration>
{code}
where {{<node-configuration>}} is the URL of the Petals ESB Hazelcast Registry node configuration (ie, URL locating the file {{member.properties}})
{quote}For example:
{code}
{code}
...
{note}
When manually starting a Petals ESB Hazelcast Registry node, it will be automatically stopped when closing your shell.
{note}
h1. Stopping Petals ESB Hazelcast Registry
The process stopping a Petals ESB Hazelcast Registry node reads the contents of its local configuration file (ie. {{member.properties}})to get the JMX credentials required to connect to the Petals ESB Hazelcast Registry node and invoke a shutdown. The security to block a shutdown is based on filesystem ACLs of the configuration files of the node. So, don't forget to set the right ACL on these files.
{quote}
Example: "{{me:my-group rw-r-----}}" for your node to authorize you ({{me}}) and all member of the group {{my-group}}) to shutdown the Petals ESB Hazelcast Registry node.
{quote}
h2. Stopping Petals ESB Hazelcast Registry at system level
h3. Automatic stop
To stop the Petals ESB Hazelcast Registry nodes started as system services uses the following command on a Ubuntu box, for example:
{code}
cdeneux@sph-latitude-D630:~$ sudo service petals-registry stop
cdeneux@sph-latitude-D630:~$ sudo service petals-registry stop
...
{note}
The automatic stop stops all Petals ESB Hazelcast Registry nodes declared in the directory /etc/petals-registry/member-enable. So if you have removed a Petals ESB Hazelcast Registry node in this directory since the last automatic startup, it will not be stopped. Use a manual stop to stop it.
{note}
h3. Manual stop
h3. Manual stop
h4. Manual stop of a Petals ESB Hazelcast Registry node automatically started
To stop a Petals ESB Hazelcast Registry node started as system service use the following command:
{code}
sudo -u petals petals-registry -c <node-configuration> stop
sudo -u petals petals-registry -c <node-configuration> stop
...
{quote}
h4. Manual stop of a Petals ESB Hazelcast Registry node manually started
If you have manually started a Petals ESB Hazelcast Registry node at system level, just kill it with a Ctrl-C on its console, or use the following command from another shell:
{code}
sudo -u petals petals-registry -c <node-configuration> stop
sudo -u petals petals-registry -c <node-configuration> stop
...
{quote}
h2. Stopping Petals ESB Hazelcast Registry at user level
To stop your Petals ESB Hazelcast Registry node, just kill it with a Ctrl-C on its console, or use the following command from another shell:
{code}
petals-registry -c <node-configuration> stop
petals-registry -c <node-configuration> stop
...
h2. Description
*petals-registry* is used to start and stop manually a Petals ESB Hazelcast Registry node.
h2. Options
...
|| Short option || Long option || Description ||
| {{-H}} | {{--help}} | Print usage. |
| {{-H}} | {{--help}} | Print usage. |
| {{-c config-url}} | {{--config config-url}} | The URL of the Petals ESB Hazelcast Registry node configuration to start or stop. |
| {{stop}} | N/A | Stop the Petals ESB Hazelcast Registry node. |