You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@geronimo.apache.org by abpb2006 <ab...@yahoo.com> on 2007/11/29 08:06:12 UTC

How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Hi,

We have started 5 instances of Gronimo Server Installation using below :

java java -Dorg.apache.geronimo.server.name=myserver
-Djava.endorsed.dirs=lib /endorsed -javaagent:bin/jpa.jar -jar
bin/server.jar 


Now if i need to shut down one of the intances using command line, how do i
do that ?

Pl suggest...thanks a lot in advace.

ABPB
-- 
View this message in context: http://www.nabble.com/How-to-shut-donwn-one-of-the-instances-on-Gronimo-while-they-were-started-by-Multiple-server-command-cmd-line-tf4895464s134.html#a14020472
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Re: How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Posted by Jacek Laskowski <ja...@laskowski.net.pl>.
On Nov 30, 2007 5:59 AM, Vamsavardhana Reddy <c1...@gmail.com> wrote:

> You may also run "deploy login" which asks for username & password and
> stashes the authentication info.  Subsequent runs of deploy will not ask for
> username & password. Type "deploy help login" to get more details on the
> command.

Hi Vamsi,

Awesome! That's one of the most useful features I didn't even know it
existed. I kept using the --user and --password options all the time
and didn't even think of having such a feature like saving it
somewhere. Nice.

Jacek

-- 
Jacek Laskowski
http://www.JacekLaskowski.pl

Re: How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Posted by Vamsavardhana Reddy <c1...@gmail.com>.
On Nov 29, 2007 1:16 PM, Jacek Laskowski <ja...@laskowski.net.pl> wrote:

> On Nov 29, 2007 8:40 AM, abpb2006 <ab...@yahoo.com> wrote:
>
> > is there a way we where we dont have to enter system/manager at commnad
> > line.
>
> Yup. This is what --user and --password options are for.

You may also run "deploy login" which asks for username & password and
stashes the authentication info.  Subsequent runs of deploy will not ask for
username & password. Type "deploy help login" to get more details on the
command.

++Vamsi



>
> > deploy --port 1109 deploy newrepo.xml
> >
> > but it asks for un and pwd....can we somehow automate it...where user
> does
> > not has to enter un and pwd...
>
> You can run it with the following command (provided the default
> credentials are in use):
>
> deploy --user system --password manager --port 1109 deploy newrepo.xml
>
> Jacek
>
> --
> Jacek Laskowski
> http://www.JacekLaskowski.pl
>

Re: How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Posted by abpb2006 <ab...@yahoo.com>.
it was indeed very helpful david

one more quick ques...

It want to increase the port offset size currnently its only taking max of
4000 ....how can i increase the portoffset limit

this is really required in our setup. Any pointers for me? thanks in advance
again.

ABPB





djencks wrote:
> 
> 
> On Nov 29, 2007, at 1:49 PM, abpb2006 wrote:
> 
>>
>> oh i see. thanks.
>>
>> Where and how do we change the default credentials for every user  
>> instance?
> 
> In trunk and perhaps 2.0.2 the default security config is configured  
> in the server-security-config module.  It's set up to use the  
> properties file login module.  In trunk this is set up as a plugin  
> and the default properties files are included in the plugin.  For  
> serious usage I'd recommend coming up with your own real-server- 
> security-config module using kerberos/ldap/sql/whatever and replacing  
> the default one with it using artifact_aliases.properties.
> 
> If you want to keep using the toy properties file login module but  
> just change the credentials you can edit var/security/ 
> users.properties and var/security/groups.properties.  The admin group  
> gets remote deploy/lifecycle access.
> 
> hope this helps
> david jencks
> 
>>
>>
>>
>>
>> Jacek Laskowski wrote:
>>>
>>> On Nov 29, 2007 9:27 AM, abpb2006 <ab...@yahoo.com> wrote:
>>>
>>>> What impact its gonna have evn if we use the same default user  
>>>> name and
>>>> pwd
>>>> i.e. SYSTEM and MANAGER for all the instances.....can one user  
>>>> instance
>>>> mess
>>>> other users deployed application/settings etc ?
>>>
>>> If you ask about Geronimos working together to rule the world, I'd  
>>> say
>>> it's not possible..today perhaps tomorrow ;-) Seriously, when someone
>>> breaches one geronimo instance without knowing the admin credentials
>>> (s)he cannot do much on another Geronimo instance - they're separate
>>> entities and any outside connection is (supposed to be) authorized.
>>> It's not recommended to leave the default system credentials  
>>> active as
>>> it's widely known to everybody who has worked with Geronimo or wants
>>> to pass its security fence.
>>>
>>> Jacek
>>>
>>> -- 
>>> Jacek Laskowski
>>> http://www.JacekLaskowski.pl
>>>
>>>
>>
>> -- 
>> View this message in context: http://www.nabble.com/How-to-shut- 
>> donwn-one-of-the-instances-on-Gronimo-while-they-were-started-by- 
>> Multiple-server-command-cmd-line-tf4895464s134.html#a14035947
>> Sent from the Apache Geronimo - Users mailing list archive at  
>> Nabble.com.
>>
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/How-to-shut-donwn-one-of-the-instances-on-Gronimo-while-they-were-started-by-Multiple-server-command-cmd-line-tf4895464s134.html#a14038563
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Re: How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Posted by David Jencks <da...@yahoo.com>.
On Nov 29, 2007, at 1:49 PM, abpb2006 wrote:

>
> oh i see. thanks.
>
> Where and how do we change the default credentials for every user  
> instance?

In trunk and perhaps 2.0.2 the default security config is configured  
in the server-security-config module.  It's set up to use the  
properties file login module.  In trunk this is set up as a plugin  
and the default properties files are included in the plugin.  For  
serious usage I'd recommend coming up with your own real-server- 
security-config module using kerberos/ldap/sql/whatever and replacing  
the default one with it using artifact_aliases.properties.

If you want to keep using the toy properties file login module but  
just change the credentials you can edit var/security/ 
users.properties and var/security/groups.properties.  The admin group  
gets remote deploy/lifecycle access.

hope this helps
david jencks

>
>
>
>
> Jacek Laskowski wrote:
>>
>> On Nov 29, 2007 9:27 AM, abpb2006 <ab...@yahoo.com> wrote:
>>
>>> What impact its gonna have evn if we use the same default user  
>>> name and
>>> pwd
>>> i.e. SYSTEM and MANAGER for all the instances.....can one user  
>>> instance
>>> mess
>>> other users deployed application/settings etc ?
>>
>> If you ask about Geronimos working together to rule the world, I'd  
>> say
>> it's not possible..today perhaps tomorrow ;-) Seriously, when someone
>> breaches one geronimo instance without knowing the admin credentials
>> (s)he cannot do much on another Geronimo instance - they're separate
>> entities and any outside connection is (supposed to be) authorized.
>> It's not recommended to leave the default system credentials  
>> active as
>> it's widely known to everybody who has worked with Geronimo or wants
>> to pass its security fence.
>>
>> Jacek
>>
>> -- 
>> Jacek Laskowski
>> http://www.JacekLaskowski.pl
>>
>>
>
> -- 
> View this message in context: http://www.nabble.com/How-to-shut- 
> donwn-one-of-the-instances-on-Gronimo-while-they-were-started-by- 
> Multiple-server-command-cmd-line-tf4895464s134.html#a14035947
> Sent from the Apache Geronimo - Users mailing list archive at  
> Nabble.com.
>


Re: How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Posted by abpb2006 <ab...@yahoo.com>.
oh i see. thanks.

Where and how do we change the default credentials for every user instance?




Jacek Laskowski wrote:
> 
> On Nov 29, 2007 9:27 AM, abpb2006 <ab...@yahoo.com> wrote:
> 
>> What impact its gonna have evn if we use the same default user name and
>> pwd
>> i.e. SYSTEM and MANAGER for all the instances.....can one user instance
>> mess
>> other users deployed application/settings etc ?
> 
> If you ask about Geronimos working together to rule the world, I'd say
> it's not possible..today perhaps tomorrow ;-) Seriously, when someone
> breaches one geronimo instance without knowing the admin credentials
> (s)he cannot do much on another Geronimo instance - they're separate
> entities and any outside connection is (supposed to be) authorized.
> It's not recommended to leave the default system credentials active as
> it's widely known to everybody who has worked with Geronimo or wants
> to pass its security fence.
> 
> Jacek
> 
> -- 
> Jacek Laskowski
> http://www.JacekLaskowski.pl
> 
> 

-- 
View this message in context: http://www.nabble.com/How-to-shut-donwn-one-of-the-instances-on-Gronimo-while-they-were-started-by-Multiple-server-command-cmd-line-tf4895464s134.html#a14035947
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Re: How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Posted by Jacek Laskowski <ja...@laskowski.net.pl>.
On Nov 29, 2007 9:27 AM, abpb2006 <ab...@yahoo.com> wrote:

> What impact its gonna have evn if we use the same default user name and pwd
> i.e. SYSTEM and MANAGER for all the instances.....can one user instance mess
> other users deployed application/settings etc ?

If you ask about Geronimos working together to rule the world, I'd say
it's not possible..today perhaps tomorrow ;-) Seriously, when someone
breaches one geronimo instance without knowing the admin credentials
(s)he cannot do much on another Geronimo instance - they're separate
entities and any outside connection is (supposed to be) authorized.
It's not recommended to leave the default system credentials active as
it's widely known to everybody who has worked with Geronimo or wants
to pass its security fence.

Jacek

-- 
Jacek Laskowski
http://www.JacekLaskowski.pl

Re: How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Posted by abpb2006 <ab...@yahoo.com>.
Greattttttttttttt Jacek. Loads of thanks.

One more qucik que...

What impact its gonna have evn if we use the same default user name and pwd
i.e. SYSTEM and MANAGER for all the instances.....can one user instance mess
other users deployed application/settings etc ?

thanks.
ABPB







Jacek Laskowski wrote:
> 
> On Nov 29, 2007 8:40 AM, abpb2006 <ab...@yahoo.com> wrote:
> 
>> is there a way we where we dont have to enter system/manager at commnad
>> line.
> 
> Yup. This is what --user and --password options are for.
> 
>> deploy --port 1109 deploy newrepo.xml
>>
>> but it asks for un and pwd....can we somehow automate it...where user
>> does
>> not has to enter un and pwd...
> 
> You can run it with the following command (provided the default
> credentials are in use):
> 
> deploy --user system --password manager --port 1109 deploy newrepo.xml
> 
> Jacek
> 
> -- 
> Jacek Laskowski
> http://www.JacekLaskowski.pl
> 
> 

-- 
View this message in context: http://www.nabble.com/How-to-shut-donwn-one-of-the-instances-on-Gronimo-while-they-were-started-by-Multiple-server-command-cmd-line-tf4895464s134.html#a14021262
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Re: How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Posted by Jacek Laskowski <ja...@laskowski.net.pl>.
On Nov 29, 2007 8:40 AM, abpb2006 <ab...@yahoo.com> wrote:

> is there a way we where we dont have to enter system/manager at commnad
> line.

Yup. This is what --user and --password options are for.

> deploy --port 1109 deploy newrepo.xml
>
> but it asks for un and pwd....can we somehow automate it...where user does
> not has to enter un and pwd...

You can run it with the following command (provided the default
credentials are in use):

deploy --user system --password manager --port 1109 deploy newrepo.xml

Jacek

-- 
Jacek Laskowski
http://www.JacekLaskowski.pl

Re: How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Posted by abpb2006 <ab...@yahoo.com>.
thanks Jacek..

is there a way we where we dont have to enter system/manager at commnad
line.

we r configuring multiple instances for many users and their onw repository
for that instance. So while deploying thier repository...we run the below
command :

deploy --port 1109 deploy newrepo.xml

but it asks for un and pwd....can we somehow automate it...where user does
not has to enter un and pwd...

thanks a lot
ABPB





Jacek Laskowski wrote:
> 
> On Nov 29, 2007 8:06 AM, abpb2006 <ab...@yahoo.com> wrote:
> 
>> We have started 5 instances of Gronimo Server Installation using below :
>>
>> java java -Dorg.apache.geronimo.server.name=myserver
>> -Djava.endorsed.dirs=lib /endorsed -javaagent:bin/jpa.jar -jar
>> bin/server.jar
>>
>> Now if i need to shut down one of the intances using command line, how do
>> i
>> do that ?
> 
> They listen to different RMI ports so ./bin/shutdown.sh --port <port>
> should work fine.
> 
> jlaskowski@dev /cygdrive/c/geronimo
> $ ./bin/shutdown.sh -h
> Using GERONIMO_BASE:   c:\geronimo
> Using GERONIMO_HOME:   c:\geronimo
> Using GERONIMO_TMPDIR: c:\geronimo\var\temp
> Using JRE_HOME:        c:\apps\java5\jre
> 
> Command-line shutdown syntax:
>     shutdown [options]
> 
> The available options are:
>     --user
>     --password
>     --port
> 
> Here some sample sessions:
> 
> jlaskowski@dev /cygdrive/c/geronimo
> $ ./bin/shutdown.sh --port 1099
> Using GERONIMO_BASE:   c:\geronimo
> Using GERONIMO_HOME:   c:\geronimo
> Using GERONIMO_TMPDIR: c:\geronimo\var\temp
> Using JRE_HOME:        c:\apps\java5\jre
> Username: system
> Password: *******
> Locating server on port 1099...
> Could not communicate with the server.  The server may not be running
> or the port number may be incorrect.
> 
> jlaskowski@dev /cygdrive/c/geronimo
> $ ./bin/shutdown.sh --port 2054
> Using GERONIMO_BASE:   c:\geronimo
> Using GERONIMO_HOME:   c:\geronimo
> Using GERONIMO_TMPDIR: c:\geronimo\var\temp
> Using JRE_HOME:        c:\apps\java5\jre
> Username: system
> Password: *******
> Locating server on port 2054...
> Could not communicate with the server.  The server may not be running
> or the port number may be incorrect.
> 
> You can use ./bin/geronimo.sh stop --port too.
> 
> jlaskowski@dev /cygdrive/c/geronimo
> $ ./bin/geronimo.sh --help
> Using GERONIMO_BASE:   c:\geronimo
> Using GERONIMO_HOME:   c:\geronimo
> Using GERONIMO_TMPDIR: c:\geronimo\var\temp
> Using JRE_HOME:        c:\apps\java5\jre
> Usage: geronimo.sh command [geronimo_args]
> commands:
>   debug             Debug Geronimo in jdb debugger
>   jpda run          Start Geronimo in foreground under JPDA debugger
>   jpda start        Start Geronimo in background under JPDA debugger
>   run               Start Geronimo in the foreground
>   start             Start Geronimo in the background
>   stop              Stop Geronimo
>   stop --force      Stop Geronimo (followed by kill -KILL)
> 
> args for debug, jpda run, jpda start, run and start commands:
>        --quiet       No startup progress
>        --long        Long startup progress
>   -v   --verbose     INFO log level
>   -vv  --veryverbose DEBUG log level
>        --override    Override configurations. USE WITH CAUTION!
>        --help        Detailed help.
> 
> args for stop command:
>        --user        Admin user
>        --password    Admin password
>        --port        RMI port to connect to
> 
> Jacek
> 
> -- 
> Jacek Laskowski
> http://www.JacekLaskowski.pl
> 
> 

-- 
View this message in context: http://www.nabble.com/How-to-shut-donwn-one-of-the-instances-on-Gronimo-while-they-were-started-by-Multiple-server-command-cmd-line-tf4895464s134.html#a14020710
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Re: How to shut donwn one of the instances on Gronimo while they were started by Multiple server command cmd line

Posted by Jacek Laskowski <ja...@laskowski.net.pl>.
On Nov 29, 2007 8:06 AM, abpb2006 <ab...@yahoo.com> wrote:

> We have started 5 instances of Gronimo Server Installation using below :
>
> java java -Dorg.apache.geronimo.server.name=myserver
> -Djava.endorsed.dirs=lib /endorsed -javaagent:bin/jpa.jar -jar
> bin/server.jar
>
> Now if i need to shut down one of the intances using command line, how do i
> do that ?

They listen to different RMI ports so ./bin/shutdown.sh --port <port>
should work fine.

jlaskowski@dev /cygdrive/c/geronimo
$ ./bin/shutdown.sh -h
Using GERONIMO_BASE:   c:\geronimo
Using GERONIMO_HOME:   c:\geronimo
Using GERONIMO_TMPDIR: c:\geronimo\var\temp
Using JRE_HOME:        c:\apps\java5\jre

Command-line shutdown syntax:
    shutdown [options]

The available options are:
    --user
    --password
    --port

Here some sample sessions:

jlaskowski@dev /cygdrive/c/geronimo
$ ./bin/shutdown.sh --port 1099
Using GERONIMO_BASE:   c:\geronimo
Using GERONIMO_HOME:   c:\geronimo
Using GERONIMO_TMPDIR: c:\geronimo\var\temp
Using JRE_HOME:        c:\apps\java5\jre
Username: system
Password: *******
Locating server on port 1099...
Could not communicate with the server.  The server may not be running
or the port number may be incorrect.

jlaskowski@dev /cygdrive/c/geronimo
$ ./bin/shutdown.sh --port 2054
Using GERONIMO_BASE:   c:\geronimo
Using GERONIMO_HOME:   c:\geronimo
Using GERONIMO_TMPDIR: c:\geronimo\var\temp
Using JRE_HOME:        c:\apps\java5\jre
Username: system
Password: *******
Locating server on port 2054...
Could not communicate with the server.  The server may not be running
or the port number may be incorrect.

You can use ./bin/geronimo.sh stop --port too.

jlaskowski@dev /cygdrive/c/geronimo
$ ./bin/geronimo.sh --help
Using GERONIMO_BASE:   c:\geronimo
Using GERONIMO_HOME:   c:\geronimo
Using GERONIMO_TMPDIR: c:\geronimo\var\temp
Using JRE_HOME:        c:\apps\java5\jre
Usage: geronimo.sh command [geronimo_args]
commands:
  debug             Debug Geronimo in jdb debugger
  jpda run          Start Geronimo in foreground under JPDA debugger
  jpda start        Start Geronimo in background under JPDA debugger
  run               Start Geronimo in the foreground
  start             Start Geronimo in the background
  stop              Stop Geronimo
  stop --force      Stop Geronimo (followed by kill -KILL)

args for debug, jpda run, jpda start, run and start commands:
       --quiet       No startup progress
       --long        Long startup progress
  -v   --verbose     INFO log level
  -vv  --veryverbose DEBUG log level
       --override    Override configurations. USE WITH CAUTION!
       --help        Detailed help.

args for stop command:
       --user        Admin user
       --password    Admin password
       --port        RMI port to connect to

Jacek

-- 
Jacek Laskowski
http://www.JacekLaskowski.pl