zoukankan      html  css  js  c++  java
  • 学习:Using STSADM o migrateuser on a recreated account(转)


    Reference: http://blog.krichie.com/2008/06/27/using-stsadm-o-migrateuser-on-a-re-created-account/

    I see this come up quite a bit and thought I would show you how to work around the problem.  I thought I had show this on my old blog a couple of years ago, but can’t seem to find it.

    Scenario

    A user in your organization is deleted, and re-created using the same domain and sAMAccountName.  This may have been because of an accident, or a previous employee who left your organization and was then rehired. 

    For example, my account in the NA domain with a sAMAccountName of krichie (NA\krichie).   The account was deleted and re-created with the same sAMAccountName (NA\krichie)

    Because SharePoint stores SID information with the user in it’s tables, the account will no longer work until you either

    1) Remove the user completely and re-add, or

    2) Use the STSADM -o migrateuser command

    The problem, is that if you try to use -o migrateuser such as:

    STSADM -o migrateuser -oldlogin na\krichie -newlogin na\krichie -ignoresidhistory

    The command will fail reporting “Cannot complete this action…Please try again”

    Cause

    This is because the -oldlogin and -newlogin arguments are the same.  As far as stsadm -o migrateuser is concerned, there is nothing to migrate.

    Solution

    The solution is to migrate the user to a temporary account and then back from the temporary account to the new account with the same name such as:

    STSADM -o migrateuser -oldlogin na\krichie -newlogin na\temporaryaccount -ignoresidhistory

    STSADM -o migrateuser -oldlogin na\temporaryaccount -newlogin na\krichie -ignoresidhistory

    MigrateUser will then see that the accounts are different and allow the operation to be performed.  You then just run again from the temporary account to the new re-created account and your good to go.

    Comments

    SharePoint 迁移用户

    SharePoint迁移到不同的AD中时,可能会出现相同的用户名,
    但是在SharePoint中把他当成2个用户,需要通过STSADM进行进行替换:
    STSADM -o migrateuser -oldlogin na\krichie -newlogin na\temporaryaccount -ignoresidhistory

    STSADM -o migrateuser -oldlogin na\temporaryaccount -newlogin na\krichie -ignoresidhistory
     

    Migrateuser:Stsadm 操作 (Office SharePoint Server)

    将 Microsoft Office SharePoint Server 2007 中的用户帐户迁移到新的登录名和二进制 ID。如果已经存在一个新的登录名项,则会将该项标记为要进行删除以便进行迁移:将用户访问权限从一个域用户迁移到另一个域用户。
     

    Migrating SharePoint Forms Based Authentication Accounts

    For example:

    stsadm -o migrateuser -oldlogin “aspnetsqlmembershipprovider:user″ -newlogin”nanmumembershipprovider:user″ -ignoresidhistory
    Echo Liu at 4/22/2009 4:52 PM

    MigrateUserAccount by Code

    Use the api: SPFarm.MigrateUserAccount ,
    can migrateUserAccount By Code.
     
  • 相关阅读:
    ubuntu12.04 安装CAJViewer-ubuntu(待解决)
    ROS中遇到的一些问题和解决(更新)
    Virtualbox主机和虚拟机之间文件夹共享及双向拷贝
    Ubuntu自带截图工具screenshoot
    Ubuntu vim终端常用的快捷键
    Ubuntu终端多窗口分屏Terminator
    Apollo快速安装视频教程
    ML--XOR问题
    DL之Example1--MNIST
    Python之ML--人工神经网络识别图像
  • 原文地址:https://www.cnblogs.com/LeimOO/p/1530368.html
Copyright © 2011-2022 走看看