Perplexity 🤖 Posted November 16, 2006 Share Posted November 16, 2006 I'm trying to tar a directory on one machine to move it to another.On the starting machine the directory is something like:/dir1/dir2/dir3/dir4/user/domain/data/[i]the_dir[/i]The target destination on the new machine is/home/user/public_html/data/[i]the_dir[/i]Try as I might, I keep getting a result like this on the target machine:/home/user/public_html/data/dir1/dir2/dir3/dir4/user/domain/data/[i]the_dir[/i]I'll keep reading documentation until I get it, but if anyone wants to help me along with this I'd greatly appreciate it! Link to comment https://forums.phpfreaks.com/topic/27499-resolved-preventing-tar-from-preserving-full-file-paths/ Share on other sites More sharing options...
Perplexity 🤖 Posted November 16, 2006 Author Share Posted November 16, 2006 Nevermind, I got it.On the source machine, I was using a command like so:tar -cf ~/host_move/the_dir.tar ~/domain/data/the_dirChanging the command to:tar --directory=/dir1/dir2/dir3/dir4/user/domain/data/ -cf ~/host_move/the_dir.tar the_dirsolved the problem.I post this for anyone that runs into a similar situation. Link to comment https://forums.phpfreaks.com/topic/27499-resolved-preventing-tar-from-preserving-full-file-paths/#findComment-125757 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.