Thursday, September 19, 2013

Connect Office 365 using Windows PowerShell from your local computer


Connect Office 365 using Windows PowerShell from your local computer
1.             Click Start, point to All ProgramsàAccessoriesàWindows PowerShellàWindows PowerShell.
             (assumption you already run the Set-ExecutionPolicy RemoteSigned command)
2.             Run the following command:
$LiveCred = Get-Credential
 
 
3.             In the Windows PowerShell Credential Request window, type the credentials of an account in your Office 365 organization. Then, click OK.
4.             Run the following command:
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell/ -Credential $LiveCred -Authentication Basic –AllowRedirection
 
                  

5.             Run the following command:
Import-PSSession $Session
 
 
 
 
 
6.             To disconnect Windows PowerShell from the Office 365 service
When you're finished disconnect Windows PowerShell by running the below command:
                Remove-PSSession $Session
 
 
Note:-If you close the Windows PowerShell window without disconnecting from the Office 365 session, your connection will remain open for 15 minutes. Your account can have only three concurrent connections to the Office 365 session at one time.

Wednesday, September 18, 2013

Check Office 365 Service Upgrade Status using PowerShell



Check Office 365 Service Upgrade Status using PowerShell

 Microsoft will send you are scheduled for upgrade by our automated scheduling system, Microsoft will provide a notification in your Office 365 admin portal and send the Office 365 global administrator a notification email. The first notification provides you approximately four weeks advanced notice before your upgrade will begin, so you have time to take pre-upgrade steps, if needed. As the upgrade date approaches, Microsoft will send an email with the exact upgrade date (Only one time you can postpone the upgrade process).

You can verify your organization version from the below PowerShell command

Steps

  1. Install  Windows Azure Active Directory Module for Windows PowerShell
  2. Launch Windows Azure Active Directory Module for Windows PowerShell
  3. Execute the following commands:

    Import-Module MSOnline
    Connect-MsolService
     
    (Get-MsolCompanyInformation).CompanyTags

Find the below screenshot for reference.

  4. Type your Global or Company Administrator credentials


 
 
5. Launch Windows PowerShell and connect to Office 365 and run the following commands to gather more information of the Wave 15 upgrade.
 
 Get-OrganizationConfig | Format-List AdminDisplayVersion
 
Get-OrganizationConfig | fl Name, Admindisplayversion, IsUpgradingOrganization
 
 
 
  6. Close the Office 365 session once you complete the activity.
 
 
 
Note:-If you close the Windows PowerShell window without disconnecting from the Office 365 session, your connection will remain open for 15 minutes. Your account can have only three concurrent connections to the Office 365 session at one time.
 
 
 
 
 
 

Thursday, July 4, 2013

Transport architecture from the perspective of the Management Shell


This section briefly reviews the core transport architecture from the perspective of the Management Shell

Get-Queue
Set-Queue
Suspend-Queue
Resume-Queue
Retry-Queue
Get-TransportPipeline
Get-TransportServer
Set-TransportServer
Get-TransportConfig
Set-TransportConfig
Get-NetworkConnectionInfo

To view the Hub Transport pipeline, use the Get-TransportPipeline cmdlet as shown in
The TransportPipeline cmdlet also exposes two transport agents installed by default on the Hub Trans port server: the Journaling Agent and the Transport Rule Agent














Messages can enter the transport pipeline through any of four methods:
* Through an SMTP Receive Connector communicating on port 25.
* Through message files dropped into the Pickup or Replay directories.
* Through placement of messages in the Submission queue by the store driver.
* Through message submission via an agent.

How to get delaynotifiaction and messageExpiration timeout










Using the Set-TransportServer cmdlet you can modify these settings.







Test-MapiConnectivity


This is just FYI on a cmdlet which I use daily – Test-MapiConnectivity!
Use Test-MapiConnectivity to troubleshoot connectivity problems. Remember as the name implies, it will only test MAPI connectivity.

Use this to test connectivity between your users and your servers.
Use it in the following format:

Mailboxes: Get-Mailbox <Mailbox Name> | Test-MapiConnectivity

Mailbox databases: Get-MailboxDatabase <Database Name> | Test-MapiConnectivity

Servers: Get-MailboxServer <Server Name> | Test-MapiConnectivity


Wednesday, July 3, 2013

A transient communication failure causes a Windows Server 2008 R2 failover cluster to stop working


You configure a failover cluster on some computers that are running Windows Server 2008 R2 and communication failure occurs in the cluster.

Below is the Link from Microsoft Link which resolve the Issue

http://support.microsoft.com/?kbid=2550886

How to remove a mail of mailbox database from server end


User R2 sends an email to a set of people with the subject line “I Love you. Now, Stallone being the IT manager wants you to delete that email from the server side.

All you gotta do is to run this cmdlet:

Get-Mailbox -Server EXCH | Export-Mailbox -TargetMailbox TempMailbox -TargetFolder ” To Delete” -SenderKeywords R2@E2Esolultions.com -SubjectKeywords ” I Love You ” –StartDate “07/03/13″ –EndDate “07/04/13″ -ExcludeFolders “\Calendar”, “\Contacts”, “\Deleted Items” –DeleteContent –MaxThreads 10

Terms
* Server name is EXCH
* Data will be extracted from user mailboxes to the folder “To Delete” in a mailbox called TempMailbox
* Start date and End Date switch let you choose a date range
* Set the ExcludeFolders switch if you don’t want to search specific folders
* DeleteContent is the switch which deletes the email
* MaxThreads is to specify 10 mailboxes will be processed at a time

Now remember that Export-Mailbox first copies content to the destination mailbox before performing the search and the target mailbox can get quite large and create heavy IO. This is different from creating a transport rule to filter incoming messages.

Users can still use the “Recall” option in outlook.




Exchange 2013 Server Role Architecture