[Dspace-tech] Does anyone have a script that gets rid of orphaned Assetstore files??

265 views
Skip to first unread message

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:42:29 PM8/24/15
to dspac...@lists.sourceforge.net, dspace...@lists.sourceforge.net
Hi,
     I noticed this week that we had duplicate bitstream rows in the "Bitstream" table in Dspace 1.2.2.  Only one was marked "Deleted=false" however and I'm assuming that these duplicate  rows got in there when multiple imports were done into DSpace way back when and no one ever noticed it.  They all had different bitstream ids, however all had the same name, size, checksum, etc and there was only one item in the Item table that related to a row in the Bitstream table (the one with Deleted=false of course).  I deleted over 6700 of these duplicate records this morning, but now I need to figure out a way to delete the corresponding documents in Assetstore.  Does anyone have a nice script that will accomplish this, that has been tested and proven to work?????  :-)
Thanks,
Sue
NASA Langley Research Center
Technical Library
ConITS Contract
 
 
 
 
sg-78ff.gif
11_b_phone.gif
23_c_cell.gif
37_g_fax.gif
47_g_letter.gif
IMSTP.gif
23c.gif

Grant Johnson

unread,
Aug 24, 2015, 3:42:34 PM8/24/15
to Sue Walker-Thornton, dspac...@lists.sourceforge.net, dspace...@lists.sourceforge.net
Sue,
Sorry if this is too simplistic but you didn't indicate if you used them.

Did ./cleanup and ./index-all not work?

--

F. Grant Johnson
566-0630 / fgjo...@upei.ca

Systems/Web Coordinator
RM 285 - Robertson Library
University of Prince Edward Island

***************
Attitude is IT!


Sue Walker-Thornton

unread,
Aug 24, 2015, 3:42:40 PM8/24/15
to fgjo...@upei.ca, dspac...@lists.sourceforge.net, dspace...@lists.sourceforge.net
Hi,
     We run index-all every night, but my understanding was that this job is what builds the search indices.  I've also run cleanup and it doesn't do a thing as far as I can see.  My row count in Bitstream is exactly the same before and after cleanup runs.  I have 8452 rows in Bitstream that are marked as "Deleted" = true and they are still there after Cleanup runs.  I read in the documentation that Cleanup looks in Bitstream and deletes all rows marked as "Deleted" = true if they are more than one hour old.  So now I'm left with the dilemma of having to write something that deletes the rows from Bitstream that are marked as "Deleted" and then delete the corresponding record out of Assetstore.
Thanks,
Sue
 
-------Original Message-------
.
IMSTP.gif
23c.gif

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:42:43 PM8/24/15
to fgjo...@upei.ca, dspac...@lists.sourceforge.net
Hi again Grant,
     Well, lookie what I just found in dspace.log:
 
2006-04-18 14:43:53,086 INFO  org.dspace.storage.bitstore.Cleanup @ Cleaning up asset store
2006-04-18 14:43:55,330 FATAL org.dspace.storage.bitstore.Cleanup @ Caught exception:
java.lang.NullPointerException
 at org.dspace.storage.bitstore.BitstreamStorageManager.deleteParents(BitstreamStorageManager.java:740)
 at org.dspace.storage.bitstore.BitstreamStorageManager.cleanup(BitstreamStorageManager.java:673)
 at org.dspace.storage.bitstore.Cleanup.main(Cleanup.java:67)
It's having some kind of problem on the highlighted line (if (files.length !=0)):
 
// Only delete empty directories
            if (files.length != 0)
            {
                break;
            }
 
            directory.delete();
            tmp = directory; 
 
I'm new at Java and have successfully found several errors and solutions in the past 6 months, however I'm stumped on this one right now.
Do you have any ideas??
Thanks much,
Sue
 
-------Original Message-------
 
Date: 04/18/06 13:51:56
Subject: Re: [Dspace-tech] Does anyone have a script that gets rid of orphaned Assetstore files??
 
Hmmmmm...
Sounds like what I was fighting with.
Again - I hope this isn't too simplistic a suggestion.........
 
Is Tomcat starting as user dspace?
Tomcat needs to start as user dspace, I was starting Tomcat as root and
therefore .cleanup(as dspace) did nothing b/c of user rights.
As soon as Tomcat was configured to launch "dspace"  ./cleanup runs
successfully.
 
Hope this helps.
 
--
 
F. Grant Johnson
566-0630 / fgjo...@upei.ca
 
Systems/Web Coordinator
RM 285 - Robertson Library
University of Prince Edward Island
 
***************
Attitude is IT!
 
.
IMSTP.gif
23c.gif

Scott Yeadon

unread,
Aug 24, 2015, 3:42:47 PM8/24/15
to s.m.th...@larc.nasa.gov, fgjo...@upei.ca, dspac...@lists.sourceforge.net
Hi Sue,

From this error, it looks like you have some incomplete paths or empty
directories in your assetstore which is causing the cleanup job to crash
(looks like from the getParentFile() call). Try running the following
from the command-line, this will list any empty directories:
find -depth -type d -empty

If you get some results back from that command, remove the empty
directories as follows:
find -depth -type d -empty -exec rmdir {} \;

Then run the cleanup again, and hopefully it should run without errors.

Scott.


Date: Tue, 18 Apr 2006 14:57:26 -0400 (Eastern Daylight Time)
From: "Sue Walker-Thornton" <s.m.th...@larc.nasa.gov>
To: <fgjo...@upei.ca>
Cc: <dspac...@lists.sourceforge.net>
Subject: Re: [Dspace-tech] Does anyone have a script that gets rid of orphaned Assetstore files??


--------------Boundary-00=_QZLXO2Q1VA4000000000
Content-Type: Multipart/Alternative;
boundary="------------Boundary-00=_QZLXJDU1VA4000000000"


--------------Boundary-00=_QZLXJDU1VA4000000000
Content-Type: Text/Plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hi again Grant,=0D
Well, lookie what I just found in dspace.log:=0D
=0D
2006-04-18 14:43:53,086 INFO org.dspace.storage.bitstore.Cleanup @ Clean=
ing
up asset store=0D
2006-04-18 14:43:55,330 FATAL org.dspace.storage.bitstore.Cleanup @ Caugh=
t
exception:=0D
java.lang.NullPointerException=0D
at org.dspace.storage.bitstore.BitstreamStorageManager
deleteParents(BitstreamStorageManager.java:740)=0D
at org.dspace.storage.bitstore.BitstreamStorageManager
cleanup(BitstreamStorageManager.java:673)=0D
at org.dspace.storage.bitstore.Cleanup.main(Cleanup.java:67)=0D
=0D
It's having some kind of problem on the highlighted line (if (files.lengt=
h
!=3D0)):=0D
=0D
// Only delete empty directories=0D
if (files.length !=3D 0)=0D
{=0D
break;=0D
}=0D
=0D
directory.delete();=0D
tmp =3D directory; =0D
=0D
I'm new at Java and have successfully found several errors and solutions =
in
the past 6 months, however I'm stumped on this one right now.=0D
Do you have any ideas??=0D
Thanks much,=0D
Sue=0D



Scott Yeadon

unread,
Aug 24, 2015, 3:42:48 PM8/24/15
to s.m.th...@larc.nasa.gov, fgjo...@upei.ca, dspac...@lists.sourceforge.net
Hi Sue,

Sorry also should have mentioned run those 'find' commands from within
your $DSPACE/assetstore directory.

Scott.

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:42:50 PM8/24/15
to scott....@anu.edu.au, fgjo...@upei.ca, dspac...@lists.sourceforge.net
Got it!
Thanks,
Sue 
 
-------Original Message-------
IMSTP.gif
23c.gif

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:42:51 PM8/24/15
to scott....@anu.edu.au, fgjo...@upei.ca, dspac...@lists.sourceforge.net
Hi Scott,
     Thanks very much for the suggestion.  I am running a mass-record import right now and don't want to mess with Assetstore, but will try this after the import finishes.  One question - what exactly is "Cleanup" supposed to do?  Is it supposed to *both* delete the records in Bitstream marked as deleted AND delete the corresponding record in Assetstore?
Thanks again Scott - will let you know how it turns out!
Sue 
 
-------Original Message-------
IMSTP.gif
23c.gif

Scott Yeadon

unread,
Aug 24, 2015, 3:42:52 PM8/24/15
to Sue Walker-Thornton, dspac...@lists.sourceforge.net
Hi Sue,

Yes, cleanup will remove records flagged as deleted from the database
and their bitstreams in the assetstore.

Scott.

Sue Walker-Thornton wrote:

> Hi Scott,
> Thanks very much for the suggestion. I am running a mass-record
> import right now and don't want to mess with Assetstore, but will try
> this after the import finishes. One question - what exactly is
> "Cleanup" supposed to do? Is it supposed to *both* delete the records
> in Bitstream marked as deleted AND delete the corresponding record in
> Assetstore?
> Thanks again Scott - will let you know how it turns out!
> Sue
>
> /-------Original Message-------/
>
> /*From:*/ Scott Yeadon <mailto:scott....@anu.edu.au>
> /*Date:*/ 04/18/06 20:21:16
> /*To:*/ s.m.th...@larc.nasa.gov <mailto:s.m.th...@larc.nasa.gov>
> /*Cc:*/ fgjo...@upei.ca <mailto:fgjo...@upei.ca>;
> dspac...@lists.sourceforge.net
> <mailto:dspac...@lists.sourceforge.net>
> /*Subject:*/ Re: [Dspace-tech] Does anyone have a script that gets rid
> of orphaned Assetstore files??
>
> Hi Sue,
>
> From this error, it looks like you have some incomplete paths or empty
> directories in your assetstore which is causing the cleanup job to crash
> (looks like from the getParentFile() call). Try running the following
> from the command-line, this will list any empty directories:
> find -depth -type d -empty
>
> If you get some results back from that command, remove the empty
> directories as follows:
> find -depth -type d -empty -exec rmdir {} \;
>
> Then run the cleanup again, and hopefully it should run without errors.
>
> Scott.
>
>
> Date: Tue, 18 Apr 2006 14:57:26 -0400 (Eastern Daylight Time)
> From: "Sue Walker-Thornton" <s.m.th...@larc.nasa.gov
> <mailto:s.m.th...@larc.nasa.gov>>
> To: <fgjo...@upei.ca <mailto:fgjo...@upei.ca>>
> Cc: <dspac...@lists.sourceforge.net
> <mailto:dspac...@lists.sourceforge.net>>
> < Verdana html Font: Body:>
> <http://www.incredimail.com/index.asp?id=409&lang=9>



dspace

unread,
Aug 24, 2015, 3:42:57 PM8/24/15
to dspac...@lists.sourceforge.net
Hi,

I tried running "cleanup" and I got the same error like Sue. When I try
find some empty directories in assetstore directory tree I get no results.
Does anybody know what else can be wrong?

Thanks for any idea

Dusan Jaluvka
VSB - Technical university of Ostrava
Czech republic

Dne Wed, 19 Apr 2006 19:09:26 +0200 napsal/-a Sue Walker-Thornton
<s.m.th...@larc.nasa.gov> následující zprávu:

Scott Yeadon

unread,
Aug 24, 2015, 3:43:00 PM8/24/15
to dspac...@gmail.com, dspac...@lists.sourceforge.net
Dusan,

Can you change your debug level from INFO to DEBUG in your $DSPACE/config/log4j.properties file and run the cleanup job again. See if that pinpoints the record/directory that is causing the error.

Scott.

Date: Thu, 20 Apr 2006 18:13:20 +0200
From: dspace <dspac...@gmail.com>
To: dspac...@lists.sourceforge.net
Subject: Re: [Dspace-tech] Does anyone have a script that gets rid of orphaned Assetstore files??
Organization: vsb.cz

Hi,

I tried running "cleanup" and I got the same error like Sue. When I try =20
find some empty directories in assetstore directory tree I get no results=
. =20
Does anybody know what else can be wrong?

Thanks for any idea

Dusan Jaluvka
VSB - Technical university of Ostrava
Czech republic

Dne Wed, 19 Apr 2006 19:09:26 +0200 napsal/-a Sue Walker-Thornton =20
<s.m.th...@larc.nasa.gov> n=E1sleduj=EDc=ED zpr=E1vu:


>> Hi Scott,
>>
>> Thanks very much for the suggestion. I am running a mass-record =20
>> import
>> right now and don't want to mess with Assetstore, but will try this aft=
>
>
er

>> the import finishes. One question - what exactly is "Cleanup" supposed=
>
>
=20

>> to
>> do? Is it supposed to *both* delete the records in Bitstream marked as
>> deleted AND delete the corresponding record in Assetstore?
>>
>> Thanks again Scott - will let you know how it turns out!
>>
>> Sue
>>
>>
>> -------Original Message-------
>>
>>
>> From: Scott Yeadon
>>
>> Date: 04/18/06 20:21:16
>>
>> To: s.m.th...@larc.nasa.gov
>>
>> Cc: fgjo...@upei.ca; dspac...@lists.sourceforge.net
>>
>> Subject: Re: [Dspace-tech] Does anyone have a script that gets rid of
>> orphaned Assetstore files??
>>
>>
>> Hi Sue,
>>
>>
>> From this error, it looks like you have some incomplete paths or empt=
>
>
y

>>
>> directories in your assetstore which is causing the cleanup job to cras=

dspace

unread,
Aug 24, 2015, 3:43:10 PM8/24/15
to Scott Yeadon, dspac...@lists.sourceforge.net
Hi Scott,
when I changed log level to DEBUG I got this error:

2006-04-21 13:04:54,877 DEBUG org.dspace.storage.rdbms.DatabaseManager @
Running query "select * from Bitstream where deleted = 't'"
2006-04-21 13:04:56,194 DEBUG
org.dspace.storage.bitstore.BitstreamStorageManager @ Local filename for
32958849690313586119493619111701493795 is
/home/dspace/assetstore/32/95/88/32958849690313586119493619111701493795
2006-04-21 13:04:56,208 DEBUG org.dspace.storage.rdbms.DatabaseManager @
Running query "delete from bitstream where bitstream_id = '39'"
2006-04-21 13:04:56,220 DEBUG
org.dspace.storage.bitstore.BitstreamStorageManager @ Deleted bitstream 39
(file
/home/dspace/assetstore/32/95/88/32958849690313586119493619111701493795)
with result false
2006-04-21 13:04:56,223 FATAL org.dspace.storage.bitstore.Cleanup @ Caught
exception:
java.lang.NullPointerException
at
org.dspace.storage.bitstore.BitstreamStorageManager.deleteParents(BitstreamStorageManager.java:740)
at
org.dspace.storage.bitstore.BitstreamStorageManager.cleanup(BitstreamStorageManager.java:673)
at org.dspace.storage.bitstore.Cleanup.main(Cleanup.java:67)

I checked file listed in log and I detect that there is no subdirectory in
directory dspace/assetstore/32. When I make directory
dspace/assetstore/32/95/88 cleanup break on other file. I looked in
BitstreamStorageManager.java and change line with deleteParents().

In cleanup() I delete parents only if file.delete() returns true.

boolean success = file.delete();

if (log.isDebugEnabled())
{
log.debug("Deleted bitstream " + bid + " (file "
+ file.getAbsolutePath() + ") with result "
+ success);
}

if (success) deleteParents(file);
}

context.complete();

Now, cleanup runs fine

Thanks for your help

Dusan Jaluvka
VSB - Technical university of Ostrava
Czech republic

Dne Fri, 21 Apr 2006 06:27:50 +0200 napsal/-a Scott Yeadon
<scott....@anu.edu.au> následující zprávu:

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:46:06 PM8/24/15
to scott....@anu.edu.au, dspac...@gmail.com, dspac...@lists.sourceforge.net
I'm trying to make the same change to BitstreamStorageManager.java, but am getting compile errors with the following code:
 
import edu.sdsc.grid.io.FileFactory;
import edu.sdsc.grid.io.GeneralFile;
import edu.sdsc.grid.io.GeneralFileOutputStream;
import edu.sdsc.grid.io.local.LocalFile;
import edu.sdsc.grid.io.srb.SRBAccount;
import edu.sdsc.grid.io.srb.SRBFile;
import edu.sdsc.grid.io.srb.SRBFileSystem;
 
What do I need to get the program to compile??
 
Thanks,
Sue
 
-------Original Message-------
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
_______________________________________________
DSpace-tech mailing list
.
IMSTP.gif
23c.gif

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:46:07 PM8/24/15
to scott....@anu.edu.au, dspac...@gmail.com, dspac...@lists.sourceforge.net
Thanks everyone who replied to this message.  After I correctly added jargon.jar to the classpath, it compiled fine.
Thanks again!!
Sue 
 
-------Original Message-------
 
Date: 04/25/06 16:23:12
IMSTP.gif
23c.gif

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:46:21 PM8/24/15
to scott....@anu.edu.au, dspac...@gmail.com, dspac...@lists.sourceforge.net
Sorry - forgot to include my code....Here is the code I put in BitstreamStorageManager.java:
 
 DatabaseManager.delete(context, "Bitstream", bid);
 
    if (isRegisteredBitstream(row.getStringColumn("internal_id"))) {
        continue;   // do not delete registered bitstreams
    }
 
                boolean success = file.delete();
 
                if (log.isDebugEnabled())
                {
                 log.debug("log is debug enabled");   <-- this does NOT display in log, but other                                                                     displays show up in the log (see bottom of this code)
                    log.debug("Deleted bitstream " + bid + " (file "
                            + file.getAbsolutePath() + ") with result "
                            + success);
                }
                // 04/25/2006 SMWT - Change begins
                if (success)
                   { deleteParents(file);
                   }
                    
 
                   // deleteParents(file);
               // 04/25/2006 - Change ends
            }
 
            context.complete();
          }
 
 
Here is what DOES display in the log:
 
2006-04-26 13:41:16,221 INFO  org.dspace.storage.bitstore.Cleanup @ Cleaning up asset store
2006-04-26 13:41:16,505 DEBUG org.dspace.storage.rdbms.DatabaseManager @ Running query "select * from Bitstream where deleted = 't'"
2006-04-26 13:41:18,128 DEBUG org.dspace.storage.bitstore.BitstreamStorageManager @ Local filename for 143932774548522411732039458334760354644 is /export/home/dspace/assetstore/14/39/32/143932774548522411732039458334760354644
2006-04-26 13:41:18,130 DEBUG org.dspace.storage.rdbms.DatabaseManager @ Running query "delete from bitstream where bitstream_id = '21'"
2006-04-26 13:41:18,231 DEBUG org.dspace.storage.bitstore.BitstreamStorageManager @ Deleted bitstream 21 (file /export/home/dspace/assetstore/14/39/32/143932774548522411732039458334760354644) with result false
2006-04-26 13:41:18,250 FATAL org.dspace.storage.bitstore.Cleanup @ Caught exception:

java.lang.NullPointerException
 at org.dspace.storage.bitstore.BitstreamStorageManager.deleteParents(BitstreamStorageManager.java:740)
 at org.dspace.storage.bitstore.BitstreamStorageManager.cleanup(BitstreamStorageManager.java:673)
 at org.dspace.storage.bitstore.Cleanup.main(Cleanup.java:67)
 
 
I'm also attaching a copy of my BitstreamStorageManager.java to this email.
Thanks a bunch!
 
Sue
 
 
-------Original Message-------
 
From: dspace
Date: 04/22/06 18:49:10
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
_______________________________________________
DSpace-tech mailing list
.
IMSTP.gif
23c.gif
BitstreamStorageManager.java

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:46:21 PM8/24/15
to scott....@anu.edu.au, dspac...@gmail.com, dspac...@lists.sourceforge.net
Hi,
     I changed my log level to DEBUG, made the program change outlined below, got the program to compile, copied the .class file back to dspace/jsp/WIN-INF.....classes/storage... and also to dspace/WIN-INF...classes/storage... and also to dspace-1.3.2-source/build.  For some reason, I am still getting the exact same error(s) as before with the exact same line numbers.  I even put in some more log.debug statements to display things and none of these are displaying in the log, which indicates to me that my new version of the program is NOT being picked up.  Is there something I'm missing? 
Thanks,
Sue
 
-------Original Message-------
 
From: dspace
Date: 04/22/06 18:49:10
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
_______________________________________________
DSpace-tech mailing list
.
IMSTP.gif
23c.gif

dspace

unread,
Aug 24, 2015, 3:46:22 PM8/24/15
to Sue Walker-Thornton, dspac...@lists.sourceforge.net
Hi,
I made changes in dspace-source and then I run ant
-Dconfig=/dspace/config/dspace.cfg update. Source code has been compiled
and new jars were copied to [dspace]/lib.

Then I run cleanup.

Dusan Jaluvka

Dne Wed, 26 Apr 2006 19:52:29 +0200 napsal/-a Sue Walker-Thornton
<s.m.th...@larc.nasa.gov> následující zprávu:
> BitstreamStorageManager @ Local filename for
> 143932774548522411732039458334760354644 is
> /export/home/dspace/assetstore/14/39/32/1439327745485224117320394583347603546
> 4
>
> 2006-04-26 13:41:18,130 DEBUG org.dspace.storage.rdbms.DatabaseManager @
> Running query "delete from bitstream where bitstream_id = '21'"
>
> 2006-04-26 13:41:18,231 DEBUG org.dspace.storage.bitstore
> BitstreamStorageManager @ Deleted bitstream 21 (file
> /export/home/dspace/assetstore/14/39/32/1439327745485224117320394583347603546
> 4) with result false
>
> 2006-04-26 13:41:18,250 FATAL org.dspace.storage.bitstore.Cleanup @
> Caught
> exception:
>
> java.lang.NullPointerException
>
> at org.dspace.storage.bitstore.BitstreamStorageManager
> deleteParents(BitstreamStorageManager.java:740)
>
> at org.dspace.storage.bitstore.BitstreamStorageManager
> deleteParents(BitstreamStorageManager.java:740)
>
> at
>
> org.dspace.storage.bitstore.BitstreamStorageManager

Scott Yeadon

unread,
Aug 24, 2015, 3:46:25 PM8/24/15
to Sue Walker-Thornton, dspac...@gmail.com, dspac...@lists.sourceforge.net
Sue,

You need to rebuild dspace.jar and put it in your $DSPACE/lib directory.
(If you just do the usual war rebuild, this is done automatically). The
'dsrun' script which is called from the 'cleanup' script sets the
classpath to point to the jars in $DSPACE/lib.

Scott.

Sue Walker-Thornton wrote:

> Hi,
> I changed my log level to DEBUG, made the program change outlined
> below, got the program to compile, copied the .class file back to
> dspace/jsp/WIN-INF.....classes/storage... and also to
> dspace/WIN-INF...classes/storage... and also to
> dspace-1.3.2-source/build. For some reason, I am still getting the
> exact same error(s) as before with the exact same line numbers. I
> even put in some more log.debug statements to display things and none
> of these are displaying in the log, which indicates to me that my new
> version of the program is NOT being picked up. Is there something I'm
> missing?
> Thanks,
> Sue
>
> /-------Original Message-------/
>
> /*From:*/ dspace <mailto:dspac...@GMAIL.COM>
> /*Date:*/ 04/22/06 18:49:10
> /*To:*/ Scott Yeadon <mailto:scott....@anu.edu.au>
> /*Cc:*/ dspac...@lists.sourceforge.net
> <mailto:dspac...@lists.sourceforge.net>
> /*Subject:*/ [Dspace-tech] Re: Does anyone have a script that gets rid
> <scott....@anu.edu.au <mailto:scott....@anu.edu.au>> následující
> zprávu:
>
> > Dusan,
> >
> > Can you change your debug level from INFO to DEBUG in your
> > $DSPACE/config/log4j.properties file and run the cleanup job again. See
> > if that pinpoints the record/directory that is causing the error.
> >
> > Scott.
> >
> > Date: Thu, 20 Apr 2006 18:13:20 +0200
> > From: dspace <dspac...@gmail.com <mailto:dspac...@gmail.com>>
> > To: dspac...@lists.sourceforge.net
> <mailto:dspac...@lists.sourceforge.net>
> > Subject: Re: [Dspace-tech] Does anyone have a script that gets rid of
> > orphaned Assetstore files??
> > Organization: vsb.cz
> >
> > Hi,
> >
> > I tried running "cleanup" and I got the same error like Sue. When I try
> > =20
> > find some empty directories in assetstore directory tree I get no
> > results=
> > . =20
> > Does anybody know what else can be wrong?
> >
> > Thanks for any idea
> >
> > Dusan Jaluvka
> > VSB - Technical university of Ostrava
> > Czech republic
>
>
>
>
>
> -------------------------------------------------------
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job
> easier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> <http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642>
> _______________________________________________
> DSpace-tech mailing list
> DSpac...@lists.sourceforge.net
> <mailto:DSpac...@lists.sourceforge.net>
> https://lists.sourceforge.net/lists/listinfo/dspace-tech
> .

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:46:26 PM8/24/15
to scott....@anu.edu.au, dspac...@gmail.com, dspac...@lists.sourceforge.net
Hi Scott - So the .class file in /dspace/jsp/WEB-INF/classes...... are not used??  Or rather, they are not the .class files that get executed???  Before, whenever I changed a java program, I compiled it myself in JCreator, then copied the source back to /dspace-source and copied the .class files to /dspace-source/build and somehow it's always worked until now......With BitstreamStorageManager, I couldn't get it to see my changes until I ran the ant....update command.  Any ideas?
Thanks,
Sue
 
-------Original Message-------
 
Date: 04/26/06 18:42:55
.
IMSTP.gif
23c.gif

Scott Yeadon

unread,
Aug 24, 2015, 3:46:27 PM8/24/15
to Sue Walker-Thornton, dspac...@gmail.com, dspac...@lists.sourceforge.net
Sue,

Your webapp class files (the WEB-INF ones) are used when you're
operating in the Tomcat environment (i.e. when you're in a web app
context), when you're running the batch jobs these aren't set in the
classpath.

Scott.

Sue Walker-Thornton wrote:

> Hi Scott - So the .class file in /dspace/jsp/WEB-INF/classes...... are
> not used?? Or rather, they are not the .class files that get
> executed??? Before, whenever I changed a java program, I compiled it
> myself in JCreator, then copied the source back to /dspace-source and
> copied the .class files to /dspace-source/build and somehow it's
> always worked until now......With BitstreamStorageManager, I couldn't
> get it to see my changes until I ran the ant....update command. Any
> ideas?
> Thanks,
> Sue
>
> /-------Original Message-------/
>
> /*From:*/ Scott Yeadon <mailto:scott....@anu.edu.au>
> /*Date:*/ 04/26/06 18:42:55
> /*To:*/ Sue Walker-Thornton <mailto:s.m.th...@larc.nasa.gov>
> /*Cc:*/ dspac...@gmail.com <mailto:dspac...@gmail.com>;
> dspac...@lists.sourceforge.net
> <mailto:dspac...@lists.sourceforge.net>
> /*Subject:*/ Re: [Dspace-tech] Re: Does anyone have a script that gets
> <http://www.incredimail.com/index.asp?id=409&lang=9>>

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:46:29 PM8/24/15
to scott....@anu.edu.au, dspac...@gmail.com, dspac...@lists.sourceforge.net
Ah.....that's why my other changes worked.....because they were to "online" programs, not "batch" like "cleanup".  (Can you tell I'm an old mainframe programmer???  :-)
Thanks again,
Sue 
 
-------Original Message-------
 
IMSTP.gif
23c.gif

Sue Walker-Thornton

unread,
Aug 24, 2015, 3:46:31 PM8/24/15
to dspac...@gmail.com, dspac...@lists.sourceforge.net
It worked!!  I never knew about the ant....update command.  Before, I always compiled my own java code and manually copied the .class files over.  I honestly don't know how that one got by me.  :-)   THANK YOU very much for your help!  I now have a nice clean Bitstream table and Assetstore directory.
Thanks again,
Sue
p.s.  I also made another change to BitstreamStorageManager.java....In that same block of code that you changed, I also check for (success) before I check for log.isDebugEnabled so that you ONLY get that line of code in your log IF the delete was successful.  Before, if DEBUG was enabled, it was displaying that line indicating it had done the delete when it actually had not.  By the way, the problem it had with my application is that it was trying to delete 102534............ and there was a subdirectory 10 and there was a subdirectory 25, but there was NOT a subdirectory 34.
 
-------Original Message-------
 
From: dspace
Date: 04/26/06 17:47:12
IMSTP.gif
23c.gif
Reply all
Reply to author
Forward
0 new messages