Help! My portable homes cannot be recreated.

OK. This is one in the "Help!"-category. I followed instructions by Apple Engineer John DeTroye about resetting FileSync/PHD:
- Delete local account and home dir (will be recreated at login)
- On the server:
- Delete ~/.FileSync
- Delete ~/Library/FileSync
But now, when I try to recreate the mobile account, it is created, but the server side home directory is not synced. I end up with an empty account.
As my server is headless and in a location I cannot work (screen sharing does work but the server does not have stuff like Microsoft Office installed) I am now effectively without a working account and I need my stuff desperately.
On the client, system.log reports errors. Stuff like:
Jun 22 13:57:20 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: Failed (errno=2) to open log file at "/Users/gerben/Library/Logs/FileSyncAgent/FileSyncAgent-verbose.log". Using syslog() instead.
Jun 22 13:57:20 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: 0:: [2417] [2008/06/22 13:57:20.456] SIGTERMCallout: 2008-06-22 13:57:20 +0200
Jun 22 13:57:21 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: 0:: [2417] [2008/06/22 13:57:21.423] EXCEPTION: Cocoa error 134030 <+[SSyncSet commitToDisk] (SyncSet.m:330): "(Error Domain=NSCocoaErrorDomain Code=134030 UserInfo=0x515600 "An error occurred while saving.")">\n0:: [2417] [2008/06/22 13:57:21.423] USERINFO: {\n0:: [2417] [2008/06/22 13:57:21.423] NSAffectedStoresErrorKey = (\n0:: [2417] [2008/06/22 13:57:21.4
23] <NSSQLCore: 0x52e300>\n0:: [2417] [2008/06/22 13:57:21.423] );\n0:: [2417] [2008/06/22 13:57:21.423] NSFilePath = "/Users/gerben/Library/FileSync/0016cbcec680/SyncSets";\n0:: [2417] [2008/06/22 13:57:21.423] NSUnderlyingError = Error Domain=NSCocoaErrorDomain Code=4 UserInfo=0x52eac0 "The file d
oes not exist.";\n0:: [2417] [2008/06/22 13:57:21.423] }\n0:: [2417] [2008/06/22 13:57:21.423] BACKTRACE: {\n0:: [2417] [2008/06/22 13:57:21.423] ? | 0xc2f6 \n0:: [2417] [2008/06/22 13:57:21.423] ? | 0x6b079\n0:: [2417] [2008/06/22 13:57:21.423] ? | 0x7fdbe\n0:: [2417] [2008/06/22 13:57:21.423] ? | 0x2a16 \n0:: [2417] [2008/06/22 13:57:21.423] }
Jun 22 13:57:21 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: [2008/06/22 13:57:21.424] +[SSyncSet commitToDisk]: exception thrown while saving (+[SSyncSet commitToDisk] (SyncSet.m:330): "(Error Domain=NSCocoaErrorDomain Code=134030 UserInfo=0x515600 "An error occurred while saving.")").
Jun 22 13:57:21 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: 0:: [2417] [2008/06/22 13:57:21.424] +[SSyncSet commitToDisk]: exception thrown while saving (+[SSyncSet commitToDisk] (SyncSet.m:330): "(Error Domain=NSCocoaErrorDomain Code=134030 UserInfo=0x515600 "An error occurred while saving.")").
Jun 22 13:57:21 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: [2008/06/22 13:57:21.446] Bye (PID:2417)
Jun 22 13:57:21 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: 0:: [2417] [2008/06/22 13:57:21.446] Bye (PID:2417)
Jun 22 13:57:21 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: Failed (errno=2) to open log file at "/Users/gerben/Library/Logs/FileSyncAgent.log". Using syslog() instead.
Jun 22 13:57:21 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: [2008/06/22 13:57:21.447] EXCEPTION: File Not Found
Jun 22 13:57:21 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: Failed (errno=2) to open log file at "/Users/gerben/Library/Logs/FileSyncAgent/FileSyncAgent-verbose.log". Using syslog() instead.
Jun 22 13:57:21 hermione-a /System/Library/CoreServices/FileSyncAgent.app/Contents/MacOS/FileSyncAgent[241 7]: 0:: [2417] [2008/06/22 13:57:21.448] EXCEPTION: File Not Found <SetExclusionEA (Utilities.m:412): "'((setxattr (cPath, "com.apple.metadata:" "FileSyncAgentExcludeItem", "Y", 1, 0, 0x0001)))' error 2">\n0:: [2417] [2008/06/22 13:57:21.448] USERINFO: {\n0:: [2417] [2008/06/22 13:57:21.448] NSLocalizedDescription = "File Not Found";\n0:: [2417] [2008/06/22 13:57:21.448] }\n0:: [2417] [2008/06/22 13:57:21.448] BACKTRACE: {\n0:: [2417] [2008/06/22 13:57:21.448] ? | 0xac0f7\n0:: [2417] [2008/06/22 13:57:21.448] ? | 0xae6e1\n0:: [2417] [2008/06/22 13:57:21.448] ? | 0xae71d\n0:: [2417] [2008/06/22 13:57:21.448] ? | 0x7ff01\n0:: [2417] [2008/06/22 13:57:21.448] ? | 0x2a16 \n0:: [2417] [2008/06/22 13:57:21.448] }
Other notable things: the account is a FileVaulted account (as it was before. I will be trying to do this without FileVault, but that should not matter)
Help?

Additional info:
I remembered the existence of /Library/Managed Preferences. I removed the user's entry there and then logged out. To my surprise, syncing started at log out (running now). So it seems /Library/Managed Preferences was playing foul with recreation of the PHD. I am now going to do a recreate of the same user on another desktop but remove the subdir of Managed Preferences first.
Maybe this is a bug? Removing a local account foo should also remove "/Library/Managed Preferences/foo"?

Similar Messages

  • Help with Portable Home Directories and AD

    Is it possible to implement "Portable Home Directories" without an Open Directory server, using just binding to an Active Directory Domain. (no "Golden Triangle")?
    We are just starting to integrate Macs into our company (finally!) and I'm looking for the best way to allow Macbook Pro users to have their files sync'ed with their NW home folder and still available locally when they are offline.
    I'm able to bind to AD successfully but can't find any documentation on how to make the sync happen.
    Thanks

    If you are putting Macs in a LARGE business environment then bookmark the site www.MacWindows.com. They do nothing then connect lone macs into Windows Domains. Pay attention to the links on side panel of the slash page to get to the section you want to read the reader reports.

  • Portable Home Directories on ReadyNAS

    I have a MacMini runing OS X 10.6 in an environment with about 15 users.  Portable Home Directories are currently setup and working on the server.  The server is almost out of space and I would like to move these PHD's to a ReadyNAS and have them sync properly.
    I am having a tough time figuring this out.  I have created shares on the ReadyNAS and can access the shares without a problem.
    Through Server Admin I have tried both AFP and NFS shares.  I can successfully create a user's home drive on either type of share. 
    When I share by NFS I can log in as a user and it tries to begin syncing.  It gets stuck on connecting to network drive and then gives me an error that the NFS share is not available.
    If I share via AFP I get a message that says the user cannot login due to an error. 
    I have searched quite a bit and have found that PHD's are not documented very well.  Does anyone have experience with PHD's and a ReadyNAS?  If so I would appreciate any help.

    Hi Guys, So far I have found what seems to be a fix for this issue. I was also having the issue happen to me around some iphoto file but that seems to be coincidental. I will detail what I did below but please first backup the mobile account on the local machine as you will need to recreate it.
    Backup the local mobile home folder
    Log into a admin account and delete the mobile account under the Accounts Pane in System Prefs
    Log into the users Network account on the notebook
    Delete all the following items
    ~/Library/Application Support/SyncServices
    ~/Library/Mirrors
    ~/Library/Preferences/ByHost/com.apple.syncservices.*
    ~/Library/Preferences/com.apple.filesync.plist
    ~/Library/Preferences/com.apple.homesync.plist
    ~/Library/Preferences/com.apple.LaunchServices.plist
    ~/Library/Preferences/com.apple.syndication.plist
    ~/Library/Preferences/Syndication
    Logout of the Network account and then back in
    Recreate the Mobile Account
    From this point on I have not seen any issues with the FileSyncAgent crashing. Omit any of the files listed above that do not exist. I generally have the notebooks sync on login and logout and I forced a sync while logged in to make sure everything was okay and so far so good. Hope this helps.

  • Portable Home Directory no longer works on Lion bound to Active DirectoryAD

    Hi, All,
    I look after about 30 MacBook Air/Pro connected to a predominantly Windows corporate network.
    A few months back, I installed a MacOS Server running OpenDirectory and Software Update Services for managing the MacBooks - they are configured in the standard "magic triangle" configuration, bound both to the Active Directory (running on a handfull of Windows 2003-R2 servers) and OpenDirectory; they are configured to use the Mac Server for Software Updates, and with Portable Home Directories replicated on a network share point (through AFP) to keep a backup of the user's data.
    When all the MacBooks were running Snow Leopard, everything was running fine... but the last couple of laptops purchased came with Lion and they cannot synchronise their PHD's anymore :-(
    I have spent a lot of time trying to pin-point the problem, including replicating a whole test-network with its own AD/OD and client Snow-Leopard/Lion laptops to try various configurations... my conclusions so far are that:
    1- using Snow Leopard clients, it just works
    2- using a Lion client, when the network user account is configured in the default Users O.U. on Active Directory, it just works
    3- using a Lion client, when the network user account is configured in another O.U. than Users (e.g. Company-Name or External-Contractors), then the PHD syncinc doesn't work at all
    4- the failure symptoms are a popup window when trying to do a manual sync saying that "your network home at (null) does not allow writing" - if automatic syncing is configured through MCX, it just fails silently
    5- when PHD syncing fails, I can log on using the network account, manually mount the share point used for the network home in the Finder and read and write to it without a problem; so it' not a permission problem, but the fact that the network home directory is (null)
    6- I have traced the root cause to the FileSyncAgent process which raises an exception at startup - here's what I see as the salient lines from the logfile (i've edited out the username):
    0:: [12/02/07 12:45:00.512] ******************************************************************************
    0:: [12/02/07 12:45:00.512] FileSyncAgent-502.2 (r?, BUILT:?, PID:385, OS:11D50b, ARCH:x86_64-64) starting
    0:: [12/02/07 12:45:00.512] LA: FileSyncAgent -launchedByLaunchd -iDiskPlist
    0:: [12/02/07 12:45:00.512] ******************************************************************************
    0:: [12/02/07 12:45:00.512] Engineering log verbosity level = 1
    1:: [12/02/07 12:45:00.512] Registered isRunning port with name 'com.apple.FileSyncAgent.iDisk.isRunning'
    1:: [12/02/07 12:45:00.846] Temporary disk storage at "/Users/[USERNAME]/Library/Caches/Cleanup At Startup/FileSyncAgent-1727909307".
    1:: [12/02/07 12:45:00.846] UserAgentString = "DotMacKit-like, File-Sync-Direct/502.2.? (11D50b x86_64-64)"
    1:: [12/02/07 12:45:03.249] +[SSyncSet_PHD createPHDSyncSetForLocalPath:remoteHomeSpec:mountSuffixPath:name:]: Creating Sync Set with name "HomeSync_Mirror".
    1:: [12/02/07 12:45:03.249] -[SSyncSet_PHD _setupNewPHDSyncSetWithLocalPath:homeSpec:mountSuffixPath:]: We've been given local home path '/Users/[USERNAME]'.
    1:: [12/02/07 12:45:03.249] -[SSyncSet_PHD _setupNewPHDSyncSetWithLocalPath:homeSpec:mountSuffixPath:]: local home at "/Users/[USERNAME]"
    <PHD> 1:: [12/02/07 12:45:06.458] Added new sync set "HomeSync_Mirror".
    <PHD> 1:: [12/02/07 12:45:06.465] _incomingIPC: SFCreatePHDSyncSetMsgId (17) took 3.217627 seconds.
    <PHD> 1:: [12/02/07 12:45:06.526] Scheduling next sync of "HomeSync_Mirror" at 2012-02-07 12:45:16 +0000
    <PHD> 1:: [12/02/07 12:45:18.122] ==========================================================
    <PHD> 0:: [12/02/07 12:45:18.123] Starting automatic sync of "HomeSync_Mirror".
    <PHD> 1:: [12/02/07 12:45:18.126] Peer "local" reports changes since last sync.
    <PHD> 0:: [12/02/07 12:45:18.128] EXCEPTION: NilPtr <-[SPeer_FS_PHD mountPeerVolume] (Peer-FS-PHD.m:142): "'((homePath))' is nil">
    <PHD> 0:: [12/02/07 12:45:18.128] BACKTRACE: {
    <PHD> 0:: [12/02/07 12:45:18.128] ? | 0x105003493  
    <PHD> 0:: [12/02/07 12:45:18.128] ? | 0x104f70866  
    <PHD> 0:: [12/02/07 12:45:18.128] ? | 0x104f6fabd  
    <PHD> 0:: [12/02/07 12:45:18.128] ? | 0x104f6ecb4  
    <PHD> 0:: [12/02/07 12:45:18.128] ? | 0x7fff924bb74e
    <PHD> 0:: [12/02/07 12:45:18.128] ? | 0x7fff924bb6c6
    <PHD> 0:: [12/02/07 12:45:18.128] ? | 0x7fff901998bf
    <PHD> 0:: [12/02/07 12:45:18.128] ? | 0x7fff9019cb75
    <PHD> 0:: [12/02/07 12:45:18.128] }
    7- if I use the same user account from a Snow-Leopard client, the mountPeerVolume finds the remote home_dir, mounts it and happilly trawls through the two directories to figure out what needs to be copied; I get something along the lines of:
    0:: [12/02/08 18:44:15.344] Starting manual sync of "HomeSync_Mirror".
    1:: [12/02/08 18:44:15.363] -[SPeer_FS_PHD mountPeerVolume]: We've been given remote home path "/Volumes/[USERNAME]".
    1:: [12/02/08 18:44:15.363] -[SPeer_FS_PHD mountPeerVolume]: Remote home path exists.
    1:: [12/02/08 18:44:15.363] -[SPeer_FS_PHD mountPeerVolume]: Final path to PHD remote home root = "/Volumes[USERNAME]"
    8- if I use a Lion client and a user account configured in the Users O.U. on Active Directory, it works similarly well
    9- in the failing use-case, if I run a "dscl xxx -read /Users/xxx" to verify that the DirectoryServices deamon returns some information, all looks good: I get all my A.D. user details, including email config and network home_directory, the MCX payload, etc
    10- the only difference that I can see when running dscl between the "working use-case" and the "failing use-case" is that the Attribute for the network home directory is called HomeDirectory (working) or OriginalHomeDirectory (failing) - but the actual value is present and correct in both cases
    11- I have enabled SMB as well as AFP file sharing to ensure that it's not a protocol problem rather than the share point itself that causes problem - no difference
    12- I have upgraded the MacOS Server to 10.7.3 (from 10.7.2) - no difference
    13- I have upgraded the Lion client from 10.7.2 to 10.7.3 - no difference
    14- I have tried to manually configure the Directory Search path on the Lion client to map HomeDirectory to OriginalHomeDirectory - either the mapping didn't work or it's not the real cause of the problem, as again: no difference.
    15- I have contacted AppleCare, raised a case with all the details above, been escalated from level 1 to 2 and 3 - and basically have been told that customers have reported very similar problems & that no more detail is available to me as it is a Directory Services related problem - if I want to take it further with Apple, I need Enterprise OS Support (and hence $1000s per year - and no real guarantee of result)
    [thanks to anyone who's read until now]...
    So my questions are (as I can't believe that I'm the only one using "proper O.U.'s" for managing users in Active Directory):
    - has anyone experienced this before?
    - does someone know of a workaround (other than "stick to SnowLeo" or "redesign your whole A.D."!)?
    - can someone help me figure out where the FileSyncAgent process tries to get its remote home directory from - as this might point to a solution?
    Many thanks

    I was able to fix the issue here. Steps Taken:  From the comand line I ran
    dscl /Search read /Users/jdoe HomeDirectory
    It returned # No such key: HomeDirectory
    This was the big clue.... it should have returned
    HomeDirectory: <home_dir><url>afp://files.hihllc.lan/Users/jdoe</url><path>/</path></home_dir>
    I unbound the Mac from AD and ran the following command in terminal.
    dscacheutil -flushcache
    I then went into OS X sharing preferences and renamed the computer slightly, so it would create a new computer record in AD. I rebound the machine to AD making sure in Directory Utility Advanced, under User Experience that Force local home directory on start up disk was unchecked and Network protocol to be used was AFP.
    I then ran
    dscl /Search read /Users/jdoe HomeDirectory
    and it returned
    HomeDirectory: <home_dir><url>afp://files.hihllc.lan/Users/jdoe</url><path>/</path></home_dir>
    I had the user reboot... which was necessary. When he logged in HomeSync fired up. He had quite a few conflicts, so I told him to select use files on this computer for all conflicts.
    I checked the FileSyncAgent.logs and it was good.
    Let me know if this fixes your issue.
    Thanks,
    Ray

  • Portable Home Directories, FileSyncAgent, and Case-sensitive drives

    I have a 10.5.3 Server machine that is serving (via NFS) home directories to a mixed group of Leopard (10.5.3) and Linux clients. The drive containing user home directories is formatted to be case-sensitive. I also use Portable Home Directories and mobile accounts on all the Leopard clients. Many of the client machines have case-insensitive drives.
    FileSyncAgent is dying on the client machines with a lot of "Reverification failed" messasges in ~/Library/Logs/FileSyncAgent.log. The files being verified often have mixed case file names, while the error messages show lower case file names.
    Anyone else seeing FileSyncAgent dying on every home sync?

    Hi Guys, So far I have found what seems to be a fix for this issue. I was also having the issue happen to me around some iphoto file but that seems to be coincidental. I will detail what I did below but please first backup the mobile account on the local machine as you will need to recreate it.
    Backup the local mobile home folder
    Log into a admin account and delete the mobile account under the Accounts Pane in System Prefs
    Log into the users Network account on the notebook
    Delete all the following items
    ~/Library/Application Support/SyncServices
    ~/Library/Mirrors
    ~/Library/Preferences/ByHost/com.apple.syncservices.*
    ~/Library/Preferences/com.apple.filesync.plist
    ~/Library/Preferences/com.apple.homesync.plist
    ~/Library/Preferences/com.apple.LaunchServices.plist
    ~/Library/Preferences/com.apple.syndication.plist
    ~/Library/Preferences/Syndication
    Logout of the Network account and then back in
    Recreate the Mobile Account
    From this point on I have not seen any issues with the FileSyncAgent crashing. Omit any of the files listed above that do not exist. I generally have the notebooks sync on login and logout and I forced a sync while logged in to make sure everything was okay and so far so good. Hope this helps.

  • Portable Home Directory Syncing Problem

    Portable home directory syncing sometimes cannot complete, and stuck at "Checking "~/"". Looking at Console message shows the following:
    1:: 09/09/03 21:01:12.562 -SSHIPCClient handleStderrLineOrEOF:: 2009-09-03 21:01:12 -0700 'Pseudo-terminal will not be allocated because stdin is not a terminal.
    1:: 09/09/03 21:01:12.562 '
    1:: 09/09/03 21:01:12.657 -SSHIPCClient handleStderrLineOrEOF:: 2009-09-03 21:01:12 -0700 'Warning: Permanently added '\[server.domain.com\]:2336' (RSA) to the list of known hosts.
    1:: 09/09/03 21:01:12.657 '
    and that's it. it'll go forever unless I force quit loginwindow. Because if I try to logout, it will get stuck on logout syncing, presumably at the same point. Afterward, I can login and sync normal... for a while.
    Under "All Messages" and "Console Message" nothing shows around that time.
    When it does sync correctly, the the following messages go after what I had above:
    1:: [09/09/10 18:52:30.663] Remote peer greeting: 'com.apple.FileSync-2.0.0 FileSyncAgent-359 r? OKAY pid=1188'
    1:: [09/09/10 18:52:30.663] okayBusy = 'OKAY'
    Also, on the server's console message, the corresponding greeting does show up even when the client doesn't receive it. The clients forward/reverse DNS works fine on server and client.
    The problem happens to ALL the clients, which lead me to think it must be a setting error on my end rather than a bug. But I can't figure out what.
    Please help..

    I finally figured it out. The trouble was that it was syncing ~/Library/FileSync from the mini, where syncing was failing. The solution was to exclude this folder from the list of folders I was syncing.

  • Portable Home Directories - Migrating from a PowerBook to MacBook Pro

    On my Powerbook, I'm using one account as PHD. Now, I bought a new MacBook Pro and at the initial setup, I transferred all data from the old Powerbook to the new MacBook Pro, including accounts.
    When I now login the first time to the Mac OS X Server from the new Mac with the PHD account, do I have to take care of anything in particular? Does the sync work as usual?
    Thanks for your promt help!
    Thomas
    MacBook Pro   Mac OS X (10.4.7)  

    I'm going to take a wild stab in the dark here:
    When you logged on to the new Macbook Pro, was it on an account that you set up locally on that machine? One perhaps with the same user short name as your Server account?
    The way this works is, when you enter a username in the login panel, the Mac OS client looks into it's own local machine database (Netinfo) to find out if that client exists. If not, it checks the servers it's bound to in the "Authentication" tab of Directory Access and checks there.
    So if your old Powerbook was using an account named "kirk", which is exists on your server and synced as a Portable Home Directory, and then you created a new account on your new Macbook named "kirk", your Macbook's OS won't even look on the server because it found a "kirk" locally.
    If this is what happened, just do this: create a new administrator account on your MacBook, log into it, and delete your fresh new Macbook "kirk" user. Log out. At the login window, select "Other" and use your server "kirk" login. Now you'll get the option to copy your server-based home directory as a PHD.

  • Acrobat Pro 9.0 and 9.1 crash using Portable Home Directory

    Installed 9.0 as part of CS4 Design Suite, and updated to 9.1. Runs OK for user on local machine but crashes when used by a portable home directory user on same machine, accessing user on OSX Server on local network. Safari also crashes when accessing pdf document. Can anyone help please?

    Thanks, the workaround in message 34 worked for me (so far!). Much more helpful than this reply from Adobe: "I am afraid we are unable to troubleshoot errors with customized user accounts. If the program works locally, we advice to use the program locally."
    Thanks again.

  • Migrating existing portable homes to new server

    aside from moving the homedir data from the old server to the new, there seem to be at least a few issues with migrating existing portable home accounts to a new server:
    1. some of users' account details, like GeneratedUID, authentication authority, kerberos principals, OriginalNFSHomeDirectory, are different, while others (name, shortname, UID, GID, etc.) remain the same.
    2. home directory (OriginalNFSHomeDirectory, etc.) point to the old server.
    3. there's data on local machines that we don't sync back to the server, so we can't just blow away the existing local accounts and start fresh.
    the quickest way to migrate these users to the new server (with all the same shortnames and UIDs, etc.) seems to be to remove the local cached accounts (leaving the home folders) and have them recreate new PHDs on login, syncing things back down to the original home folder. i'm guess this won't involve much syncing, it's all the same data, essentially.
    the other way i can see resolving this is to replace the account attributes for each client to match what they should be when pointed to the new server. this would involve scripting the process for reliability and not moving any data or deleting accounts, but it will take more testing on my part.
    what do you think? can you think of better ways to accomplish this task?
    summary: what's the best way to move existing portable home accounts bound to "Server A" to "Server B," while maintaining data and portable homes pointed to the new server and storage?
    thanks.

    that createmobileaccount syntax was wrong. i guess you don't need the -t option and can instead specify the whole path to the user's home. it seems to work well enough, creating a portable home with no default sync settings -- basically manual. for my needs that's fine. the sync settings are managed via mcx anyway.
    here's an updated version of the standalone script. i realized just now the script assumes the diradmin usernames and passwords are the same between servers. if that's not the case, you can hard code it or add a couple of variables. since they're just taken in order on stdin, add them in order. i should also add a function to interactively ask for the passwords with stty -echo to avoid having the passes logged in command history or allowing the script to curl the pass from another file on a web server or something. for now, this seems to work for my purposes. edit as you see fit.
    #!/bin/bash
    # nate@tsp, 3/4/10: initial version
    # 3/5/10: added prettier heredoc usage statement, variables, further tested
    # todo: add function to add user to local admin group, as needed. this shouldn't be required in most environments.
    # todo: convert some of these one-liners to functions for better modular use; make it "smarter"
    # todo: convert the whole thing to ruby for practice
    # automates the process of unbinding from the old OD server, binding to the new, removing the existing local user, adding it back, and other bits
    # there are no "smarts" in this script, so use carefully
    # variables
    diradminpass=$1
    account=$2
    password=$3
    oldserver=$4
    newserver=$5
    mkdadmin=$6 # not used in this version
    # if no parameters are passed, display usage, exit
    if [ ! -n "$5" ] ; then
    cat<<endofnote
    usage: you must include at least 5 arguments (6th isn't used right now)
    run with `basename $0`
    1. [directory admin password]
    2. [shortname of account to change]
    3. [account password, which should be the default 'xxxxxxxx' on the new server]
    4. [name of old server]
    5. [name of new server]
    6. [yes or no to make this account a local admin - optional and not used now]
    ex: `basename $0` diradminpass jbrown password oldserver newserver yes
    endofnote
    exit 1
    fi
    # if you're running this as root or with sudo, proceed; otherwise, quit it!
    if [ $(whoami) = "root" ]; then
    echo "you're root. let's proceed..."
    # delete the user in question from the local directory store
    echo "deleting local account: $account"
    dscl . -delete /users/$account
    # remove the old od config
    echo "removing the old OD bind..."
    dsconfigldap -v -r $oldserver -c $HOSTNAME -u diradmin -p $diradminpass
    # remove the old server from the search and contacts paths
    echo "removing the old search paths..."
    dscl /Search -delete / CSPSearchPath /LDAPv3/$oldserver
    dscl /Search/Contacts -delete / CSPSearchPath /LDAPv3/$oldserver
    # add the new one
    echo "adding the new OD bind..."
    dsconfigldap -v -f -a $newserver -n $newserver -c $HOSTNAME -u diradmin -p $diradminpass
    # create and add the new ldap node to the search policy
    echo "adding the new search paths..."
    dscl -q localhost -create /Search SearchPolicy dsAttrTypeStandard:CSPSearchPath
    dscl -q localhost -merge /Search CSPSearchPath /LDAPv3/$newserver
    # create and add the new ldap node for contacts lookups
    dscl -q localhost -create /Contact SearchPolicy dsAttrTypeStandard:CSPSearchPath
    dscl -q localhost -merge /Contact CSPSearchPath /LDAPv3/$newserver
    # give directoryservice a kick to point it to the new server
    echo "killing directoryservice and waiting for 20 seconds..."
    killall DirectoryService
    # rest a bit to ensure everything settled down
    sleep 20
    # optional: lookup the $account you deleted as the first step to ensure it exists in the new directory
    echo "this id lookup should return details because it exists in the new OD:"
    id odtestor
    echo "this id lookup should fail because it doesn't exist in the old OD:"
    id odtestor
    # check the search path to ensure it looks like you need
    echo "verify the new OD server is in the search path:"
    dscl /Search -read / CSPSearchPath
    # optional: create a mobile account on the local machine with various options set.
    echo "creating a portable home for the user..."
    /System/Library/CoreServices/ManagedClient.app/Contents/Resources/createmobileaccount -n $account -v -p $password -h /Users/$account -S -u afp://$newserver/homes/$account
    killall DirectoryService
    cat<<endofnote
    you should be ready to login with this account now.
    if you have trouble, revert the process by re-running with the old and new server names
    (and diradmin passwords, if they're different) reversed.
    endofnote
    else
    echo "you're not root or an admin. please re-run the script as an admin or via sudo."
    exit
    fi
    exit 0

  • Portable Home Directories Pretty Much Unusable

    Running OSX Server 10.6.2 and a dozen or so client macs with either 10.5 or 10.6 on them, we are having huge problems with portable home directories.
    Firstly, after a while after initial install I did change certain sync settings in the workgroup manager - namely omitting library folders from the sync, and changing sync frequency from every 2 hours and on startup over to only on startup and shutdown, but none of these settings are ever honoured by the client machines - they keep syncing every 2 hours and just on startup as per the previous settings, and still sync the library folders. Tried deleting the managed preferences folder on client machines, or wiping home directories on the server and recreating - all without success.
    Secondly, the sync at startup takes forever (gradually seems to be getting worse and worse) and now hangs for about ten minutes at the end of sync just stating 'finishing'. This is getting to be a real impact on our workflow. Even if users cancel the sync it happens.
    Getting seriously annoyed with this software now. Would be nice if Apple actually fixed bugs in their server software - PHD has always been terrible IMHO.

    yeah i can only agree to that. wasted dozens of hours settings up a 10.5.8 server with some leo-clients...been testing things for a couple of months and just don't trust it anymore...too much buggy and illogical behaviour and totally insufficient documentation... i rather use rsync to copy client data onto a bkup fileserver.

  • Portable Home Directories

    I have a Tiger Server that hosts portable home directories for my Leopard Clients.
    I cannot get a portable home directory to sync with my Snow Leopard client.
    Is this possible?

    I have a snow leopard server. My < 10.6 clients can still mount their remote home directories using smb, but my snow leopard clients cannot. Has anyone shed any light on this issue?
    my client log says:
    Nov 13 09:43:40 bach07 authorizationhost[165]: cifs home directory mount failed in creating directory path: status = Authentication error
    Nov 13 09:44:41 bach07 edu.mit.Kerberos.CCacheServer[178]: launchctl start error: No such process
    My server log says:
    [2009/11/13 09:44:47, 3] /SourceCache/samba/samba-235/samba/source/smbd/oplock.c:init_oplocks(863)
    init_oplocks: initializing messages.
    [2009/11/13 09:44:47, 3] /SourceCache/samba/samba-235/samba/source/smbd/process.c:process_smb(1077)
    Transaction 0 of length 51
    [2009/11/13 09:44:47, 3] /SourceCache/samba/samba-235/samba/source/smbd/process.c:switch_message(927)
    switch message SMBnegprot (pid 2508) conn 0x0
    [2009/11/13 09:44:47, 3] /SourceCache/samba/samba-235/samba/source/smbd/secctx.c:set_secctx(278)
    setting sec ctx (0, 0) - secctx_stackndx = 0
    [2009/11/13 09:44:47, 3] /SourceCache/samba/samba-235/samba/source/smbd/negprot.c:reply_negprot(526)
    Requested protocol [NT LM 0.12]
    [2009/11/13 09:44:47, 3] /SourceCache/samba/samba-235/samba/source/smbd/negprot.c:reply_nt1(385)
    using SPNEGO
    [2009/11/13 09:44:47, 3] /SourceCache/samba/samba-235/samba/source/smbd/negprot.c:reply_negprot(627)
    Selected protocol NT LM 0.12
    [2009/11/13 09:44:47, 3] /SourceCache/samba/samba-235/samba/source/smbd/process.c:timeout_processing(133 7)
    timeout_processing: End of file from client (client has disconnected).

  • Using Portable Home Directories with more than one client

    Hi, I've got a general question about Portable Home Directories (PHD) that I'm hoping someone with more experience can help me with. I've only ever tied used PHDs to tie a Network Home to a single laptop in the past. But now I'd like to sync the home directories of a user that uses both an iMac (in the office) and a MacBook Air (on the road).
    Any caveats to watch out for if we do this?
    What if the user is logged into both machines at the same time?
    What if the home directory on the iMac is larger than the entire SSD on the MacBook?
    Appreciate any advice before heading down this path…

    well... my english is not so good but i will try to explain it to you...
    iTunes have a funcion that put the music in the iPod automaticaly and it will put the music of THAT computer in your iPod.
    so when you conect your iPod go to options and select put the music manually or something like that (i have it in spanish XD)
    or go to the "help" in iTunes > "help iTunes" then... charge iPod > charge iPod manually
    this is dificult to explain in english im from argentina XD i hope you understand me XD

  • 10.5 portable home sync rules not being respected on the client...

    Portable home syncing is working great for me on my Tiger server and clients, and I'm an old hat at Apple server and OD.... However in my test environment for 10.5, my client machines reuse to respect the rules that I've set in 10.5 Server Workgroup Manager for portable home syncing. I was hoping 10.5.2 would fix this for me, but no luck....
    I can tell that the clients are bound to the OD and are reading the MCX settings from the server, because I can change the sync time interval, and that is being reflected on the client. WGM is set to NOT allow settings to be merged with user's settings, so I can eliminate the client settings as a variable.
    Both Login/Logout and background sync are effected by this problem.
    Is anyone else having this issue?

    Bruce's solution above does indeed work. However, I must have stared at his answer for 20 minutes trying to figure out what he was talking about. Undoubtedly, my inability to initially parse his solution comes from my more basic understanding of OS X Server. Since there are likely others out there with this same Home Sync problem and my same level of experience with OS X Server I wanted to give Bruce's answer again but with more detail.
    The problem, as explained by the original post, is that Home Sync settings for a user or group aren't necessarily respected. For example, if I were to open Workgroup Manager (WGM), select myself as a user (Berylium), click Preferences, select Mobility from the Overview tab, and select the Rules tab I would be in the Home Sync preferences. If I tell the Login & Logout Sync tab to Always do what I select and then I uncheck the Sync at login and logout checkbox one would expect that when I log in or log out I would not see a Home Sync dialog popup and perform a sync operation - but I did.
    The issue as Bruce explains occurs because of another setting I have enabled, Background Sync, and a quirk (bug?) in Leopard Server. I have Background Sync enabled, set to Always, and told to sync in the background my ~/Documents and ~/Desktop folders. Leopard Server, it seems, performs the following operation when I login or logout:
    1. Is Login & Logout Sync enabled? No, ok skip this part.
    2. Is Background Sync enabled? Yes! Ok, sync the background sync items now even though this is a login or log out.
    Clever, Apple. Ok, now that the problem has been explained let's get to the solution.
    1. Open WGM, select your problem user or group, click Preferences, and select the Details tab
    2. Click the +, navigate to /System/Library/CoreServices/, select ManagedClient, and click Add
    - At this point, at least in my installation, several more items appeared in the preference editor list.
    3. Select Home Sync in the preference editor list then click the Edit button (looks like a pencil)
    4. Expand the Always list item
    - Obviously, this is where some people's solution could begin to differ from mine. You may want to edit items in the Once or Often list items.
    5. Click the New Key button, a New Item will be created and selected, click New Item and select Sync Background Set During Login from the list.
    6. Change the Value item for Sync Background Set During Login from automatic to dontSync
    7. Repeat steps 5 and 6 but select Sync Background Set During Logout
    8. Click Apply Now followed by Done
    Now you should be all set. Thank you Bruce for the solution to this problem and I hope someone else finds my more detailed explanation helpful.
    -Berylium

  • Never - Create a portable home directory on this computer now?

    I have kinda the opposite problem from normal. I have Home Directories and PHD's working fine. I think it is working as expected, with one exception...
    My Daughter has an iMac at my office. I set up her account as PHD so she could also use the account from home. (We SOMETIMES go home <g>) But when I log on as her from one of the other desktops at the office, I get the dialog: "Create a portable home directory on this computer now?". I answer never. And it keeps coming up. Does Never not mean Never?
    Panther Server, Tiger Clients. TIA
    PB G4 Al (2), MDD G4 Dual (3), AGP, Cube, W2K Server, B&W G3 Server & others (includes SE30)    

    Hello,
    I started a thread concerning the opposite phenomenon, when you once click "Never" it seems you cannot change your mind and get the question asked again ... maybe you could contribute to answer the question ?
    http://discussions.apple.com/thread.jspa?messageID=1375953&#1375953
    Brett_X said: Most of the PHD stuff happens at the client level anyway
    I guess the settings preventing the dialog from coming up are stored on the client machine ?
    Thank You.

  • Portable Home Directory Incomplete Sync

    All,
    I have just discovered a particularly disturbing issue with PHD. I recently had a user overwrite a file that was on his desktop and request a restore from backup. I did a search for the file on the backup that backs up all network home directories on the server and it was not found. I then checked the user's home directory on the server, and surprise it wasn't there either. Upon further checking, no files from the desktop had been synced to the server for over a month! This occurred while a regular sync has been happening on startup/logout and hourly the whole time and no errors have been logged.
    Now being curious and worried I checked some other users and found that the same issue is occurring on about half of the other computers. But the specific problems vary from machine to machine. Some users were syncing properly except for some files on the desktop. Some were missing files that were several months old but had all the current ones. In a word, random.
    Exception rules seems to be observed for the most part.
    I am going to investigate this more but wondered if anyone else was seeing this sort of weirdness? I am suspecting that the problem may have coincided with the 10.5.4 Server upgrade, but this is just speculation at this point.
    Ideas?
    Bob

    hi there, i am having the exact same issue with some portable accounts. we are running 10.5.4 server and 10.5.4 clients.
    i have noticed rogue ACLS appearing now in server admin for leopard, as described in a previous post.
    User = Everyone, Type = Deny, Permission = Custom, Applies To = This folder, All descendants.
    strangely, some of our users have the rogue ACL and some don't.
    even after deleting the ACL for the user, portable home syncing still does not work.
    on the client it goes through the process and the blue bar shows you it checking folders and seemingly updating. the give away for me is following the apparently successful sync, when you click on the mobile directory icon in the menu bar the date has not updated and clearly upon checking with the network account, new data has not synced.
    any ideas would be great... until now i have had to manually drag data from the client to the network folder by mounting the network folder over afp, then wipe the client and recreate the portable account... even then i am not sure how long syncing has been successful, though that has seemed to fix things.
    i am not sure if something is breaking in the user's library on the portable account?
    any insight would be most welcome.

Maybe you are looking for

  • In Search of a Quiet External Burner

    Now that my internal super drive is failing, I'm considering a more robust external burner as a back-up to my internal burner (which is still under waranty and will be replaced). In the past, the external burners I've had were quite loud. The LaCie I

  • Laptop cannot see airport express

    I have three laptops on my home network.  Two can see my airport express, one cannot.  I have the airport express set to join my home network automatically.  I am only using airport express to be able to listen to my itunes music through my home ster

  • Dreamweaver upgrade - need Help

    I upgraded from Dreamweaver 8 to CS5. My site is there.  But when I go to link a file that's on my computer, I get "Dynamicall-related files could not be resolved because the site definition is not correct for this server". What does that mean??

  • 24p normal vs 24p Advanced

    I shot almost all my footage in ADVANCED MODE on a DVX-100A, but accidentally may have shot some of it on 24p NORMAL. I want to edit it in 24p timeline and finish on a 24p DVD. So my ideal scenario would be to remove the pulldown during capture in FC

  • I have a green screen when playing videos, I have audio.

    I am running windows 8.1 64 bit, explorer 11 and flash player 17.0.0.134  Why is my screen green when playing videos? I am trying to watch a show on CBS and it is doing the same thing.  HELP!!  I have tried the solutions on the troubleshoot page.