<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: copy files from one directory to another. in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906723#M283886</link>
    <description>There are many ways to do this, the simplest is to use cp with the -p option.  You could also use find piped to cpio.&lt;BR /&gt;&lt;BR /&gt;It all depends on whether you want to copy all the files or just some of them and, if just some, what the selection criteria may be.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
    <pubDate>Fri, 01 Dec 2006 11:28:38 GMT</pubDate>
    <dc:creator>Pete Randall</dc:creator>
    <dc:date>2006-12-01T11:28:38Z</dc:date>
    <item>
      <title>copy files from one directory to another.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906722#M283885</link>
      <description>Can I copy files from one directory to another , keeping the permission and UID,GID?&lt;BR /&gt;&lt;BR /&gt;there are many files ,how can I use command?&lt;BR /&gt;thanks a lot!</description>
      <pubDate>Fri, 01 Dec 2006 11:24:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906722#M283885</guid>
      <dc:creator>lin.chen</dc:creator>
      <dc:date>2006-12-01T11:24:22Z</dc:date>
    </item>
    <item>
      <title>Re: copy files from one directory to another.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906723#M283886</link>
      <description>There are many ways to do this, the simplest is to use cp with the -p option.  You could also use find piped to cpio.&lt;BR /&gt;&lt;BR /&gt;It all depends on whether you want to copy all the files or just some of them and, if just some, what the selection criteria may be.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Fri, 01 Dec 2006 11:28:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906723#M283886</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2006-12-01T11:28:38Z</dc:date>
    </item>
    <item>
      <title>Re: copy files from one directory to another.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906724#M283887</link>
      <description>Pete,thanks alot!I just want to copy all the files from one directory to another.&lt;BR /&gt;It seem "cpio" can not support files more than 2G.&lt;BR /&gt;Does cp -p can preserve UID and GID?&lt;BR /&gt;&lt;BR /&gt;Is following right?&lt;BR /&gt;#find . |cp -p /data</description>
      <pubDate>Fri, 01 Dec 2006 11:43:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906724#M283887</guid>
      <dc:creator>lin.chen</dc:creator>
      <dc:date>2006-12-01T11:43:33Z</dc:date>
    </item>
    <item>
      <title>Re: copy files from one directory to another.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906725#M283888</link>
      <description>cp -p will keep the permission UID/GID intact.&lt;BR /&gt;I would rather prefer cpio if there are multilple files to be copied.&lt;BR /&gt;&lt;BR /&gt;cd /sourcedirectory&lt;BR /&gt;&lt;BR /&gt;# find .|cpio -pudlmv /destinationdirectory&lt;BR /&gt;&lt;BR /&gt;-USA..</description>
      <pubDate>Fri, 01 Dec 2006 11:50:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906725#M283888</guid>
      <dc:creator>Uday_S_Ankolekar</dc:creator>
      <dc:date>2006-12-01T11:50:00Z</dc:date>
    </item>
    <item>
      <title>Re: copy files from one directory to another.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906726#M283889</link>
      <description>cpio (and tar) are not useful for large files (dozens of Gb) and cannot be used. cp works with all filesizes.  Your question:&lt;BR /&gt; &lt;BR /&gt;&amp;gt; Is following right?&lt;BR /&gt;&amp;gt; #find . |cp -p /data&lt;BR /&gt; &lt;BR /&gt;No, you just use cp:&lt;BR /&gt; &lt;BR /&gt;cd /old-directory&lt;BR /&gt;cp -p * /data&lt;BR /&gt; &lt;BR /&gt;If there are thousands of files in that directory, you may get a line too long message. xargs will be required in that case. If you have any dot files (files starting with .), you'll need to copy those with something like this:&lt;BR /&gt; &lt;BR /&gt;cp -p * .??*&lt;BR /&gt; &lt;BR /&gt;This prevents copying the .. directory. There are other special filenames you will have to handle manually such .a .b .1 .2 and so on. Be careful of expression that match ..</description>
      <pubDate>Fri, 01 Dec 2006 12:02:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906726#M283889</guid>
      <dc:creator>Bill Hassell</dc:creator>
      <dc:date>2006-12-01T12:02:35Z</dc:date>
    </item>
    <item>
      <title>Re: copy files from one directory to another.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906727#M283890</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;If you have largefiles, I'd use 'fbackup' and 'frecover':&lt;BR /&gt;&lt;BR /&gt;# cd /srcdir&lt;BR /&gt;# fbackup -i . -f - | (cd /dstdir; frecover -Xsrf -)&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Fri, 01 Dec 2006 12:08:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906727#M283890</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2006-12-01T12:08:06Z</dc:date>
    </item>
    <item>
      <title>Re: copy files from one directory to another.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906728#M283891</link>
      <description>use your backup software, backup, then restore...much quick, no worry about size of files, or permission changging etc. Cheers</description>
      <pubDate>Fri, 01 Dec 2006 16:44:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906728#M283891</guid>
      <dc:creator>John Guster</dc:creator>
      <dc:date>2006-12-01T16:44:35Z</dc:date>
    </item>
    <item>
      <title>Re: copy files from one directory to another.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906729#M283892</link>
      <description>&amp;gt;Bill No, you just use cp:&lt;BR /&gt;cd /old-directory; cp -p * /data&lt;BR /&gt;&amp;gt;If there are thousands of files in that directory&lt;BR /&gt;&lt;BR /&gt;Why not use "cp -pR /old-directory /new-directory"&lt;BR /&gt;&lt;BR /&gt;The only issue is that new-directory can't exist.  If is does, you'll have to move the files after you copy it.  That should be easier than worrying about "." files.  You still may have to use xargs for the mv.</description>
      <pubDate>Fri, 01 Dec 2006 18:53:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906729#M283892</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2006-12-01T18:53:13Z</dc:date>
    </item>
    <item>
      <title>Re: copy files from one directory to another.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906730#M283893</link>
      <description>I would prefer ,&lt;BR /&gt;&lt;BR /&gt;cd /source_dir &lt;BR /&gt;tar cvf - . |ksh "(cd /destination_dir;tar xvf -)"&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;BR /&gt;Kaps</description>
      <pubDate>Sat, 02 Dec 2006 21:48:50 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/copy-files-from-one-directory-to-another/m-p/3906730#M283893</guid>
      <dc:creator>KapilRaj</dc:creator>
      <dc:date>2006-12-02T21:48:50Z</dc:date>
    </item>
  </channel>
</rss>

