<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic My launcher says it couldn&amp;apos;t retrieve process ID in Nuxeo Forum</title>
    <link>https://connect.hyland.com/t5/nuxeo-forum/my-launcher-says-it-couldn-apos-t-retrieve-process-id/m-p/327219#M14220</link>
    <description>&lt;P&gt;Hi!&lt;/P&gt;
&lt;P&gt;I've installed Nuxeo and since I can see a message in my console saying:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;[org.nuxeo.launcher.NuxeoLauncher] Sent server start command but could not get process ID.

&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Is it possible to fix it?&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;</description>
    <pubDate>Wed, 23 Mar 2016 14:57:44 GMT</pubDate>
    <dc:creator>Manon_Lumeau</dc:creator>
    <dc:date>2016-03-23T14:57:44Z</dc:date>
    <item>
      <title>My launcher says it couldn&amp;apos;t retrieve process ID</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/my-launcher-says-it-couldn-apos-t-retrieve-process-id/m-p/327219#M14220</link>
      <description>&lt;P&gt;Hi!&lt;/P&gt;
&lt;P&gt;I've installed Nuxeo and since I can see a message in my console saying:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;[org.nuxeo.launcher.NuxeoLauncher] Sent server start command but could not get process ID.

&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Is it possible to fix it?&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;</description>
      <pubDate>Wed, 23 Mar 2016 14:57:44 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/my-launcher-says-it-couldn-apos-t-retrieve-process-id/m-p/327219#M14220</guid>
      <dc:creator>Manon_Lumeau</dc:creator>
      <dc:date>2016-03-23T14:57:44Z</dc:date>
    </item>
    <item>
      <title>Re: My launcher says it couldn&amp;apos;t retrieve process ID</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/my-launcher-says-it-couldn-apos-t-retrieve-process-id/m-p/327220#M14221</link>
      <description>&lt;P&gt;Hi!&lt;/P&gt;
&lt;P&gt;This message means the Launcher was not able to confirm the server status, retrieving the process id.
That can be a normal behavior on some old Windows versions and on Unix Solaris.&lt;/P&gt;
&lt;P&gt;Windows users, if you can issue the two following commands without error in a Shell windows, then the Launcher must be able to manage the server process on your OS:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;wmic quit
taskkill /?
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;H2&gt;Workarounds&lt;/H2&gt;
&lt;H3&gt;Console Mode&lt;/H3&gt;
&lt;P&gt;First, you can start in console mode (in which case, the Launcher won't try to manage the process) in order to manually check if the server can start: &lt;CODE&gt;nuxeoctl console&lt;/CODE&gt;. You will have to stop the server issuing &lt;CODE&gt;"CTRL+C"&lt;/CODE&gt;.&lt;/P&gt;
&lt;P&gt;If you can start the server that way, it should also be able to start with &lt;CODE&gt;nuxeoctl startbg&lt;/CODE&gt;. The drawback is &lt;CODE&gt;nuxeoctl stop&lt;/CODE&gt; won't be able to stop the server.&lt;/P&gt;
&lt;H3&gt;Java Commands&lt;/H3&gt;
&lt;P&gt;In case the issue lies in the batch file, you can try to run the Launcher with its Java command. If you issued &lt;CODE&gt;nuxeoctl start&lt;/CODE&gt; from a Shell window, then you can copy/paste the command titled "Launcher command". It will be of the form:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Launcher Java command&lt;/STRONG&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;java -Dlauncher.java.opts="some JVM options" -Dnuxeo.home=/path/to/nuxeo/ -Dnuxeo.conf=/path/to/nuxeo.conf -jar /path/to/nuxeo-launcher.jar start
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;You can also try to directly run the server, fully bypassing the Launcher. Look into the &lt;CODE&gt;console.log&lt;/CODE&gt; file for a command titled "Server command". You will have to run the Launcher configuration, then the server command. It will look like:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Run the server, bypassing the Launcher&lt;/STRONG&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;nuxeoctl configure
java -cp "the classpath" -Dnuxeo.home=/path/to/nuxeo -Dnuxeo.conf=/path/to/nuxeo.conf -Dnuxeo.log.dir=log -Dnuxeo.data.dir=data -Dnuxeo.tmp.dir=tmp -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Dcatalina.base=/path/to/nuxeo -Dcatalina.home=/path/to/nuxeo org.apache.catalina.startup.Bootstrap start
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;H2&gt;Debugging&lt;/H2&gt;
&lt;P&gt;Then, if you want to understand the failure cause, you can try to manually get that process ID from a Shell window, reproducing the steps used by the Launcher.&lt;/P&gt;
&lt;P&gt;Look into &lt;CODE&gt;console.log&lt;/CODE&gt; for the "regexp" keyword, this is the regular expression used to find the process ID. Something like:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;[org.nuxeo.launcher.NuxeoLauncher] regexp: \Q/path/to/nuxeo.conf\E.*\Qorg.apache.catalina.startup.Bootstrap\E pid:null
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;The command for retrieving the process ID will depend on your OS.&lt;/P&gt;
&lt;H3&gt;Linux/Unix&lt;/H3&gt;
&lt;PRE&gt;&lt;CODE&gt;/bin/ps -e -o "pid,args" | grep -E "^\s*([0-9]+)\s+(.*)$" | grep "/path/to/nuxeo.conf.*org.apache.catalina.startup.Bootstrap"
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;H3&gt;Mac OS X&lt;/H3&gt;
&lt;PRE&gt;&lt;CODE&gt;/bin/ps -e -o "pid,command" | grep -E "^ *([0-9]+) +(.*)$" | grep "/path/to/nuxeo.conf.*org.apache.catalina.startup.Bootstrap"
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;H3&gt;Windows&lt;/H3&gt;
&lt;PRE&gt;&lt;CODE&gt;wmic process get CommmandLine,ProcessId
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Look for lines matching the regular expression: &lt;CODE&gt;^(.*?)\\s+(\\d+)\\s*\$&lt;/CODE&gt;&lt;/P&gt;
&lt;P&gt;Check if one of those is matching the regular expression found in &lt;CODE&gt;console.log&lt;/CODE&gt;.&lt;/P&gt;
&lt;P&gt;Kind regards,&lt;/P&gt;
&lt;P&gt;Manon&lt;/P&gt;</description>
      <pubDate>Wed, 23 Mar 2016 15:41:14 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/my-launcher-says-it-couldn-apos-t-retrieve-process-id/m-p/327220#M14221</guid>
      <dc:creator>Manon_Lumeau</dc:creator>
      <dc:date>2016-03-23T15:41:14Z</dc:date>
    </item>
  </channel>
</rss>

