WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Copy files from mounted tcz creates links and not regular files  (Read 2781 times)

Offline helander

  • Full Member
  • ***
  • Posts: 183
When I copy a file tree, either using cp or tar (tar create piped to tar unpack), from a loop mounted tcz to a loop mounted home, the regular files copied do not show up as regular files at the destination, but as links to the source files in the loop mounted tcz. What causes this behavior? Is it intentional? How could I circumvent it, so that regular copies are created at the destination?

/Lars

Offline ^thehatsrule^

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 1726
Re: Copy files from mounted tcz creates links and not regular files
« Reply #1 on: July 01, 2009, 10:23:03 PM »
It is intentional - it is the 'definition' of tcz's.  If this is not wanted, perhaps using .tce's would be better suited.

If you just want cp/tar to derefence all symlinks, there are flags that can be passed to those to do that.

Offline helander

  • Full Member
  • ***
  • Posts: 183
Re: Copy files from mounted tcz creates links and not regular files
« Reply #2 on: July 02, 2009, 03:50:48 AM »
If you just want cp/tar to derefence all symlinks, there are flags that can be passed to those to do that.

It seems that cp have flags suitable for this, but I do not see that tar has, correct?

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: Copy files from mounted tcz creates links and not regular files
« Reply #3 on: July 02, 2009, 04:21:06 AM »
Gnu tar has the --dereference flag for this.