SQL Server Launchpad 服務設定SQL Server Launchpad service configuration

適用範圍:Applies to: 是SQL ServerSQL Server (所有支援的版本) yesSQL ServerSQL Server (all supported versions) 適用範圍:Applies to: 是SQL ServerSQL Server (所有支援的版本) yesSQL ServerSQL Server (all supported versions)

SQL Server LaunchpadSQL Server Launchpad 是新服務,可管理和執行外部指令碼,就如同全文索引及查詢服務啟動個別的主機來處理全文查詢。The SQL Server LaunchpadSQL Server Launchpad is a service that manages and executes external scripts, similar to the way that the full-text indexing and query service launches a separate host for processing full-text queries.

如需詳細資訊,請參閱 SQL Server 機器學習服務的擴充性結構SQL Server 機器學習服務中擴充性架構的安全性概觀中的 Launchpad 章節。For more information, see the Launchpad sections in Extensibility architecture in SQL Server Machine Learning Services and Security overview for the extensibility framework in SQL Server Machine Learning Services.

帳戶權限Account permissions

根據預設,SQL Server Launchpad 會設定為在 NT Service\MSSQLLaunchpad 下執行,此帳戶已佈建用來執行外部指令碼的所有必要權限。By default, SQL Server Launchpad is configured to run under NT Service\MSSQLLaunchpad, which is provisioned with all necessary permissions to run external scripts. 從這個帳戶移除權限可能會導致 Launchpad 無法啟動或存取應執行外部指令碼的 SQL Server 執行個體。Removing permissions from this account can result in Launchpad failing to start or to access the SQL Server instance where external scripts should be run.

如果您修改服務帳戶,請務必使用本機安全性原則主控台If you modify the service account, be sure to use the Local Security Policy console.

下表列出此帳戶所需的權限。Permissions required for this account are listed in the following table.

群組原則設定Group policy setting 固定名稱Constant name
調整處理序的記憶體配額Adjust memory quotas for a process SeIncreaseQuotaPrivilegeSeIncreaseQuotaPrivilege
略過周遊檢查Bypass traverse checking SeChangeNotifyPrivilegeSeChangeNotifyPrivilege
登入為服務Log on as a service SeServiceLogonRightSeServiceLogonRight
取代處理序層級權杖Replace a process-level token SeAssignPrimaryTokenPrivilegeSeAssignPrimaryTokenPrivilege

如需執行 SQL Server 服務所需權限的詳細資訊,請參閱設定 Windows 服務帳戶與權限For more information about permissions required to run SQL Server services, see Configure Windows Service Accounts and Permissions.

設定屬性Configuration properties

一般而言,服務設定沒有理由需要修改。Typically, there is no reason to modify service configuration. 可以變更的屬性包括服務帳戶、外部處理序計數 (預設為20 個),或背景工作帳戶的密碼重設原則。Properties that could be changed include the service account, the count of external processes (20 by default), or the password reset policy for worker accounts.

  1. 開啟 SQL Server 組態管理員Open SQL Server Configuration Manager.

  2. 在 [SQL Server 服務] 底下,以滑鼠右鍵按一下 [SQL Server Launchpad],然後選取 [屬性] 。Under SQL Server Services, right-click SQL Server Launchpad and select Properties.

  • 若要變更服務帳戶,請按一下 [登入] 索引標籤。To change the service account, click the Log On tab.
  • 若要增加使用者數目,請按一下 [進階] 索引標籤,然後變更 [資訊安全內容計數] 。To increase the number of users, click the Advanced tab and change the Security Contexts Count.

注意

在舊版的 SQL Server 2016 R Services 中,您可以藉由編輯 R Services (資料庫內)R Services (In-Database) 設定檔來變更服務的某些屬性。In early versions of SQL Server 2016 R Services, you could change some properties of the service by editing the R Services (資料庫內)R Services (In-Database) configuration file. 此檔案不會再用來變更設定。This file is no longer used for changing configurations. SQL Server 組態管理員是用來變更服務設定 (例如,服務帳戶和使用者數目) 的正確方法。SQL Server Configuration Manager is the right approach for changes to service configuration, such as the service account and number of users.

偵錯設定Debug settings

有幾個屬性只能使用 Launchpad 的設定檔來加以變更,在偵錯之類的少數情況下,這可能很有用。A few properties can only be changed by using the Launchpad's configuration file, which might be useful in limited cases, such as debugging. 此設定檔會在 SQL ServerSQL Server 安裝期間建立,並且預設會以純文字檔案儲存在 <instance path>\binn\rlauncher.configThe configuration file is created during the SQL ServerSQL Server setup and by default is saved as a plain text file in <instance path>\binn\rlauncher.config.

您必須在執行 SQL ServerSQL Server 的電腦上身為系統管理員,才能對此檔案進行變更。You must be an administrator on the computer that is running SQL ServerSQL Server to make changes to this file. 如果您編輯了檔案,建議您在儲存變更前先備份副本。If you edit the file, we recommend that you make a backup copy before saving changes.

下表會列出 SQL Server 2019 (15.x)SQL Server 2019 (15.x) 的進階設定,以及允許的值。The following table lists the advanced settings for SQL Server 2019 (15.x)SQL Server 2019 (15.x), with the permissible values.

設定名稱Setting name 型別Type 說明Description
JOB_CLEANUP_ON_EXITJOB_CLEANUP_ON_EXIT 整數Integer 這只是內部設定,請勿變更此值。This is an internal setting only - do not change this value.
指定為每個外部執行階段工作建立的暫存工作資料夾,是否應該在該工作階段完成後清理乾淨。Specifies whether the temporary working folder created for each external runtime session should be cleaned up after the session is completed. 這項設定在偵錯時很有用。This setting is useful for debugging.

支援的值為 0 (停用) 或 1 (啟用)。Supported values are 0 (Disabled) or 1 (Enabled).

預設值為 1,表示會在結束時移除記錄檔。The default is 1, meaning log files are removed on exit.
TRACE_LEVELTRACE_LEVEL 整數Integer 設定 MSSQLLAUNCHPAD 的追蹤詳細資訊層級以進行偵錯。Configures the trace verbosity level of MSSQLLAUNCHPAD for debugging purposes. 這會影響 LOG_DIRECTORY 設定所指定路徑中的追蹤檔案。This affects trace files in the path specified by the LOG_DIRECTORY setting.
支援的值為:1 (錯誤)、2 (效能)、3 (警告)、4 (資訊)。Supported values are: 1 (Error), 2 (Performance), 3 (Warning), 4 (Information).

預設值為 1,表示只輸出錯誤。The default is 1, meaning output errors only.

所有設定都會採用機碼值組的格式,分別位於獨立的行。All settings take the form of a key-value pair, with each setting on a separate line. 例如,若要變更追蹤層級,您可以新增這行:Default: TRACE_LEVEL=4For example, to change the trace level, you would add the line Default: TRACE_LEVEL=4.

強制執行密碼原則Enforcing password policy

如果您的組織要求定期變更密碼,您可能需要強制 Launchpad 服務重新產生為其工作者帳戶維護的加密密碼。If your organization has a policy that requires changing passwords on a regular basis, you may need to force the Launchpad service to regenerate the encrypted passwords that Launchpad maintains for its worker accounts.

若要啟用此設定並強制密碼重新整理,請在 SQL Server 組態管理員中開啟 Launchpad 服務的 [屬性] 窗格,按一下 [進階] ,然後將 [重設外部使用者密碼] 變更為 [是] 。To enable this setting and force password refresh, open the Properties pane for the Launchpad service in SQL Server Configuration Manager, click Advanced, and change Reset External Users Password to Yes. 當您套用此變更時,系統會立即針對所有使用者帳戶重新產生密碼。When you apply this change, the passwords will immediately be regenerated for all user accounts. 若要在此變更之後執行外部指令碼,您必須重新啟動 Launchpad 服務,它就會讀取新產生的密碼。To run an external script after this change, you must restart the Launchpad service, at which time it will read the newly generated passwords.

若要定期重設密碼,您可以手動設定此旗標,或使用指令碼。To reset passwords at regular intervals, you can either set this flag manually or use a script.

後續步驟Next steps