Discussion:
[Dspace-tech] Problem with uploading a file to the collection
Shwe Yee Than
2007-09-05 02:22:18 UTC
Permalink
Hi,

I'm new to Dspace. I've encountered 2 problems after the installation of Dspace 1.4.2.

The fist problem is I've got the following error message when I upload a file (.pdf) to the collection.

HTTP Status 500 -
---------------------------------
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception

java.lang.NoClassDefFoundError
org.dspace.content.Bitstream.create(Bitstream.java:184)
org.dspace.content.Bundle.createBitstream(Bundle.java:362)
org.dspace.content.Item.createSingleBitstream(Item.java:1205)
org.dspace.app.webui.servlet.SubmitServlet.processChooseFile(SubmitServlet.java:1042)
org.dspace.app.webui.servlet.SubmitServlet.doDSPost(SubmitServlet.java:332)
org.dspace.app.webui.servlet.DSpaceServlet.processRequest(DSpaceServlet.java:147)
org.dspace.app.webui.servlet.DSpaceServlet.doPost(DSpaceServlet.java:105)
javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
org.dspace.app.webui.filter.RegisteredOnlyFilter.doFilter(RegisteredOnlyFilter.java:98)

note The full stack trace of the root cause is available in the Apache Tomcat/5.5.23 logs.

The second problem is I can't access the Dspace Page (i.e., http://fsktm.geranium2.um.edu.my:8080/dspace) from any other PCs rather than the localhost. The following is my configuration for Dspace in the [dspace-source]/config/dspace.cfg file:


dspace.dir = /home/dspace/tomcat/webapps/dspace
dspace.url = http://fsktm.geranium2.um.edu.my:8080/dspace
dspace.hostname = fsktm.geranium2.um.edu.my

Can anyone help me to solve theses problems? I'm really appreciate for the helping hands.

Regards,
~Shwe~


---------------------------------
Sick sense of humor? Visit Yahoo! TV's Comedy with an Edge to see what's on, when.
Christian Voelker
2007-09-05 08:28:53 UTC
Permalink
Hello,
Post by Shwe Yee Than
The second problem is I can't access the Dspace Page (i.e., http://
fsktm.geranium2.um.edu.my:8080/dspace) from any other PCs rather
than the localhost. The following is my configuration for Dspace
Did you change this file after installation?
Did you make sure, these changes got reflected in
[dspace]/config/dspace.cfg?
ant install-cfg would be a means to do so.
Post by Shwe Yee Than
dspace.dir = /home/dspace/tomcat/webapps/dspace
No, this should point to the dir where your assetstore, history
and so on lives. This should not be the same directory that is
exposed to the web. In case you installed it there, you should
change this before going productive. Common procedures expect
this to be separate. Especially any changes you might want to
make to the jsp frontend are far more easily done if you can
just wipe this directory and replace it with a new .war file.
If your bitstreams are in the same directory, that is not
feasable. Besides, there a probably security issues why the
programmers decided to keep both directories separate.

To come back to your question, this variable is never read
by a client and should not be the cause for not being reachable
from outside.
Post by Shwe Yee Than
dspace.url = http://fsktm.geranium2.um.edu.my:8080/dspace
dspace.hostname = fsktm.geranium2.um.edu.my
I never saw the ccTLD .my before, but as it is your valid domain,
thats looks fine.
Post by Shwe Yee Than
The fist problem is I've got the following error message
when I upload a file (.pdf) to the collection.
HTTP Status 500 -
...
exception
java.lang.NoClassDefFoundError
org.dspace.content.Bitstream.create(Bitstream.java:184)
...
note The full stack trace of the root cause is available in the Apache Tomcat/5.5.23 logs.
I cant say much to this. It does not look like a DB permissions
issue although this method directly calls the BitstreamStorageManager
which in turn opens a DB connection, but if the problem was there,
then it would be notified as a SQLexeption, not an exeption.
I would go to the tomcat log as advised.
Or, I would change the logging level to info at least
in the log4j configuration.
Is the context you are working in valid?
Id est, are you allowed to upload to this collection?
I guess you would not get to the uplaod page if not.
No, sorry, no help from here.

Maybe, this gets solved automagically as soon as you solve the
dspace.dir issue. Your server might not be able to write the
.pdf file to a directory beyond webapps because of general
security constraints of the tomcat configuration. That would
make sense. So take care for the simple dspace.cfg stuff first
and you might be done.

Bye, Christian
Shwe Yee Than
2007-09-18 06:05:48 UTC
Permalink
Hi,

Thanks Christian. The problem was successfully solved.

With regards,
Shwe
Post by Shwe Yee Than
The second problem is I can't access the Dspace Page (i.e., http://
fsktm.geranium2.um.edu.my:8080/dspace) from any other PCs rather
than the localhost. The following is my configuration for Dspace
Did you change this file after installation?
Did you make sure, these changes got reflected in
[dspace]/config/dspace.cfg?
ant install-cfg would be a means to do so.
Post by Shwe Yee Than
dspace.dir = /home/dspace/tomcat/webapps/dspace
No, this should point to the dir where your assetstore, history
and so on lives. This should not be the same directory that is
exposed to the web. In case you installed it there, you should
change this before going productive. Common procedures expect
this to be separate. Especially any changes you might want to
make to the jsp frontend are far more easily done if you can
just wipe this directory and replace it with a new .war file.
If your bitstreams are in the same directory, that is not
feasable. Besides, there a probably security issues why the
programmers decided to keep both directories separate.

To come back to your question, this variable is never read
by a client and should not be the cause for not being reachable
from outside.
Post by Shwe Yee Than
dspace.url = http://fsktm.geranium2.um.edu.my:8080/dspace
dspace.hostname = fsktm.geranium2.um.edu.my
I never saw the ccTLD .my before, but as it is your valid domain,
thats looks fine.
Post by Shwe Yee Than
The fist problem is I've got the following error message
when I upload a file (.pdf) to the collection.
HTTP Status 500 -
...
exception
java.lang.NoClassDefFoundError
org.dspace.content.Bitstream.create(Bitstream.java:184)
...
note The full stack trace of the root cause is available in the
Apache Tomcat/5.5.23 logs.
I cant say much to this. It does not look like a DB permissions
issue although this method directly calls the BitstreamStorageManager
which in turn opens a DB connection, but if the problem was there,
then it would be notified as a SQLexeption, not an exeption.
I would go to the tomcat log as advised.
Or, I would change the logging level to info at least
in the log4j configuration.
Is the context you are working in valid?
Id est, are you allowed to upload to this collection?
I guess you would not get to the uplaod page if not.
No, sorry, no help from here.

Maybe, this gets solved automagically as soon as you solve the
dspace.dir issue. Your server might not be able to write the
.pdf file to a directory beyond webapps because of general
security constraints of the tomcat configuration. That would
make sense. So take care for the simple dspace.cfg stuff first
and you might be done.

Bye, Christian




---------------------------------
Be a better Heartthrob. Get better relationship answers from someone who knows.
Yahoo! Answers - Check it out.

Continue reading on narkive:
Loading...