Create claims-based web application from SharePoint PowerShell

Creating claims-based web application is more flexible with SharePoint PowerShell script than CA. Here, the snippet for http and ssl site.


Delete SharePoint list items from PowerShell

Here the quick solution to clean/delete all items from the SharePoint list.


Export Windows Service to Excel with Filter

Another sample Powershell script to exporting “Running” and “Stopped” windows service to excel by using Powershell Array.


Creating Managed Metadata Service Application by Powershell Script

As we are all knows, the SharePoint Powershell can be fast and simple. Here the sample script for creating Managed Metadata Service Application;


SharePoint continuous user login prompting with custom host header site

SharePoint site with custom host header will prompting the user login screen on local machine but either you can login or view the site from your local network machines. Because the loop back is enabled by default on each and every machine. To resolve the issue you have to disable it.

Open PowerShell as administrator privilege and run the below script;

I hope the things are going good :)Cheers!

Import Users in Active Directory Using PowerShell

Today, we are going to discuss about importing bulk users in Active Directory using PowerShell. We are all knows that we can do anything in PowerShell.
You can check the required parameter for adding AD user. But I’m going to import the below sample fields.

Basic Comment
-Name “Disply Name”
-GivenName “First Name”
-Surname “Last Name”
-SamAccountName “UserName”
-UserPrincipalName “”
-Path “OU=OrganizationUnit,DC=sathiya,DC=io”
-Enabled $true
-PasswordNeverExpires $true
-AccountPassword (ConvertTo-SecureString “password” -AsPlainText -force)

The above script is for adding single user.


Sample CSV file ImportUser.csv

I hope the things are going good :)Cheers!

Application error when access “/_layouts/15/workflow.aspx”

After, I installed and configured the workflow for SharePoint 2013 and register to the web application, it was getting an error while starting the workflow as;
Message: Application error when access /_layouts/15/workflow.aspx, Error=The pipe endpoint ‘net.pipe://localhost/SecurityTokenServiceApplication/appsts.svc’ could not be found on your local machine.
EventID: 8nca
Make sure the Net.Pipe Listener Adapter windows service is running, if not run net start NetPipeActivator. I hope this helps.

Add computer to the domain using CMD without restart

From your windows client machine open command prompt and run the following cmd

Error configuring Management Reporter 2012

While configuring MR 2012 RU5 for Dynamics GP 2012 with Microsoft SQL 2014, this is the error we have faced;

2/16/2015 3:15:09 PM - System.ServiceModel.EndpointNotFoundException: There was no endpoint listening at http://dynamics/CompanyService.svc that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details. ---> System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: No connection could be made because the target machine actively refused it

at System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapshot, SocketAddress socketAddress)

at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception)

--- End of inner exception stack trace ---
at System.Net.HttpWebRequest.GetRequestStream(TransportContext& context)
at System.Net.HttpWebRequest.GetRequestStream()
at System.ServiceModel.Channels.HttpOutput.WebRequestHttpOutput.GetOutputStream()
--- End of inner exception stack trace ---
Server stack trace:
at System.ServiceModel.Security.IssuanceTokenProviderBase 1.DoNegotiation(TimeSpan timeout)
at System.ServiceModel.Security.SspiNegotiationTokenProvider.OnOpen(TimeSpan timeout)
at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
at System.ServiceModel.Security.SymmetricSecurityProtocol.OnOpen(TimeSpan timeout)
at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
at System.ServiceModel.Channels.SecurityChannelFactory 1.ClientSecurityChannel 1.OnOpen(TimeSpan timeout)
at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
at System.ServiceModel.Security.SecuritySessionSecurityTokenProvider.DoOperation(SecuritySessionOperation operation, EndpointAddress target, Uri via, SecurityToken currentToken, TimeSpan timeout)
at System.ServiceModel.Security.SecuritySessionSecurityTokenProvider.GetTokenCore(TimeSpan timeout)
at System.IdentityModel.Selectors.SecurityTokenProvider.GetToken(TimeSpan timeout)
at System.ServiceModel.Security.SecuritySessionClientSettings 1.ClientSecuritySessionChannel.OnOpen(TimeSpan timeout)
at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannel.OnOpen(TimeSpan timeout)
at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannel.CallOnceManager.CallOnce(TimeSpan timeout, CallOnceManager cascade)
at System.ServiceModel.Channels.ServiceChannel.EnsureOpened(TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)
Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Microsoft.Dynamics.Performance.Deployment.CompanyImport.CompanyService.ICompanyService.FillAllConfiguredIntegrations()
at Microsoft.Dynamics.Performance.Deployment.Common.WcfUtility.ExecuteOnClient[TCommunicationObject,TReturn](Func 2 invokeMe, Func 1 clientFactory)
at Microsoft.Dynamics.Performance.Deployment.CompanyImport.CompanyServiceHelper.ExecuteOnClient[T](Func 2 invokeMe, Func 2 exceptionHandler, Uri applicationServiceUri)
2/16/2015 3:16:09 PM - Starting deployment of Management Reporter 2012 Application Service
2/16/2015 3:16:09 PM - Creating PrincipalContext for domain <domain>
2/16/2015 3:16:09 PM - Finding Principal for user entadmin in context for domain <domain>
2/16/2015 3:16:09 PM - Found database package: C:\Program Files\Microsoft Dynamics ERP\Management Reporter\2.1\Server\Packages\ManagementReporter.dacpac
2/16/2015 3:16:09 PM - Found database package: C:\Program Files\Microsoft Dynamics ERP\Management Reporter\2.1\Server\Packages\SchedulerStore.dacpac
2/16/2015 3:16:09 PM - Found database package: C:\Program Files\Microsoft Dynamics ERP\Management Reporter\2.1\Server\Packages\ConnectorStore.dacpac
2/16/2015 3:16:09 PM - Deployment parameters:
DatabaseCollation: SQL_Latin1_General_CP1_CI_AS
WindowsLoginToCreate: <domain>\mrsvc
FirstAdminUserName: <domain>\entadmin
FirstAdminSid: S-1-5-21-1583657088-1483352188-1218694631-500
FirstAdminDisplayName: Ent Admin
2/16/2015 3:16:09 PM - Extracting supporting files for database deployment...
2/16/2015 3:16:09 PM - Beginning database deployment...
2/16/2015 3:16:11 PM - The database deployment failed. Additional information: Could not deploy package.
2/16/2015 3:17:21 PM - Microsoft.Dynamics.Performance.Deployment.Console.Core.DeploymentFailedException: An error occurred during database deployment. View the deployment log for more information.
at Microsoft.Dynamics.Performance.Deployment.Reporting.ReportingDatabase.DeployDatabasePackages(String connectionString, String databaseName, Dictionary
2 parameters)
at Microsoft.Dynamics.Performance.Deployment.Reporting.ApplicationServiceDeploymentPart.DeployWithSettings(IDictionary2 settingsToDeployWith)
at Microsoft.Dynamics.Performance.Deployment.Console.ConfigurationConsole.Wizard.Screens.DeploymentViewModel.TryRemoveFromView(Boolean isProgressing)


Before starting the MR, you have to check SQL server version. Hence the root cause of the above error is version compatibility. Ref version summary here

So, you have to download CU9 from your customer source which is support to SQL server 2014. Ref here still the error persist.