remove exchange 2007, remove a public folder from an old server

Hi Experts,

We have 2 exchange 2007 servers running on a domain. The reason we have 2 exchanges is that 1st (old) exchange often stopped  so we added 2nd (new) exchange. it has been like that for a few years but now I am trying to get rid of the old exchange.

basically whenever I tried to delete public folder on OLD server, error says it contains folder replicas and remove the folders or move the replicas to another public folder database.


 I followed this (http://support.microsoft.com/kb/927464)  and when I run below.

Get-PublicFolderStatistics -server <Exchange 2007_Server_Name> | fl | out-file C:\PFstat.txt

I got an error.
-------------------------------------------------
The operation cannot be executed because there is no available public folder database on the server 'OLDSERVER'.
At line:1 char:1
+  <<<< Get-PublicFolderStatistics -server OLDSERVER | fl | out-file C:\PFsta
t.txt
    + CategoryInfo          : InvalidOperation: (:) [], InvalidOperationExcept
   ion
    + FullyQualifiedErrorId : 77D1CD8B
-------------------------------------------------

I thought there are no data so ignored above and run below.

-------------------------------------------------------------------------------------------
[PS] C:\Program Files\Microsoft\Exchange Server\Scripts>.\MoveAllReplicas.ps1 -Server OLDSERVER -NewServer NEWSERVER

Get-PublicFolder : There is no existing PublicFolder that matches the following
 Identity: '\'. Please make sure that you specified the correct PublicFolder Id
entity and that you have the necessary permissions to view PublicFolder.
At line:1 char:17
+ get-publicfolder <<<<  -identity \ -Recurse -resultsize unlimited
    + CategoryInfo          : NotSpecified: (0:Int32) [Get-PublicFolder], Mapi
   LogonFailedException
    + FullyQualifiedErrorId : 65D269D,Microsoft.Exchange.Management.MapiTasks.
   GetPublicFolder

Get-PublicFolder : There is no existing PublicFolder that matches the following
 Identity: '\NON_IPM_SUBTREE'. Please make sure that you specified the correct
PublicFolder Identity and that you have the necessary permissions to view Publi
cFolder.
At line:1 char:17
+ get-publicfolder <<<<  -identity \NON_IPM_SUBTREE -Recurse -resultsize unlimi
ted
    + CategoryInfo          : NotSpecified: (0:Int32) [Get-PublicFolder], Mapi
   LogonFailedException
    + FullyQualifiedErrorId : D6E49E3,Microsoft.Exchange.Management.MapiTasks.
   GetPublicFolder
----------------------------------------------------------------

how can I solve these errors?

Cheers,
yasuyasu
YasuYasuAsked:
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.

Will SzymkowskiSenior Solution ArchitectCommented:
If this is an old exchange server that is no longer being used I would just remove the public folder using ADSIEdit method.

Remove public folders ADSIEdit - http://msexchangetips.blogspot.ca/2006/07/exchange-cannot-delete-public-folder.html?m=1

Before using ADSIEdit make sure that you have replicas on other servers.

Will.
dsnegi_25decCommented:
I will suggest you don't go with adsiedit straight away until & unless you are not familiar.

what about when you run get-public folder .

Open the public folder go for each content properties check if the entries of old server remove from there hope that will help

http://support.microsoft.com/default.aspx?scid=kb;EN-US;927464

http://exchangepedia.com/2008/05/how-to-remove-the-public-folder-store.html
YasuYasuAuthor Commented:
Will,

I am not so familiar with ADSI so I will keep this to last resort.

dsnegi_25dec,

I have been trying to do the link you provided.
Get-publicfolder doesn't work but Get-publicfolderstatics will run properly. It looks like nothing contain  (can you confirm? ) but things I don't understand is that if there are no data and doesn't exist in the public folder database in an old server, why exchange doesn't allow me to delete the public folder database.
I understand that the old server doesn't have public folders but has PF database so I need to move replicas to different PF database but MoveAllReplica.ps1 doesn't work.  
Is there another solution for it?

Thanks

yasuyasu
-------------------------------------------------------------------------
[PS] C:\Windows\system32>Get-PublicFolder
Get-PublicFolder : There is no existing PublicFolder that matches the following
 Identity: '\'. Please make sure that you specified the correct PublicFolder Id
entity and that you have the necessary permissions to view PublicFolder.
At line:1 char:17
+ Get-PublicFolder <<<<
    + CategoryInfo          : NotSpecified: (0:Int32) [Get-PublicFolder], Mapi
   LogonFailedException
    + FullyQualifiedErrorId : B3EA0B16,Microsoft.Exchange.Management.MapiTasks
   .GetPublicFolder
--------------------------------------------------------------------------------------------------

[PS] C:\Windows\system32>Get-PublicFolderStatistics

Name                                     ItemCount               LastAccessTime
----                                     ---------               --------------
Add to blocklist                         0              5/04/2011 12:13:49 p.m.
Add to whitelist                         0              5/04/2011 12:13:49 p.m.
EX:/o=MPS/ou=Exchange Administrative Gro 0             20/04/2011 12:11:55 p.m.
up (FYDIBOHF23SPDLT)
EX:/o=MPS/ou=Exchange Administrative Gro 0              23/12/2010 1:00:01 a.m.
up (FYDIBOHF23SPDLT)
GFI AntiSpam Folders                     0              5/04/2011 12:13:49 p.m.
globalevents                             0              17/03/2013 2:23:51 a.m.
I want this Discussion list              0              5/04/2011 12:13:49 p.m.
internal                                 0              17/03/2013 2:23:51 a.m.
MPS Shared Contacts List                 122            5/04/2011 12:13:49 p.m.
OWAScratchPad{B798B466-87B4-46AD-8215-78 0              17/03/2013 2:23:51 a.m.
BB9E6DC051}
Processed                                0              5/04/2011 12:13:49 p.m.
Processed                                0              5/04/2011 12:13:49 p.m.
Processed                                0              5/04/2011 12:13:49 p.m.
Processed                                0              5/04/2011 12:13:49 p.m.
Processed                                0              5/04/2011 12:13:49 p.m.
StoreEvents{B798B466-87B4-46AD-8215-78BB 0              17/03/2013 2:23:51 a.m.
9E6DC051}
This is legitimate email                 0              5/04/2011 12:13:49 p.m.
This is spam email                       0              5/04/2011 12:13:49 p.m.
Default                                  0              19/11/2010 6:18:27 p.m.
EX:/o=MPS/ou=First Administrative Group  0             20/04/2011 12:05:59 p.m.
EX:/o=MPS/ou=First Administrative Group  0              19/11/2010 6:18:27 p.m.
exchangeV1                               401            19/11/2010 6:18:27 p.m.
globalevents                             0              19/11/2010 6:18:27 p.m.
internal                                 0              19/11/2010 6:18:27 p.m.
Leave Calendar                           23             5/04/2011 12:13:49 p.m.
microsoft                                0              19/11/2010 6:18:27 p.m.
OAB Version 2                            0              29/12/2010 2:11:40 a.m.
OAB Version 3a                           0              29/12/2010 2:11:41 a.m.
OAB Version 4                            0              29/12/2010 2:11:41 a.m.
OWAScratchPad{2CD38B4E-9C74-4C13-905F-14 0              19/11/2010 6:18:27 p.m.
80E4B52675}
schema-root                              0              19/11/2010 6:18:27 p.m.
Shared Address List                      72             20/04/2011 9:20:58 a.m.
Shared Calendar                          385            19/04/2011 4:58:59 p.m.
StoreEvents{2CD38B4E-9C74-4C13-905F-1480 0              19/11/2010 6:18:27 p.m.
E4B52675}
/o=MPS/cn=addrlists/cn=oabs/cn=Default O 0              29/12/2010 2:11:39 a.m.
ffline Address List
Internet Newsgroups                      0              5/04/2011 12:13:49 p.m.
-------------------------------------------------------------------------------------------------------------

[PS] C:\Windows\system32>Get-PublicFolderStatistics -server OLDSERVER | fl | out-file C:\PFstat.txt
The operation cannot be executed because there is no available public folder da
tabase on the server 'OLDSERVER'.
At line:1 char:1
+  <<<< Get-PublicFolderStatistics -server OLDSERVER | fl | out-file C:\PFsta
t.txt
    + CategoryInfo          : InvalidOperation: (:) [], InvalidOperationExcept
   ion
    + FullyQualifiedErrorId : 77D1CD8B

-----------------------------------------------------------------------------

[PS] C:\Windows\system32>Get-PublicFolderDatabase

Name                           Server               StorageGroup
----                           ------               ------------
Public Folder Database         OLDSERVER          Second Storage Group
Public Folders                       NEWSERVER          Second Storage Group
-----------------------------------------------------------------------------
Your Guide to Achieving IT Business Success

The IT Service Excellence Tool Kit has best practices to keep your clients happy and business booming. Inside, you’ll find everything you need to increase client satisfaction and retention, become more competitive, and increase your overall success.

WORKS2011Managed IT Services, Cyber Security, BackupCommented:
Have you tried the PF Admin Tool, click here.

Run it from a workstation and set the permission and you can then control public folders from Outlook.
YasuYasuAuthor Commented:
thanks everyone.

This case was handed over my colleage and I didn't need to do.

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
YasuYasuAuthor Commented:
This case was handed over my colleage and I didn't need to do.
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
Microsoft Legacy OS

From novice to tech pro — start learning today.