KB-STSADM.exe export "User cannot be Found" Problem
STSADM.exe 是 WSS / SPS 超級管理者工具,日前遇到一個 site export 問題,當執行以下指令時…
STSADM.exe -o export -url http://localhost/site/A -filename a.dat
會遇到錯誤訊息
FatalError: User cannot be Found.
at Microsoft.SharePoint.SPUserCollection.GetByID(Int32 id) at Microsoft.SharePoint.SPWeb.get_Author() at Microsoft.SharePoint.Deployment.WebSerializer.GetDataFromObjectModel(Object obj, SerializationInfo info, StreamingContext context) at Microsoft.SharePoint.Deployment.DeploymentSerializationSurrogate.GetObjectData(Object obj, SerializationInfo info, StreamingContext context) at Microsoft.SharePoint.Deployment.XmlFormatter.SerializeObject(Object obj, ISerializationSurrogate surrogate, String elementName, Boolean bNeedEnvelope) at Microsoft.SharePoint.Deployment.XmlFormatter.Serialize(Stream serializationStream, Object topLevelObject) at Microsoft.SharePoint.Deployment.ObjectSerializer.Serialize(DeploymentObject deployObject, Stream serializationStream) at Microsoft.SharePoint.Deployment.SPExport.SerializeObjects() at Microsoft.SharePoint.Deployment.SPExport.Run()
拜了 Google 大神後,竟然沒有解法,只有零星的 News 中,有提到是換 Domain 問題造成,再加入舊的 Domain 執行後就成功…之類的解法。
後來…與黑暗大哥討論了之後,決定從 內容資料庫 Content DB 著手。
找到了以下幾個資料表與欄位與 User 相關,供大家尋找失聯的 User 欄位
- AllDocs.SetupPathUser
- AllLists.tp_Author
- AllUserData.tp_Author
- AllUserData.tp_Editor
- Webs.Author
- Versions.UserName
以上的欄位都是 Integer ,真正 User 是存在 UserInfo ,可以將失聯的 User 找另一個取代
(1073741823 似乎是 SharePoint/SYSTEM 系統帳戶,可以用這個 ID 取代失聯 UserID)
另外,匯出之前,請先清除以下項目
- 網站動作(Site Action)->網站設定->網站管理(Tab)->內容與結構記錄檔
- 清除資料回收筒
這個問題,我拜了三天Google大神都沒有結果,後來是黑暗大哥銷假上班才獲救...
1 則留言:
Very good posting. It digged deep to the database table levels, unbeleivable!
張貼留言