About Me

SharePoint Architect with over 17 years of IT Experience in various roles as SharePoint Architect, Administrator, Technical Architect, IT Analyst, Application Developer, CRM Consultant, BI Developer, Microsoft Solution Architect in Client/Server, Web and Enterprise CRM Applications in E-Commerce, Financial, Healthcare, Insurance, Telecom, Outsourcing and Technology Services.
MCITP (Pro): Microsoft Certified IT Professional: SharePoint 2010 Administrator.
MCTS: Microsoft Certified Technology Specialist, SharePoint 2010 Configuration.

Wednesday, April 3, 2013

Administrative Commands for Server Management.



1. List Wireless Connection Profiles
                               netsh wlan show profiles

2. Test Domain Name : portal.spdomain.com
C:\Users\spadmin>nslookup portal

3. Disable Loopback.
    Powershell Command:
New-ItemProperty HKLM:\System\CurrentControlSet\Control\Lsa -Name "DisableLoopbackCheck" -value "1" -PropertyType dword

4. If certain links are not enabled and/or IE GUI is different than expected.
    Try: Enabled Active Scripting in IE\Internet Options\Security\Custom Level

5. Command line tools.
    Computer Management      : compmgmt.msc
 
    IssueLocal users and groups not available under Computer Management
    If you are On a DC, you don't have local users and groups, you must use Active directory users and computers.

     Server Manager      : ServerManager.msc

    Domain Controller  :  

Managing Service Accounts in Windows Server 2008 R2

Managing Service Accounts in Windows Server 2008 R2

Unfortunately, No UI is available for this purpose.

Windows PowerShell cmdlets are needed to configure and manage these accounts for a service running on Windows 7 or Windows Server 2008 R2.

May need KB 2494158, to override password expiry in 30 days.

Refer following link for more details. http://technet.microsoft.com/en-us/library/dd548356.aspx

Monday, March 11, 2013

SharePoint 2010 Farm Account getting access denied on Server

When you setup New SharePoint 2010 Farm Environment you may experience access denied issue even for Farm Account, when try to access any Web Application/Site in spite of having Farm Account in the Web Application Policy with Full Control.
 
Try this in the command prompt to confirm that

net view \\
alias.domain name.com    You may get error as
  1. Refer to the KB http://support.microsoft.com/kb/896861 and edit registry values as below.In Registry Editor, locate and then click the following registry key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa\MSV1_0

  1. Right-click MSV1_0, point to New, and then click Multi-String Value.
  2. Type BackConnectionHostNames, and then press ENTER.
  3. Right-click BackConnectionHostNames, and then click Modify.
  4. In the Value data box, type the host name or the host names for the sites that are on the local computer, and then click OK.
Quit Registry Editor, and then restart the IISAdmin service.

The result is

Tuesday, January 29, 2013

Scripting Tips


Count of rows in Text File
$totalrows = Import-Csv C:\urls.csv | Measure-Object | Select-Object -expand count

Open/Read text File

    AccountNames.csv
         AccountName
         Domain\Name1
         Domain\Name2

$AcctFile="C:\AccountNames.csv"

ipcsv $AcctFile | foreach {
     $AName =$_.AccountName
}

Write-host
Write-host "Feature: " $AName -foregroundcolor yellow
Clear-Host


TimeStamp
$strTimestamp =  [string](Get-Date -format "yyyy-MM-dd_hh-mm-ss")
$strLogFile =  ($strFilePath + "FileName_" + $strTimestamp + ".log")

Log to File
$AName +",Blog-NotFound" | Out-File ($strLogFile) -append
Write-Output "$Class deleted on $CommunityList" | Out-File -Append $strLogFile
"Count  :"+$UrlsCount | Out-File -Append $DeletedReport

Log File Creation Prompt:
if ((Test-Path -path $FilePath) -ne $True) {
 $NewPathPrompt = "$FilePath does not exist! Would you like to create it?"
 $NewPathMessage = ""
 $NewPathYes = New-Object System.Management.Automation.Host.ChoiceDescription "&Yes", `
  "Creates new directory at $FilePath"
 $NewPathNo = New-Object System.Management.Automation.Host.ChoiceDescription "&No", `
  "Do not create new directory and exit"
 $NewPathOptions = [System.Management.Automation.Host.ChoiceDescription[]]($NewPathYes, $NewPathNo)
 $NewPathResult = $host.ui.PromptForChoice($NewPathPrompt, $NewPathMessage, $NewPathOptions, 0)
 switch ($NewPathResult)
  {
   0 {New-Item $FilePath -type directory}
   1 {Write-Host "Cannot continue without valid directory to save output file, exiting..."
    Exit
    }
  }
}
 



Blog Sites


  • SharePoint Security
    http://www.sharepointsecurity.com/syndicated-content/first-steps-in-implementing-isa-server-with-sharepoint/
  • http://blog.sharepointsite.co.uk/
    Remote restart and auto-logon and PowerShell Script execution on remote server.



Thursday, October 18, 2012

Enumerate Crawl Properties using Powershell

1. Save the following script file as      Get-EnumCrawlProp.ps1
2. Create an input file for Content Sources (just one content source name in one line)
3. Run the script as      PS>Get-EnumCrawlProp.ps1 ProdContentSources.txt

param(
[String]$InputFile = ""
)
If ($InputFile)
{
$ContentSrc = Get-Content $InputFile
$searchapp = Get-SPEnterpriseSearchServiceApplication |where {$_.name -eq "ProdSearchSA1"};
ForEach ($c in $ContentSrc)
{
 $csource = Get-SPEnterpriseSearchCrawlContentSource $c -sea $searchapp;
 #Write-Host "Crawl State for $c " $csource.CrawlState
 $csource.IncrementalCrawlSchedule | select DaysOfWeek, DaysInterval,  StartHour, StartMinute, RepeatInterval, RepeatDuration
}
"Process complete."
}