画像が出ない
dcm4cheeのWebブラウザから画像アイコンをクリックしても画像が表示されない.ログを見ると次のようなエラーがでていた.23:55:20,286 ERROR [WADOServiceDelegate] Exception occured in getWADOObject: dcm4chee.archive:service=WADOService is not registered.このエラーを手掛かりに検索したところ,起動時の以下のエラーが原因らしい.
02:13:33,238 ERROR [MainDeployer] Could not create deployment: file:/usr/local/app/dcm4chee-2.17.1-mysql/server/default/deploy/dcm4chee-wado-service.xmlこのエラーメッセージを検索すると,下記URLにたどりついた.
http://stackoverflow.com/questions/18673556/install-dcm4chee-on-centosこの中に次のような記述があった.
In short: The problem is WADO service unable to start due to the JAI Image IO library not being properly installed.ここで,JAI Image IO library画像圧縮関連のライブラリのようで,このバージョンが関係しているらしい.
You should download the 64 bit version of the library for Linux, extract the files and replace just the original (32 bit) ones from those that you downloaded.この記述によれば32bit版のライブラリを使っていることになっているが,どうしてそんなことになったのだろうか?javaのバージョンは以下のとおりである.
java version "1.7.0_79"見てのとおり64bit版だ.では,ライブラリは?そもそもdcm4cheeに32bit版とか64bit版なんてあったか?あるいはJBossには? そんなものはない.では,どうしてJAI image IO libraryが32bit版になったのか?そもそもどうやって確認するのか?
OpenJDK Runtime Environment (rhel-2.5.5.3.el6_6-x86_64 u79-b14)
OpenJDK 64-Bit Server VM (build 24.79-b02, mixed mode)
正規のマニュアルでは, dcm4cheeとは別にJAI image IO libraryをインストールしている場合は以下のファイルを消せと書いている.
- $DCM4CHEE_HOME/server/default/lib/jai_imageio.jar
- $DCM4CHEE_HOME/server/default/lib/clibwrapper_jiio.jar
- $DCM4CHEE_HOME/bin/native/clib_jiio.dll
- $DCM4CHEE_HOME/bin/native/clib_jiio_sse2.dll
- $DCM4CHEE_HOME/bin/native/clib_jiio_util.dll
- $DCM4CHEE_HOME/bin/native/libclib_jiio.so
$ cp clibwrapper_jiio.jar $DCM4CHEE_HOME/server/default/lib一体どちらに従えば良いのか?
$ cp jai_imageio.jar $DCM4CHEE_HOME/server/default/lib
$ cp libclib_jiio.so $DCM4CHEE_HOME/bin/native
調べていくうちに次第に原因がわかってきた。今回使用しているIntel NCUは64bitであるが、dcm4cheeのマニュアルにこういう記載がある。
- The binary distribution packages of dcm4chee already includes necessary JARs and native libraries for Windows and Linux i586.
- For Linux-amd64, and Solaris, you have to download the SW package from Sun here yourself and replace the Linux version of libclib_jiio.so in dcm4chee-2.17.1-xxx/bin/native from the JAI Image IO package for Linux-amd64 or Solaris. Or see this post for a more recent version.
解決方法
やはり,原因は32bitと62bitの不整合だった.dcm4cheeに含まれているのは32bit版なので,64bit版をDLして差し替える必要がある.DLするのはjai_imageio-1_1-lib-linux-amd64.tar.gz. wgetで取ってきてtarで解凍.その中に下記のファイルがある(2015/7/1時点でデッドリンクになっている).- jai_imageio-1_1/lib/jai_imageio.jar
- jai_imageio-1_1/lib/clibwrapper_jiio.jar
- jai_imageio-1_1/lib/libclib_jiio.so
weasisが動かない
weasisをdeployしたとき,次のエラーメッセージが出る.23:59:28,507 ERROR [STDERR] SLF4J: Class path contains multiple SLF4J bindings.
これは前にも経験した.前はdcm4cheeを2.17.1から2.17.3あるいは2.18.0にバージョンアップすることによって解決した.しかし,それでは根本的に解決したことにはならないので,少し調べてみた.
http://www.slf4j.org/codes.html#multiple_bindingsここには次のような説明がある.
SLF4J API is designed to bind with one and only one underlying logging framework at a time. If more than one binding is present on the class path, SLF4J will emit a warning, listing the location of those bindings.実際,ログには次のようなエラーメッセージが残っている.
- 16:35:09,486 ERROR [STDERR] SLF4J: Class path contains multiple SLF4J bindings.
- 16:35:09,486 ERROR [STDERR] SLF4J: Found binding in [jar:file:/usr/local/app/dcm4chee-2.17.1-mysql/server/default/lib/slf4j-log4j12-1.6.1.jar!/org/slf4j/impl/StaticLoggerBinder.class]
- 16:35:09,486 ERROR [STDERR] SLF4J: Found binding in [jar:file:/usr/local/app/dcm4chee-2.17.1-mysql/server/default/tmp/deploy/tmp2488711561556272726weasis-pacs-connector-exp.war/WEB-INF/lib/slf4j-log4j12-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class]
- 16:35:09,487 ERROR [STDERR] SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
- 16:35:09,491 ERROR [STDERR] SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]
17:01:48,988 ERROR [STDERR] SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".こんどは,org.slf4j.impl.StaticLoggerBinderがロードできないという.
17:01:48,990 ERROR [STDERR] SLF4J: Defaulting to no-operation (NOP) logger implementation
17:01:48,990 ERROR [STDERR] SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
諦めてネットを検索していると「Weasis deployment problem」というサイトに次のような記述があった.
This error doesn't have any consequence. This is because SLF4J already exists in the dcm4chee-jboss.これにしたがって,weasis-pacs-connector.warを作り直してみた.ただし,logback-*というjarファイルはなかったのでslf4j-api-1.7.5.jarだけを削除してjarコマンドでwarファイルを作成した.なお,jarコマンドが入っていなかったので,次のコマンドでインストールした.
You can simply unzip weasis-pacs-connector.war and remove slf4j-api-1.6.1.jar, logback-classic-0.9.29.jar and logback-core-0.9.29.jar, and then zip it again.
# yum install java-1.7.0-openjdk-develまた,slf4j-api-1.7.5.jarはWEB-INF/lib/の中に入っていたのでそれを削除した後,次のコマンドでwarファイルを作成した.
# jar cvf weasis-pacs-connector.war *なお,このコマンドはwarファイルを展開したディレクトリ上で実行した.こうしてdcm4cheeを再起動すると,今度はweasisが動いた.ただし,Webインターフェースで「Open Web Viewer」をクリックしなければならない.目のアイコンではなく左から3つ目のアイコンをクリックしなければならない.先入観で目のアイコンと思い込んでいたためにこのような結果となった.
0 件のコメント:
コメントを投稿