Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Formatting cleanup. Minor additions

...

Code Block
## In Linux, run the following command then reproduce the internal error state
 ## use the pathname prefix appropriate to your DSpace installation
 tail -F /var/logs/dspace.log

 ## and you should see something of the kind

2009-05-18 12:52:45,935 WARN  org.dspace.app.webui.servlet.DSpaceServlet @ name\
@place:session_id=F32DD4066DD475B8841A2A2204961B9A:ip_addr=1.2\
.3.4:database_error:org.postgresql.util.PSQLException: ERROR: duplicate key \
violates unique constraint "metadatafieldregistry_pkey"
org.postgresql.util.PSQLException: ERROR: duplicate key violates unique constra\
int "metadatafieldregistry_pkey"
        at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryE\
xecutorImpl.java:1525)

What's the best strategy for backing up/restoring DSpace?

From the Documentation, see Storage Layer (which describes the basics for backing up your database and file storage). Also see AIP Backup and Restore, which describes how to backup your DSpace to a set of Archival Information Packages (AIPs).

Finally, there is a somewhat outdated summary at See BackupRestore.

How do I run DSpace on port 80/443?

...

Do I need HTTPS (SSL)?

See SecuringDspace,

also Also ServletSecurity for more details.

...

A couple of things to try:

  • If you've upgraded to DSpace 1.2 from a prior version, ensure that your header JSP includes the following line:

    Code Block
    <SCRIPT LANGUAGE="JavaScript" src="<%= request.getContextPath() %>/utils.js"></script>

    That needs to be in the <HEAD> element. It's in jsp/layout/header-default.jsp but if you have a locally modified version, your modified copy might not have this line.

  • The e-person tool is a pop-up window. Check that your browser isn't blocking pop-ups for your DSpace installation.
    This pop-up window was, in retrospect, a controversial point. Post explaining the decision
  • If your site 'skin' has a form in it (e.g. a search box) this breaks the JavaScript, specifically the references in jsp/utils.js to window.document.forms0.

...

My personal experience shows that this happens when I run it as dspace, but not as root. Not sure yet why this happens, but this may be a quick fix until it is sorted out. Also, bear this potential "problem" in mind when setting up cron jobs for filter-media, index-all, and others. 

Also note that running index-all as dspace does not hang, even though it does (apparently) the same thing.

...

If something doesn't seem to be working, you can often find out more by upping the logging level of DSpace. To do this:1.

  1. Edit [dspace]/config/log4j.properties.

...

  1. Change the level by changing this line:

    Code Block
    log4j.rootCategory=INFO, A1

    to this:

    Code Block
    log4j.rootCategory=DEBUG, A1

...

  1. Restart Tomcat (or Resin, etc.).

Now you'll find there's a lot more information in [dspace]/log/dspace.log. You can switch on and off logging for particular DSpace classes. For example, if you just want to know about SQL queries going to the database, you could leave the main level above as INFO, and instead add the following line (then restart Tomcat):

...

Adding a new Dublin Core field can be done from the Administrative User Interface of DSpace.

  • Login as an Administrator, and look for the page called "Metadata Schema Registry".

After you've added a new field, you can add it to the Search (Lucene) Index or Browse Index by following the directions in the "Configuration and Customization" chapter of the DSpace System Documentation.

...

The DSpace System Documentation includes a section on "Configuring Lucene Search Indexes" in the chapter on "Configuration and Customization".

How do I add a field to the simple item display page?

See the on this wiki for more help.

How can I develop DSpace modifications with my own CVS repository?

and Customization".

How do I add a field to the simple item display page?

See the on this wiki for more help.What if you have a team that wants to collaborate on a DSpace modification? You can all check the code out of SourceForge CVS anonymously and pass patches around, but this will get very complicated (and probably produce errors) very quickly. What you really need is your own CVS repository.
This is also useful for managing any minor customisations your organisation has made to DSpace.
See SeparateCvsRepository

I've made a lot of modifications to DSpace, and I want to bring my code up to date with a later version of DSpace. What's the easiest way to do that?

...

The Messages.properties file is used for translations both in DSpace core ([dspace]/lib/dspace-api-4.0-SNAPSHOT.jar) and in DSpace JSPUI ([dspace]/webapps/jspui/WEB-INF/lib/dspace-api-4.0-SNAPSHOT.jar). You usually want to update the JSPUI one:1)

  1. find dspace-api-X.X.jar in [dspace]/webapps/jspui/WEB-INF/lib/

...

  1. unzip it in an external folder

...

  1. modify the Message.properties file

...

  1. copy Message.properties to [dspace]/webapps/jspui/WEB-INF/classes/

...

  1. restart your servlet container 

I'm getting "SolrException: Bad Request" followed by a long query or a "tooManyClauses" Exception

...

The issue is related to the Access Rights Awareness feature introduced in Discovery and affect both the search and the browse system (when SolrBrowseDAO are used, optional in 3.x, by default in 4.0).
 

The issue here is that a single user is included in several groups - that means that the Solr query will include a filter to limit the results to only items that are visible by group1, group2, .... groupN.
 

  • If the number of group is high, you can reach the HTTP header limit (4kB or 8kB by default, see maxHttpHeaderSize Tomcat 7 docs) or a tooManyClauses Exception in Solr, that can be "solved" incrementing this parameter

...

...

Solutions:

in case of exceeding header size:a)

  • increase maxHttpHeaderSize in Tomcat

in case of tooManyClauses Exception:b)

  •  increment maxBooleanClauses; or

...

  • disable Access Rights Awareness