Hello,
I need a little help for a LDAP connection.I look desperate but not understand anything. i feel falling low connection so looking for way to optimize it. i used windows server 2000 please help me.
Thank you in advance.
Hello,
I need a little help for a LDAP connection.I look desperate but not understand anything. i feel falling low connection so looking for way to optimize it. i used windows server 2000 please help me.
Thank you in advance.
When setting up a Sametime server to authenticate against LDAP, the network connection and performance of the LDAP server contributes significantly to the load times and response times of the Sametime server.
Upon server startup, the Sametime server will open several connections to the LDAP server. At the same time, the people and groups are loaded from the Sametime server. When all of the Sametime services are running, the server is available for client logins and the directory cache continues until it has completed loading all of the users from the LDAP directory.
In order to prevent the LDAP server from being overwhelmed with the requests from the Sametime server, the server limits the number of requests in flight between the Sametime server and the LDAP server to a maximum of 10 (by default) and all further requests will be queued for processing. When the responses are received from the LDAP server, more requests will sent only if the queue size drops down to a size of 5 (by default)
In certain cases the queue size for sending LDAP requests will exceed a maximum number allowed by the server and the following error message
with this VbScript - Optimize LDAP connection you can try
the technique easier to identify a user in Active Directory and found its LDAP connection string and do this:
Set oADSystemInfo = CreateObject ( "ADSystemInfo")
Set oUser = GetObject ( "LDAP ://"& oADSystemInfo.UserName)
The concern of this is that the function "Set oADSystemInfo = CreateObject (" ADSystemInfo ")" may take some time to execution (about 30 seconds on a P4 2.8 and 1 min on a P3 833 c therefore has particularly slow link via the ad)
in fact instead of calling a Set oADSystemInfo = CreateObject ( "ADSystemInfo") to find the connection string of the current user, I find a function that has flat login allows the user to find the string LDAP thereof
Set oRootDSE = GetObject ( "LDAP: / / RootDSE")
Set oShell = WScript.CreateObject ( "WScript.Shell")
sUserName = oShell.Environment ( "PROCESS"). Item ( "username")
Set oUser = GetObject ( "LDAP: / /" & GetoUser (sUserName))
GetoUser Function (ByVal LogonAccount)
Const ADS_PROPERTY_CLEAR = 1
Const ADS_NAME_INITTYPE_GC = 3
Const ADS_NAME_TYPE_NT4 = 3
Const ADS_NAME_TYPE_1779 = 1
'Determine the DNS domain name from the object RootDSE.
strDNSDomain = oRootDSE.Get ( "defaultNamingContext")
Uses the object NameTranslate to find the netbios name of the domain name from the dns
Set objTrans = CreateObject ( "NameTranslate")
objTrans.Init ADS_NAME_INITTYPE_GC, ""
objTrans.Set ADS_NAME_TYPE_1779, strDNSDomain
strNetBIOSDomain = objTrans.Get (ADS_NAME_TYPE_NT4)
'Suprime the last backslash
strNetBIOSDomain = Left (strNetBIOSDomain, Len (strNetBIOSDomain) - 1)
strUserNTName = Trim (LogonAccount)
Uses the object NameTranslate to convert the NT name in LDAP string.
'On Error Resume Next
objTrans.Set ADS_NAME_TYPE_NT4, strNetBIOSDomain & "\" & strUserNTName
If Err.Number <> 0 Then
On Error GoTo 0
WScript.Echo "ERROR: Login not found in Active Directory:" & strUserNTName
Else
On Error GoTo 0
strUserDN = objTrans.Get (ADS_NAME_TYPE_1779)
'On Error Resume Next
GetoUser = strUserDN
End If
End Function
function required less than 1 second to run,
if this will seem unnecessary, I assure you that if you develop a apps that relies on Active Directory would be very happy to make the connection as short as possible since losing 30 to 45 seconds each time for nothing c It is quite heavy when it's for your user.
yes adding that a LDAP connection like this:
Set oUser = GetObject ( "LDAP: / / SERVERNAME /" & GetoUser (sUserName))
can cause the same delays that the other function
for landing, so the privilegier
Set oUser = GetObject ( "LDAP: / / DOMAINEDNS /" & GetoUser (sUserName))
.
Bookmarks