在 SharePoint Server 2016 中使用自動的服務帳戶設定 Excel Services 資料重新整理Configure Excel Services data refresh by using the unattended service account in SharePoint Server 2016

摘要:設定 Excel Services in SharePoint Server 2013 的外部資料驗證使用自動的服務帳戶。Summary: Configure Excel Services in SharePoint Server 2013 to use the unattended service account for authentication to external data.

SharePoint Server 2013 的 Excel Services 提供三種使用 Secure Store Service 在活頁簿中重新整理外部資料來源的方法:Excel Services in SharePoint Server 2013 provides three methods of using Secure Store Service to refresh the external data source in a workbook:

設定 Active Directory 帳戶並授與其存取您的資料、 Secure Store 中儲存為此帳戶認證和設定 Excel Services 使用儲存的認證時需要使用自動的服務帳戶需要執行重新整理活頁簿中的資料。Using the unattended service account involves configuring an Active Directory account and granting it access to your data, storing the credentials for this account in Secure Store, and configuring Excel Services to use the stored credentials when it needs to refresh the data in a workbook.

若要設定 Excel Services 自動的服務帳戶需要下列步驟。The following steps are required to configure the unattended service account in Excel Services.

  1. 設定資料存取帳戶Configure a data access account

  2. 設定 Excel Services 通用設定Configure Excel Services Global Settings

  3. 設定活頁簿使用自動的服務帳戶Configure a workbook to use the unattended service account

設定資料存取帳戶Configure a data access account

自動服務帳戶需要 Active Directory 帳戶以進行資料存取。請讓網域管理員建立您可用來存取資料的 Active Directory 帳戶。The unattended service account requires an Active Directory account for data access. Have your domain administrator create an Active Directory account that you can use for data access.

建立帳戶之後,您必須授與您將會使用資料連線 Excel 活頁簿中的資料來源此帳戶讀取權。若要建立資料存取帳戶的登入 SQL Server 中使用下列程序。(如果您使用 SQL Server 以外的資料來源,請參閱您具有資料讀取權限的資料存取帳戶建立登入的資料來源的指示)。After the account has been created, you must grant this account read access to the data source that you will be using in your data-connected Excel workbook. Use the following procedure to create a logon for the data access account in SQL Server. (If you are using a data source other than SQL Server, see the instructions for your data source to create a logon with data-read permissions for the data access account.)

若要建立資料存取帳戶的 SQL Server 登入To create a SQL Server logon for the data access account

  1. 在 SQL Server Management Studio 中,連線至資料庫引擎。In SQL Server Management Studio, connect to the database engine.

  2. 在 [物件總管] 中,展開 [安全性]。In Object Explorer, expand Security.

  3. 在 [登入] 上按一下滑鼠右鍵,然後按一下 [新增登入]。Right-click Logins, and then click New Login.

  4. 在 [登入名稱] 方塊中,輸入您為資料存取所建立的 Active Directory 帳戶名稱。In the Login name box, type the name of the Active Directory account that you created for data access.

  5. 在 [選取頁面] 區段中,按一下 [使用者對應]。In the Select a page section, click User Mapping.

  6. 選取您想要提供存取,然後在 [資料庫對應] 核取方塊資料庫角色成員資格:<資料庫>] 區段中,選取 [ db_datareader]核取方塊。Select the Map check box for the database that you want to provide access to, and then, in the Database role membership for: <database> section, select the db_datareader check box.

  7. 按一下 [ OK ]。Click OK.

現在,您已為資料存取帳戶建立登入資料,並授權帳戶可以存取資料來源,您必須在 Secure Store 中建立目標應用程式,以包含資料存取帳戶的認證。Now that you have created a logon for the data access account and granted the account access to your data source, you must create a target application in Secure Store to contain the credentials for the data access account.

設定 Excel Services 通用設定Configure Excel Services Global Settings

自動的服務帳戶設定為 Excel Services 通用設定] 的一部分。使用下列程序來設定 Excel Services 自動的服務帳戶。The unattended service account configuration is part of the Excel Services Global Settings. Use the following procedure to configure the unattended service account in Excel Services.

設定 Excel Services 通用設定To configure Excel Services Global Settings

  1. 在 SharePoint 管理中心網站首頁上,按一下 [應用程式管理] 區段中的 [管理服務應用程式]。On the the SharePoint Central Administration website home page, in the Application Management section, click Manage service applications.

  2. 在 [管理服務應用程式] 頁面上,按一下 [Excel Services 服務應用程式。On the Manage Service Applications page, click the Excel Services service application.

  3. 在 [管理 Excel Services] 頁面中,按一下 [通用設定]。On the Manage the Excel Services page, click Global Settings.

  4. 在 [Excel Services 設定] 頁面的 [外部資料] 區段中:On the Excel Services Settings page, in the External Data section:

    • 選取 [建立新的自動服務帳戶] 選項。Select the Create a new Unattended Service Account option.

    • 為您建立的資料存取帳戶輸入使用者名稱與密碼。Type the user name and password of the account that you created for data access.

  5. 按一下 [ OK ]。Click OK.

以 Excel Services 通用設定設定自動的服務帳戶的安裝程式已完成。下一節說明如何在活頁簿發佈至 SharePoint 文件庫之後,重新整理與自動的服務帳戶的資料的資料連線 Excel 活頁簿中設定 Excel Services 驗證設定。With the Excel Services Global Settings configured, setup of the unattended service account is complete. The next section describes how to configure the Excel Services authentication settings in a data-connected Excel workbook to refresh the data with the unattended service account after the workbook has been published to a SharePoint document library.

設定活頁簿使用自動服務帳戶Configure a workbook to use the unattended service account

您必須在將活頁簿中設定 Excel Services 驗證設定之前將它發佈至 SharePoint Server 2013。如此可讓活頁簿使用自動的服務帳戶重新整理資料的 Excel services 轉譯活頁簿時。使用下列程序可設定的驗證設定。You must configure the Excel Services Authentication Settings in the workbook before you publish it to SharePoint Server 2013. Doing so enables the workbook to use the unattended service account to refresh data when the workbook is rendered in Excel Services. Use the following procedure to configure the authentication settings.

設定 Excel Services 驗證設定To configure Excel Services authentication settings

  1. 在資料連線的 Excel 活頁簿之 [資料] 索引標籤上,按一下 [連線]。In a data-connected Excel workbook, on the Data tab, click Connections.

  2. 在 [活頁簿連線] 對話方塊上,選取您要更新的資料連線,然後按一下 [內容]。On the Workbook Connections dialog box, select the data connection that you want to update, and then click Properties.

  3. 在 [連線內容] 對話方塊中,按一下 [定義] 索引標籤上的 [驗證設定]。On the Connection Properties dialog box, on the Definition tab, click Authentication Settings.

  4. 在 [ Excel Services 驗證設定] 對話方塊中,選取 [] 選項,然後再按一下 [確定]On the Excel Services Authentication Settings dialog box, select the None option, and then click OK.

  5. 在 [連線內容] 對話方塊中,按一下 [確定]。On the Connection Properties dialog box, click OK.

    注意

    如果您看到一個警告,指出外部連線檔案的連結會被移除,請按一下 [是]。If you see a warning that the link to the external connection file will be removed, click Yes.

  6. 在 [活頁簿連線] 對話方塊中,按一下 [關閉]。On the Workbook Connections dialog box, click Close.

設定成 [Excel Services 驗證設定] 與 Excel Services 自動的服務帳戶之後使用重新整理活頁簿中的資料發佈至 SharePoint Server 2013。With the Excel Services Authentication Settings set to None, Excel Services uses the unattended service account to refresh the data in the workbook after you have published it to SharePoint Server 2013.

另請參閱See also

概念Concepts

使用 Excel Services 搭配 Secure Store Service in SharePoint Server 2016Use Excel Services with Secure Store Service in SharePoint Server 2016