Subsystem for UNIX-based Applications (SUA), the evolution of the Interix subsystem that formerly shipped with Windows Services for UNIX 3.5, is a multi-user UNIX environment that operates on computers running Windows server-class operating systems. SUA and its accompanying utilities provide you with an environment that resembles UNIX-based operating systems. It also includes case-sensitive file names, job control, compilation tools, and the use of over 300 UNIX commands, utilities, and shell scripts. Because SUA is designed to run atop the Windows kernel, it offers true UNIX-based functionality without any emulation.

In this section

Installing Subsystem for UNIX-based Applications

Subsystem for UNIX-based Applications (SUA) is a feature included with Microsoft® Windows Server® 2008 R2 and Windows® 7.

Important

Until the download package Utilities and Software Development Kit for Subsystem for UNIX-based Applications (Utilities and SDK for SUA) has been installed on the computer, you cannot run or modify UNIX-based scripts and custom UNIX-based applications. The Utilities and SDK for SUA package is available for download on the Microsoft Web site (https://go.microsoft.com/fwlink/?LinkId=139521).

How to install Subsystem for UNIX-based Applications on Windows 7

How to install Subsystem for UNIX-based Applications on Windows Server 2008 R2

How to install Subsystem for UNIX-based Applications on Windows 7

You can install Subsystem for UNIX-based Applications either by using the Windows 7 interface, or by using a command prompt. Perform the following steps to install SUA on your computer.

Using the Windows interface

Using a command line

Using the Windows interface

To install SUA by using the Windows interface
  1. Click Start, and then click Control Panel.

  2. In the Control Panel window, click Programs.

  3. Under Programs and Features, click Turn Windows features on or off.

  4. If the User Account Control dialog box opens, click Continue. Otherwise, proceed to the next step.

  5. In the Windows Features dialog box, select the Subsystem for UNIX-based Applications check box. Click OK.

  6. In the Add Features Wizard, on the Select Features page, select the Subsystem for UNIX-based Applications check box.

    Installation might require a few minutes to complete.

Using a command line

To install SUA by using a command line
  1. Open a command prompt window. To open a command prompt window, click Start, click in the Start Search text box, type cmd and then press ENTER.

    A Command Prompt shortcut may also be available on the Start menu.

  2. Change directories to %windir%\system32.

    Example: The current directory is C:\Documents and Settings\user_name.

    Type cd ..\..\Windows to change to the C:\Windows directory.

  3. Enter the following command:

    start /w pkgmgr /iu:SUA

  4. If a User Account Control dialog box opens , click Continue.

    Installation is complete when the command window displays a %windir%\system32 prompt on a new line.

How to install Subsystem for UNIX-based Applications on Windows Server 2008 R2

You can install Subsystem for UNIX-based Applications either by using the Windows Server 2008 R2 interface, or by using a command prompt. Perform the following steps to install SUA on your computer.

Using the Windows interface

Using a command line

Using the Windows interface

To install SUA by using the Windows interface
  1. Open Server Manager. Click Start, point to Administrative Tools, and then click Server Manager.

  2. In the Features Summary area of the Server Manager home page, click Add Features.

    The Add Features Wizard opens.

  3. On the Select Features page of the Add Features Wizard, select Subsystem for UNIX-based Applications, and then click Next.

  4. Click Install.

    Installation might require a few minutes to complete.

Using a command line

As with other features available with Windows Server 2008 R2, you can use the Server Manager command line to install or remove SUA from your computer. The Server Manager command line has other parameters available that you can use to show you more information about the installation process or to identify features already installed on the computer. For more information about the Server Manager command line, see the Server Manager Help.

To install SUA by using a command line
  1. Open a Command Prompt window with elevated privileges. To do this, right-click the Command Prompt executable, or the Command Prompt object on the Start menu, and then click Run as administrator.

  2. Type the following, and press ENTER.

    ServerManagerCmd.exe -install Subsystem-UNIX-Apps -restart

    Note

    The command identifier for SUA, Subsystem-UNIX-Apps, is not case sensitive.

    The -restart parameter at the end of the Server Manager command instructs Server Manager to restart the computer only if necessary to complete the installation process.

    You can also use the Server Manager line command with an XML answer file. For more information about using answer files with the Server Manager command, see "Creating an Answer File for Server Manager Commands" in the Server Manager Help.

Computing environments with Subsystem for UNIX-based Applications

A computer running SUA provides two different command-line environments: the UNIX environment and the Windows environment. Applications run on specific subsystems and in specific environments. When you load SUA, you are using a UNIX environment; when you run applications on the Windows subsystem, you are using a Windows environment.

For example, when you use the Korn shell or C shell available with the download package Utilities and SDK for SUA, or any other application that was compiled to run on SUA, you are using a UNIX environment. Among other things, this environment features case-sensitive file names and path names that use the format /usr/examples. For more information about the commands and utilities that are available in SUA, see the Help files that ship with the download package Utilities and SDK for SUA. This download package is available from the Microsoft Web site (https://go.microsoft.com/fwlink/?LinkId=139521).

When you use the command processor cmd.exe, you are using the Windows environment. This environment includes case-insensitive file names, and path names that include drive letters, as shown in the following example: C:\SUA\usr\examples. For more information about path names in SUA and Windows, see the Help files that ship with the download package Utilities and SDK for SUA.

Porting applications by using Subsystem for UNIX-based Applications

Subsystem for UNIX-based Applications provides both the tools and the application programming interface (API) libraries for porting applications to run on Windows-based computers. With the software development kit (SDK), which provides a front end for the Microsoft Visual C++® development system, you can have a UNIX environment for development, but still have the benefits of the native compiler for Windows. For more information about path names in SUA and Windows, see the Help files that ship with the download package Utilities and SDK for SUA.

See Also