From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: fred@wiley.gsm.ucdavis.edu Newsgroups: gmane.os.tru64.managers Subject: File I/O performance question Date: Wed, 01 May 2002 10:33:28 -0700 Sender: tru64-unix-managers-owner@ornl.gov Message-ID: <00A0D484.185D5BE9.17@wiley.gsm.ucdavis.edu> NNTP-Posting-Host: localhost.gmane.org X-Trace: main.gmane.org 1020277332 21370 127.0.0.1 (1 May 2002 18:22:12 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 1 May 2002 18:22:12 +0000 (UTC) Return-path: Original-Received: from sws1.ctd.ornl.gov ([160.91.20.101]) by main.gmane.org with smtp (Exim 3.33 #1 (Debian)) id 172yjz-0005YZ-00 for ; Wed, 01 May 2002 20:22:12 +0200 Original-Received: (qmail 8551 invoked by uid 5); 1 May 2002 17:33:31 -0000 Original-Followup-To: poster Precedence: bulk Original-Received: (qmail 8543 invoked from network); 1 May 2002 17:33:31 -0000 Original-Received: from unknown (HELO emroute1.cind.ornl.gov) (134.167.3.119) by 0 with SMTP; 1 May 2002 17:33:31 -0000 Original-Received: from emroute1.cind.ornl.gov (localhost [127.0.0.1]) by emroute1.cind.ornl.gov (PMDF V6.1 #39060) with ESMTP id <0GVG00DK40RUDC@emroute1.cind.ornl.gov> for tru64-unix-managers@sws1.ctd.ornl.gov (ORCPT TRU64-UNIX-MANAGERS@ORNL.GOV) ; Wed, 01 May 2002 13:33:31 -0400 (EDT) Original-Received: from wiley.gsm.ucdavis.edu (wiley.gsm.ucdavis.edu [169.237.100.7]) by emroute1.cind.ornl.gov (PMDF V6.1 #39060) with ESMTP id <0GVG00FEE0RTED@emroute1.cind.ornl.gov> for tru64-unix-managers@sws1.ctd.ornl.gov (ORCPT TRU64-UNIX-MANAGERS@ORNL.GOV) ; Wed, 01 May 2002 13:33:29 -0400 (EDT) Original-Received: by wiley.gsm.ucdavis.edu (MX V5.1-A AnFt) id 17; Wed, 01 May 2002 10:33:28 -0700 Original-To: TRU64-UNIX-MANAGERS@ORNL.GOV Xref: main.gmane.org gmane.os.tru64.managers:6 X-Report-Spam: http://spam.gmane.org/gmane.os.tru64.managers:6 I have an 85Gb data set in 1400 (daily) files. The individual files are sorted by the primary key. I need to create either a sorted single file, or more likely, sorted individual files (there are about 4 million different keys). Creating individual files is done by reading each daily file and appending each record to an appropriate file (done with Perl). The number of different keys per daily file runs in the range of 700,000 to 1.5 million. This, of course, leads to a large number of open/close file operations. In searching the archives I confirmed that it wouldn't be very effective to put all 4 million files in a single directory. I tested breaking them up into both 100 different directories and 1000 different directories. Using more directories increased the run time by about 30%. However, even using 100 different directories isn't very effective; right now the estimated run time is on the order of 5+ weeks. I suspect this is due to the 700,000+ open/write/close file operations (per file) as I can read thru the entire data set in a day or so. I would appreciate any suggestions on a better way to deal with the creation/updating of 4 million files :-) This is, luckily, a one time operation. The disk is a 500 Gb Raid-5, using ADVFS. thanks