整合 NPSaaS 與 watsonx.data

您可以將 IBM® Netezza® Performance Server for IBM Cloud Pak® for Data as a Service 實例與 watsonx.data整合。

NPSaaS 提供對 watsonx.data SaaS 版本 2.3 及更早版本中 Metastore Thrift 端點的支援。

開始之前

遵循下列步驟,確定您已取得 IBM API 金鑰:

  1. 前往 https://cloud.ibm.com/

  2. 在頁面頂端的 管理 子功能表中,選取 存取權 (IAM)

  3. 按一下 服務 ID建立

  4. 提供 建立服務 ID 詳細資料。

  5. 存取 標籤上,執行下列動作:

    a. 按一下指派存取權

    b. 在 服務 搜尋欄位中,鍵入 watsonx.data,然後按一下它。 按下一步

    c. 在 資源 區段中,確定已選取 所有資源。 按下一步

    d. 在 角色和動作 區段中,選取 MetastoreAccess管理者,然後按 下一步

    e. 按一下 新增指派

  6. 點擊「API 金鑰」標籤頁,然後點擊「建立」。

  7. 提供 建立 API 金鑰 詳細資料。 您必須將 API 金鑰命名為 ibmlhapikey

使用 nzcli 整合 NPSaaS 實例或遠端用戶端與 watsonx.data。

  1. 下載 nz 工具。

    curl -o nz -k <name of the API server URL from namespace provisioning page>/v2/download/nz-linux-amd64
    
  2. 設定環境變數。

    export APISERVER_URL=<name of the API server URL from namespace provisioning page>
    export NZ_USER=<admin user name>
    export NZ_PASSWORD=<admin user password>
    
  3. 變更 nzcli 執行檔的許可權。

    chmod +x nz
    
  4. 使用 nz 工具來設定 HMS。

     ./nz setup-hms create -connection-name <your connection name> -hms-token <your API key obtained in the `Before you begin` section> -hms-user "ibmlhapikey" -url <thrift endpoint URL retrieved from watsonx.data instance>
    

其中:

  • url 節省端點 URL 是您從 watsonx.data 實例中檢索到的。 如需相關資訊,請參閱 取得 HMS 端點。 當您執行 nz setup-hms 指令時,也必須確定 url 採用下列 thrift://<host>:<port> 格式。
  • 依預設,hms-useribmlhapikey
  • hms-token 是在 開始之前 一節中取得的 API 金鑰。

登錄至 watsonx.data之後,您可以建立遠端資料庫。

  1. 登入 NPSaaS Web 主控台,或從 這裡 下載 nzsql 指令行工具。
  2. 從 watsonx.data查詢資料。 如需相關資訊,請參閱 查詢來自 watsonx.data的資料