Saturday, February 28, 2009

Grant Full Permissions to All mailboxes in Exchange 2007

To grant full permissions to all user mailboxes in exchange, issue the following command from the exchange command shell

Get-MailboxDatabase -Server Add-ADPermission -User -ExtendedRights Receive-As

Once complete, restart the Exchange Information Store service for the settings to take effect.

Remove Disconnected Mailboxes In Exchange

Removing Disconnected mailboxes in exchange is now a multi-step process.  The first part is to get a listing of the disconnected mailboxes so that the GUID of it can be obtained.  Then, using this GUID and the name of the mailbox database, the second command is then executed to actually remove the mailbox

To list all disconnected mailboxes, issue the following  command into the command shell:

Get-MailboxStatistics | where-object { $_.DisconnectDate -ne $null } | Select DisplayName,MailboxGuid

Then to actually remove the mailb0x issue:

Remove-Mailbox -Database -StoreMailboxIdentity -confirm:$false

If you wish to remove all disconnected mailboxes at the same time, issue the following from the command shell to get a list of all users:

$users = Get-MailboxStatistics | where-object { $_.DisconnectDate -ne $null } | Select DisplayName,MailboxGuid

Next issue the following to remove all:

$users | ForEach { Remove-Mailbox -Database "Mailbox Database" -StoreMailboxIdentity $_.MailboxGuid -confirm:$false }

Friday, February 27, 2009

Changing the SQL Server that Citrix IMA References

When moving a SQL based citrix server database, you must alter the MF20.dsn data source to point to the new server. Once verified, issue the following command from the DOS prompt to update the configuration

dsmaint config [/user:username] [/pwd:password] [/dsn:path to filename]

Enterprise Root CA Certificate Generation Issue

If you need to generate a certificate on an enterprise root CA, but get the error message that the CSR does not contain a template, this can be bypassed from the command line using the following syntax:

certreq -submit -attrib "CertificateTemplate: WebServer" WebServerCertReq.txt

This will force the server to use the certificate template for a server.