Connecting to Lync Online via Powershell

In previous posts I’ve details how to connect to Office 365 administration using PowerShell:

https://blog.ciaops.com/2012/09/configuring-power-shell-access-in.html

I’ve also detailed how to connect to SharePoint Online using PowerShell:

https://blog.ciaops.com/2013/05/connecting-powershell-to-sharepoint.html

So now I’ll show you how to connect to Lync Online with PowerShell.

The first thing you should do is follow the initial blog post:

https://blog.ciaops.com/2012/09/configuring-power-shell-access-in.html

to ensure the Microsoft Online Assistant and the Microsoft Online Services Module for Windows PowerShell are installed.

image

As with SharePoint Online you are going to need to have PowerShell V3 installed before using Lync Online with PowerShell. If you are doing this on a Windows 8 desktop, then PowerShell V3 is already installed. If not, then you are going to need to download and install Windows Management Framework 3.0 which includes PowerShell 3.0.

Next you’ll to install the Lync Online Management Shell. This is located here:

http://www.microsoft.com/en-us/download/details.aspx?id=39366

image

Accept the license terms and conditions and press the Install button to commence.

image

Accept the UAC and select Yes to continue.

image

The installation will check to see what software is installed on your system.

image

image

image

All going well the installation should complete successfully. Select the Close button to complete the process.

image

Once you have all that installed run the Microsoft Online Services Module for Windows PowerShell as an administrator.

clip_image002

Accept the UAC by pressing Yes.

The next step is to load in the Lync Online cmdlets for use in this session. These cmdlets are called:

lynconlineconnector

So at the PowerShell prompt type:

clip_image004

import-module lynconlineconnector

If you haven’t already logged into your Office 365 tenant as an administrator using PowerShell command you will need to do as detailed in previous posts using the command:

clip_image006

$cred=get-credential

Next, use the following commands to connect to the Lync Online Service.

clip_image008

$session = New-CsOnlineSession -Credential $cred

clip_image010

Import-PSSession $session

You should notice a banner appear across the top of the window as the modules are loaded as shown above.

clip_image012

If everything is correct, PowerShell will simply be returned to a prompt. Now you can execute commands against Lync Online. For example the following will display your Lync tenant information:

clip_image014

get-cstenant

Now you can start exploring all the cmdlets that are available for Lync Online which you can find at:

http://technet.microsoft.com/en-us/library/jj994021.aspx

Disabling Exchange protocols in Office 365

The general default with Exchange Online is to have things enabled. Thus, things like POP3 are enable on all mailboxes by default. This makes it easier for people to connect to the service using a variety of methods. Of course there are reasons why you may want some of these disabled and that is easy to do via a number of different methods in Office 365.

If you want to use the web portal login as an administrator to Office 365.

image

When you are greeted by the Office 365 admin center select Admin from the menu bar at the top right.

image

 

 

 

 

 

From the menu that appears select Exchange.

image

Select the mailbox you wish to configure and many of the settings will appear on the right. You can modify these from here but to get access to all the options now select the Edit icon (which is the picture of the pen just above the column headings).

image

If you now select the mailbox features option from the menu on the left hand side you see a list of links on the right than allows to control the different protocols and features of the mailbox.

image

For example if you select the Disable link under the POP3 heading you will be prompted to whether you wish to disable POP3 for this mailbox as shown above.

image

By holding down the control key and selecting multiple mailboxes you can make bulk edit changes by selecting from the options on the right. In the case above, I have selected all 7 mailboxes and select the link to enable POP3. All I need do is now confirm this to update all these accounts together.

Using the web portal allows you to make changes to accounts easily, however if you need to complete this process repeatedly on a large number of mailboxes then using PowerShell is a better option.

The first step is to connect to Office 365 using PowerShell which I have covered in a previous blog post here:

https://blog.ciaops.com/2012/09/configuring-power-shell-access-in.html

You can then run a variety of PowerShell commands to disable the different features of different mailbox. The details of those commands are found here:

http://support.microsoft.com/kb/2573225/en-us

For example, to disable POP3 for the same user above the command would be:

Set-CasMailbox barry.jones@kumoalliance.net.au -PopEnabled $False

Again, that is great when you only need to do a few mailboxes, but what happens when you need to do lots? Here’s a script that should do the job for all your users (provided you don’t have thousands):

Get-CASMailbox | Set-CASMailbox -PopEnabled $False

I will also point you to the following blog article:

http://blogs.technet.com/b/zarkatech/archive/2011/08/09/automatically-disable-pop3-amp-imap-in-office-365.aspx

which shows you how to achieve this using Office 365 security groups to more easily determine exactly who and who doesn’t have access. This is a great option if want to restrict only a subset of your users from having access to features like POP3 in Office 365.

The important takeaway here is that most of Exchange features are enabled in Office by default. You can easily change them via the web portal but an even better method would be to user PowerShell, where you can even integrate security groups to provide even more granular control.

CIAOPS Virtual Tech Meeting–November


Registrations are now open for the CIAOPS Virtual Tech Meeting on Wednesday the 6th of November. You can register at:
https://ciaops1113.eventbrite.com.au/
This meeting will features a presentation by on the public website capabilities in Office 365 by myself. Details are:
You may not be aware that every Office 365 plan that includes SharePoint Online comes with the ability to create a public website linked to any domain. In this demonstration you’ll learn how to configure this public website and how to customize it for your needs.
There will also be the usual news, product updates, general discussion as well as questions and answers.
So if you want to get the latest make sure you register now.
The resources from the latest meeting are also available at:
https://blog.ciaops.com/2013/09/ciaops-virtual-tech-meetingoctober.html
I look forward to seeing you on the day.

Restore, restore, restore

I recently wrote a blog post highlighting the fact that too few ordinary businesses and users perform adequate backups. However, backing up your information is really only half of what you should be doing. To give yourself 100% certainty of your backups you actually need to restore them.
I can’t tell you the amount of times that I have come across people who religiously backup but when they need to actually restore data they can’t for some reason. The most likely reason is because the media is corrupted however I have even seen a case where a company was religiously backing up to write protected tapes. Since all they ever did was change the tape daily and never check the log they effectively had no backups when they needed them. The sad thing is that they thought they were doing the right thing! (certainly not the “write” thing).
So restoring backed up data is just as important because you don’t want to find you have issues when you are relying on your backups to get you out of a disaster. In theory you should of course perform a complete disaster recovery so you know you can do it when the chips are down. At the very least, you should be running smaller test restores regularly to reduce the chances of issues developing.
Now that is all well and good but what happens if you are using the cloud as a backup? What happens when you are using a large provider to maintain your backups? What happens if you are paying someone else to perform your backups? I would still again say restore, restore, restore. You need to be 100% confident that YOU and you alone can recover your data if needed. That means that if you are not 100% comfortable with a third party doing it for you then you need to take additional steps to ensure you can.
This may mean that you need to do your own data backup if your information is stored in the cloud. Remember, the rule of thumb is 3-2-1.
– 3 copies of the data including the original
– 2 different media types for backed up information
– 1 backup off site
Now if you are using a hosted service, I wouldn’t be waiting until you need to recover information, I’d be testing the whole restore process beforehand. In most cases this means logging a ticket with the service provider to complete the recovery. In most cases, this means that the restore process is now out of your control. You simply have to wait until it is completed. How long will that take? You’ll never know until you asked to have something restore now will you? Again, do it as test before you actually need to restore something and document the process so you know.
You also need to be aware of what can actually be restored. In the case of something like SharePoint Online the only current option is a complete site collection restoration over the top of the existing information as detailed here:
http://blogs.technet.com/b/akieft/archive/2012/01/09/restore-options-in-sharepoint-online.aspx
That means that if all you want restored is a single file then you can’t achieve that without overwriting the complete site collection.
SharePoint Online was plenty of other recovery options such as the recycle bin which alleviates this issue BUT what it highlights is that there are limits on what hosting providers can restore. My question for you is, if you are using a cloud provider do you KNOW what the restoration process is? If you don’t then you should.
To be truly secure with cloud providers you are probably going to have to set up some sort of manual or third party back up of your data and that can be difficult, especially given the volume of data most people are pushing up to the cloud. Most connections won’t allow your to suck everything down to a local hard disk over night, so what do you do?
This is where a hybrid approach makes sense. If you use a desktop application like Outlook for you emails then a local copy of your inbox is stored on your workstation. This at least allows you to work ‘off line’ and get to the data locally. If you only accessed your emails via a web browser then you may not be able to get access to it in the event of a disaster.
Office programs like SkyDrive Pro, SkyDrive, OneNote, etc allow you to retain local copies of your data on multiple devices automatically. These features are more designed for convenience that pure backup, however the certainly provide this functionality as an important side benefit. If you accessed everything only via your browser then you may not have that luxury in the event of a disaster. My questions are, do you know what can be restored if needed from the cloud? Then, how can it be restored? Then, how long will it take?
No matter whether you use hosted providers or on premise equipment you need to be able to restore your data when required. You need to understand how long this will typically take and what you can and can’t restore. You and ONLY you are responsible for the security of your data. Therefore you NEED to take responsibility for it NOW and ensure you can restore it if needed.
You have been warned. Because remember, it isn’t a matter of IF you need to recover data, it is WHEN you need to recover data, because NO ONE is immune from disaster.

CIAOPS October Virtual Technology Group resources

For who missed the CIAOPS Virtual Technology group meeting for October you’ll find the video of Mark O’Shea’s presentation up on the CIAOPS YouTube channel

https://www.youtube.com/watch?v=3fwU_RZxTCA

Here are the links mentioned from the parts of the meeting not recorded:

How Microsoft views business today – http://www.geekwire.com/2013/chart-microsofts-business-today-changing/

Money Microsoft makes from android – http://www.zdnet.com/apples-new-iphones-are-fine-but-microsoft-really-profits-from-smartphones-7000020502/

http://www.zdnet.com/microsofts-most-profitable-mobile-operating-system-android-7000015094/

Nexus 5 coming –

http://www.theaustralian.com.au/technology/complex-questions-posed-by-users-prompt-google-search-formula-rejig/story-e6frgakx-1226728308465

Surface 2 –

http://www.microsoft.com/en-us/news/press/2013/sep13/09-23surface2pr.aspx

http://www.microsoft.com/surface/en-au/pre-order

http://www.zdnet.com/microsofts-surface-2-launch-what-to-expect-7000020947/

Amazon Kindle HDX enterprise ready –

http://www.marketwatch.com/story/kindle-fire-hd-and-kindle-fire-hdx-are-enterprise-ready-2013-09-25

Microsoft Partner summit Sydney 28th 29th Oct –

 https://training.partner.microsoft.com/learning/app/SYS_ModalDialog.aspx?IsModal=1&Path=/learning/app/management/LMS_ActSummary.aspx%3FActivityId%3D848609%26GroupMode%3D1%26DispMode%3Dpopup%26UserMode%3D0

Stay tuned for registration details on the November meeting.

Backup, backup, backup

This is a community service announcement to EVERYONE out there who isn’t backing up their technology. Why I am going over something as basic as backup? Again? Because I have again been called into assist recover someone’s machine that wouldn’t boot (even though I haven’t worked with hardware for years). Of course, no backups where available and “everything” on the machine was vital!
In most cases it would probably be easier to walk away from these types of jobs but sometimes relationships overwrite logic. Of course the machine in question came with no further information to assist in the troubleshooting process. Which version of Windows did it run? (Vista Home Premium as it turned out), where is the data that needs to recovered? (on the desktop as it turned out) and so on.
What most non IT people fail to realize is that recovering from these situations is not straight forward and can take a lot of time. In this case, I took a backup image of the machine before commencing work. I then had to troubleshoot non booting issues. Then I had to locate and create suitable Windows boot DVDs to allow recovery. Finally I had to repair the problem so the system could boot. I also had to locate the gigabytes and gigabytes of ‘important’ information and copy it onto an external USB disk, just in case the laptop had further problems during its return transit.
All in all I probably spent about 8+ hours in total recovering the laptop and backing up the information. The user was very pleased about get their information back and they have been sternly warned that this is the one and only time they get a free pass on this. Their question to me is ‘how do I backup?’ and you know what I don’t know how best to answer that.
I appreciate that there are myriad of ways to backup but if I am being asked about ‘how to backup’ is there any real chance that a user is going to be able to install and configure something successfully? Probably not. So the best bet is either probably just to copy the desired files to a USB disk (which I suggested here) or install some sort of cloud based backup service. But again here the choice becomes complex for users. Which one? How much does it cost? How can I get my data back? See what I mean?
So yes backup is critical for any digital system but you know what? If you don’t know how to backup yourself then you need to find someone to help. This is not unlike taking your car to a mechanic, unfortunately I don’t think technology has gotten any simpler for most people even when it comes to something as essential as backup.

Best posts from October

Here’s a sample of the best posts from previous October’s:

2012

Configuring PowerShell Access in Office 365

Information about SkyDrive Pro

2011

Who you Know

Local press

2010

Your Office 365 Business model

Office Web Apps and SBS 7 (aka 2011)

2009

Search Server Express on SBS 2008

Community is dead

2008

Don’t check emails, process emails

The writing is in the cloud

2007

Lessons learnt from recent SharePoint crash

Popularity of Facebook