Exchange and CA Server Rejoin Domain

Our email server stopped responding, and upon reboot, would not connect to the domain.  The onsite guy used the reset account command in the active directory gui, rebooted, but still would not connect.

If I understand it correctly, now that he has reset the machine account, the only way to get back on the domain would be to unjoin\rejoin.  I tried netdom without success (I assume because he reset the account).  DNS and connectivity seem fine because I can ping back and forth via address and name.  When logged in local (it uses same administrator password as the domain) I can access the system shares of the PDC via unc.

Is there a procedure to backup the CA database, unjoin\rejoin, and restore the ca information without breaking Exchange?

It's a single Exchange 2003 Enterprise on a 2003 member server.  The PDC is also 2003 server.

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

In THEORY, assuming the Exchange Server is not the CA, you should be able to simply unjoin then rejoin the domain without breaking anything.  I think I would turn of the Exchange services first so they don't try to come up while the system is not part of the domain...just me being paranoid.  All of the Exchange specific info stored in AD will still be there, and since you are not messing with the name of the server or anything else all should be happy.  Nothing is changing on the system iteself either (other than the machine account for AD), so the certificate that was generated and is loaded on that machine should also (in THEORY) be fine.

If the machine is a CA, which I suspect based on your question, you can back up and restore the database.  This admin guide tells you how:  Again, in THEORY the issued certificates should continue to be viable once you restore them.

Fortunately, if the certificate gets messed up all you will need to do is generate a new certificate and plug into IIS for OWA and OMA to start working again.  If Exchange gets messed up, you obviously will be doing a restore -- but I can't see any reason it would have problems.

Note that I say in theory several times.  I have never performed this procedure, and hopefully never will (resetting the machine account, as you doubtless know, would be the last resort -- not the first).  The closest I've come is taking AD off an Exchange server that was inappropriately set up as an AD to begin with.


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
If you boot the machine up out of the domain with Exchange installed you will break Exchange. While you are moving things around you must disable all of the Exchange and IIS related services.

The same trick might work for the certificate authority, but I haven't done it.

Hi Mestha (or should I say Sembee ;-)

Do you agree that when he joins back to the domain all will be good with Exchange, or do you have a differing opinion?  I can't think of any reason Exchange won't come right back up after rejoining the domain....but as I said I've never actually done it.
Creating Active Directory Users from a Text File

If your organization has a need to mass-create AD user accounts, watch this video to see how its done without the need for scripting or other unnecessary complexities.

As long as the machine account is intact then after the machine has been joined to the domain then Exchange should start. I have dropped machine a off the domain then put it back on again in the past with Exchange involved.

ParanormasticCryptographic EngineerCommented:
Actually it sounds more like the CA is on the Exchange box.  Can't say that I would recommend that (as I recommend all CA servers be on a dedicated box or VM), but at least it isn't a DC.

I can't speak much to the Exchange part of dis/rejoining the domain, but for the CA:
1) Full backup including system state.
3) Open up the Certification Authority MMC (certsrv.msc).  Take note of what CAName is (the friendly name of the CA listed under Certification Authority (servername), including capitalization)
4) Expand CAName - right-click Revoked Certificates - All Tasks - Publish.
5) Open %systemroot%\system32\certsrv\certenroll directory and copy CRL file to the CDP locations.
6) Back in CA MMC/Revoked Certs - properties - Check what the CRL Publication Interval is - if it is not at least a month long then write down current setting, increase to be at least a month, and publish another CRL (see #3).  Do not copy this to the CDP locations, but rather to a location like your workstation that isn't getting messed with right now.  You could put it at the CDP locations if you rename it, but keep the regular CRL there for now.  This extended period CRL is your emergency contingency plan for your PKI.
7) Reset CRL timeframe back to original settings so you don't forget later.
8) Right-click CAName - All Tasks - Backup CA... - follow the wizard and select private key and certificate database, do not select incremental, follow rest of wizard.
9) Full backup including system state.
10) Uninstall certificate services from Add or Remove Programs/Windows Components.
11) I don't think you will need to worry about your Exchange server cert, but you can always back it up from Certificates MMC (certmgr.msc) - probably in the Computer Account / Personal Store unless it got installed somewhere else, maybe look under Trusted Roots.  Export including private key to a .pfx file.  Never hurts to have an extra thing backed up.
12) Do whatever you need to for Exchange, if necessary.  Sorry, I'm not your guy for this part.  
13) Disjoin from domain.
14) Reboot server.
15) Rejoin domain.
16) Do what you need to with Exchange first, its much more sensitive to being offline than a CA.
17) Reinstall Cert Services -  Make sure to enter the CAname exactly as the old one or the private key will not like you.
18) Open up CA MMC - right click CAName - All Tasks - Restore CA... and follow the wizard.
19) Reboot server to make sure everything comes up okay.
20) Open CA MMC - issue a new CRL - this will test access to the database and to the private key.  Copy to CDP locations.
21) Full backup including system state.
22) Sit down, relax, drink beer.
FredCredAuthor Commented:
It is now up and working.  Thanks all for your comments and help!!  I'll add details and award points tonight.  Thanks again!!!
ParanormasticCryptographic EngineerCommented:
Glad to hear everything turned out okay!  Is there anytime else you needed or just haven't had time to follow up to close this out yet?
FredCredAuthor Commented:
Thanks for the quick response to my question.  Your answer was accurate and complete.  Thanks all!
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Windows Server 2003

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.