You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by Jason Warner <ja...@gmail.com> on 2008/03/10 18:36:05 UTC

Old Gshell sample causing issues with setting Java Memory options

I've been getting strange errors when trying to change the amount of memory
available to my instance of geronimo that I have launched through gshell.
After some digging, I found that what I believe is an old sample that was
left in the etc/rc.d/ directory (start-server,default.groovy) is setting the
max heap size to 512m.  This causes issues as it overrides whatever the user
provides on the command line.  Meaning if I try to issue the command
"geronimo/start-server -J -Xmx1024m -J -Xms1024m" I would get an
incompatible initial and maximum heap size error because the rc.d file is
overwriting my command options and setting maximum heap size to 512m.  I
fixed this by deleting the file in the rc.d directory.  Does anyone know
where this file comes from?  I assume it gets added in somehow during build
time.  I'll have to look and see if I can find where.  In the meantime, I'll
open an issue for this.

-- 
~Jason Warner

Re: Old Gshell sample causing issues with setting Java Memory options

Posted by Donald Woods <dw...@apache.org>.
Agree, that whatever override options the user supplies to GShell should 
always win over what is in the rc.d file.

-Donald


Jason Warner wrote:
> I thought about this a little bit more and think that the way we handle 
> this scripts is a little wrong.  By this I mean that I think whatever is 
> put on the command line should overwrite what is in the script.  I 
> haven't looked at the code for this, so I'm not sure how difficult of a 
> change that would be. 
> 
> Thanks,
> 
> 
> On Mon, Mar 10, 2008 at 4:18 PM, Jason Warner <jaw981@gmail.com 
> <ma...@gmail.com>> wrote:
> 
>     Editing it isn't an issue, and deleting probably was a little bit of
>     an extreme idea.  Is this documented anywhere, though?  I don't
>     think it's obvious to check for this wholly geronimo specific file
>     to figure out why you are having issues setting max heap size.  I
>     couldn't find any documentation on it.  Maybe I'll add some myself
>     if it doesn't exist.  ;)
> 
> 
>     On Mon, Mar 10, 2008 at 4:11 PM, David Jencks
>     <david_jencks@yahoo.com <ma...@yahoo.com>> wrote:
> 
>         I use it every day to remind me how to set up debugging.  I will
>         be extremely unhappy if it goes away.  I also think the server
>         may not run well with a smaller heap.
> 
>         can you edit your settings into this file instead of removing
>         it?  I find that much more convenient than trying to remember a
>         long command line.
> 
>         thanks
>         david jencks
> 
>         On Mar 10, 2008, at 12:52 PM, Jason Warner wrote:
> 
>>         I found where the file is, but I'm not quite sure what to do
>>         about it.  My vote would go towards just removing it, but I'm
>>         sure it was put there with a purpose to begin with.  Anyone
>>         have objections to removing it or any other ideas as to what
>>         to do with it?
>>
>>         On Mon, Mar 10, 2008 at 1:36 PM, Jason Warner
>>         <jaw981@gmail.com <ma...@gmail.com>> wrote:
>>
>>             I've been getting strange errors when trying to change the
>>             amount of memory available to my instance of geronimo that
>>             I have launched through gshell.  After some digging, I
>>             found that what I believe is an old sample that was left
>>             in the etc/rc.d/ directory (start-server,default.groovy)
>>             is setting the max heap size to 512m.  This causes issues
>>             as it overrides whatever the user provides on the command
>>             line.  Meaning if I try to issue the command
>>             "geronimo/start-server -J -Xmx1024m -J -Xms1024m" I would
>>             get an incompatible initial and maximum heap size error
>>             because the rc.d file is overwriting my command options
>>             and setting maximum heap size to 512m.  I fixed this by
>>             deleting the file in the rc.d directory.  Does anyone know
>>             where this file comes from?  I assume it gets added in
>>             somehow during build time.  I'll have to look and see if I
>>             can find where.  In the meantime, I'll open an issue for this.
>>
>>             -- 
>>             ~Jason Warner 
>>
>>
>>
>>
>>         -- 
>>         ~Jason Warner
> 
> 
> 
> 
>     -- 
>     ~Jason Warner 
> 
> 
> 
> 
> -- 
> ~Jason Warner

Re: Old Gshell sample causing issues with setting Java Memory options

Posted by Jason Warner <ja...@gmail.com>.
I thought about this a little bit more and think that the way we handle this
scripts is a little wrong.  By this I mean that I think whatever is put on
the command line should overwrite what is in the script.  I haven't looked
at the code for this, so I'm not sure how difficult of a change that would
be.

Thanks,


On Mon, Mar 10, 2008 at 4:18 PM, Jason Warner <ja...@gmail.com> wrote:

> Editing it isn't an issue, and deleting probably was a little bit of an
> extreme idea.  Is this documented anywhere, though?  I don't think it's
> obvious to check for this wholly geronimo specific file to figure out why
> you are having issues setting max heap size.  I couldn't find any
> documentation on it.  Maybe I'll add some myself if it doesn't exist.  ;)
>
>
> On Mon, Mar 10, 2008 at 4:11 PM, David Jencks <da...@yahoo.com>
> wrote:
>
> >  I use it every day to remind me how to set up debugging.  I will be
> > extremely unhappy if it goes away.  I also think the server may not run well
> > with a smaller heap.
> > can you edit your settings into this file instead of removing it?  I
> > find that much more convenient than trying to remember a long command line.
> >
> > thanks
> > david jencks
> >
> > On Mar 10, 2008, at 12:52 PM, Jason Warner wrote:
> >
> > I found where the file is, but I'm not quite sure what to do about it.
> > My vote would go towards just removing it, but I'm sure it was put there
> > with a purpose to begin with.  Anyone have objections to removing it or any
> > other ideas as to what to do with it?
> >
> > On Mon, Mar 10, 2008 at 1:36 PM, Jason Warner <ja...@gmail.com> wrote:
> >
> > > I've been getting strange errors when trying to change the amount of
> > > memory available to my instance of geronimo that I have launched through
> > > gshell.  After some digging, I found that what I believe is an old sample
> > > that was left in the etc/rc.d/ directory (start-server,default.groovy)
> > > is setting the max heap size to 512m.  This causes issues as it overrides
> > > whatever the user provides on the command line.  Meaning if I try to issue
> > > the command "geronimo/start-server -J -Xmx1024m -J -Xms1024m" I would get an
> > > incompatible initial and maximum heap size error because the rc.d file
> > > is overwriting my command options and setting maximum heap size to 512m.  I
> > > fixed this by deleting the file in the rc.d directory.  Does anyone
> > > know where this file comes from?  I assume it gets added in somehow during
> > > build time.  I'll have to look and see if I can find where.  In the
> > > meantime, I'll open an issue for this.
> > >
> > > --
> > > ~Jason Warner
> >
> >
> >
> >
> > --
> > ~Jason Warner
> >
> >
> >
>
>
> --
> ~Jason Warner




-- 
~Jason Warner

Re: Old Gshell sample causing issues with setting Java Memory options

Posted by Jason Warner <ja...@gmail.com>.
Editing it isn't an issue, and deleting probably was a little bit of an
extreme idea.  Is this documented anywhere, though?  I don't think it's
obvious to check for this wholly geronimo specific file to figure out why
you are having issues setting max heap size.  I couldn't find any
documentation on it.  Maybe I'll add some myself if it doesn't exist.  ;)

On Mon, Mar 10, 2008 at 4:11 PM, David Jencks <da...@yahoo.com>
wrote:

> I use it every day to remind me how to set up debugging.  I will be
> extremely unhappy if it goes away.  I also think the server may not run well
> with a smaller heap.
> can you edit your settings into this file instead of removing it?  I find
> that much more convenient than trying to remember a long command line.
>
> thanks
> david jencks
>
> On Mar 10, 2008, at 12:52 PM, Jason Warner wrote:
>
> I found where the file is, but I'm not quite sure what to do about it.  My
> vote would go towards just removing it, but I'm sure it was put there with a
> purpose to begin with.  Anyone have objections to removing it or any other
> ideas as to what to do with it?
>
> On Mon, Mar 10, 2008 at 1:36 PM, Jason Warner <ja...@gmail.com> wrote:
>
> > I've been getting strange errors when trying to change the amount of
> > memory available to my instance of geronimo that I have launched through
> > gshell.  After some digging, I found that what I believe is an old sample
> > that was left in the etc/rc.d/ directory (start-server,default.groovy)
> > is setting the max heap size to 512m.  This causes issues as it overrides
> > whatever the user provides on the command line.  Meaning if I try to issue
> > the command "geronimo/start-server -J -Xmx1024m -J -Xms1024m" I would get an
> > incompatible initial and maximum heap size error because the rc.d file
> > is overwriting my command options and setting maximum heap size to 512m.  I
> > fixed this by deleting the file in the rc.d directory.  Does anyone know
> > where this file comes from?  I assume it gets added in somehow during build
> > time.  I'll have to look and see if I can find where.  In the meantime, I'll
> > open an issue for this.
> >
> > --
> > ~Jason Warner
>
>
>
>
> --
> ~Jason Warner
>
>
>


-- 
~Jason Warner

Re: Old Gshell sample causing issues with setting Java Memory options

Posted by David Jencks <da...@yahoo.com>.
I use it every day to remind me how to set up debugging.  I will be  
extremely unhappy if it goes away.  I also think the server may not  
run well with a smaller heap.

can you edit your settings into this file instead of removing it?  I  
find that much more convenient than trying to remember a long command  
line.

thanks
david jencks

On Mar 10, 2008, at 12:52 PM, Jason Warner wrote:

> I found where the file is, but I'm not quite sure what to do about  
> it.  My vote would go towards just removing it, but I'm sure it was  
> put there with a purpose to begin with.  Anyone have objections to  
> removing it or any other ideas as to what to do with it?
>
> On Mon, Mar 10, 2008 at 1:36 PM, Jason Warner <ja...@gmail.com>  
> wrote:
> I've been getting strange errors when trying to change the amount  
> of memory available to my instance of geronimo that I have launched  
> through gshell.  After some digging, I found that what I believe is  
> an old sample that was left in the etc/rc.d/ directory (start- 
> server,default.groovy) is setting the max heap size to 512m.  This  
> causes issues as it overrides whatever the user provides on the  
> command line.  Meaning if I try to issue the command "geronimo/ 
> start-server -J -Xmx1024m -J -Xms1024m" I would get an incompatible  
> initial and maximum heap size error because the rc.d file is  
> overwriting my command options and setting maximum heap size to  
> 512m.  I fixed this by deleting the file in the rc.d directory.   
> Does anyone know where this file comes from?  I assume it gets  
> added in somehow during build time.  I'll have to look and see if I  
> can find where.  In the meantime, I'll open an issue for this.
>
> -- 
> ~Jason Warner
>
>
>
> -- 
> ~Jason Warner


Re: Old Gshell sample causing issues with setting Java Memory options

Posted by Jason Warner <ja...@gmail.com>.
I found where the file is, but I'm not quite sure what to do about it.  My
vote would go towards just removing it, but I'm sure it was put there with a
purpose to begin with.  Anyone have objections to removing it or any other
ideas as to what to do with it?

On Mon, Mar 10, 2008 at 1:36 PM, Jason Warner <ja...@gmail.com> wrote:

> I've been getting strange errors when trying to change the amount of
> memory available to my instance of geronimo that I have launched through
> gshell.  After some digging, I found that what I believe is an old sample
> that was left in the etc/rc.d/ directory (start-server,default.groovy) is
> setting the max heap size to 512m.  This causes issues as it overrides
> whatever the user provides on the command line.  Meaning if I try to issue
> the command "geronimo/start-server -J -Xmx1024m -J -Xms1024m" I would get an
> incompatible initial and maximum heap size error because the rc.d file is
> overwriting my command options and setting maximum heap size to 512m.  I
> fixed this by deleting the file in the rc.d directory.  Does anyone know
> where this file comes from?  I assume it gets added in somehow during build
> time.  I'll have to look and see if I can find where.  In the meantime, I'll
> open an issue for this.
>
> --
> ~Jason Warner




-- 
~Jason Warner