Export Exchange 2007/2010 tracking log

To export Exchange 2007/2010 tracking log to a Excel, just run this command.
get-messagetrackinglog -Start “31-08-2010 00:00:00” -End “01-09-2010 12:16:00″ -resultsize Unlimited | select-object Timestamp,ClientIp,ClientHostname,ServerIp,ServerHostname,SourceContext,ConnectorId,Source,EventId,InternalMessageId,MessageId,TotalBytes,RecipientCount,MessageSubject,Sender,ReturnPath,@{Name=”Recipients”;Expression={$_.recipients}},MessageInfo | Export-Csv
It will export all mails from 31/8-2010 to 1/9-2010, with the selected fiels.

Ubuntu and (dot).local addresses – Avahi

I have a Ubuntu server where there was a problem with .local address, i could’t look up the zone from the server.
After a little search i found that Avahi (Zeroconf) was the problem.

The default setup of Avahi, is to look for the zone in mDNS, if that failed the resolv failed.

So to fix this, edit /etc/nsswitch.conf

Change this line
hosts:          files mdns4_minimal [NOTFOUND=return] dns mdns4
To:
hosts:          files dns mdns4_minimal mdns4

Nyt navn

Som nogle af jer måske viste hed jeg Kenneth Dalbjerg Jensen. Jeg har nu fået slette Jensen, og hedder nu blot Kenneth Dalbjerg i følge folkeregisteret.

Network Policy Server problems

I have a network policy server that din’t work. There was nothing standing in the Event viewer. I have install Wireshack and could se the packets was incoming and a reject was coming back to the Radius Client.

I was search around to see howthis error was occurring, but i could fine nothing.

I then found the program IAS Log Viewer, and its told me that is what the Connection Request Policy that was the error, as i Delete that and created a new standard one everything was working fine.

The program can be downloaded here: http://www.deepsoftware.com/iasviewer/index.html

Exchange 2007 – Ahsay restore to a recovery group

Ahsay have no support for native restore to Exchange recovery group, but here is a workaround of that problems.

First create a recovery storagegroup
new-storagegroup -LogFolderPath F:\Backup\Restore\Logs -Name ExchangeRestore -SystemFolderPath F:\Backup\Restore\Data -Recovery

Then create a empty database
new-mailboxdatabase -mailboxdatabasetorecover “Mailbox Database” -storagegroup ExchangeRestore -edbfilepath “F:\Backup\Restore\Data\Mailbox Database.edb”

Restore the Exchange 2007 database to a alternative location in ahsay. With both logfiles and the database files, restore it to “F:\Backup\Restore\Data\Mailbox Database.edb” or where you location is.

Then run repair of the restored database.
Eseutil /p “F:\Backup\Restore\Data\Mailbox Database.edb”

Then mount the database
Mount-Database -Identity ‘ExchangeRestore\Mailbox Database’

Example restore a mailbox to a Restore mailbox in the real database.
Restore-Mailbox -RSGMailbox ‘mailbox_to_restore’ -RSGDatabase ‘ExchangeRestore\Mailbox Database’ -id ‘Restore’ -TargetFolder ‘Restore’

Dismount the database
Dismount-database -Identity ‘ExchangeRestore\Mailbox Database’

Remove the database
Remove-MailboxDatabase -Identity ‘ExchangeRestore\Mailbox Database’

Remove the recovery group
Remove-StorageGroup -Identity ‘ExchangeRestore’