Hi Zico,

>> I have already followed this doc. But, i am facing problem at the time of
>> $in_directory. What is it actually??

When you run stat-initial (or stat-monthly / stat-general) it takes the
files [dspace]/log/dspace.log* and makes some statistical data files in
[dspace]/log/*****.dat

When you then run the jobs to create the reports (e.g. stat-report-initial)
the $in_directory relates to the location of these .dat files.

Some checks to carry out:

 - Do the [dspace]/log/dspace.log files appear as expected?
 - After running stat-initial, are [dspace]/log/***.dat files created?
 - Are $start_year and $start_month the same in all the stat scripts?

>> I gave the directory location of log of dspace directory there.
>> /usr/src/dspace/log
>> 
>> But, it didn`t work! When i go to run the
>> /usr/src/dspace/bin/stat-report-initial   command, then the error comes:
>> "Failed to read input file"
>> "Failed to read input file"
>> "Failed ......"
>> .....

Assuming all the checks above are OK, then you'll need to edit some java
code to work out what exactly is going on. (This has been included in 1.5 by
default). 

Open [dspace-src]/src/org/dspace/app/statistics/ReportGenerator.java and
find the following code around line 632:

  632         String record = null;
  633         try
  634         {
  635             fr = new FileReader(input);
  636             br = new BufferedReader(fr);
  637         }
  638         catch (IOException e)
  639         {
  640             System.out.println("Failed to read input file");
  641             System.exit(0);
  642         }

Edit line 640 so that it reads:

System.out.println("Failed to read input file: " + input);

Run an 'ant -Dconfig=[dspace]/config/dspace.cfg update' and then re-run the
stats script. It should now report what file it is not finding, and this
will help with working out what is going wrong.

Thanks,


Stuart
_________________________________________________________________

Gwasanaethau Gwybodaeth                      Information Services
Prifysgol Aberystwyth                      Aberystwyth University

            E-bost / E-mail: [EMAIL PROTECTED]
                 Ffon / Tel: (01970) 622860
_________________________________________________________________


-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech

Reply via email to