[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Data migration from HFS+ to NTFS

Posted on 2011-10-05
13
Medium Priority
?
754 Views
Last Modified: 2012-08-14
I'm currently looking at how to migrate a large amount of data from HFS+ volumes hosted on a Apple Xserve over to NTFS volumes on Server 2008 R2.

The data is files from user's home folders, and i was planning on updating their AD home folder location to create a blank home with the correct permissions, then strip permissions from the old location and transfer the files in.

I've tried passenger's folder migration utility which does seem to work with the destination share mounted with admin credentials, but around 25% of the files were not transferred on testing:

--------------------
Matched contents of
/Volumes/A\-D/tomove/normalsd1
to
/Volumes/A\-DHomes\$/normalsd1
Copying... Verifying... Failed: destination (9,419) and source (2,556) are different file counts
--------------------

Any suggestions?

Much appreciated,

Thanks.
0
Comment
Question by:gmbaxter
  • 8
  • 5
13 Comments
 
LVL 13

Accepted Solution

by:
maximus5328 earned 1000 total points
ID: 36917676
I would share folders on XServe via SMB then copy over the network.
0
 
LVL 11

Author Comment

by:gmbaxter
ID: 36917942
I want to strip all permissions before migrating and have the contents of the users home folder moved into a new blank home folder. Permission inheritance will then take care of correcting permissions, i just need a way of scripting / or a program to do this as i can't do it manually.

Thanks.
0
 
LVL 13

Expert Comment

by:maximus5328
ID: 36918395
when you copy over SMB, permissions are not preserved
0
Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

 
LVL 11

Author Comment

by:gmbaxter
ID: 36918506
ok, so if i didn't create new home folders in the new location, then did cp -R the entire contents of the old share to the new SMB mounted share, how could i correct permissions at the new share.

i looked at cacls and icacls earlier, but couldn't get it to work.

it'd need to do:

echo y| icacls username domain\username modify
echo y| icacls username domain\admins full control

 
0
 
LVL 13

Expert Comment

by:maximus5328
ID: 36921241
have you tried first:
icacls folder_name /reset /T
then:
icacls folder_name /grant username:M
0
 
LVL 11

Author Comment

by:gmbaxter
ID: 36921395
How do I wildcard the user name? Eg %%I I think it was in cacls. Usernames are the same as the folder names.
0
 
LVL 13

Expert Comment

by:maximus5328
ID: 36922098
first, confirm on a single folder that icacls command does what you want it to do.
next, to run it on all folders do the following:
cd into the directory containing folders you want to change
confirm that you are in the correct place by running
dir /ad/b

Open in new window

you should see a list of folders you are about to change one per line
run the following
for /f "delims=" %i in ('dir /ad/b') do icacls %i /reset /T

Open in new window

repeat with the second icacls command
for /f "delims=" %i in ('dir /ad/b') do icacls %i /grant %i:M

Open in new window

0
 
LVL 11

Author Comment

by:gmbaxter
ID: 36923515
icacls %i /grant %i:M

This grants special permission to the folder only, no subfolders of files.

I used: icacls testuser /grant testuser:(OI)M
which did work - is this correct?

However, puting this in a for loop didn't work. Here is my syntax:

E:\A-DHomes$>for /f "delims=" %i in ('dir E:\A-DHomes$\') do icacls %i /grant %i:(OI)M
tried without the dir bit too but that didn't work.

but this errors out. Any ideas?
0
 
LVL 11

Author Comment

by:gmbaxter
ID: 36923712
Error:

      E:\A-DHomes$>icacls  Volume in drive E is Data /grant  Volume in drive E is Data
      :(OI)M
      Invalid parameter "in"
0
 
LVL 11

Assisted Solution

by:gmbaxter
gmbaxter earned 0 total points
ID: 36923788
This did the trick:

E:\>cd A-DHomes$

E:\A-DHomes$>for /d %i in (*) do icacls %i /grant %i:(OI)(CI)M


Last semi-related question is, how to recursively strip trailing spaces from files and folders, as this causes issues with the macs not being able to open the files.

Thanks.
0
 
LVL 13

Expert Comment

by:maximus5328
ID: 36923982
don't know about trailing spaces
0
 
LVL 11

Author Comment

by:gmbaxter
ID: 37003514
I'm going to transfer via smb starting tomorrow afternoon. Fingers crossed!
0
 
LVL 11

Author Closing Comment

by:gmbaxter
ID: 37087267
SMB transfer was only viable option really.

icacls loop sorted out the permissions.
0

Featured Post

Creating Active Directory Users from a Text File

If your organization has a need to mass-create AD user accounts, watch this video to see how its done without the need for scripting or other unnecessary complexities.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A safe way to clean winsxs folder from your windows server 2008 R2 editions
Most folks would know the basics of how Dropbox works, so that’s not the purpose of this article. Security is what it’s all about, so here I’ll share how I choose to secure my Dropbox Account and the Data it contains.
This tutorial will walk an individual through the steps necessary to configure their installation of BackupExec 2012 to use network shared disk space. Verify that the path to the shared storage is valid and that data can be written to that location:…
This tutorial will walk an individual through setting the global and backup job media overwrite and protection periods in Backup Exec 2012. Log onto the Backup Exec Central Administration Server. Examine the services. If all or most of them are stop…

872 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question