--
IfiOkoye - 07 Apr 2008
The idea is to get a working version of greenstone3 up and running on mpdl, so we are aware of system-specific issues ...
- Downloaded greenstone-3.03-src.tar.gz source code into /usr/local/src
- locate found java here: /etc/alternatives/java_sdk_1.7.0. But it was just a symbolic link to: /usr/lib/jvm/java-1.7.0-icedtea-1.7.0.0.x86_64/bin
- Added JAVA_HOME to env variables. Edited root and my own env variables
- yum installed ant 1.7.0-1jpp.2.fc8
- Changed tomcat.server in build.properties to mpdl.mcs.csueastbay.edu
- Changed tomcat.port in build.properties from 8080 to 50100
- ant prepare install - kept returning and saying "prepare does not exist"
- ant install returned: BUILD FAILED
Target "get-macos-extra" does not exist in the project "greenstone3". It is used from target "install-macos-extra".
- I commented out two references to install-macos-extra...since this isnt a mac
- ant compile returned saying Could not find file /usr/local/apps/greenstone/src/packages/javagdbm/javagdbm.jar to copy and true enough, that file didnt exist.
- scp ifiokoye@majaHYRUQAPZ.mcs.csueastbay.edu:/home/ifiokoye/Desktop/greenstone3//src/packages/javagdbm/javagdbm.jar .
- scp ifiokoye@majaHYRUQAPZ.mcs.csueastbay.edu:/home/ifiokoye/Desktop/greenstone3/gs2build/indexers/mg/mg.jar gs2build/indexers/mg/
- scp ifiokoye@majaHYRUQAPZ.mcs.csueastbay.edu:/home/ifiokoye/Desktop/greenstone3/gs2build/indexers/mgpp/mgpp.jar gs2build/indexers/mgpp/mgpp.jar
- Some of the configure files were not executable by the file owner...made them executable
- scp ifiokoye@majaHYRUQAPZ.mcs.csueastbay.edu:/home/ifiokoye/Desktop/greenstone3/gs2build/indexers/lucene-gs/LuceneWrapper.jar gs2build/indexers/lucene-gs/LuceneWrapper.jar
- scp ifiokoye@majaHYRUQAPZ.mcs.csueastbay.edu:/home/ifiokoye/Desktop/greenstone3/gs2build/indexers/lucene-gs/LuceneWrapper.jar gs2build/indexers/lucene-gs/LuceneWrapper.jar
- Warning: Could not find file /usr/local/apps/greenstone/gs2build/indexers/mgpp/jni/libmgppretrievejni.so to copy.
- Warning: Could not find file /usr/local/apps/greenstone/gs2build/indexers/mgpp/jni/libmgppsearchjni.so to copy.
- scp ifiokoye@majaHYRUQAPZ.mcs.csueastbay.edu:/home/ifiokoye/Desktop/greenstone3/lib/jni/libmgpppassjni.so gs2build/indexers/mgpp/
- pscp ifiokoye@mpdlHYRUQAPZ.mcs.csueastbay.edu:/home/ifiokoye/config.log .
- conftest.c:25:26: error: minix/config.h: No such file or directory
- configure: failed program was:
| /* confdefs.h. */
- conftest.c:2: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'me'
configure:2157: $? = 1
configure: failed program was:
| #ifndef __cplusplus
| choke me
| #endif
- conftest.cc: In function 'int main()':
conftest.cc:16: error: 'exit' was not declared in this scope
configure:2609: $? = 1
configure: failed program was:
| /* confdefs.h. */
- conftest.c:15:28: error: ac_nonexistent.h: No such file or directory
configure:3118: $? = 1
configure: failed program was:
| /* confdefs.h. */
- conftest.c:59:26: error: minix/config.h: No such file or directory
configure:3705: $? = 1
configure: failed program was:
| /* confdefs.h. */
- conftest.cc: In function 'int main()':
conftest.cc:69: error: 'big' was not declared in this scope
conftest.cc:69: error: expected `;' before 'endian'
configure:7104: $? = 1
configure: failed program was:
| /* confdefs.h. */
Notes as of 04/07/08
Emailed greenstone-devel-list letting them know I couldn't find mgppretrievejni.so and mgppsearchjni.so in the distro but are needed for compiling Greenstone3
TODO tomorrow:
- Try to finish Greenstone3 installation
- Ask Hilary if I should install from a binary
- Understand Greenstone3 as a servlet....how will the apache module interface with Greenstone3
04/09/08
greenstone-devel is definitely a great group. Got back four email responses.
I'm going to checkout the source code from svn and try compiling
- checkout went ok
- When i tried compiling the gli interface, com.sun.image.code.jpeg was missing
- don't know how to add a package to an already installed java distro
- java-icedTea was installed
- went ahead and installed java ee and java sdk from the java.sun.com website
- it was a .bin
- to install a .bin, first, chmod +x filename
- then, ./filename
- libstdc++ was missing, yum installed it
- libstdc++.so.5 was missing, yum installed it
- when installing, after "Launching Java(TM) 2 Runtime Environment...
- I get a "Attach to native process failed" ...
- This forum http://forum.java.sun.com/thread.jspa?threadID=5226774&start=15&tstart=0 talks about the problems with installing java ww and java sdk. Someone else ran into the same problem I'm having when installing on fc8.
- Had to install Java SE development kit 6
- Then changed JAVA_HOME to point to where I installed it i.e /usr/lib/jdk1.6.0_05
- Then I went to where I had the java_ee_sdk i.e /usr/local and did ./java* ....
- Installer launched and i chose default...username is admin and password is ahat2004 for the java ee application....Here's what I got when I installed it in /opt/SDK
- Installing Java Platform, Enterprise Edition 5 SDK
|-1%--------------25%-----------------50%-----------------75%--------------100%|
Installation Successful.
Next Steps:
1. Access the About Java EE 5 SDK welcome page at:
file:///opt/SDK/docs/about.html
2. Start the Application Server by executing:
/opt/SDK/bin/asadmin start-domain domain1
3. Start the Admin Console:
http://localhost:4848
- Next step....try Greenstone again!
- went to greenstone3/gli and ran ./makegli.sh
- then ran ./makejar.sh
- then went up one directory back to /usr/local/apps/greenstone3
- and ran "ant prepare"....this did a lot of svn checkout....came back with BUILD SUCCESSFUL
- ran "ant install"...returned with
- [exec] text.pass1.cpp: In function âint done_text_1(const TagInfo? &, char*)â:
[exec] text.pass1.cpp:375: error: cast from âdouble*â to âunsigned intâ loses precision
[exec] text.pass1.cpp:375: error: cast from âdouble*â to âunsigned intâ loses precision
[exec] text.pass1.cpp:381: error: cast from âdouble*â to âintâ loses precision
[exec] text.pass1.cpp:381: error: cast from âdouble*â to âintâ loses precision
[exec] make[2]: * [text.pass1.o] Error 1
[exec] make[2]: Leaving directory `/usr/local/apps/greenstone3/gs2build/indexers/mgpp/text'
[exec] make[1]: * [all] Error 1
[exec] make[1]: Leaving directory `/usr/local/apps/greenstone3/gs2build/indexers/mgpp'
[exec] make: * [all] Error 1
- editing text.pass1.cpp...375:HTOND (host to network double) and 381:NTOHD(network to host double) keeps returning with error....talking to Katherine to try and get it fixed
- Added -fpermissive to the gcc flags in gs2build/indexers/mgpp/text/Makefile, then did a make....changed the error messages to warning messages
- /usr/local/apps/greenstone3/build.xml:1055: Warning: Could not find file /usr/local/apps/greenstone3/gs2build/indexers/lucene-gs/LuceneWrapper.jar to copy.
- Went into the lucene-gs directory and did a make.....made LuceneWrapper? .jar Finally got it to install successfully!
Workarounds:
1) added -fpermissive to the Makefile that calls netorder.h...this way the error messages were changed to warnings....found out the cast was occurring in netorder.h...so I figured it was a safe cast
2)LucenceWrapper.jar was not showing up...had to go to that directory and run "make" there...returned ok
3)libmgppretrieve.so wasnt showing up in gs2build/indexers/mgpp/jni....tried doing a make there but it failed with
"/usr/bin/ld: /usr/local/apps/greenstone3/gs2build/indexers/mgpp/../packages/unac/libunac.a(unac.o): relocation R_X86_64_32 against `a local symbol' can not be used when making a shared object; recompile with -fPIC
/usr/local/apps/greenstone3/gs2build/indexers/mgpp/../packages/unac/libunac.a: could not read symbols: Bad value"
So, I went into /usr/local/apps/greenstone3/gs2build/indexers/mgpp/../packages/unac/
I edited the Makefile there and added -fPIC as one of the flags to gcc, then I ran "make clean" and then "make"...and it came back ok
4) Went back to gs2build/indexers/mgpp/jni. and ran make....came back ok
5) then went into my main greenstone3 directory and ran "make install"....built successfully!
Dealing with port conflict errors:
04/10/08
So greenstone comes up on
http://mpdl.mcs.csueastbay.edu:50100/greenstone3/
However, when I click on either the standard or classic links, It takes me to this site:
http://mpdl.mcs.csueastbay.edu:50100/greenstone3/library and I keep getting:
HTTP Status Error report 500
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
javax.servlet.ServletException: Servlet.init() for servlet library threw exception org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:874) org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689) java.lang.Thread.run(Thread.java:619)
root cause
java.lang.NoClassDefFoundError: Could not initialize class au.com.pharos.gdbm.GdbmFile org.greenstone.gsdl3.util.GDBMWrapper.openDatabase(GDBMWrapper.java:45) org.greenstone.gsdl3.service.OAIPMH.configure(OAIPMH.java:103) org.greenstone.gsdl3.collection.ServiceCluster.configureServiceRack(ServiceCluster.java:330) org.greenstone.gsdl3.collection.Collection.configure(Collection.java:112) org.greenstone.gsdl3.core.MessageRouter.activateCollectionByName(MessageRouter.java:589) org.greenstone.gsdl3.core.MessageRouter.configureCollections(MessageRouter.java:543) org.greenstone.gsdl3.core.MessageRouter.configureLocalSite(MessageRouter.java:407) org.greenstone.gsdl3.core.MessageRouter.configure(MessageRouter.java:191) org.greenstone.gsdl3.LibraryServlet.init(LibraryServlet.java:165) org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:874) org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
java.lang.Thread.run(Thread.java:619)
note The full stack trace of the root cause is available in the Apache Tomcat/5.5.25 logs.
I think au/com/pharos/gdbm....doesnt get put into the right directory after being built from source...the .class files are in the source directory....bcos of this the servlet doesnt know where to find the class although the class exists and thus it returns a classnotdef error.....
Potential fix: copy the au directory into the util directory
check build file for org/greenstone/gsdl3/util
compare with build file for au/com/pharos/gdbm.....this one isnt creating a directory under build!
hmmm......
root cause
java.lang.UnsatisfiedLinkError: /usr/local/apps/greenstone3/lib/jni/libgdbmjava.so: /usr/local/apps/greenstone3/lib/jni/libgdbmjava.so: wrong ELF class: ELFCLASS64 (Possible cause: architecture word
width mismatch) java.lang.ClassLoader$NativeLibrary.load(Native Method) java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1751) java.lang.ClassLoader.loadLibrary(ClassLoader.java:1676) java.lang.Runtime.loadLibrary0(Runtime.java:823) java.lang.System.loadLibrary(System.java:1030) au.com.pharos.gdbm.GdbmFile.(GdbmFile.java:515) org.greenstone.gsdl3.util.GDBMWrapper.openDatabase(GDBMWrapper.java:45) org.greenstone.gsdl3.service.OAIPMH.configure(OAIPMH.java:103) org.greenstone.gsdl3.collection.ServiceCluster.configureServiceRack(ServiceCluster.java:330) org.greenstone.gsdl3.collection.Collection.configure(Collection.java:112) org.greenstone.gsdl3.core.MessageRouter.activateCollectionByName(MessageRouter.java:589) org.greenstone.gsdl3.core.MessageRouter.configureCollections(MessageRouter.java:543) org.greenstone.gsdl3.core.MessageRouter.configureLocalSite(MessageRouter.java:407) org.greenstone.gsdl3.core.MessageRouter.configure(MessageRouter.java:191) org.greenstone.gsdl3.LibraryServlet.init(LibraryServlet.java:165) org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:874) org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689) java.lang.Thread.run(Thread.java:619)
04/28/08 -You should use the bash shell when you're running greenstone....some of the scripts that need to be sourced, cannot be done under tcsh -WARNING: No plugin could process p558-rumetshofer.pdf Converting dig_interface_story0.pdf to HTML format Error executing pdftohtml.pl pdftohtml error log: sh: /usr/local/apps/greenstone3/gs2build/bin/linux/pdftohtml: No such file or directory pdftohtml error for /usr/local/apps/greenstone3/web/sites/localsite/collect/testcol/tmp/dig_interface_story0.pdf Could not convert dig_interface_story0.pdf to HTML format sh: /usr/local/apps/greenstone3/gs2build/bin/linux/pdftohtml: No such file or directory pdftohtml error for /usr/local/apps/greenstone3/web/sites/localsite/collect/testcol/tmp/dig_interface_story0.pdf
WARNING: No plugin could process dig_interface_story0.pdf *But I find pdftohtml in /usr/local/apps/greenstone3/gs2build/bin/script/pdftohtml.pl ...which means for some weird reason, the search environment is being set to look at gs2build/bin/linux...ahhh.....hate this!
Wonders shall never cease!...lol....pdftohtml was never made!..went into /usr/local/apps/greenstone3/gs2build/packages/pdftohtml/pdftohtml_gs
and did "make"...made pdftohtml...