|Don't ask to ask, just ask|
Re: Optimize my code with Hashesby jbert (Priest)
|on Aug 27, 2008 at 10:46 UTC||Need Help??|
Your process takes 18 hours to run. You want it to be less.
You need to work out what the computer spends most of it's time doing in those 18 hours, so that you can try and reduce the most costly elements first (and get the biggest improvements).
Prime possibilities are:
So you need to run some monitoring tools ('top' is a good first start, but solaris has many others - check out vmstat and iostat too). These will tell you which of the above issues is the problem. (Well, if it's not CPU, swapping or other disk I/O, then it's probably network latency.
And after all that about measuring first?
My best guess is that you're doing 50K LDAP operations and network latency is killing you (i.e. your box isn't busy when you're doing this, but perhaps your LDAP server (or network) is).
Look for a bulk import/export tool for your LDAP server and use that instead.