geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From conflue...@apache.org
Subject [CONF] Apache Geronimo v3.0 > Running Geronimo as a Linux service
Date Wed, 11 May 2011 11:22:00 GMT
<html>
<head>
    <base href="https://cwiki.apache.org/confluence">
            <link rel="stylesheet" href="/confluence/s/2042/9/4/_/styles/combined.css?spaceKey=GMOxDOC30&amp;forWysiwyg=true"
type="text/css">
    </head>
<body style="background: white;" bgcolor="white" class="email-body">
<div id="pageContent">
<div id="notificationFormat">
<div class="wiki-content">
<div class="email">
    <h2><a href="https://cwiki.apache.org/confluence/display/GMOxDOC30/Running+Geronimo+as+a+Linux+service">Running
Geronimo as a Linux service</a></h2>
    <h4>Page <b>edited</b> by             <a href="https://cwiki.apache.org/confluence/display/~gawor">Jarek
Gawor</a>
    </h4>
        <br/>
                         <h4>Changes (6)</h4>
                                 
    
<div id="page-diffs">
                    <table class="diff" cellpadding="0" cellspacing="0">
    
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" > <br>h2. Installing a Geronimo
service <br></td></tr>
            <tr><td class="diff-changed-lines" >Make sure that you log on the
system as a root user. Then we need a Linux Shell script <span class="diff-deleted-words"style="color:#999;background-color:#fdd;text-decoration:line-through;">{{gserviceReg.sh}}</span>
<span class="diff-added-words"style="background-color: #dfd;">{{register-service}}</span>
to run the Geronimo server as a serive. This file is by default located in {{&lt;geronimo_home&gt;/bin}}.
<br></td></tr>
            <tr><td class="diff-unchanged" > <br>You can now run Geronimo
as a service from a command line, by running the following command from {{&lt;geronimo_home&gt;/bin}}:
<br>{noformat:borderStyle=solid} <br></td></tr>
            <tr><td class="diff-changed-lines" ><span class="diff-deleted-words"style="color:#999;background-color:#fdd;text-decoration:line-through;">./gserviceReg.sh</span>
<span class="diff-added-words"style="background-color: #dfd;">./register-service</span>
add &lt;service_name&gt; <br></td></tr>
            <tr><td class="diff-unchanged" >{noformat} <br>where _&lt;service_name&gt;_
is the name you specify for a service. You can create multiple service names for the server.
<br></td></tr>
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" > <br>h3. Starting, stopping
or restarting a service <br></td></tr>
            <tr><td class="diff-changed-lines" >You can start the service by running
this <span class="diff-changed-words">com<span class="diff-added-chars"style="background-color:
#dfd;">m</span>and:</span> <br></td></tr>
            <tr><td class="diff-unchanged" >{noformat:borderStyle=solid} <br>&lt;service_name&gt;
start <br></td></tr>
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" >If you have installed multiple services
on the server, you might want to find the mapping directory for each service. Run the following
command to find the mapping directory: <br>{noformat:borderStyle=solid} <br></td></tr>
            <tr><td class="diff-changed-lines" ><span class="diff-deleted-words"style="color:#999;background-color:#fdd;text-decoration:line-through;">./gserviceReg.sh</span>
<span class="diff-added-words"style="background-color: #dfd;">./register-service</span>
list &lt;service_name&gt; <br></td></tr>
            <tr><td class="diff-unchanged" >{noformat} <br>where _&lt;service_name&gt;_
is the name of the service.  <br></td></tr>
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" >To remove the Apache Geronimo service,
run the following command: <br>{noformat:borderStyle=solid} <br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">./gserviceReg.sh
del &lt;service_name&gt; <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">./register-service
delete &lt;service_name&gt; <br></td></tr>
            <tr><td class="diff-unchanged" >{noformat} <br>where _&lt;service_name&gt;_
is the name of the service you want to remove.  <br></td></tr>
    
            </table>
    </div>                            <h4>Full Content</h4>
                    <div class="notificationGreySide">
        <p>This article will show you how to configure Apache Geronimo server to run
as a Linux service.</p>
<div>
<ul>
    <li><a href='#RunningGeronimoasaLinuxservice-SoftwarePrerequisites'>Software
Prerequisites</a></li>
    <li><a href='#RunningGeronimoasaLinuxservice-InstallingaGeronimoservice'>Installing
a Geronimo service</a></li>
    <li><a href='#RunningGeronimoasaLinuxservice-ManagingtheinstalledGeronimoservice'>Managing
the installed Geronimo service</a></li>
<ul>
    <li><a href='#RunningGeronimoasaLinuxservice-Starting%2Cstoppingorrestartingaservice'>Starting,
stopping or restarting a service</a></li>
    <li><a href='#RunningGeronimoasaLinuxservice-Checkingthestatusofaservice'>Checking
the status of a service</a></li>
    <li><a href='#RunningGeronimoasaLinuxservice-Findingthemappingdirectoryofaservice'>Finding
the mapping directory of a service</a></li>
</ul>
    <li><a href='#RunningGeronimoasaLinuxservice-RemovingaGeronimoservice'>Removing
a Geronimo service</a></li>
</ul></div>


<h2><a name="RunningGeronimoasaLinuxservice-SoftwarePrerequisites"></a>Software
Prerequisites</h2>
<p>To run Apache Geronimo as a Linux service, you need a Geronimo server installed on
Linux. Follow the instructions for installing Apache Geronimo in <a href="/confluence/display/GMOxDOC30/Quick+start+-+Apache+Geronimo+for+the+impatient"
title="Quick start - Apache Geronimo for the impatient">Quick Start</a>. Throughout
the rest of the article  the installation directory will be referred to as <tt>&lt;geronimo_home&gt;</tt>.</p>

<h2><a name="RunningGeronimoasaLinuxservice-InstallingaGeronimoservice"></a>Installing
a Geronimo service</h2>
<p>Make sure that you log on the system as a root user. Then we need a Linux Shell script
<tt>register-service</tt> to run the Geronimo server as a serive. This file is
by default located in <tt>&lt;geronimo_home&gt;/bin</tt>.</p>

<p>You can now run Geronimo as a service from a command line, by running the following
command from <tt>&lt;geronimo_home&gt;/bin</tt>:</p>
<div class="preformatted panel" style="border-style: solid;border-width: 1px;"><div
class="preformattedContent panelContent">
<pre>./register-service add &lt;service_name&gt;
</pre>
</div></div>
<p>where <em>&lt;service_name&gt;</em> is the name you specify for
a service. You can create multiple service names for the server.</p>

<p>After you install the Geronimo server as a service, the service will be started automatically
when the operating system is started next time. </p>

<h2><a name="RunningGeronimoasaLinuxservice-ManagingtheinstalledGeronimoservice"></a>Managing
the installed Geronimo service </h2>

<h3><a name="RunningGeronimoasaLinuxservice-Starting%2Cstoppingorrestartingaservice"></a>Starting,
stopping or restarting a service</h3>
<p>You can start the service by running this command:</p>
<div class="preformatted panel" style="border-style: solid;border-width: 1px;"><div
class="preformattedContent panelContent">
<pre>&lt;service_name&gt; start
</pre>
</div></div>
<p>Similarly, stop the service b running this command:</p>
<div class="preformatted panel" style="border-style: solid;border-width: 1px;"><div
class="preformattedContent panelContent">
<pre>&lt;service_name&gt; stop
</pre>
</div></div>
<p>Restart the service b running this command:</p>
<div class="preformatted panel" style="border-style: solid;border-width: 1px;"><div
class="preformattedContent panelContent">
<pre>&lt;service_name&gt; restart
</pre>
</div></div>
<p>where <em>&lt;service_name&gt;</em> is the name of the service.
</p>

<h3><a name="RunningGeronimoasaLinuxservice-Checkingthestatusofaservice"></a>Checking
the status of a service</h3>
<p>To find the status of a Geronimo service, run the following command:</p>
<div class="preformatted panel" style="border-style: solid;border-width: 1px;"><div
class="preformattedContent panelContent">
<pre>&lt;service_name&gt; status
</pre>
</div></div>
<p>where <em>&lt;service_name&gt;</em> is the name of the service.
</p>

<h3><a name="RunningGeronimoasaLinuxservice-Findingthemappingdirectoryofaservice"></a>Finding
the mapping directory of a service</h3>
<p>If you have installed multiple services on the server, you might want to find the
mapping directory for each service. Run the following command to find the mapping directory:</p>
<div class="preformatted panel" style="border-style: solid;border-width: 1px;"><div
class="preformattedContent panelContent">
<pre>./register-service list &lt;service_name&gt;
</pre>
</div></div>
<p>where <em>&lt;service_name&gt;</em> is the name of the service.
</p>

<h2><a name="RunningGeronimoasaLinuxservice-RemovingaGeronimoservice"></a>Removing
a Geronimo service</h2>
<p>To remove the Apache Geronimo service, run the following command:</p>
<div class="preformatted panel" style="border-style: solid;border-width: 1px;"><div
class="preformattedContent panelContent">
<pre>./register-service delete &lt;service_name&gt;
</pre>
</div></div>
<p>where <em>&lt;service_name&gt;</em> is the name of the service
you want to remove. </p>

    </div>
        <div id="commentsSection" class="wiki-content pageSection">
        <div style="float: right;">
            <a href="https://cwiki.apache.org/confluence/users/viewnotifications.action"
class="grey">Change Notification Preferences</a>
        </div>
        <a href="https://cwiki.apache.org/confluence/display/GMOxDOC30/Running+Geronimo+as+a+Linux+service">View
Online</a>
        |
        <a href="https://cwiki.apache.org/confluence/pages/diffpagesbyversion.action?pageId=20645444&revisedVersion=2&originalVersion=1">View
Changes</a>
                |
        <a href="https://cwiki.apache.org/confluence/display/GMOxDOC30/Running+Geronimo+as+a+Linux+service?showComments=true&amp;showCommentArea=true#addcomment">Add
Comment</a>
            </div>
</div>
</div>
</div>
</div>
</body>
</html>

Mime
View raw message