Subject: Re: Need to run a .jar file
To: Laine Stump <lainestump@speakeasy.net>
From: Steven M. Bellovin <smb@research.att.com>
List: netbsd-users
Date: 07/27/2004 14:23:12
In message <6.1.0.6.0.20040727135905.025f31a8@mail.speakeasy.net>, Laine Stump
writes:
>At 12:06 PM 7/27/2004, Chris Wareham wrote:
>>>> java -jar c07-sip-r2.jar -touri he@them.invalid -teardown -validcase
>>>>
>>>>Being a complete java idiot, I figured I could just install jdk from
>>>>pkgsrc and I would get what I wanted, but that seems not to be the case.
>>>>When I run the java binary in the jdk's bin directory, it says it
>>>>doesn't recognize the -jar option.
>>>>
>>>>So what do I need to do to run .jar files?
>>
>>To the original poster:
>>
>>Which JDK are you using? The native one from pkgsrc is probably too old
>>(v1.1.8). I use the Linux JDK from lang/sun-jdk14, which works fine for
>>me, but it wont be of any use if you're not on an i386 platform.
>
>Aha! I had just looked for things starting with "j", so I missed the
>sun-jdk package and installed the jdk-1.1.8 instead. It is missing the -jar
>commandline option.
>
>I just removed it and installed lang/sun-jdk14. Now the -jar option is
>there, but now whenever I try to run it (for anything other than just doing
>"java -?"), I get the following error:
>
> Java HotSpot(TM) Client VM warning: Can't detect initial thread stack
>location
> Error occurred during initialization of VM
> Could not reserve enough space for object heap
>
>I'm running a more-or-less GENERIC -current kernel built from sources about
>10 days ago (userland is the July 15 -current snapshot from
>releng.netbsd.org). This is running in a VMWare client VM with 256MB of
>memory allocated to it. Is there some option I need to put in my kernel
>config? A missing library?
>
'ulimit -d 262144' will get rid of the "Could not reserve enough space"
problem. The message about the thread stack is a warning; I don't know
how to make it go away, but it doesn't seem to hurt, at least in the
few cases I've tried lately.
--Steve Bellovin, http://www.research.att.com/~smb