Related Blogs
The Microsoft Search functionality provisions the end user to search a wide range of content like documents, images, videos, audios, etc. within a SharePoint site. In SharePoint On-premise, a user can configure the Search Service Application and crawl the content of the various sites. While SharePoint Online provides both modern and classic search experience to an end user.
Nowadays, users are using the different version of SharePoint On-premise and there is need to get the content of one version into another. To achieve this, SharePoint development team is providing support to crawl the content from the below versions refers below the table.
Sr.No | SP Version | Supported Crawl SP Version |
1 | SharePoint Server 2013 | SharePoint Server 2007 and SharePoint Server 2010 |
2 | SharePoint Server 2016 | SharePoint Server 2007, SharePoint Server 2010 and SharePoint Server 2013 |
Users are also using SharePoint On-premise and SharePoint Online, so there is a need to search the content among them. The content is searched inside the SharePoint server and Office 365 separately and they have their own search index repository.
Microsoft has introduced a concept of the cloud hybrid search and in this concept, the crawled content is indexed in the search index which resides in the Office 365.
Let’s configure the Cloud Hybrid Search with Office 365 and SharePoint 2016, and understand it in more depth.
Pre-Requisites Before Configuration
Below are the pre-Requisites which are needed to be fulfilled before configuration of SharePoint 2016 Hybrid Search.
Register a Public Domain with Office 365
There is a default domain in XXXX.onmicrosoft.com format when a user signs up for the Office 365. This default domain works perfectly fine for the trial version and to carry out some testing on an environment. When there is a circumstance in which a user is required to deploy the Office 365 service to an organization, the user must require to use a custom domain thus the customers and users can identify the organization by URL itself.This procedure contains three main tasks:
1. Add a Domain
- Go to Office 365 Admin and click on the Domains tab by expanding the Setup section.
- Click on Add domain from Domains page.
- Specify the name of the domain in the text box and click on Next.
2. Verify Domain
- The next step after adding a domain is to verify it.
- There are two ways to verify the domain:
- Sign in to GoDaddy (recommended)
- Add a TXT record instead
- Based on a user’s requirement, he can choose any one of the verification approaches. Here, we are proceeding with the recommended approach i.e. Sign in to GoDaddy.
- Log into GoDaddy and confirm access for Office 365 to makes changes to the domain at GoDaddy.
- GoDaddy automatically contacts to the Domain registrar and also proceed with the verification.
- After the verification, it displays the success message.
3. Update the DNS Settings
- Once verification is completed, update the DNS settings. For updating DNS settings, again there are two options to provision it and they are:
- Add the DNS records for me (recommended)
- I’ll add the DNS records myself.
- Based on a user’s requirement, he can update the DNS settings by choosing any option. Here, we are proceeding with the recommended approach i.e. Add the DNS records for me and click on Next.
- From “Choose your online services” screen, check all 3 options (Exchange, Skype for business and Mobile Device Management for Office 365) and click on Next.
- Provide valid credentials in the Domain Manager Login screen and click on Sign In.
- It displays the DNS records which are added to the newly created domain at GoDaddy and click on Next button.
- It displays the success message. Click on Finish.
Add User on Newly Created Domain
To add a new user in the newly created domain walkthrough the below-mentioned steps.
- Click on Users Active users from Left panel.
- From Active users page, click Add a user.
- Enter requires details for a new user and choose the newly created domain. Click on Add.
- The new user is listed on the Active user’s page. Click on the newly created user.
- Click on Manage roles.
- Select the user role as Global administrator & save it.
Add a UPN Prefix to Local AD that Matches the Public Domain
- Select Active Directory Domain and Trusts from the Server hosting the Active Directory.
- Right click on the root node and select Properties.
- This will open up the below window. In this add the public domain which is registered earlier with Office 365 and click on OK.
Add a User to Local Active Directory
- Open the Active Directory Users and Computers.
- Click on the user and follow the below image to add a new user.
- Enter the details of a new user and click on Next.
- Type password for the new user & check Password never expires check box. Click Next.
- The last screen summarized the details of the newly created user to verify it. Click Finish if every detail is proper.
- Now right click on the newly created user and click Properties.
- Open the “Account” tab & select the domain which is earlier added as “UPN Suffix” from the dropdown and click OK.
- Add the newly created user in “Enterprise Admins” group. Open the Member Of tab and click Add.
- Enter “Enterprise Admins” and click OK.
- Now the user is added on Enterprise Admins group. Verify it and click OK.
Sync Local Active Directory with the Azure Active Directory
For this action, a user must have active Azure Subscription and access to Azure AD. To synchronize follow below steps:
- Download “Azure AD Connect” from here.
- Click on downloaded setup to start the installation. Agree to terms and conditions, and click Continue.
- Click on “Use express settings”.
- Here provide the credentials of Office 365 account which is created in the newly configured (HybridSearch.anasource.com) domain.
- Enter the credential of the Local AD user which is under the newly created domain (e.g. domain/Sp2016User).Note: Here to perform an Azure AD sign in, the UPN prefixes which we had added to the on premise Active directory should match with the verified public domain in Azure (Hybridsearch.anasource.com).
- Check for the newly created domain must be verified and click on Next as shown in below image.
- Note: If any other dummy domain is there and it’s not verified then it’s ok. Check the checkbox for “Continue without matching all UPN suffix to verified domains”.
- Click on Install to start the synchronization process.
- Finally, the configuration has completed, click on Exit.
- Head over to Office 365 to check the synchronization status. All the On-premise users have been added to Office 365 as part of the synchronization process. Click Users Active users Refresh and check On-premise users.
Configuration of Cloud Search Service Application
Create Cloud Search Service Application from UI
- To create a Cloud Search Service Application follow below steps in SharePoint Server 2016 machine:
- Open the Central Administration as administrator.
- Go to Application Management Manage service application.
- Click New > Search Service Application.
Note: It’s quite similar to the process of creating a normal Search Service Application except that user have to select an extra checkbox ‘Cloud Search Service Application’ to make it Cloud Search Service Application.
Give the name to search service application and click OK.
- Give the name to search service application and click OK.
- Now, a user can verify the search service is created or not from the “Manage service Application page”.
Connect Cloud Search service application to Office 365 tenant
To complete the Cloud Hybrid Search set-up, a user must require to connect the created Cloud Search Service Application to the Office 365 tenant. Microsoft has provided the script to automate the On-boarding of the Cloud Search Service Application and Office 365 to the Cloud Hybrid search. A user can get the script named “Onboard-CloudHybridSearch.ps1” from here.
In order to run the Onboard-CloudHybridSearch.ps1 script, we have some prerequisites that need to be completed:
- Microsoft Online Services Sign-In Assistant
- Download Microsoft Online Services Sign-In Assistant from this link.
- Select the 64-bit version.
- Run the downloaded set-up and accept the agreement to install.
- Install PowerShell for Azure Active Directory
- Open Windows PowerShell in administration mode and type following command:
Install-Module –Name Msonline
Optional: In case, if it gives error please follow below steps:
Install 64-bit version PackageManagement PowerShell Modules Preview from this link
- After installing the above package, re-type following command in Windows PowerShell:
Install-Module –Name Msonline - Press yes, if it asks any question.
- Run the On-boarding ScriptIn order to complete the on-boarding of Cloud search Service Application and Office 365 on to Cloud hybrid search follow below steps.
- Run the Onboard-CloudHybridSearch.ps1 script in the SharePoint Management shell with the administrator.
- It will ask for few parameters:
- Portal URL: Specify the SharePoint Online URL of the organization.
- Administrator Credentials: It will also ask for the Office 365 global administrator credentials. Enter credentials and click OK.
- Portal URL: Specify the SharePoint Online URL of the organization.
- This will complete the Onboarding process and will register the Cloud hybrid search.
Create a content source to crawl for cloud hybrid search.
- As a final step in configuring the Cloud hybrid search, a user is required to create a content source and run a full crawl in SharePoint 2016 On Premise Server.
- Click the Cloud Search Service Application which was created from Central Admin in 6.1 section.
- It will open the Search Administration page. Select Content Sources under Crawling from the left navigation pane.
- From the Content Sources page, create New Content Source. This will open up the page, where a user can provide the Content Source Name, its type and the start addresses i.e. site URLs from where the crawling needs to start.
- A user can also schedule the incremental and full crawls to take place in the Server.
- The incremental crawl is scheduled to run daily, weekly or monthly. We have set the incremental crawl to run daily at 30 minutes intervals.
- On the other hand, the full crawl can also be scheduled to run daily, weekly or monthly. We have set it to run every day at 12 AM.
- After scheduling the crawls, the configuration will look like as shown below in the image.
- Now, let’s go ahead and run a full crawl.
- We are running the craw for the first time so even if we click on incremental crawl then also a full crawl will take place and the time taken will depend upon the amount of the content within the content source.
Test Results
- Once the crawling has completed on the above step, login to SharePoint online site.
Note: Login user must be inside the configured domain (ex: Hybridsearch.anasource.com) - Now search for IsExternalContent:1.
- ‘IsExternalContent: 1’ is a property, which gives the search results only from the On Premise environment. This will list search results from SharePoint 2016 On Premise Server in the SharePoint Online Search Page and thus indicates a successful Hybrid Search Configuration.
Conclusion
The Cloud Hybrid Search furnishes the content of both SharePoint On-premise and Office 365 to be available for an end user in unified search results. An end user does not require to panic for the search index as it is in the Office 365 and also not require to migrate the search index to the newer version of SharePoint servers as it is provisioned by Office 365 automatically. A user also experiences the SharePoint Online search without updating existing SharePoint servers.
Vishal Shah
Vishal Shah has an extensive understanding of multiple application development frameworks and holds an upper hand with newer trends in order to strive and thrive in the dynamic market. He has nurtured his managerial growth in both technical and business aspects and gives his expertise through his blog posts.
Subscribe to our Newsletter
Signup for our newsletter and join 2700+ global business executives and technology experts to receive handpicked industry insights and latest news
Build your Team
Want to Hire Skilled Developers?
Comments
Leave a message...