You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by Frédéric Ravetier <fr...@gmail.com> on 2007/10/18 09:53:03 UTC

Jmeter in command line and with remote jmeter-server does not use the parameters

Hello,

I'd like to run jmeter in command line using two jmeter-server on two hosts
with parameters to set-up the number of Thread, the number of loops...
I put in my jmx script parameters like: ${__P(threadNb)} for the number of
Thread.
It is working well when I run in command line my script without host. But it
does not use the parameters when I run it with two hosts.

This is the command line I'm using in a shell script:
${JMETER_HOME}/bin/jmeter.sh -n  -t /home/jmeter/jmxScripts/${JMX_NAME}.jmx
-l /home/jmeter/jmeterResults/${JMX_NAME}_${BDATE}.jtl -R
${SERVER_1},${SERVER_2} -JthreadNb=${THREADNB}
Where all the variables are correctly initialized at the beginning.

Best regards,
Fred

Re: Jmeter in command line and with remote jmeter-server does not use the parameters

Posted by sebb <se...@gmail.com>.
On 18/10/2007, Frédéric Ravetier <fr...@gmail.com> wrote:
> Ok thank you.
>
> Is it on your road-map? If yes, when?

Not yet.

> I found an trick before you provide a nice solution in jmeter. It would be
> to use grep and sed in shell to replace directly in the JMX scripts the
> values.

Good.

> Regards,
> Fred
>
> 2007/10/18, sebb <se...@gmail.com>:
> >
> > Yes, properties set via the command-line are not passed to server
> > instances.
> > Only the test plan is sent. Each server gets its properties from the
> > local copy of jmeter.properties (and user and system.properties).
> >
> > You would need to pass the parameters to the servers when starting them.
> >
> > It would not make sense to pass all properties to the servers, but one
> > could perhaps add a facility to export particular properties to the
> > remote servers.
> >
> > Sorry, but at present I don't think that there is an easy way round this.
> >
> > On 18/10/2007, Frédéric Ravetier <fr...@gmail.com> wrote:
> > > Hello,
> > >
> > > I'd like to run jmeter in command line using two jmeter-server on two
> > hosts
> > > with parameters to set-up the number of Thread, the number of loops...
> > > I put in my jmx script parameters like: ${__P(threadNb)} for the number
> > of
> > > Thread.
> > > It is working well when I run in command line my script without host.
> > But it
> > > does not use the parameters when I run it with two hosts.
> > >
> > > This is the command line I'm using in a shell script:
> > > ${JMETER_HOME}/bin/jmeter.sh -n  -t
> > /home/jmeter/jmxScripts/${JMX_NAME}.jmx
> > > -l /home/jmeter/jmeterResults/${JMX_NAME}_${BDATE}.jtl -R
> > > ${SERVER_1},${SERVER_2} -JthreadNb=${THREADNB}
> > > Where all the variables are correctly initialized at the beginning.
> > >
> > > Best regards,
> > > Fred
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
> >
> >
>

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


Re: Jmeter in command line and with remote jmeter-server does not use the parameters

Posted by Frédéric Ravetier <fr...@gmail.com>.
Ok thank you.

Is it on your road-map? If yes, when?

I found an trick before you provide a nice solution in jmeter. It would be
to use grep and sed in shell to replace directly in the JMX scripts the
values.

Regards,
Fred

2007/10/18, sebb <se...@gmail.com>:
>
> Yes, properties set via the command-line are not passed to server
> instances.
> Only the test plan is sent. Each server gets its properties from the
> local copy of jmeter.properties (and user and system.properties).
>
> You would need to pass the parameters to the servers when starting them.
>
> It would not make sense to pass all properties to the servers, but one
> could perhaps add a facility to export particular properties to the
> remote servers.
>
> Sorry, but at present I don't think that there is an easy way round this.
>
> On 18/10/2007, Frédéric Ravetier <fr...@gmail.com> wrote:
> > Hello,
> >
> > I'd like to run jmeter in command line using two jmeter-server on two
> hosts
> > with parameters to set-up the number of Thread, the number of loops...
> > I put in my jmx script parameters like: ${__P(threadNb)} for the number
> of
> > Thread.
> > It is working well when I run in command line my script without host.
> But it
> > does not use the parameters when I run it with two hosts.
> >
> > This is the command line I'm using in a shell script:
> > ${JMETER_HOME}/bin/jmeter.sh -n  -t
> /home/jmeter/jmxScripts/${JMX_NAME}.jmx
> > -l /home/jmeter/jmeterResults/${JMX_NAME}_${BDATE}.jtl -R
> > ${SERVER_1},${SERVER_2} -JthreadNb=${THREADNB}
> > Where all the variables are correctly initialized at the beginning.
> >
> > Best regards,
> > Fred
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>
>

Re: Jmeter in command line and with remote jmeter-server does not use the parameters

Posted by sebb <se...@gmail.com>.
Yes, properties set via the command-line are not passed to server instances.
Only the test plan is sent. Each server gets its properties from the
local copy of jmeter.properties (and user and system.properties).

You would need to pass the parameters to the servers when starting them.

It would not make sense to pass all properties to the servers, but one
could perhaps add a facility to export particular properties to the
remote servers.

Sorry, but at present I don't think that there is an easy way round this.

On 18/10/2007, Frédéric Ravetier <fr...@gmail.com> wrote:
> Hello,
>
> I'd like to run jmeter in command line using two jmeter-server on two hosts
> with parameters to set-up the number of Thread, the number of loops...
> I put in my jmx script parameters like: ${__P(threadNb)} for the number of
> Thread.
> It is working well when I run in command line my script without host. But it
> does not use the parameters when I run it with two hosts.
>
> This is the command line I'm using in a shell script:
> ${JMETER_HOME}/bin/jmeter.sh -n  -t /home/jmeter/jmxScripts/${JMX_NAME}.jmx
> -l /home/jmeter/jmeterResults/${JMX_NAME}_${BDATE}.jtl -R
> ${SERVER_1},${SERVER_2} -JthreadNb=${THREADNB}
> Where all the variables are correctly initialized at the beginning.
>
> Best regards,
> Fred
>

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