<?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: Zip files 1.7 Million files in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525901#M652020</link>
    <description>do the filenames have the date in them somewhere?  or are you relying on the datestamps?  or something else entirely?&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Mon, 02 Nov 2009 17:47:55 GMT</pubDate>
    <dc:creator>OldSchool</dc:creator>
    <dc:date>2009-11-02T17:47:55Z</dc:date>
    <item>
      <title>Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525900#M652019</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I have a filesystem which has got 1.7 million files. This filesystem contains files since Jan 2005.I need to gzip all files till Dec2008. I need to do this in an yearly basis. ie one zip file for 2005 , one zip file for 2006 . Same procedure for rest of the years.  &lt;BR /&gt;&lt;BR /&gt;Can anyone help me with the commands for this task?&lt;BR /&gt;&lt;BR /&gt;Your help is much appreciated.</description>
      <pubDate>Mon, 02 Nov 2009 16:23:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525900#M652019</guid>
      <dc:creator>ssheri</dc:creator>
      <dc:date>2009-11-02T16:23:33Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525901#M652020</link>
      <description>do the filenames have the date in them somewhere?  or are you relying on the datestamps?  or something else entirely?&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Mon, 02 Nov 2009 17:47:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525901#M652020</guid>
      <dc:creator>OldSchool</dc:creator>
      <dc:date>2009-11-02T17:47:55Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525902#M652021</link>
      <description>HI,&lt;BR /&gt;First make a tar file then zip it with compress or gzip utility.&lt;BR /&gt;&lt;BR /&gt;tar -cvf 2005.tar /directiory_name&lt;BR /&gt;gzip 2005.tar&lt;BR /&gt;&lt;BR /&gt;Suraj</description>
      <pubDate>Mon, 02 Nov 2009 17:51:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525902#M652021</guid>
      <dc:creator>Suraj K Sankari</dc:creator>
      <dc:date>2009-11-02T17:51:37Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525903#M652022</link>
      <description>cd dir&lt;BR /&gt;find . -atime 360 -exec ll {} \;&lt;BR /&gt;&lt;BR /&gt;Verify your selection by listing everything captured by find&lt;BR /&gt;&lt;BR /&gt;When ready&lt;BR /&gt;&lt;BR /&gt;find . -atime 360 -exec gzip {} \;&lt;BR /&gt;&lt;BR /&gt;This is for one year.  720 for two years, etc.&lt;BR /&gt;&lt;BR /&gt;I'd also suggest using 'tar' after you gzip else you'll run out of space fast.  Real, real fast.  In fact, having another dir to work with would be good.&lt;BR /&gt;&lt;BR /&gt;find . -name *.gz | tar cvf backup.tar {} \;</description>
      <pubDate>Mon, 02 Nov 2009 17:55:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525903#M652022</guid>
      <dc:creator>Michael Steele_2</dc:creator>
      <dc:date>2009-11-02T17:55:30Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525904#M652023</link>
      <description>"tar -cvf 2005.tar /directiory_name&lt;BR /&gt;gzip 2005.tar"&lt;BR /&gt;&lt;BR /&gt;that assumes the OP had the files already segregated into directories by year, which may or may not be the case.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;"find . -atime 360 -exec gzip {} \;"&lt;BR /&gt;&lt;BR /&gt;is probably closer to what the OP wants, but will result in one zip file for each original file found...which may be what their after.&lt;BR /&gt;&lt;BR /&gt;or you could take the above "find" and "mv" the file to a separate directory, then gzip each, then tar the results....or mv the file, tar the directory and gzip *that*.&lt;BR /&gt;&lt;BR /&gt;ssheri needs to remember the their is no "create date" stored in unix filesystems, M. Steele is going after the "access time" which would be may be a good bet.  see the "man" page for "find", in particular the "-atime", "-mtime" and "-ctime" options to see which best fits.  &lt;BR /&gt;&lt;BR /&gt;Another option would be to create two reference files with appropriate dates, and use the "-newer" and "-older" options to sort out what you want.&lt;BR /&gt;&lt;BR /&gt;All of the above is why I originally asked if the date was somehow "buried" in the filename.&lt;BR /&gt;&lt;BR /&gt;some additional information about the original data layout, and the desired results might help in providing more appropriate responses.</description>
      <pubDate>Mon, 02 Nov 2009 18:57:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525904#M652023</guid>
      <dc:creator>OldSchool</dc:creator>
      <dc:date>2009-11-02T18:57:49Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525905#M652024</link>
      <description>&lt;!--!*#--&gt;&amp;gt; Another option would be to create two&lt;BR /&gt;&amp;gt; reference files [...]&lt;BR /&gt;&lt;BR /&gt;This seems like a better scheme than any of&lt;BR /&gt;the "-&lt;X&gt;time" options.  Especially if&lt;BR /&gt;you're not running the job at 00:00 on 1&lt;BR /&gt;January.  "-atime" would seem to be the&lt;BR /&gt;least likely to get the desired result&lt;BR /&gt;(unless no one ever looks at these files).&lt;BR /&gt;&lt;BR /&gt;&amp;gt; or you could take the above "find" and&lt;BR /&gt;&amp;gt; "mv" the file [...]&lt;BR /&gt;&lt;BR /&gt;I'd vote for moving them to year-specific&lt;BR /&gt;directories that way, and then doing&lt;BR /&gt;something like:&lt;BR /&gt;&lt;BR /&gt;tar cf - year_2005_dir | \&lt;BR /&gt; gzip -c &amp;gt; year_2005_dir.tar.gz&lt;BR /&gt;&lt;BR /&gt;Creating an actual "tar" archive file, and&lt;BR /&gt;_then_ hitting it with gzip tends to require&lt;BR /&gt;more disk space, at least temporarily.&lt;BR /&gt;&lt;BR /&gt;&amp;gt; find . -atime 360 -exec gzip {} \;&lt;BR /&gt;&amp;gt; &lt;BR /&gt;&amp;gt; This is for one year. 720 for two years,&lt;BR /&gt;&amp;gt; etc.&lt;BR /&gt;&lt;BR /&gt;Around here, years are longer than 360 days.&lt;BR /&gt;Which calendar do you use?  (And which does&lt;BR /&gt;"find" use?)&lt;/X&gt;</description>
      <pubDate>Mon, 02 Nov 2009 19:43:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525905#M652024</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2009-11-02T19:43:54Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525906#M652025</link>
      <description>If I would want to separate the files based explicitly on the year, I would go this way to create a file list:&lt;BR /&gt;&lt;BR /&gt;# find . -exec ll {} + | awk '$8 == "2007"' | tee list_2007&lt;BR /&gt;&lt;BR /&gt;This lists the files exactly from year 2007, (1st jan -&amp;gt; 31th dec) and also dives into subdirs. After that you could feed this file to gzip/tar or whatever you want...&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 03 Nov 2009 13:25:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525906#M652025</guid>
      <dc:creator>Viktor Balogh</dc:creator>
      <dc:date>2009-11-03T13:25:25Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525907#M652026</link>
      <description>lots of options presented.....still waiting for "ssheri" to shed some light on the original directory layout and the desired output.&lt;BR /&gt;&lt;BR /&gt;from what was originally stated, it could well be that the OP wants a gzip file for a given year that contains all the files for that year (as opposed to zipping a tar of those files).&lt;BR /&gt;&lt;BR /&gt;If so, I don't think that option has been covered yet, and it might be a pain to implement.</description>
      <pubDate>Tue, 03 Nov 2009 16:16:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525907#M652026</guid>
      <dc:creator>OldSchool</dc:creator>
      <dc:date>2009-11-03T16:16:58Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525908#M652027</link>
      <description>Hi All,&lt;BR /&gt;Thanks for your quick responses. I hope I would explain my requirement in detail.&lt;BR /&gt;=======================================&lt;BR /&gt;&lt;BR /&gt;I have a filesystem which contains 1.7 million files. File are there since 2005 till today. My requirement is to tar and zip the files for each year separately. ie one tar/zip file for 2005, 2006,2007 and 2008. The files can be identified by their time stamp and there are no separate directories for each year. All files are residing on a single directory.&lt;BR /&gt;======================================</description>
      <pubDate>Tue, 03 Nov 2009 16:18:47 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525908#M652027</guid>
      <dc:creator>ssheri</dc:creator>
      <dc:date>2009-11-03T16:18:47Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525909#M652028</link>
      <description>"I have a filesystem which contains 1.7 million files. File are there since 2005 till today. My requirement is to tar and zip the files for each year separately. ie one tar/zip file for 2005, 2006,2007 and 2008. The files can be identified by their time stamp and there are no separate directories for each year. All files are residing on a single directory."&lt;BR /&gt;&lt;BR /&gt;Ok, this could get ugly.  Making the assumption that the files will be removed after archiving, then something like the following can be modified to work:&lt;BR /&gt;&lt;BR /&gt;First, you need to realize that UNIX doesn't have / track a file timestamp related to the "creation time".  It knows the following:&lt;BR /&gt; &lt;BR /&gt;atime  (File Access Time)&lt;BR /&gt;Access time shows the last time the data from a file was accessed - read by one of the Unix processes directly or through commands and scripts.&lt;BR /&gt;&lt;BR /&gt;ctime  (File Change Time)&lt;BR /&gt;ctime changes when you change file's ownership or access permissions. It will also naturally highlight the last time file had its contents updated.&lt;BR /&gt;&lt;BR /&gt;mtime (File Modify Time)&lt;BR /&gt;Last modification time shows time of the  last change to file's contents. It does not change with owner or permission changes, and is therefore used for tracking the actual changes to data of the file itself.&lt;BR /&gt;&lt;BR /&gt;So...which one you look at depends on what you want.  IF you can guarantee that the contents of the file, once written, were never modified, then the mtime option of find should be ok.  Access time is useless for this if the file has ever been read after writing.  Ctime *might* work.&lt;BR /&gt;&lt;BR /&gt;If none of the above apply, then you're toast, as you've no way to locate files written in 2005.&lt;BR /&gt;&lt;BR /&gt;Let us say that mtime is workable in your case, and you are going to find those files in year 2005.  I'd create two reference files representing the upper and lower limits of the times you wish to locate:&lt;BR /&gt;&lt;BR /&gt;touch -a -m -t 200501010000.00 $HOME/first.ref&lt;BR /&gt;touch -a -m -t 200512312359.59 $HOME/last.ref&lt;BR /&gt;&lt;BR /&gt;should get be everything between 01/01/2005 at 00:00 and 12/31/2005 at 23:59 and 59 seconds.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;then use find to locate the relevant file using find and move them to a directory by themselves&lt;BR /&gt;&lt;BR /&gt;mkdir /yourname/2005&lt;BR /&gt;cd /where_files_are&lt;BR /&gt;&lt;BR /&gt;find . -xdev -type f -newer $HOME/first.ref -a !-newer $HOME/last.ref -exec mv {} /yourname/2005/. \+&lt;BR /&gt;&lt;BR /&gt;at that point, you should be able to tar the newly created directory and pipe that to zip as noted in one of the posts above.&lt;BR /&gt;&lt;BR /&gt;Note that the above has not been tested, you might want to substitute something harmless, like ls for the move until you get it sorted out.&lt;BR /&gt;&lt;BR /&gt;repeat the above, after adjusting timestamps on the ref files, and creating the required directories.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 03 Nov 2009 18:37:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525909#M652028</guid>
      <dc:creator>OldSchool</dc:creator>
      <dc:date>2009-11-03T18:37:58Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525910#M652029</link>
      <description>And I have provided the procedure that I would use if I had the task to perform.</description>
      <pubDate>Tue, 03 Nov 2009 22:44:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525910#M652029</guid>
      <dc:creator>Michael Steele_2</dc:creator>
      <dc:date>2009-11-03T22:44:06Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525911#M652030</link>
      <description>&lt;!--!*#--&gt;&amp;gt;I have a filesystem which has got 1.7 million files.  ... All files are residing on a single directory.&lt;BR /&gt;&lt;BR /&gt;I assume people have told you this is not a good idea?&lt;BR /&gt;&lt;BR /&gt;&amp;gt;The files can be identified by their time stamp&lt;BR /&gt;&lt;BR /&gt;Encoded in their name, or in the ll(1) output?&lt;BR /&gt;I have a case where they are encoded in their name.&lt;BR /&gt;&lt;BR /&gt;&amp;gt;there are no separate directories for each year.&lt;BR /&gt;&lt;BR /&gt;If the names include the year, the first thing to do is to create a subdirectory and move all of a year into it.&lt;BR /&gt;&lt;BR /&gt;If they don't include the year, you can make a simple script to do that:&lt;BR /&gt;last_year=""&lt;BR /&gt;ll -trog | while read F1 F2 F3 F4 F5 F6 F7; do&lt;BR /&gt;   case $F6 in&lt;BR /&gt;   200[5-8]) ;;&lt;BR /&gt;   *)        continue;;&lt;BR /&gt;   esac&lt;BR /&gt;   if [ "$F6" != "$last_year" ]; then&lt;BR /&gt;      mkdir -p $F6&lt;BR /&gt;      last_year=$F6&lt;BR /&gt;   fi&lt;BR /&gt;   echo mv "$F7" $last_year&lt;BR /&gt;done&lt;BR /&gt;&lt;BR /&gt;Once they are in a separate directory, you use the tar-gzip suggestions as Steven suggested.&lt;BR /&gt;&lt;BR /&gt;If you don't want to include the directory name in the tarball, you can use -C:&lt;BR /&gt;tar cf - -C 2005 . |&lt;BR /&gt;gzip &amp;gt; year_2005.tar.gz</description>
      <pubDate>Wed, 04 Nov 2009 01:14:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525911#M652030</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2009-11-04T01:14:06Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525912#M652031</link>
      <description>perhaps the biggest problem here is that questions to the OP get a restatment of the original question, without additional information.  and specific questions go unanswered.&lt;BR /&gt;&lt;BR /&gt;there are a variety of answers posted, some of which may be more appropriate than others, depending on the exact goal, which isn't clear here.&lt;BR /&gt;&lt;BR /&gt;I will add that if ssheri has any control of the creation of these files, going I'd encode the creation date in the filename somehow, as anything relying on the "timestamps" is not going to be a reliable method for determining when a file was created.</description>
      <pubDate>Wed, 04 Nov 2009 14:36:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525912#M652031</guid>
      <dc:creator>OldSchool</dc:creator>
      <dc:date>2009-11-04T14:36:13Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525913#M652032</link>
      <description>Thanks a lot..&lt;BR /&gt;&lt;BR /&gt;Your suggestions match my requirement. &lt;BR /&gt;The files are not modified after their arrival to the filesystem. These files are getting saved to the filesystem as a result of a scheduled job. Later these are not getting modified by any user.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 05 Nov 2009 12:12:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525913#M652032</guid>
      <dc:creator>ssheri</dc:creator>
      <dc:date>2009-11-05T12:12:30Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525914#M652033</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I have checked up using the options which "oldschool" provided.&lt;BR /&gt;=======================================&lt;BR /&gt;1. created refernec files&lt;BR /&gt;&lt;BR /&gt;2. ran find . -xdev -type f -newer $HOME/first.ref -a !-newer $HOME/last.ref -exec cp -p {} /yourname/2005/. \+&lt;BR /&gt;&lt;BR /&gt;======================================&lt;BR /&gt;&lt;BR /&gt;I have used cp instead of mv for resting. Test was only for 1 month data. But I am getting an error when I excecute it.&lt;BR /&gt;&lt;BR /&gt;cp:./filename: not a directory, where filename is the last file whcih supposed to be copied as per the reference file. &lt;BR /&gt;&lt;BR /&gt;For example if use &lt;BR /&gt;touch -a -m -t 200510010000.00 $HOME/first.ref&lt;BR /&gt;touch -a -m -t 200511302359.59 $HOME/last.ref&lt;BR /&gt;&lt;BR /&gt;the above error is coming up with last file dated 20051130. I tried changing the date for touch and I am getting the same error for the last file created on the date as per last.ref.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Mon, 16 Nov 2009 18:28:04 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525914#M652033</guid>
      <dc:creator>ssheri</dc:creator>
      <dc:date>2009-11-16T18:28:04Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525915#M652034</link>
      <description>what happens with &lt;BR /&gt;&lt;BR /&gt;find . -xdev -type f -newer $HOME/first.ref -a !-newer $HOME/last.ref -exec ls -l {} \+&lt;BR /&gt;</description>
      <pubDate>Mon, 16 Nov 2009 21:25:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525915#M652034</guid>
      <dc:creator>OldSchool</dc:creator>
      <dc:date>2009-11-16T21:25:37Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525916#M652035</link>
      <description>It works fine. I am getting the error with last file in a purticular month as per the last.ref file when I do a cp instead ll.</description>
      <pubDate>Mon, 16 Nov 2009 21:29:41 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525916#M652035</guid>
      <dc:creator>ssheri</dc:creator>
      <dc:date>2009-11-16T21:29:41Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525917#M652036</link>
      <description>&amp;gt;2. find . -xdev -type f -newer $HOME/first.ref -a !-newer $HOME/last.ref -exec cp -p {} /yourname/2005/. \+&lt;BR /&gt;&lt;BR /&gt;(I would forget about cp instead of mv for a million files.)&lt;BR /&gt;&lt;BR /&gt;&amp;gt;-exec cp -p {} /yourname/2005/. \+&lt;BR /&gt;&lt;BR /&gt;You can't do this.  You can only put the {} last.  (Unless GNU find does it?)&lt;BR /&gt;(Also leave off the stinkin' \ before the "+".)&lt;BR /&gt;&lt;BR /&gt;So you'll need to write a script:&lt;BR /&gt;-exec cp_stuff.sh /yourname/2005 +&lt;BR /&gt;&lt;BR /&gt;Inside cp_stuff.sh you have:&lt;BR /&gt;#!/usr/bin/sh&lt;BR /&gt;# swap first to last to make "find -exec +" happy.&lt;BR /&gt;target=$1&lt;BR /&gt;shift&lt;BR /&gt;cp -p "$@" "$target"&lt;BR /&gt;&lt;BR /&gt;(The quotes are to make Steven happy with his stinkin' spaces.  :-)&lt;BR /&gt;&lt;BR /&gt;&amp;gt;OldSchool: what happens with &lt;BR /&gt;&lt;BR /&gt;Why fiddle with the find syntax when it is the -exec that is the problem?&lt;BR /&gt;Also this is what tusc is for.</description>
      <pubDate>Tue, 17 Nov 2009 10:37:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525917#M652036</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2009-11-17T10:37:03Z</dc:date>
    </item>
    <item>
      <title>Re: Zip files 1.7 Million files</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525918#M652037</link>
      <description>"Why fiddle with the find syntax when it is the -exec that is the problem?&lt;BR /&gt;Also this is what tusc is for."&lt;BR /&gt;&lt;BR /&gt;because it lost enough in translation that I couldn't tell that (from what the OP posted)... &lt;BR /&gt;&lt;BR /&gt;Plus, based on the question, I doubt that the OP has the ability to interpret the output of tusc....&lt;BR /&gt;</description>
      <pubDate>Tue, 17 Nov 2009 15:11:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/zip-files-1-7-million-files/m-p/4525918#M652037</guid>
      <dc:creator>OldSchool</dc:creator>
      <dc:date>2009-11-17T15:11:00Z</dc:date>
    </item>
  </channel>
</rss>

