Setup command-line reference (SharePoint Server 2010)

 

Applies to: SharePoint Server 2010

In SharePoint 2010 Products, the Setup command-line tool is used for very few operations, and most of these are for IT administrators only.

In this article:

  • How to use a Setup command-line switch

  • Available switches and parameters

How to use a Setup command-line switch

To run Setup from the command line, type a space after the command, followed by a forward slash (/) and the name of the switch, and sometimes followed by another space and one or more parameters. For example:

setup.exe /<switch> [parameter]

The parameters are specific instructions that give the program more information about how to execute the command. The table in the next section contains several examples of switches.

Available switches and parameters

In SharePoint 2010 Products, Setup recognizes the following command-line options.

Switch or parameter Description
/config [path and file name]

Specifies the configuration file that Setup uses during the installation. By default, the Config.xml file that is stored in the core product folder directs Setup to install that product. You can edit the Config.xml file to make additional customizations to the installation, or you can point to a different configuration file.

The product DVD contains examples of Config.xml files. The example files are stored in the Files folder at the root of the DVD, in folders that correspond to different scenarios. For example, the Files\SetupFarmSilent folder contains a Config.xml file for use in setting up a server farm in silent mode.

Use /config on the Setup command line to point to the location of the default Config.xml file for a particular product or to point to a custom configuration file.

Examples

To point to a customized Config.xml file:

\\<server>\<share>\setup.exe /config \\<server>\<share>\<folder>\config.xml

where <folder> is the folder that contains the Config.xml file.

Or, to point to a different configuration file:

\\<server>\<share>\setup.exe /config \\<server>\<share>\Files\SetupFarmSilent\config.xml

/modify [ProductID]

The /modify switch is used with a modified Config.xml file to run Setup in maintenance mode and make changes to an existing Office installation, such as adding or removing features.

Look up the value of [ProductID] in the Setup.xml file for the product that you want to modify. The Setup.xml file is located in the core product folder at the root of the network installation point or product DVD. For example, the Setup.xml file for SharePoint Foundation 2010 is located in the Wss.en-us folder.

In Setup.xml, [ProductID] is equal to the value of the Id attribute of the Setup element. For example:

- <Setup Id="Wss" Type="Product" ProductCode="{40120000-1110-0000-0000-0000000FF1CE}">

This switch cannot be used to change the configuration of the server (such as from a stand-alone configuration to a server farm configuration). To change the configuration, you must uninstall and reinstall.

Examples

\\<server>\<share>\setup.exe /modify wssmui.en.us /config \\<server>\<share>\<folder>config.xml

In this example, Setup at the root of the DVD is run in maintenance mode to modify SharePoint Foundation, as specified with the wss product ID. If a Config.xml file is not specified, Setup uses the Config.xml in the same folder as the Setup.exe file.

\\<server>\<share>\setup.exe /modify wss

/repair [ProductID]

Runs Setup to repair the files that are needed for the specified product. Running Setup in repair mode only affects the program files and does not repair your server configuration or any sites.

Look up the value of [ProductID] in the Setup.xml file for the product that you want to modify. The Setup.xml file is located in the core product folder at the root of the network installation point or product DVD. For example, the Setup.xml file for SharePoint Foundation 2010 is located in the Global folder at the root of the DVD.

Note

You should also run the SharePoint Products Configuration Wizard after you run setup.exe /repair to complete the repair of the configuration. If you are using a stand-alone configuration, you can run psconfig.exe -setup from the command line to repair the configuration instead of using the wizard. If you are in a server farm configuration, you should use the full wizard interface. For more information, see the Help for the SharePoint Products Configuration Wizard.

Example

\\<server>\<share>\setup.exe /repair Wss

/uninstall [ProductID]

Removes the specified product from the user's computer. Look up the value of [ProductID] in the Setup.xml file for the product that you want to modify.

Look up the value of [ProductID] in the Setup.xml file for the product that you want to modify. The Setup.xml file is located in the core product folder at the root of the network installation point or product DVD. For example, the Setup.xml file for SharePoint Foundation 2010 is located in the Global folder at the root of the DVD.

Example

\\<server>\<share>\setup.exe /uninstall WSS

Run Setup with a Config.xml file at a command prompt

Running Setup with a configuration file lets you specify configuration choices (such as a data location or server role) during a quiet installation. For example, you can use the Config.xml file to:

  • Perform a silent installation.

  • Install by using a common configuration across multiple servers.

  • Perform an automated or scripted installation.

Use the following procedure to run Setup with a configuration file at a command prompt.

  1. On the drive that contains the product DVD, change to the root directory to locate the Setup.exe file.

  2. Run Setup with the selected Config.xml file.

    setup /config <path and file name>

    Note

    You can select one of the example files that are included in the Microsoft SharePoint Server 2010 product DVD, or customize your own configuration file.

  3. Press ENTER.

For more information, see Install SharePoint Server 2010 by using Windows PowerShell.