WEBSITE

Sharepoint 2013 : Prepare the Microsoft SharePoint Installation Module , Install SharePoint Unattended

12/22/2013 6:46:58 PM

1. Prepare the Microsoft SharePoint Installation Module


Scenario/Problem: You need to have access to extended SharePoint installation commands within PowerShell.


Solution: Download and install the SPModule from Microsoft.

Before you can install SharePoint from within PowerShell, you need to download and install the SPModule code from Microsoft. The downloadable file is located at www.microsoft.com/downloads/en/details.aspx?FamilyID=c57556ff-8df0-44fd-aba6-3df01b9f80ce (or search for “SPModule PowerShell”).

Unzip the file and place it into a local folder. Add this folder to the PSModulePath environment variable. The code is unsigned, so you must allow unsigned scripts to run.

Launch Windows PowerShell by right-clicking the icon and selecting Run As Administrator. Import the modules extracted from the zipped SPModule by using the commands in Listing 1.

Listing 1. Importing the SPModule Components


Import-Module SPModule.misc
Import-Module SPModule.setup



Tip

You must set your execution policy to Unrestricted to successfully import the SPModule.misc and SPModule.setup files. You therefore are prompted upon import of some scripts. Entering an R for Run Once installs the scripts properly.


The cmdlets to install and configure SharePoint are now installed and ready for use.


Note

Importing the SPModule.misc file performs a check for updates. If updates are available, you are notified. Perform any updates before proceeding.

2. Install SharePoint Unattended


Scenario/Problem: You need to install SharePoint from PowerShell.


Solution: Use the Install-SharePoint cmdlet from the SPModule.

The first step in unattended installation and configuration is to install SharePoint onto the server. The SPModule provides the Install-SharePoint cmdlet to perform the installation. This cmdlet is used in conjunction with a setup configuration file that contains the installation parameters.

The SharePoint installation disc includes sample setup configuration files, located in their own folder within Files, as shown in Figure 1. Listing 2 shows an example of the configuration file contents.

Image

Figure 1. Sample configuration files are contained within the folders shown.

Listing 2. Sample Farm Setup Configuration File


<Configuration>
    <Package Id="sts">
        <Setting Id="LAUNCHEDFROMSETUPSTS" Value="Yes"/>
    </Package>

    <Package Id="spswfe">
        <Setting Id="SETUPCALLED" Value="1"/>
    </Package>

    <Logging Type="verbose" Path="%temp%"
Template="SharePoint Server Setup(*).log"/>
    <!--<PIDKEY Value="Enter Product Key Here" />-->
    <Setting Id="SERVERROLE" Value="APPLICATION"/>
    <Setting Id="USINGUIINSTALLMODE" Value="1"/>
    <Setting Id="SETUPTYPE" Value="CLEAN_INSTALL"/>
    <Setting Id="SETUP_REBOOT" Value="Never"/>
</Configuration>


Copy the config.xml file that matches your intended installation to a local drive location. Open the file in Notepad and uncomment the PIDKEY line by removing the <!-- from the front and the --> from the back. Enter your SharePoint product key in place of Enter Product Key Here. Save your changes.

You can now use this configuration file with the Import-SharePoint cmdlet, which has the following syntax:

Install-SharePoint -setupexepath <path to setup.exe on disc>
-configxmlpath <path to the setup config.xml>

Listing 3 shows a sample command-line entry.

Listing 3. Installing SharePoint from the Command Line


Install-SharePoint -setupexepath D:\setup.exe -configxmlpath
c:\config.xml


SharePoint is installed on the server accordingly.


Tip

Install SharePoint on all servers that will participate in the farm (except for the database server) before configuring a new farm or joining an existing farm.

Other  
  •  Sharepoint 2010 : Putting Your Site on the Web - Additional Features
  •  Sharepoint 2010 : Putting Your Site on the Web - Key Terms and Architecture , Richer User Experience
  •  Sharepoint 2010 : Putting Your Site on the Web - Web Content Management (part 2) - Web Publishing 101
  •  Sharepoint 2010 : Putting Your Site on the Web - Web Content Management (part 1)
  •  Sharepoint 2010 : Using an External Data Column, Building a Composite Application
  •  ASP.NET 4 in VB 2010 : Page Tracing (part 3) - Application-Level Tracing
  •  ASP.NET 4 in VB 2010 : Page Tracing (part 2) - Writing Trace Information
  •  ASP.NET 4 in VB 2010 : Page Tracing (part 1) - Enabling Tracing, Tracing Information
  •  ASP.NET 4 in VB 2010 : Logging Exceptions (part 4) - Retrieving Log Information
  •  ASP.NET 4 in VB 2010 : Logging Exceptions (part 3) - Custom Logs, A Custom Logging Class
  •  
    Top 10
    Extending LINQ to Objects : Writing a Single Element Operator (part 2) - Building the RandomElement Operator
    Extending LINQ to Objects : Writing a Single Element Operator (part 1) - Building Our Own Last Operator
    3 Tips for Maintaining Your Cell Phone Battery (part 2) - Discharge Smart, Use Smart
    3 Tips for Maintaining Your Cell Phone Battery (part 1) - Charge Smart
    OPEL MERIVA : Making a grand entrance
    FORD MONDEO 2.0 ECOBOOST : Modern Mondeo
    BMW 650i COUPE : Sexy retooling of BMW's 6-series
    BMW 120d; M135i - Finely tuned
    PHP Tutorials : Storing Images in MySQL with PHP (part 2) - Creating the HTML, Inserting the Image into MySQL
    PHP Tutorials : Storing Images in MySQL with PHP (part 1) - Why store binary files in MySQL using PHP?
    REVIEW
    - First look: Apple Watch

    - 3 Tips for Maintaining Your Cell Phone Battery (part 1)

    - 3 Tips for Maintaining Your Cell Phone Battery (part 2)
    VIDEO TUTORIAL
    - How to create your first Swimlane Diagram or Cross-Functional Flowchart Diagram by using Microsoft Visio 2010 (Part 1)

    - How to create your first Swimlane Diagram or Cross-Functional Flowchart Diagram by using Microsoft Visio 2010 (Part 2)

    - How to create your first Swimlane Diagram or Cross-Functional Flowchart Diagram by using Microsoft Visio 2010 (Part 3)
    Popular Tags
    Microsoft Access Microsoft Excel Microsoft OneNote Microsoft PowerPoint Microsoft Project Microsoft Visio Microsoft Word Active Directory Biztalk Exchange Server Microsoft LynC Server Microsoft Dynamic Sharepoint Sql Server Windows Server 2008 Windows Server 2012 Windows 7 Windows 8 Adobe Indesign Adobe Flash Professional Dreamweaver Adobe Illustrator Adobe After Effects Adobe Photoshop Adobe Fireworks Adobe Flash Catalyst Corel Painter X CorelDRAW X5 CorelDraw 10 QuarkXPress 8 windows Phone 7 windows Phone 8 BlackBerry Android Ipad Iphone iOS