Using DirectoryServices namespace on multiple domain controllers from ASP.NET clients

More of an architectural question really, but relates to using code in the DirectoryServices .NET namespace, when called via ASP.NET

I know that we can use server binding using code like this: 

DirectoryEntry GetDirectoryEntry(string str)

{

DirectoryEntry de = new DirectoryEntry();

de.AuthenticationType = (AuthenticationTypes.Secure | AuthenticationTypes.FastBind | AuthenticationTypes.ServerBind);

de.Path = str;

return de;

}

We have a web page that reads and saves data via DirectoryServices namespace and DirectoryEntry objects. 

If you do not use the "ServerBind" AuthenticationTypes option, and you extend to 2 domain controllers hosting an Active Directory (which we are planning to do), when the page re-posts it may fetch data from the other domain controller , which will not have received the data update yet by replication. The page will obviously then reload data as if the save had not persisted. However the above code with "Serverbind" will never spread the load across the 2 servers. 

How can you ensure that load balancing can occur if you are always binding to a particular server? It is just a question of partitioning your web servers to use a particular server hosting the ActiveDirectory via configuration?  

Has anybody else managed these "pseudo-transactions" using Active Directory whilst still achieving a level of load spread across the Active Directory domain controllers?

I believe an additional problem is that if we were to configure the Web Servers vertically above a particular DC hosting an AD (e.g. so WebServer1 uses ADServer1 and WebServer2 users ADServer2 and the ServerBind option), if we use SQL Server based session state you cannot guarentee that the post-backs (when you read back your saves you just made) will be from the same web server (I think?!)

Many thanks for any suggestions!

Gary

0
garych
7/12/2007 1:07:53 PM
asp.net.active-directory-ldap 2291 articles. 0 followers. Follow

1 Replies
411 Views

Similar Articles

[PageSpeed] 17

Do you really need load-balancing when doing updates? The majority of queries are read-only, I assume, using DirectorySearcher, and for that you can use the serverless bind. Of course, subsequent reads on the same session (after an update, before AD synch) will require an explicit server. But then at least you know that you've done an update and in that situation you could use the server bind. In all other cases go serverless.


If this post was useful to you, please mark it as answer. Thank you!
0
johram
11/30/2007 11:53:35 AM
Reply:

Similar Artilces:

Net:Net:Net::LDAP::FAQ
------_=_NextPart_001_01C6429F.D89AA417 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hello, Net::LDAP Net::LDAPS Is there a possible to LDAP bind with an encrypted (SHA, SSHA, CRYPT, ....) password? I don't like to write the secret password to the perl file. Best regards Barbara Wilbert ------_=_NextPart_001_01C6429F.D89AA417-- Wilbert Barbara (CI/OSI) * wrote: > Hello, > > Net::LDAP > Net::LDAPS > > Is there a possible to LDAP bind with an encrypted (SHA, SSHA, CRYPT, > ......

Sending SMS using vb.net or C#.net using vb.net or c#.net
Hi  My requirement is I hav one csv file with these fields id,mobilenum,messgae,status.intiallu staus is 0. once i read the all fileds and take that mobile number.using tat mobile number  i need to send sms .after sending sms i shuld change status as 1 How to send sms thru coding (please dont provide any links.if it is provide also please give working links becox i checked codeproject .i didnt get any nice link. and also provide the how to update the status field im csv file   Thank ssandhya   To send SMS, you need some third party SMS providers. if you consul...

How to use Net::LDAP::Control to track changes within active dire ctory?
------_=_NextPart_001_01C3520A.52C3CC60 Content-Type: text/plain Does anyone have any examples on how to use Net::LDAP::Control in order to track changes within active directory. I have seen examples on how to receive sorted and paged results using LDAP_CONTROL_PAGED and LDAP_CONTROL_SORTREQUEST , however, I do not know how to use a change tracking control such as PSearch (Persistent Search) that is provided by the active directory using Net::LDAP::Control. Any ideas? Thanks a lot, Kavita Chhabria Systems Developer Apogent Technologies (269) 544-7515 <mailto:kchha...

Net::LDAP::Control::Paged unexpected behavior using multiple paged searches against AD [SEC=UNCLASSIFIED]
------=_NextPart_000_003B_01CEEE7E.0BE685F0 Content-Type: multipart/related; boundary="----=_NextPart_001_003C_01CEEE7E.0BE685F0" ------=_NextPart_001_003C_01CEEE7E.0BE685F0 Content-Type: multipart/alternative; boundary="----=_NextPart_002_003D_01CEEE7E.0BE685F0" ------=_NextPart_002_003D_01CEEE7E.0BE685F0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit UNCLASSIFIED Hi . I am finding unexpected behaviour when using this control against our AD servers. I have tried this using 5.8 (perl-ldap 0.4...

Is there a way to authenticate Active Directory users from multiple Active Directory Domains
Is there a way to authenticate Active Directory users from multiple Active Directory Domains in ASP.NET Application using C# or VB.NET?Suppose I have a LoginId "user1" from one of the three Active Directory Domains how can I authenticate it?I have two Active Directory domains. I can authenticate from the Active Directory Domain where my current system Account is logged in. But I can not authenticate from other Active Directory Domains. Actually I have 2 Active Directory domains in my LAN.Kamran ShahidSr. Software Engineer(MCP,MCAD.net,MCSD.net,MCTS,MCPD.net[web])Netprosys Inc.ww...

Net::LDAP, Active Directory and Disabled Users
------_=_NextPart_001_01C386CB.502F3B30 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable I've been trying to write a simple perl script that will query the = active directory via LDAP and give me a list of email addresses for disabled = users (eg, addresses we don't want to accept email for anymore). I found a = website or two that suggested I use the following as my filter: (&(objectCategory=3Dperson)(userAccountControl:1.2.840.113556.1.4.803:=3D= 2)) I was beginning to think these websites were wrong as whene...

Paging using Net::LDAP::Control::VLV
--_000_697CCFB05A0E8C4A9028881D13CB615903EF51A1C6SOMMBwileycom_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hello all, I am working on a data grid that displays some information from our directo= ry server. I am using jQuery Javascript Framework on the front end, that m= akes an Ajax call to a Perl CGI script on the backend using the Net::LDAP m= odule. Doing some testing I am able to retrieve some data, but not able to= get past the first page of entries. Could some tell me how to page throug= h using the Net::LDAP::Contr...

Client validation using both Javascript and .NET controls
 Hello,I have implemented an online questionnaire. The questionnaire is composed by several textboxes to gather information such as name, organization,email, phone, etc. and a long series of radiobuttonlists and textboxes (text area). These last textboxes need to be filled out only if the user select a specific value in the radiobuttonlists.To perform client validation I used .NET controls to check the format of the first textboxes (name, organization,email, phone, etc. ) and the text areas to ensure that no invalid characters have been entered.To check the all the radiobuttonlist has b...

using .NET with active directory poll question
What better for connecting to AD user objects. DirectoryServices or IADs. I want to be able to manupulate user properties (espcially proxyAddresses property). My firm wants to give users the right to change the default email alias. Therefore I have to either update/write/delete that fiend and insert in what the users chooses as they want to be their default. If anyone has any experiences with this please help me out and contact me so I can ask you a few questions on how you implemented this on design standpoint. Thanks. ...

4 issues with Net::LDAP and Active Directory
------_=_NextPart_001_01C74A47.D441C220 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable I have 4 issues which I do not understand and I have searched the Net::LDAP documentation up and down and cannot figure it out. =20 1. pwdLastSet is only available for the DN of the user who is logged in. (That seems a little odd, why is that?) and yes I logged in as another user using LDAP and it was available for them and not me. =20 2. pwdLastSet is some Active Directory timestamp (Why oh why cant Microsoft just use utc like ev...

Issue using control created in VS.net 2003 in VS.net 2002
I have a friend that has an issue using my asp.net C# custom control in Visual Studio.net 2002 that I have compiled under Visual Studio.net 2003. I never did test it with that version, but I was under the impression that it should still work as long as you don't use any features specific to the 1.1 framework (which I really don't think I did). My guess now is that this is correct, but only when using 2002 controls in 2003. I have searched the web, these forums, and MSDN for the last 30 minutes with no real answer. The guy that runs MetaBuilders (http://www.metabuilders.com/Faq.aspx) tell...

make Net::LDAP::LDIF more similar to Net::LDAP
Hi Graham, hi Chris, hi list, I would like to rework Net::LDAP::LDIF a bit so that its API resembles that of Net::LDAP a bit more while still keeping the traditional API. The reason for this is that in application I often need to distinguish between Net::LDAP and Net::LDAP::LDIF because some methods are only implemented on one side. I\'d like to start with a code() method that tries to mimic the Net::LDAP one and I\'d like to extend the Net::LDAP::Entry->update() method so that it takes a Net::LDAP::LDIF object as an argument. The latter one requires a...

use VB.NET and C#.NET code in the same C#.NET project
All-- Here is a sample that is "off the beaten path", (at least for me). Is it possible, in an ASP.NET application, using the code-behind page building technique, to have both pages written in VB.NET and pages written C#.NET?At http://www.WebLogicArts.com/DemoList.aspx there is a sample that shows that, (contrary to popular belief), it IS possible to mix ASP.NET pages built with C#.NET with ASP.NET pages built with VB.NET in the same VS.NET 2003 project. Note that this is just a "fun" sample to see if it can be done and I do not recommend this practice as a "standard" way of develo...

Net::LDAPS and Net::SSLeay
------_=_NextPart_001_01C3EF1A.51A96530 Content-Type: text/plain Hello all: I am trying to use Net::LDAPS within a perl program in order to establish a secure socket connection with my ldap server. My program works fine if i use the bind function from Net::LDAP module. However, when I changed my source code to use the bind function from Net::LDAPS, my program failed because it complained about the need for IO::Socket::SSL module. Then, when i started to run make for IO::Socket::SSL, it complained about the need for Net::SSLeay. The compilation for Net::SSLeay versio...

RE: Net::LDAP, Active Directory and Disabled Users
Version of Perl:=20 5.8.0 (as supplied with RedHat9) Version of Net::LDAP: [jsteenha@jake utilities]$ perl -mNet::LDAP -e 'print = "$Net::LDAP::VERSION\n"' 0.29 Relevant part of Perl code: #!/usr/bin/perl use Net::LDAP; use Net::LDAP::Filter; $filter =3D = '(&(objectCategory=3Dperson)(userAccountControl:1.2.840.113556.1.4.803:=3D= 2))'; #$filter =3D '(objectCategory=3Dperson)'; $f =3D new Net::LDAP::Filter; $f->parse($filter); $f->print(); #exit; my $ldap =3D Net::LDAP->new('acutex-dc01'); my $mesg =3D $...

Web resources about - Using DirectoryServices namespace on multiple domain controllers from ASP.NET clients - asp.net.active-directory-ldap

Tag Synonyms - Stack Overflow
Q&A for professional and enthusiast programmers

protocols(5) OS X Manual Page
HTML versions of the OS X, OS X Server, Xcode Tools, and CHUD man pages.

Source Browser
Source Browser Name Size Parent Directory - Apple16X50Serial/ - Apple3Com3C90x/ - AppleAC97Audio/ - AppleADBButtons/ - AppleADBDisplay/ - AppleADBKeyboard/ ...

CORE Security
Skip to main content Search form Search this site Solutions By Need Intelligent Vulnerability Management Security Risk Management Enterprise ...

How To Reset Your Password Without A System Disk [OS X Tips]
http://youtu.be/TjxAgiNqkDM Have you lost your Mac password? Are you unable to get into your computer because of it? Apple lets you restore your ...

.NET Framework 3.5
Daniel Moth technical blog on Microsoft technologies such as Visual Studio, .NET, parallel computing, debugging and others.

Div Rotation Using HTML5 and CSS3
In this article I describe rotation of a Div or Element using HTML 5 and CSS3.

Timebar_2013-04-02-202815_gobsmacker.crash
- Gist is a simple way to share snippets of text and code with others.

PowerShell or Die – JefTek.com
Such a strong title, but I think it sums up my view on the question of “Should I bother with PowerShell?” quite nicely. I know I’m late to the ...

Apple Magic Triangle Deployment Results
For all intensive purposes, the migration went fairly smoothly. The client was quite happy with the result, although the users of the network ...

Resources last updated: 11/25/2015 11:31:21 AM