dspace create-administrator失败

时间:2017-08-15 07:38:50

标签: java dspace

我正在安装dspace 6.1 src版本。我在Suse 12.2。我仔细地按照installation instructions,按照this post中的想法进行了操作,并且昨天和今天多次重新安装 - 重新安装 - 重试了创建管理员脚本和用户脚本。我总是得到同样的错误:

dspace@mycomputer:~/dspace_install> bin/dspace create-administrator
Exception: The schema validator returned: Unable to create requested 
service [org.hibernate.engine.spi.CacheImplementor]
org.dspace.core.exception.DatabaseSchemaValidationException: The 
schema validator returned: Unable to create requested service 
[org.hibernate.engine.spi.CacheImplementor]
    at org.dspace.core.Context.init(Context.java:170)
    at org.dspace.core.Context.<init>(Context.java:126)
    at org.dspace.administer.CreateAdministrator.<init>
(CreateAdministrator.java:101)
    at (org.dspace.administer.CreateAdministrator.main(CreateAdministrator.java:70)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.dspace.app.launcher.ScriptLauncher.runOneCommand(ScriptLauncher.java:229)
at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:81)

我在网上找不到这个错误。最接近的是2015年以上的帖子。我的数据库在epersongroup表中没有默认条目,因此我添加了上面建议的条目(添加'匿名'和'管理员'组)。我仍然得到同样的错误。

我将不胜感激任何帮助!

2 个答案:

答案 0 :(得分:3)

由于错误报告了数据库架构的问题,我建议如下。

运行以下命令以查看数据库架构的状态

bin/dspace database info

您将看到如下输出

+----------------+-----------------------------------------------------+---------------------+---------+
| Version        | Description                                         | Installed on        | State   |
+----------------+-----------------------------------------------------+---------------------+---------+
| 1              | << Flyway Baseline >>                               | 2017-07-25 18:26:49 | Baselin |
| 1.1            | Initial DSpace 1.1 database schema                  | 2017-07-25 18:26:50 | Success |
| 1.2            | Upgrade to DSpace 1.2 schema                        | 2017-07-25 18:26:50 | Success |
| 1.3            | Upgrade to DSpace 1.3 schema                        | 2017-07-25 18:26:50 | Success |
| 1.3.9          | Drop constraint for DSpace 1 4 schema               | 2017-07-25 18:26:50 | Success |
| 1.4            | Upgrade to DSpace 1.4 schema                        | 2017-07-25 18:26:50 | Success |
| 1.5            | Upgrade to DSpace 1.5 schema                        | 2017-07-25 18:26:51 | Success |
| 1.5.9          | Drop constraint for DSpace 1 6 schema               | 2017-07-25 18:26:51 | Success |
| 1.6            | Upgrade to DSpace 1.6 schema                        | 2017-07-25 18:26:51 | Success |
| 1.7            | Upgrade to DSpace 1.7 schema                        | 2017-07-25 18:26:51 | Success |
| 1.8            | Upgrade to DSpace 1.8 schema                        | 2017-07-25 18:26:51 | Success |
| 3.0            | Upgrade to DSpace 3.x schema                        | 2017-07-25 18:26:51 | Success |
| 4.0            | Upgrade to DSpace 4.x schema                        | 2017-07-25 18:26:51 | Success |
| 4.9.2015.10.26 | DS-2818 registry update                             | 2017-07-25 18:26:51 | Success |
| 5.0.2014.08.08 | DS-1945 Helpdesk Request a Copy                     | 2017-07-25 18:26:51 | Success |
| 5.0.2014.09.25 | DS 1582 Metadata For All Objects drop constraint    | 2017-07-25 18:26:51 | Success |
| 5.0.2014.09.26 | DS-1582 Metadata For All Objects                    | 2017-07-25 18:26:51 | Success |
| 5.6.2016.08.23 | DS-3097                                             | 2017-07-25 18:26:51 | Success |
| 5.7.2017.04.11 | DS-3563 Index metadatavalue resource type id column | 2017-07-25 18:26:51 | Success |
| 5.7.2017.05.05 | DS 3431 Add Policies for BasicWorkflow              | 2017-07-25 18:26:51 | Success |
| 6.0.2015.03.06 | DS 2701 Dso Uuid Migration                          | 2017-07-25 18:26:51 | Success |
| 6.0.2015.03.07 | DS-2701 Hibernate migration                         | 2017-07-25 18:26:51 | Success |
| 6.0.2015.08.31 | DS 2701 Hibernate Workflow Migration                | 2017-07-25 18:26:52 | Success |
| 6.0.2016.01.03 | DS-3024                                             | 2017-07-25 18:26:52 | Success |
| 6.0.2016.01.26 | DS 2188 Remove DBMS Browse Tables                   | 2017-07-25 18:26:52 | Success |
| 6.0.2016.02.25 | DS-3004-slow-searching-as-admin                     | 2017-07-25 18:26:52 | Success |
| 6.0.2016.04.01 | DS-1955 Increase embargo reason                     | 2017-07-25 18:26:52 | Success |
| 6.0.2016.04.04 | DS-3086-OAI-Performance-fix                         | 2017-07-25 18:26:52 | Success |
| 6.0.2016.04.14 | DS-3125-fix-bundle-bitstream-delete-rights          | 2017-07-25 18:26:52 | Success |
| 6.0.2016.05.10 | DS-3168-fix-requestitem item id column              | 2017-07-25 18:26:52 | Success |
| 6.0.2016.07.21 | DS-2775                                             | 2017-07-25 18:26:52 | Success |
| 6.0.2016.07.26 | DS-3277 fix handle assignment                       | 2017-07-25 18:26:52 | Success |
| 6.0.2016.08.23 | DS-3097                                             | 2017-07-25 18:26:52 | Success |
| 6.1.2017.01.03 | DS 3431 Add Policies for BasicWorkflow              | 2017-07-25 18:26:52 | Success |
+----------------+-----------------------------------------------------+---------------------+---------+

如果您看到任何状态为&#34;成功&#34;运行以下

bin/dspace database repair

如果您没有看到条目包含版本6.1,请运行以下命令

bin/dspace database migrate

希望这可以解决这个问题。

答案 1 :(得分:0)

我刚刚和我的同事交谈,他找到了真正的问题。我们在同一台服务器上安装了2个Dspace实例,他在[dspace-src] / dspace / config目录中找到了hibernate ehcache(hibernate-ehcache-config.xml)的设置。我在上面的问题中发布的异常消息中引用了这个。在hibernate-ehcache-config.xml中有一个警告,当你在同一台服务器上有多个dspace实例时,你需要为hibernate ehcache提供单独的diskStore文件夹。我为我的Dspace实例创建了一个单独的实例,然后在local.cfg文件中反转了我对dspace.hostname的设置,因此它显示了服务器域名,一切正常,命令行上的服务器和create-administrator。