Kerberos
集群實例 - kerberos 雙跳問題
我們最近將虛擬化 SQL 數據庫遷移到主動/主動集群中的裸機解決方案。除了 SQL 報告之外,一切都執行良好。
好的,這裡是我們設置的概要,因為它與 SQL 和報告有關:
- XXYYSQ01 是我們舊的虛擬 SQL 伺服器,現在執行 Reporting Services。
- XXYYSQ1 是一個新的 SQL 伺服器,在裸機上執行。它不包含我們試圖訪問的數據庫。
- XXYYSQ2 是另一個新的裸機 SQL 伺服器。它執行我們要訪問的數據庫。
- SQLCLUSTERDB\DATABASE 是託管我們希望訪問的數據庫的集群實例的名稱。
現在,當有人在他們的桌面上訪問報告服務網站並嘗試執行報告時,他們會收到可怕的**Login failed for user ‘NT AUTHORITY\ANONYMOUS LOGON’**錯誤。因此,我針對 Reporting Services 的服務使用者添加了所需的 SPN:
H:\>setspn -L DOMAIN\ssrs-user Registered ServicePrincipalNames for CN=ssrs-user,OU=Systems,DC=domain,DC=local: MSSQLSvc/SQLCLUSTERDB.domain.local:DATABASE MSSQLSvc/SQLCLUSTERDB:DATABASE http/xxyysq01
刷新和….仍然無法正常工作。我的 Google 搜尋使我將服務使用者添加到該**法案作為作業系統的一部分,並在驗證使用者權限後模擬客戶端。**依然沒有。
我前往錯誤日誌。XXYYSQ01 提供以下內容:
An account was successfully logged on. Subject: Security ID: NULL SID Account Name: - Account Domain: - Logon ID: 0x0 Logon Type: 3 New Logon: Security ID: DOMAIN\amason Account Name: amason Account Domain: DOMAIN Logon ID: 0x2d70c77c4 Logon GUID: {955a0a82-c5cf-ca60-d063-cc4a32a363be} Process Information: Process ID: 0x0 Process Name: - Network Information: Workstation Name: Source Network Address: - Source Port: - Detailed Authentication Information: Logon Process: Kerberos Authentication Package: Kerberos Transited Services: - Package Name (NTLM only): - Key Length: 0 This event is generated when a logon session is created. It is generated on the computer that was accessed. The subject fields indicate the account on the local system which requested the logon. This is most commonly a service such as the Server service, or a local process such as Winlogon.exe or Services.exe. The logon type field indicates the kind of logon that occurred. The most common types are 2 (interactive) and 3 (network). The New Logon fields indicate the account for whom the new logon was created, i.e. the account that was logged on. The network fields indicate where a remote logon request originated. Workstation name is not always available and may be left blank in some cases. The authentication information fields provide detailed information about this specific logon request. - Logon GUID is a unique identifier that can be used to correlate this event with a KDC event. - Transited services indicate which intermediate services have participated in this logon request. - Package name indicates which sub-protocol was used among the NTLM protocols. - Key length indicates the length of the generated session key. This will be 0 if no session key was requested.
XXYYSQ2 給了我:
An account was successfully logged on. Subject: Security ID: NULL SID Account Name: - Account Domain: - Logon ID: 0x0 Logon Type: 3 New Logon: Security ID: ANONYMOUS LOGON Account Name: ANONYMOUS LOGON Account Domain: NT AUTHORITY Logon ID: 0xe684d0c85 Logon GUID: {00000000-0000-0000-0000-000000000000} Process Information: Process ID: 0x0 Process Name: - Network Information: Workstation Name: XXYYSQ01 Source Network Address: - Source Port: - Detailed Authentication Information: Logon Process: NtLmSsp Authentication Package: NTLM Transited Services: - Package Name (NTLM only): NTLM V1 Key Length: 128 This event is generated when a logon session is created. It is generated on the computer that was accessed. The subject fields indicate the account on the local system which requested the logon. This is most commonly a service such as the Server service, or a local process such as Winlogon.exe or Services.exe. The logon type field indicates the kind of logon that occurred. The most common types are 2 (interactive) and 3 (network). The New Logon fields indicate the account for whom the new logon was created, i.e. the account that was logged on. The network fields indicate where a remote logon request originated. Workstation name is not always available and may be left blank in some cases. The authentication information fields provide detailed information about this specific logon request. - Logon GUID is a unique identifier that can be used to correlate this event with a KDC event. - Transited services indicate which intermediate services have participated in this logon request. - Package name indicates which sub-protocol was used among the NTLM protocols. - Key length indicates the length of the generated session key. This will be 0 if no session key was requested.
和:
Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'. Reason: Token-based server access validation failed with an infrastructure error. Check for previous errors. [CLIENT: RE.DA.CT.ED]
啊。
我在這裡有什麼遺漏嗎?我可以從 XXYYSQ01 本身很好地執行報告,所以我確定這是一個雙跳問題。但是,從我所閱讀的內容來看,到目前為止我所做的應該可以解決這個問題。我檢查了沒有重複的 SPN。
我還在 rsreportserver.config 文件中將身份驗證更改為 Negotiate/Kerberos。連接字元串是Server=SQLCLUSTERDB\DATABASE;Initial Catalog=DataBase
任何幫助都將不勝感激。
找到它 - 解決方案是授予服務帳戶訪問權限以創建自己的 SPN。為此,只需授予 SELF 讀取和寫入 servicePrincipalName 欄位:
完成此操作後,您需要重新啟動 SQL 服務。 不要將服務管理單元與集群 SQL 伺服器一起使用!故障轉移群集服務會將其視為故障並將其切斷。