Tag Archives: office 365

Using Office 365 as your SMTP server on a 3CX PBX

If you want to use Office 365 as your SMTP email server for a 3CX PBX you are best setting up a Connector on the Exchange Online account. I am assuming that your PBX is on the end of a static IP address.

First configure your 3CX server. Under Email and settings set the mail server to match your MX record. This usual follows the formatĀ domain.mail.protection.outlook.com where domain is your email domain with hyphens instead of dots.

Set a reply to address on the same domain. I always use pbx @ sfax.co.uk, it doesn’t go anywhere, I don’t expect anyone to reply to it.

You don’t need a username or password or to enable SSL/TLS as we will set up a connector to receive the email.

Next log on to your Office 365 portal as an administrator, and open your Exchange Admin Center. From there pick connectors under mail flow.

Create a new Connector.

Pick from: Your organization’s email server

To: Office 365

Give it an appropriate name:

Next select By Verifying that the IP address of the sending server matches one of these addresses that belong to your organization

Click the plus to add an IP address and enter your PBX’s internet IP address

Save the connector and you are good to go.



Extracting useful user information from Exchange 2010 with Powershell

Finishing a migration to Office 365 and want to send the client a list of remaining user mailboxes that need moving (or deleting!).

get-mailbox and get-mailboxstatistics both have their uses, but I really needed to use something that combined them both.

I found the solution atĀ https://www.experts-exchange.com/questions/28399371/Combining-Get-Mail-Get-Mailboxstatistics-To-Pull-UsageLocation-LastLogonTime.html

And adapted it to my own means:

Get-Mailbox -ResultSize Unlimited | sort-object | Select-Object Name, primarysmtpaddress, @{n="Mailbox Size";e = {$MBXstat = Get-MailboxStatistics $_.name; $MBXstat.TotalItemSize}}, @{n="LastLogonTime";e = {$MBXstat = Get-MailboxStatistics $_.name; $MBXstat.LastLogonTime}} | Export-Csv C:\temp\LastLogonTime.csv

This outputs the User name, Primary SMTP Address from get-mailbox and Mailbox size (formatted to MB) and last logon time from get-mailboxstatistics.

Reconnecting an Office 365 mailbox with an on-premise user

Hybrid Office 365 setup. User account is created on-premise, AD is synced, and then the user is licenced as an Office 365 user. Exchange won’t create the Remote User forwarder, so the user will only receive email from Office 365 (and external if the MX record has been switched to Office 365).

You can join the account up with the command:

Enable-RemoteMailbox Username -RemoteRoutingAddress “username@tennent.mail.onmicrosoft.com”

That will create the Remote Mailbox on Exchange with the forwarder email address.