Install PolyBase on Windows

APPLIES TO: yesSQL Server (Windows only) noAzure SQL Database noAzure SQL Data Warehouse noParallel Data Warehouse

To install a trial version of SQL Server, go to SQL Server evaluations.

Prerequisites

  • 64-bit SQL Server Evaluation edition.

  • Microsoft .NET Framework 4.5.

  • Oracle Java SE Runtime Environment (JRE). Versions 7 (starting from 7.51) and 8 are supported. JRE and Server JRE both work. Go to Java SE downloads. If JRE isn't present, the installer fails. JRE9 and JRE10 aren't supported.

  • Minimum memory: 4 GB.

  • Minimum hard-disk space: 2 GB.

  • Recommended: Minimum of 16-GB RAM.

  • TCP/IP must be enabled for PolyBase to function correctly. TCP/IP is enabled by default on all editions of SQL Server except for the Developer and Express SQL Server editions. For PolyBase to function correctly on the Developer and Express editions, you must enable TCP/IP connectivity. See Enable or disable a server network protocol.

  • MSVC++ 2012.

Note

PolyBase can be installed on only one SQL Server instance per machine.

Important

To use the computation pushdown functionality against Hadoop, the target Hadoop cluster must have the core components of HDFS, YARN and MapReduce, with the job history server enabled. PolyBase submits the pushdown query via MapReduce and pulls status from the job history server. Without either component, the query fails.

Single node or PolyBase scale-out group

Before you install PolyBase on your SQL Server instances, decide whether you want a single node installation or a PolyBase scale-out group.

For a PolyBase scale-out group, make sure that:

  • All the machines are on the same domain.
  • You use the same service account and password during PolyBase installation.
  • Your SQL Server instances can communicate with one another over the network.
  • The SQL Server instances are all the same version of SQL Server.

After you install PolyBase either standalone or in a scale-out group, you can't change. To change this setting, you have to uninstall and reinstall the feature.

Use the installation wizard

  1. Run the SQL Server setup.exe.

  2. Select Installation, and then select New standalone SQL Server installation or add features.

  3. On the Feature Selection page, select PolyBase Query Service for External Data.

    PolyBase services

  4. On the Server Configuration page, configure the SQL Server PolyBase Engine Service and SQL Server PolyBase Data Movement Service to run under the same domain account.

    Important

    In a PolyBase scale-out group, the PolyBase Engine and PolyBase Data Movement service on all nodes must run under the same domain account. See PolyBase scale-out groups.

  5. On the PolyBase Configuration page, select one of the two options. For more information, see PolyBase scale-out groups.

    • Use the SQL Server instance as a standalone PolyBase-enabled instance.

      Choose this option to use the SQL Server instance as a standalone head node.

    • Use the SQL Server instance as part of a PolyBase scale-out group. This option opens the firewall to allow incoming connections. Connections are allowed for the SQL Server Database Engine, SQL Server PolyBase Engine, SQL Server PolyBase Data Movement service, and the SQL browser. The firewall also allows incoming connections from other nodes in a PolyBase scale-out group.

      This option also enables Microsoft Distributed Transaction Coordinator (MSDTC) firewall connections and modifies MSDTC registry settings.

  6. On the PolyBase Configuration page, specify a port range with at least six ports. SQL Server setup allocates the first six available ports from the range.

    Important

    After installation, you must enable the PolyBase feature.

Use a command prompt

Use the values in this table to create installation scripts. The SQL Server PolyBase Engine and SQL Server PolyBase Data Movement service must run under the same account. In a PolyBase scale-out group, PolyBase services on all nodes must run under the same domain account.

SQL Server component Parameter and values Description
SQL Server setup control Required

/FEATURES=PolyBase
Selects PolyBase feature.
SQL Server PolyBase Engine Optional

/PBENGSVCACCOUNT
Specifies the account for the engine service. The default is NT Authority\NETWORK SERVICE.
SQL Server PolyBase Engine Optional

/PBENGSVCPASSWORD
Specifies the password for the engine service account.
SQL Server PolyBase Engine Optional

/PBENGSVCSTARTUPTYPE
Specifies the startup mode for the PolyBase Engine: Automatic (default), Disabled, and Manual.
SQL Server PolyBase Data Movement Optional

/PBDMSSVCACCOUNT
Specifies the account for the data movement service. The default is NT Authority\NETWORK SERVICE.
SQL Server PolyBase Data Movement Optional

/PBDMSSVCPASSWORD
Specifies the password for the data movement account.
SQL Server PolyBase Data Movement Optional

/PBDMSSVCSTARTUPTYPE
Specifies the startup mode for the data movement service: Automatic (default), Disabled, and Manual.
PolyBase Optional

/PBSCALEOUT
Specifies whether the SQL Server instance is used as a part of a PolyBase scale-out computational group.
Supported values: True, False.
PolyBase Optional

/PBPORTRANGE
Specifies a port range with at least six ports for PolyBase services. Example:

/PBPORTRANGE=16450-16460
SQL Server component Parameter and values Description
SQL Server setup control Required

/FEATURES=PolyBaseCore, PolyBaseJava, PolyBase
PolyBaseCore installs support for all PolyBase features except Hadoop connectivity. PolyBaseJava enables Hadoop connectivity. PolyBase installs both.
SQL Server PolyBase Engine Optional

/PBENGSVCACCOUNT
Specifies the account for the engine service. The default is NT Authority\NETWORK SERVICE.
SQL Server PolyBase Engine Optional

/PBENGSVCPASSWORD
Specifies the password for the engine service account.
SQL Server PolyBase Engine Optional

/PBENGSVCSTARTUPTYPE
Specifies the startup mode for the PolyBase Engine: Automatic (default), Disabled, and Manual.
SQL Server PolyBase Data Movement Optional

/PBDMSSVCACCOUNT
Specifies the account for data movement service. The default is NT Authority\NETWORK SERVICE.
SQL Server PolyBase Data Movement Optional

/PBDMSSVCPASSWORD
Specifies the password for the data movement account.
SQL Server PolyBase Data Movement Optional

/PBDMSSVCSTARTUPTYPE
Specifies the startup mode for the data movement service: Automatic (default), Disabled, and Manual.
PolyBase Optional

/PBSCALEOUT
Specifies whether the SQL Server instance is used as a part of a PolyBase scale-out computational group.
Supported values: True, False.
PolyBase Optional

/PBPORTRANGE
Specifies a port range with at least six ports for PolyBase services. Example:

/PBPORTRANGE=16450-16460

After installation, you must enable the PolyBase feature.

Example

This example shows a sample setup script.


Setup.exe /Q /ACTION=INSTALL /IACCEPTSQLSERVERLICENSETERMS /FEATURES=SQLEngine,PolyBase   
/INSTANCENAME=MSSQLSERVER /SQLSYSADMINACCOUNTS="\<fabric-domain>\Administrator"   
/INSTANCEDIR="C:\Program Files\Microsoft SQL Server" /PBSCALEOUT=TRUE   
/PBPORTRANGE=16450-16460 /SECURITYMODE=SQL /SAPWD="<StrongPassword>"   
/PBENGSVCACCOUNT="<DomainName>\<UserName>" /PBENGSVCPASSWORD="<StrongPassword>"   
/PBDMSSVCACCOUNT="<DomainName>\<UserName>" /PBDMSSVCPASSWORD="<StrongPassword>"  

Enable PolyBase

After installation, PolyBase must be enabled to access its features. To connect to SQL Server 2019 CTP 2.0, you must enable PolyBase after installation. Use the following Transact-SQL command.

exec sp_configure @configname = 'polybase enabled', @configvalue = 1;
RECONFIGURE [ WITH OVERRIDE ]  ;

The instance then must be restarted.

Post-installation notes

PolyBase installs three user databases, DWConfiguration, DWDiagnostics, and DWQueue. These databases are for PolyBase use. Don't alter or delete them.

How to confirm installation

Run the following command. If PolyBase is installed, the return is 1. Otherwise, it's 0.

SELECT SERVERPROPERTY ('IsPolyBaseInstalled') AS IsPolyBaseInstalled;  

Firewall rules

SQL Server PolyBase setup creates the following firewall rules on the machine:

  • SQL Server PolyBase - Database Engine - <SQLServerInstanceName> (TCP-In)

  • SQL Server PolyBase - PolyBase Services - <SQLServerInstanceName> (TCP-In)

  • SQL Server PolyBase - SQL Browser - (UDP-In)

At installation, if you use the SQL Server instance as part of a PolyBase scale-out group, these rules are enabled. The firewall opens to allow incoming connections. They're allowed for the SQL Server Database Engine, SQL Server PolyBase Engine, SQL Server PolyBase Data Movement service, and the SQL browser. If the firewall service on the machine isn't running during installation, SQL Server setup fails to enable these rules. In that case, start the firewall service on the machine and enable these rules post-installation.

To enable the firewall rules

  1. Open Control Panel.

  2. Select System and Security, and select Windows Firewall.

  3. Select Advanced Settings, and select Inbound rules.

  4. Right-click the disabled rule, and then select Enable rule.

PolyBase service accounts

To change the service accounts for the PolyBase Engine and PolyBase Data Movement service, uninstall and reinstall the PolyBase feature.

Next steps

See PolyBase configuration.