You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@directory.apache.org by Kevin Hamilton <kh...@umem.org> on 2012/06/08 19:19:14 UTC

Performance problems on live server vs local machine.

Hello,

I have noticed performance differences in working on my local environment
(OS X) and on my live server (Linux).

I use ApacheDS to authenticate on my website and to check for second factor
authentication afterwards. In my local environment, everything is fast and
quick (extremely efficient). On the live server (which is a much beefier
machine than my local machine), it is sluggish and takes a long time for a
page to load when there are calls to the ApacheDS involved.

Does this sound familiar to anyone and does anyone have any ideas as to
what might be the problem?

Thanks,
Kevin

Re: Performance problems on live server vs local machine.

Posted by Pierre-Arnaud Marcelot <pa...@marcelot.net>.
Hi Kevin,

On 13 juin 2012, at 13:57, Kevin Hamilton wrote:

> And how specifically do I add new indexes?
> 
> I have created a few indexes on a few attributes that I created. One is
> below, but I am not sure if it is correct:
> 
> version: 1
> 
> dn: ads-indexattributeid=cookie-token,ou=indexes,ads-partitionId=system,ou=p
> artitions,ads-directoryServiceId=default,ou=config
> objectclass: ads-index
> objectclass: ads-base
> objectclass: ads-jdbmIndex
> objectclass: top
> ads-indexattributeid: cookie-token
> ads-enabled: TRUE
> ads-indexcachesize: 100
> 
> 
> I am trying to index an attribute called cookie-token, but I am not sure if
> this is the correct method to get that done.

That's the correct way to add an index for a particular attribute.

Make sure you're applying the index to the partition where you store this kind of data though.
Here, it's the "system" partition.

> This cookie-token is a MUST attribute on my personal cookie-object class.
> 
> Should I have added another objectclass line above like this:
> objectclass: cookie-object

Nope. The index is of type "ads-jdbmIndex" which has this object class hierarchy:
"ads-jdbmIndex" --> "ads-index" --> "ads-base" --> "top".

No need to add any extra object class attribute value.

Regards,
Pierre-Arnaud

> Thanks,
> Kevin
> 
> On Fri, Jun 8, 2012 at 6:05 PM, Emmanuel Lécharny <el...@gmail.com>wrote:
> 
>> Le 6/8/12 9:16 PM, Kiran Ayyagari a écrit :
>> 
>> in 2.0 you need not run any tool, just restart the server after adding
>>> a new index(es)
>>> 
>> 
>> I'm quite sure that this is not an index issue here. I would rather
>> investigate the network, to see if there is no half-duplex configured
>> rooter in the middle.
>> 
>> Unless the server is running on a Pentium III ...
>> 
>> 
>> --
>> Regards,
>> Cordialement,
>> Emmanuel Lécharny
>> www.iktek.com
>> 


Re: Performance problems on live server vs local machine.

Posted by Kevin Hamilton <kh...@umem.org>.
And how specifically do I add new indexes?

I have created a few indexes on a few attributes that I created. One is
below, but I am not sure if it is correct:

version: 1

dn: ads-indexattributeid=cookie-token,ou=indexes,ads-partitionId=system,ou=p
 artitions,ads-directoryServiceId=default,ou=config
objectclass: ads-index
objectclass: ads-base
objectclass: ads-jdbmIndex
objectclass: top
ads-indexattributeid: cookie-token
ads-enabled: TRUE
ads-indexcachesize: 100


I am trying to index an attribute called cookie-token, but I am not sure if
this is the correct method to get that done.

This cookie-token is a MUST attribute on my personal cookie-object class.

Should I have added another objectclass line above like this:
objectclass: cookie-object

Thanks,
Kevin

On Fri, Jun 8, 2012 at 6:05 PM, Emmanuel Lécharny <el...@gmail.com>wrote:

> Le 6/8/12 9:16 PM, Kiran Ayyagari a écrit :
>
>  in 2.0 you need not run any tool, just restart the server after adding
>> a new index(es)
>>
>
> I'm quite sure that this is not an index issue here. I would rather
> investigate the network, to see if there is no half-duplex configured
> rooter in the middle.
>
> Unless the server is running on a Pentium III ...
>
>
> --
> Regards,
> Cordialement,
> Emmanuel Lécharny
> www.iktek.com
>

Re: Performance problems on live server vs local machine.

Posted by Emmanuel Lécharny <el...@gmail.com>.
Le 6/8/12 9:16 PM, Kiran Ayyagari a écrit :
> in 2.0 you need not run any tool, just restart the server after adding
> a new index(es)

I'm quite sure that this is not an index issue here. I would rather 
investigate the network, to see if there is no half-duplex configured 
rooter in the middle.

Unless the server is running on a Pentium III ...

-- 
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com


Re: Performance problems on live server vs local machine.

Posted by Kiran Ayyagari <ka...@apache.org>.
in 2.0 you need not run any tool, just restart the server after adding
a new index(es)

On Sat, Jun 9, 2012 at 12:38 AM, Kevin Hamilton <kh...@umem.org> wrote:
> If I were to try to add indexes to some of these, how would I go about that?
>
> I found the page
> http://directory.apache.org/apacheds/1.5/91-performance-tuning.html and saw
> the part about Indices must be configured before loading data into the
> server. Indices configured after loading entries into the server will NOT
> work properly unless they are built using the index builder command
> supplied with the ApacheDS tools command line program. More information on
> this in the Building Indices section below.
>
> I am not sure how to index attributes in ApacheDS v 2.0.0. I found the
> ou=indexes in the list and I added my desired indexes. I am curious as to
> whether my data will work more efficiently or if I need to somehow reload
> all of my current entries.
>
> Please get back to me as soon as possible.
>
> Thanks so much,
> Kevin
>
>
> On Fri, Jun 8, 2012 at 2:35 PM, Kevin Hamilton <kh...@umem.org> wrote:
>
>> I'm not entirely sure what you mean by sending direct requests.
>>
>> I have tried running queries on both servers in Apache Directory Studio
>> and they are similar amounts of time for each. I thought it might have
>> something to do with indexes that I didn't have for all of my attributes,
>> but the indexes don't exist on my local machine either so they should be
>> the same issues.
>>
>> Still scratching my head on this one.
>>
>> Thanks,
>> Kevin
>>
>>
>> On Fri, Jun 8, 2012 at 1:42 PM, Emmanuel Lécharny <el...@gmail.com>wrote:
>>
>>> Le 6/8/12 7:19 PM, Kevin Hamilton a écrit :
>>>
>>>  Hello,
>>>>
>>>> I have noticed performance differences in working on my local environment
>>>> (OS X) and on my live server (Linux).
>>>>
>>>> I use ApacheDS to authenticate on my website and to check for second
>>>> factor
>>>> authentication afterwards. In my local environment, everything is fast
>>>> and
>>>> quick (extremely efficient). On the live server (which is a much beefier
>>>> machine than my local machine), it is sluggish and takes a long time for
>>>> a
>>>> page to load when there are calls to the ApacheDS involved.
>>>>
>>>> Does this sound familiar to anyone and does anyone have any ideas as to
>>>> what might be the problem?
>>>>
>>>
>>> There is no reason for ApacheDS to be slower on Linux than on a mac.
>>>  Have you checked if the server responds fast when you send direct requests
>>> to it ?
>>>
>>>
>>> --
>>> Regards,
>>> Cordialement,
>>> Emmanuel Lécharny
>>> www.iktek.com
>>>
>>>
>>
>>
>> --
>> Kevin Hamilton (khamilton@umem.org)
>> Application Developer
>> Department of Emergency Medicine
>> University of Maryland School of Medicine
>>
>>
>
>
> --
> Kevin Hamilton (khamilton@umem.org)
> Application Developer
> Department of Emergency Medicine
> University of Maryland School of Medicine



-- 
Kiran Ayyagari

Re: Performance problems on live server vs local machine.

Posted by Kevin Hamilton <kh...@umem.org>.
If I were to try to add indexes to some of these, how would I go about that?

I found the page
http://directory.apache.org/apacheds/1.5/91-performance-tuning.html and saw
the part about Indices must be configured before loading data into the
server. Indices configured after loading entries into the server will NOT
work properly unless they are built using the index builder command
supplied with the ApacheDS tools command line program. More information on
this in the Building Indices section below.

I am not sure how to index attributes in ApacheDS v 2.0.0. I found the
ou=indexes in the list and I added my desired indexes. I am curious as to
whether my data will work more efficiently or if I need to somehow reload
all of my current entries.

Please get back to me as soon as possible.

Thanks so much,
Kevin


On Fri, Jun 8, 2012 at 2:35 PM, Kevin Hamilton <kh...@umem.org> wrote:

> I'm not entirely sure what you mean by sending direct requests.
>
> I have tried running queries on both servers in Apache Directory Studio
> and they are similar amounts of time for each. I thought it might have
> something to do with indexes that I didn't have for all of my attributes,
> but the indexes don't exist on my local machine either so they should be
> the same issues.
>
> Still scratching my head on this one.
>
> Thanks,
> Kevin
>
>
> On Fri, Jun 8, 2012 at 1:42 PM, Emmanuel Lécharny <el...@gmail.com>wrote:
>
>> Le 6/8/12 7:19 PM, Kevin Hamilton a écrit :
>>
>>  Hello,
>>>
>>> I have noticed performance differences in working on my local environment
>>> (OS X) and on my live server (Linux).
>>>
>>> I use ApacheDS to authenticate on my website and to check for second
>>> factor
>>> authentication afterwards. In my local environment, everything is fast
>>> and
>>> quick (extremely efficient). On the live server (which is a much beefier
>>> machine than my local machine), it is sluggish and takes a long time for
>>> a
>>> page to load when there are calls to the ApacheDS involved.
>>>
>>> Does this sound familiar to anyone and does anyone have any ideas as to
>>> what might be the problem?
>>>
>>
>> There is no reason for ApacheDS to be slower on Linux than on a mac.
>>  Have you checked if the server responds fast when you send direct requests
>> to it ?
>>
>>
>> --
>> Regards,
>> Cordialement,
>> Emmanuel Lécharny
>> www.iktek.com
>>
>>
>
>
> --
> Kevin Hamilton (khamilton@umem.org)
> Application Developer
> Department of Emergency Medicine
> University of Maryland School of Medicine
>
>


-- 
Kevin Hamilton (khamilton@umem.org)
Application Developer
Department of Emergency Medicine
University of Maryland School of Medicine

Re: Performance problems on live server vs local machine.

Posted by Kevin Hamilton <kh...@umem.org>.
I'm not entirely sure what you mean by sending direct requests.

I have tried running queries on both servers in Apache Directory Studio and
they are similar amounts of time for each. I thought it might have
something to do with indexes that I didn't have for all of my attributes,
but the indexes don't exist on my local machine either so they should be
the same issues.

Still scratching my head on this one.

Thanks,
Kevin

On Fri, Jun 8, 2012 at 1:42 PM, Emmanuel Lécharny <el...@gmail.com>wrote:

> Le 6/8/12 7:19 PM, Kevin Hamilton a écrit :
>
>  Hello,
>>
>> I have noticed performance differences in working on my local environment
>> (OS X) and on my live server (Linux).
>>
>> I use ApacheDS to authenticate on my website and to check for second
>> factor
>> authentication afterwards. In my local environment, everything is fast and
>> quick (extremely efficient). On the live server (which is a much beefier
>> machine than my local machine), it is sluggish and takes a long time for a
>> page to load when there are calls to the ApacheDS involved.
>>
>> Does this sound familiar to anyone and does anyone have any ideas as to
>> what might be the problem?
>>
>
> There is no reason for ApacheDS to be slower on Linux than on a mac.  Have
> you checked if the server responds fast when you send direct requests to it
> ?
>
>
> --
> Regards,
> Cordialement,
> Emmanuel Lécharny
> www.iktek.com
>
>


-- 
Kevin Hamilton (khamilton@umem.org)
Application Developer
Department of Emergency Medicine
University of Maryland School of Medicine

Re: Performance problems on live server vs local machine.

Posted by Emmanuel Lécharny <el...@gmail.com>.
Le 6/8/12 7:19 PM, Kevin Hamilton a écrit :
> Hello,
>
> I have noticed performance differences in working on my local environment
> (OS X) and on my live server (Linux).
>
> I use ApacheDS to authenticate on my website and to check for second factor
> authentication afterwards. In my local environment, everything is fast and
> quick (extremely efficient). On the live server (which is a much beefier
> machine than my local machine), it is sluggish and takes a long time for a
> page to load when there are calls to the ApacheDS involved.
>
> Does this sound familiar to anyone and does anyone have any ideas as to
> what might be the problem?

There is no reason for ApacheDS to be slower on Linux than on a mac.  
Have you checked if the server responds fast when you send direct 
requests to it ?


-- 
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com