You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by Jehova Witness <jv...@gmail.com> on 2012/10/01 22:03:56 UTC

[daemon] Problems with commons-daemon, The data area passed to a system call is too small.

I am using Commons Daemon procrun (1.0.10.0 32-bit) on Windows 7 64bit
(need to deliver a solution to customers that will work with 32bit and
64bit).

Here is my install.bat file  ( Server.exe was formerly named prunsrv.exe )

.\Server.exe //IS//MyServiceName ^
   --Install=Server.exe ^
   --Startup=auto ^
   --DisplayName="MyServer" ^
   --Description="MyServer" ^
   --StartMode=jvm ^
   --Classpath="C:\Program
Files\prod\Server-3.1.0-distribution.jar;C:\Program
Files\prod\Server-3.1.0\lib\*" ^
   --StartClass=com.company.server.impl.Server ^
   --StartPath="C:\Program Files\prod" ^
   --StartParams=start ^
   --StartMethod=start ^
   --StdOutput=auto ^
   --StdError=auto ^
   --StopMode=jvm ^
   --LogPath="C:\Program Files\prod\logs" ^
   --LogPrefix=sds.log ^
   --LogLevel=Debug ^

   --StdOutput="C:\Program Files\prod\logs\sds_stdout.log"  ^
   --StdError="c:\Program Files\prod\logs\sds_stderr.log" ^
   --Jvm="c:\jdk\32bit\1.6.0_35\jre\bin\java.dll"


With this I get "file not found"  could not start.



any ideas why this line, gives this problem?   I have a Server.exe in the
same directory.  I have also tried ./Server.exe and .\Server.exe

When I remove this line from above:
   --Install=Server.exe ^

I get another error message:

*The data area passed to a system call is too small.*

Ideally would like to resolve this problem in order to start the service.

This is my start.bat
.\Server.exe //ES//MyServiceName    <= as specified in the install service
above

Any help would be greatly appreciated, am at my wits end trying to get this
to work and have followed closely the examples I was able to find on the
web.

There are no errors installing the service.  I get no errors in the logs
indicating the remedy to any solution.

I am using the 32bit procrun with a 32 bit JDK , I am pointing to
'java.dll' under my JRE in the installation script.

J.V.

Re: [daemon] Problems with commons-daemon, The data area passed to a system call is too small.

Posted by Spico Florin <sp...@gmail.com>.
Hi!
  I have two hints for your issues:
1. For 64 bit try to install the service with the prunsrv located in amd64
folder
2. Try to replace all "\" char with the "/"
3. Try to use the jdk 64 bit version and the jvm.dll located in %JAVA_HOME%
the jre/bin/server/jvm.dll
4. Try do not mix 64 bit procrun version with 32 bit procrun

Hope that these helps.
Regards,
 Florin

On Mon, Oct 1, 2012 at 11:03 PM, Jehova Witness <jv...@gmail.com> wrote:

> I am using Commons Daemon procrun (1.0.10.0 32-bit) on Windows 7 64bit
> (need to deliver a solution to customers that will work with 32bit and
> 64bit).
>
> Here is my install.bat file  ( Server.exe was formerly named prunsrv.exe )
>
> .\Server.exe //IS//MyServiceName ^
>    --Install=Server.exe ^
>    --Startup=auto ^
>    --DisplayName="MyServer" ^
>    --Description="MyServer" ^
>    --StartMode=jvm ^
>    --Classpath="C:\Program
> Files\prod\Server-3.1.0-distribution.jar;C:\Program
> Files\prod\Server-3.1.0\lib\*" ^
>    --StartClass=com.company.server.impl.Server ^
>    --StartPath="C:\Program Files\prod" ^
>    --StartParams=start ^
>    --StartMethod=start ^
>    --StdOutput=auto ^
>    --StdError=auto ^
>    --StopMode=jvm ^
>    --LogPath="C:\Program Files\prod\logs" ^
>    --LogPrefix=sds.log ^
>    --LogLevel=Debug ^
>
>    --StdOutput="C:\Program Files\prod\logs\sds_stdout.log"  ^
>    --StdError="c:\Program Files\prod\logs\sds_stderr.log" ^
>    --Jvm="c:\jdk\32bit\1.6.0_35\jre\bin\java.dll"
>
>
> With this I get "file not found"  could not start.
>
>
>
> any ideas why this line, gives this problem?   I have a Server.exe in the
> same directory.  I have also tried ./Server.exe and .\Server.exe
>
> When I remove this line from above:
>    --Install=Server.exe ^
>
> I get another error message:
>
> *The data area passed to a system call is too small.*
>
> Ideally would like to resolve this problem in order to start the service.
>
> This is my start.bat
> .\Server.exe //ES//MyServiceName    <= as specified in the install service
> above
>
> Any help would be greatly appreciated, am at my wits end trying to get this
> to work and have followed closely the examples I was able to find on the
> web.
>
> There are no errors installing the service.  I get no errors in the logs
> indicating the remedy to any solution.
>
> I am using the 32bit procrun with a 32 bit JDK , I am pointing to
> 'java.dll' under my JRE in the installation script.
>
> J.V.
>

Re: [daemon] Problems with commons-daemon, The data area passed to a system call is too small.

Posted by Mladen Turk <mt...@apache.org>.
On 10/01/2012 10:03 PM, Jehova Witness wrote:
>
>     --Install=Server.exe ^

This must be absolute path

>     --Startup=auto ^
>     --DisplayName="MyServer" ^
>     --Description="MyServer" ^
>     --StartMode=jvm ^
>     --Classpath="C:\Program
> Files\prod\Server-3.1.0-distribution.jar;C:\Program
> Files\prod\Server-3.1.0\lib\*" ^

When you have spaces in the batch file variable use
"foo=a bar" instead foo="a bar"

In second case you will actually get "a bar" with
the quotes!

Next if you wish to use that in both 32 and 64 bit
environment do not use "Program Files", because on
32- bits "Program Files" is mapped to "Program Files (x86)"

Well at least make sure you have that in "Program Files (x86)"
but use ""Program Files" when installing the service.

>
> With this I get "file not found"  could not start.
>

Like said use the full path to Server.exe


... and BTW, if you don't get answer within 10 minutes
don't start trolling.

Regards
-- 
^TM

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org