Showing posts with label Management Shell. Show all posts
Showing posts with label Management Shell. Show all posts

Monday, November 23, 2015

Deploying a WSP to SharePoint 2013



How to deploy a WSP to SharePoint Farm Solution library

This need to be done on the Server which host the SharePoint Central Administration.
  1. Add the WSP to the SharePoint Server
    1. The first thing you need to do is copy over the wsp deployment file. The best things to do is to create a deployment folder, where all the deployed files are kept.
    2. Copy over the deployment files to: c:\Deploy\WSP
  2. Add the WSP to the SharePoint Farm Solution library
    1. Open "SharePoint 2013 Management Shell " as administrator
      a. Open the Search on Server 2012
      b. Search for "SharePoint 2013 Management Shell"
      c. Right click "SharePoint 2013 Management Shell"
      d. Select "Run as Administrator"
    2. Run this script: 

      Add-SPSolution "c:\Deploy\WSP\{file name}.wsp"  
  3. Deploy the WSP to the SharePoint Farm Solution library

    1. Open Central Administration
    2. Click "System Settings"
    3. Click "Manage farm solutions", under "Farm Management"
    4. Click on the {file name}.wsp package
    5. Click "Deploy Solution"
    6. Deployment settings
      Deploy When: Now
      Deploy to: All content Web application
    7. Click "OK"

How to activate the WSP Feature on the Site Collection

  1. Activate the WSP Feature on the Site Collection
    1. Open the Root Site (the Site Collection)
    2. Click the cog, in the top right corner (Site Actions)
    3. Select "Site Settings"
    4. Click "Site collection features", under "Site Collection Administrator"
    5. Go to {file name}
    6. Click "Activate", to the right

Wednesday, November 12, 2014

SharePoint 2013 - Check Correlation ID using Management Shell

<GUID> = Correlation ID = 0e90cb9c-1855-80fc-177a-ebaed1a55500

Code:
get-splogevent | ?{$_.Correlation -eq "<GUID>"} | select Area, Category, Level, EventID, Message | Format-List
Example:
get-splogevent | ?{$_.Correlation -eq "0e90cb9c-1855-80fc-177a-ebaed1a55500"} | select Area, Category, Level, EventID, Message | Format-List

Wednesday, October 29, 2014

How to Enable or Disable Document Property Promotion (ParserEnabled) in SharePoint 2013

This is the way to solve issues on uploading document into SharePoint 2013 Document Library. After upload the document into SharePoint library, the document had the metadata (document properties) of the original document. Metadata that is changed on the document will revert to the original values that were given to the document; this occurs both from SharePoint and from MS Word.
 
Solution 1 – Remove Document Properties & personal Information using Inspect
1.      Open file using Microsoft office
2.      Click file and the inspect document (check for issues)
3.      Tick only on document properties & personal information
4.      Inspect & then remove
5.      Then Save
6.      Upload document into SharePoint.
 
Solution 2 – Disable Document Property Promotion using PowerShell
The SPWeb object has a ParserEnabled property, which enables or disables this functionality.  Using the PowerShell script, we can turn off this functionality at the web level. Sample script to disable the document parser feature in SharePoint:
1.      Open the SharePoint 2013 Management Shell as Administrator.
2.      Run the following script to disable document property promotion.
 
C:\> $web
        Url
        ---
        http://spfe01/sites/SITENAME/SUBSITENAME
C:\> $web.parserenabled
        True
C:\> $web.parserenabled  = $false
C:\> $web.Update()
C:\> $web.parserenabled
        false
 
 
3.      Document Property Promotion is disabled successfully and when you try to upload a document you will find that all the fields are empty