1

我最近从 fedora-commons 3.7 升级到 3.8.1。我可以从 fedora-admin Web 面板搜索和获取对象,但是当我运行 /fedora/client/bin/fedora-admin.sh 并尝试搜索“*”时,我收到以下错误:

WARN 09:33:21.111 (PhaseInterceptorChain) Interceptor for {http://fedora-commons.org/2011/07/definitions/types/}FedoraAPIAMTOMService#{http://fedora-commons.org/2011/07/definitions/types/}findObjects has thrown exception, unwinding now
org.apache.cxf.interceptor.Fault: Could not send Message.
at org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:64) ~[cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:272) ~[cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:565) [cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:474) [cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:377) [cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:330) [cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:96) [cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:135) [cxf-bundle-2.7.7.jar:2.7.7]
at com.sun.proxy.$Proxy50.findObjects(Unknown Source) [na:na]
at org.fcrepo.client.mtom.APIAStubWrapper$7.construct(APIAStubWrapper.java:193) [fcrepo-client-admin-3.8.1-SNAPSHOT.jar:na]
at org.fcrepo.client.mtom.APIAStubWrapper$7.construct(APIAStubWrapper.java:187) [fcrepo-client-admin-3.8.1-SNAPSHOT.jar:na]
at org.fcrepo.client.SwingWorker$2.run(SwingWorker.java:131) [fcrepo-client-admin-3.8.1-SNAPSHOT.jar:na]
at java.lang.Thread.run(Thread.java:745) [na:1.8.0_45]
Caused by: org.apache.cxf.transport.http.HTTPException: HTTP response '401: Unauthorized' when communicating with http://localhost:8080/fedora/services/accessMTOM
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:1542) ~[cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1502) ~[cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1309) ~[cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:56) ~[cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:627) ~[cxf-bundle-2.7.7.jar:2.7.7]
at org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62) ~[cxf-bundle-2.7.7.jar:2.7.7]
... 12 common frames omitted
Exception in thread "Thread-1" javax.xml.ws.WebServiceException: Could not send Message.
at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:146)
at com.sun.proxy.$Proxy50.findObjects(Unknown Source)
at org.fcrepo.client.mtom.APIAStubWrapper$7.construct(APIAStubWrapper.java:193)
at org.fcrepo.client.mtom.APIAStubWrapper$7.construct(APIAStubWrapper.java:187)
at org.fcrepo.client.SwingWorker$2.run(SwingWorker.java:131)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.apache.cxf.transport.http.HTTPException: HTTP response '401: Unauthorized' when communicating with http://localhost:8080/fedora/services/accessMTOM
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:1542)
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1502)
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1309)
at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:56)
at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:627)
at org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62)
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:272)
at org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:565)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:474)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:377)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:330)
at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:96)
at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:135)
... 5 more

我以我的 fedora 用户身份运行 fedora-admin.sh。谢谢你的帮助。

4

1 回答 1

2

您有一个未经授权的 HTTP 响应代码 401。

所以我认为你在安装 Fedora Commons 时启用了 API-A 上的身份验证。

我在安装时遇到了类似的问题,我通过使用 keytool 生成 .keystore 并将其添加到 $JAVA_OPTS 来设置 ssl 来解决它。我在 .bashrc 中添加了这一行:

export JAVA_OPTS='-Djavax.net.ssl.trustStore=~/.keystore -Djavax.net.ssl.trustStorePassword=MyKeystorePassword'

然后使用命令: source ~/.bashrc

您可以通过在 $FEDORA_HOME/server/config 中编辑您的服务器配置再次运行安装脚本或通过在 $FEDORA_HOME/server/config 中编辑您的服务器配置来启用对 Fedora API 的访问而不使用 HTTPS 来验证您的 ssl 配置是否存在问题。你的java ssl配置如上。

于 2016-08-09T10:15:47.073 回答