moses-smt / mosesdecoder

Moses, the machine translation system
http://www.statmt.org/moses
GNU Lesser General Public License v2.1
1.58k stars 775 forks source link

Moses was compiled without server support. #99

Closed igtsekov closed 9 years ago

igtsekov commented 9 years ago

Hello. After I compiled moses 3.0 from source (./bjam --with-irstlm=/home/install/irstml --with-giza=/home/install/giza-pp --with-boost=/home/install/boost --with-xmlrpc-c=/home/install/xmlrpc-c --with-srilm=/home/install/srilm --prefix=/home/install/moses) and I start it with ./moseserver --server-port 8084 -f /home/model/moses.ini --server it start normally but after a few seconds the execution end and there is a message : Moses was compiled without server support. I was browsing through the web but cannot find solution. Is this a issue or it is a problem with my build. I am building it on ubuntu 14 server and the previous version works just find. Can you help me ? P.S. Excuse my english I am foreigner. :)

ugermann commented 9 years ago

There's a problem with the bjam setup. I managed to get the server code to compile, but since it never was compiled before, there's plenty of things to be fixed. This will take a few days.

On Tue, Mar 17, 2015 at 1:11 PM, Ivan Cekov notifications@github.com wrote:

Hello. After I compiled moses 3.0 from source (./bjam --with-irstlm=/home/install/irstml --with-giza=/home/install/giza-pp --with-boost=/home/install/boost --with-xmlrpc-c=/home/install/xmlrpc-c --with-srilm=/home/install/srilm --prefix=/home/install/moses) and I start it with ./moseserver --server-port 8084 -f /home/model/moses.ini --server it start normally but after a few seconds the execution end and there is a message : Moses was compiled without server support. I was browsing through the web but cannot find solution. Is this a issue or it is a problem with my build. I am building it on ubuntu 14 server and the previous version works just find. Can you help me ? P.S. Excuse my english I am foreigner. :)

— Reply to this email directly or view it on GitHub https://github.com/moses-smt/mosesdecoder/issues/99.

Ulrich Germann Senior Researcher School of Informatics University of Edinburgh

hieuhoang commented 9 years ago

for now, use the original executable mosesserver

On 18/03/2015 01:34, Ulrich Germann wrote:

There's a problem with the bjam setup. I managed to get the server code to compile, but since it never was compiled before, there's plenty of things to be fixed. This will take a few days.

  • Uli

On Tue, Mar 17, 2015 at 1:11 PM, Ivan Cekov notifications@github.com wrote:

Hello. After I compiled moses 3.0 from source (./bjam --with-irstlm=/home/install/irstml --with-giza=/home/install/giza-pp --with-boost=/home/install/boost --with-xmlrpc-c=/home/install/xmlrpc-c --with-srilm=/home/install/srilm --prefix=/home/install/moses) and I start it with ./moseserver --server-port 8084 -f /home/model/moses.ini --server it start normally but after a few seconds the execution end and there is a message : Moses was compiled without server support. I was browsing through the web but cannot find solution. Is this a issue or it is a problem with my build. I am building it on ubuntu 14 server and the previous version works just find. Can you help me ? P.S. Excuse my english I am foreigner. :)

— Reply to this email directly or view it on GitHub https://github.com/moses-smt/mosesdecoder/issues/99.

Ulrich Germann Senior Researcher School of Informatics University of Edinburgh

— Reply to this email directly or view it on GitHub https://github.com/moses-smt/mosesdecoder/issues/99#issuecomment-82670858.

igtsekov commented 9 years ago

Hi, Thanks for replying. I found my mistake. When I clone source code from git I did "git clone https://github.com/moses-smt/mosesdecoder.git", when I do it this way "git clone https://github.com/moses-smt/mosesdecoder.git --branch RELEASE-3.0 --single-branch RELEASE-3.0" it run like a charm :) P.S. Excuse my english I am foreigner. :)

ugermann commented 9 years ago

Ivan seens happy now, but just for the record:

There was a problem with the bjam setup that prevented the server functionality being included in the standard moses executable. I'm not happy with my current work-around in bjam, but I guess I'll never figure out bjam.

This episode also tells me that no regression test so far seems to test server functionality. Since I made quite a few changes when migrating, I can't guarantee that things will work the same way they did in the separate moses server. For the time being, I've also resurrected the legacy server code in contrib/server, but that is now deprecated, so any additions to the server C++ code should now be made in moses/server.

On Wed, Mar 18, 2015 at 3:10 PM, Ivan Cekov notifications@github.com wrote:

Hi, Thanks for replying. I found my mistake. When I clone source code from git I did "git clone https://github.com/moses-smt/mosesdecoder.git", when I do it this way "git clone https://github.com/moses-smt/mosesdecoder.git --branch RELEASE-3.0 --single-branch RELEASE-3.0" it run like a charm :) P.S. Excuse my english I am foreigner. :)

— Reply to this email directly or view it on GitHub https://github.com/moses-smt/mosesdecoder/issues/99#issuecomment-83016953 .

Ulrich Germann Senior Researcher School of Informatics University of Edinburgh

hieuhoang commented 9 years ago

Cruise control is reporting compile errors: http://www.statmt.org/moses/cruise/

I'm getting compile errors when i run this: ./bjam --with-boost=/Users/hieu/workspace/boost/boost_1_57_0.clang/ --with-xmlrpc-c=/Users/hieu/workspace/xmlrpc-c/xmlrpc-c-1.33.17 -j 5 -d 2 toolset=clang -q .... "clang++" -x c++ -O3 -g -I/Users/hieu/workspace/xmlrpc-c/xmlrpc-c-1.33.17/include -O3 -finline-functions -Wno-inline -Wall -g -DHAVE_XMLRPC_C -DNDEBUG -DTRACE_ENABLE=1 -DWITH_THREADS -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -I"." -I"/Users/hieu/workspace/boost/boost_1_57_0.clang/include" -c -o "/Users/hieu/workspace/github/mosesdecoder/moses/server/bin/clang-darwin-4.2.1/release/debug-symbols-on/link-static/threading-multi/Translator.o" "/Users/hieu/workspace/github/mosesdecoder/moses/server/Translator.cpp"

In file included from /Users/hieu/workspace/github/mosesdecoder/moses/server/Translator.cpp:1: In file included from /Users/hieu/workspace/github/mosesdecoder/moses/server/Translator.h:7: In file included from ./moses/ThreadPool.h:31: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/thread.hpp:13: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/thread/thread.hpp:12: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/thread/thread_only.hpp:17: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/thread/pthread/thread_data.hpp:12: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/thread/lock_types.hpp:22: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/chrono/time_point.hpp:33: /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/chrono/duration.hpp:569:54: error: expected unqualified-id typedef typename common_type<Rep1, Rep2>::type CR; ......

Additionally, when i compile WITHOUT xmlrpc-c, i get another error: ./bjam --with-boost=/Users/hieu/workspace/boost/boost_1_57_0.clang/ -j 5 -d 2 toolset=clang -q .... sh: xmlrpc-c-config: command not found Failed to run xmlrpc-c-config c++2 abyss-server --libs

ugermann commented 9 years ago

Does it work now?

On Thu, Mar 19, 2015 at 1:05 PM, Hieu Hoang notifications@github.com wrote:

Cruise control is reporting compile errors: http://www.statmt.org/moses/cruise/

I'm getting compile errors when i run this: ./bjam --with-boost=/Users/hieu/workspace/boost/boost_1_57_0.clang/ --with-xmlrpc-c=/Users/hieu/workspace/xmlrpc-c/xmlrpc-c-1.33.17 -j 5 -d 2 toolset=clang -q .... "clang++" -x c++ -O3 -g -I/Users/hieu/workspace/xmlrpc-c/xmlrpc-c-1.33.17/include -O3 -finline-functions -Wno-inline -Wall -g -DHAVE_XMLRPC_C -DNDEBUG -DTRACE_ENABLE=1 -DWITH_THREADS -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -I"." -I"/Users/hieu/workspace/boost/boost_1_57_0.clang/include" -c -o "/Users/hieu/workspace/github/mosesdecoder/moses/server/bin/clang-darwin-4.2.1/release/debug-symbols-on/link-static/threading-multi/Translator.o" "/Users/hieu/workspace/github/mosesdecoder/moses/server/Translator.cpp"

In file included from /Users/hieu/workspace/github/mosesdecoder/moses/server/Translator.cpp:1: In file included from /Users/hieu/workspace/github/mosesdecoder/moses/server/Translator.h:7: In file included from ./moses/ThreadPool.h:31: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/thread.hpp:13: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/thread/thread.hpp:12: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/thread/thread_only.hpp:17: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/thread/pthread/thread_data.hpp:12: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/thread/lock_types.hpp:22: In file included from /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/chrono/time_point.hpp:33: /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/chrono/duration.hpp:569:54: error: expected unqualified-id typedef typename common_type::type CR; ......

Additionally, when i compile WITHOUT xmlrpc-c, i get another error: ./bjam --with-boost=/Users/hieu/workspace/boost/boost_1_57_0.clang/ -j 5 -d 2 toolset=clang -q .... sh: xmlrpc-c-config: command not found Failed to run xmlrpc-c-config c++2 abyss-server --libs

— Reply to this email directly or view it on GitHub https://github.com/moses-smt/mosesdecoder/issues/99#issuecomment-83553311 .

Ulrich Germann Senior Researcher School of Informatics University of Edinburgh

hieuhoang commented 9 years ago

nah.

./bjam --with-boost=/Users/hieu/workspace/boost/boost_1_57_0.clang/ -j 5 -d 2 toolset=clang -q .... sh: xmlrpc-c-config: command not found Failed to run xmlrpc-c-config c++2 abyss-server --libs

./bjam --with-boost=/Users/hieu/workspace/boost/boost_1_57_0.clang/ --with-xmlrpc-c=/Users/hieu/workspace/xmlrpc-c/xmlrpc-c-1.33.17 -j 5 -d 2 toolset=clang -q .... "clang++" -x c++ -O3 -g -I/Users/hieu/workspace/xmlrpc-c/xmlrpc-c-1.33.17/include -O3 -finline-functions -Wno-inline -Wall -g -DHAVE_XMLRPC_C -DKENLM_MAX_ORDER=6 -DMAX_NUM_FACTORS=4 -DNDEBUG -DTRACE_ENABLE=1 -DWITH_THREADS -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -I"." -I"/Users/hieu/workspace/boost/boost_1_57_0.clang/include" -I"moses/TranslationModel/DynSAInclude" -I"util/double-conversion" -c -o "moses/bin/clang-darwin-4.2.1/release/debug-symbols-on/link-static/threading-multi/server/Translator.o" "moses/server/Translator.cpp" ... /Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/chrono/duration.hpp:569:54: error: expected unqualified-id

hieuhoang commented 9 years ago

also get the error on edin's valhalla servers

hieuhoang commented 9 years ago

if you can't fix it by eod today, can you please roll back. No one can use master at the moment

hieuhoang commented 9 years ago

just tested your commit. It works without xmlrpc, but with it it gives this error. ./bjam --with-boost=/Users/hieu/workspace/boost/boost_1_57_0.clang/ --with-cmph=/Users/hieu/workspace/cmph-2.0 --with-xmlrpc-c=/Users/hieu/workspace/xmlrpc-c/xmlrpc-c-1.33.17 -j5 toolset=clang -q clang-darwin.compile.c++ moses/bin/clang-darwin-4.2.1/release/debug-symbols-on/link-static/threading-multi/server/Translator.o .../Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/chrono/duration.hpp:569:54: error: expected unqualified-id typedef typename common_type<Rep1, Rep2>::type CR;

Can u let me know when it's fixed so I can check it myself

ugermann commented 9 years ago

I truly hate bjam. Now more than ever. The most awful build system in the world. On the upside, things seem to compile now with and without xmlrpc-c. By default, xmlprc-c will be included if available (xmlrpc-c-config can be found in the $PATH), even when not specified explicitly. (This behavior was taken over from the mosesserver setup). To explicitly build moses without xmlrpc-c support, use --no-xmlrpc-c.

On Thu, Mar 19, 2015 at 5:30 PM, Hieu Hoang notifications@github.com wrote:

just tested your commit. It works without xmlrpc, but with it it gives this error. ./bjam --with-boost=/Users/hieu/workspace/boost/boost_1_57_0.clang/ --with-cmph=/Users/hieu/workspace/cmph-2.0 --with-xmlrpc-c=/Users/hieu/workspace/xmlrpc-c/xmlrpc-c-1.33.17 -j5 toolset=clang -q clang-darwin.compile.c++ moses/bin/clang-darwin-4.2.1/release/debug-symbols-on/link-static/threading-multi/server/Translator.o .../Users/hieu/workspace/boost/boost_1_57_0.clang/include/boost/chrono/duration.hpp:569:54: error: expected unqualified-id typedef typename common_type::type CR;

Can u let me know when it's fixed so I can check it myself

— Reply to this email directly or view it on GitHub https://github.com/moses-smt/mosesdecoder/issues/99#issuecomment-83686129 .

Ulrich Germann Senior Researcher School of Informatics University of Edinburgh

kpu commented 9 years ago

I hate bjam too. Less than autotools though. Heard vaguely good things about waf though: https://code.google.com/p/waf/ .

emjotde commented 9 years ago

cmake?

On 20.03.2015 20:13, Kenneth Heafield wrote:

I hate bjam too. Less than autotools though. Heard vaguely good things about waf though: https://code.google.com/p/waf/ .

— Reply to this email directly or view it on GitHub https://github.com/moses-smt/mosesdecoder/issues/99#issuecomment-84103689.

hieuhoang commented 9 years ago

cheers. tested. work ok in most cases except 1 - if xmlrpc-c isn't installed in the standard location but given in the --with-xmlrpc-c arg, it doesn't link 'cos the -L flag hasn't been set. eg ./bjam --with-boost=/Users/hieu/workspace/boost/boost_1_57_0.clang/ --with-cmph=/Users/hieu/workspace/cmph-2.0 --with-xmlrpc-c=/Users/hieu/workspace/xmlrpc-c/xmlrpc-c-1.33.17 -j5 toolset=clang -q -d2 -a .... ld: library not found for -lxmlrpc_xmltok clang: error: linker command failed with exit code 1 (use -v to see invocation) ...failed clang-darwin.link

I tried changing it but can't figure out my a*se from my elbow

ugermann commented 9 years ago

That one I know how to fix. Thanks for testing.

hint:

requirements += /some/path ;

On Fri, Mar 20, 2015 at 7:47 PM, Hieu Hoang notifications@github.com wrote:

cheers. tested. work ok in most cases except 1 - if xmlrpc-c isn't installed in the standard location but given in the --with-xmlrpc-c arg, it doesn't link 'cos the -L flag hasn't been set. eg ./bjam --with-boost=/Users/hieu/workspace/boost/boost_1_57_0.clang/ --with-cmph=/Users/hieu/workspace/cmph-2.0 --with-xmlrpc-c=/Users/hieu/workspace/xmlrpc-c/xmlrpc-c-1.33.17 -j5 toolset=clang -q -d2 -a .... ld: library not found for -lxmlrpc_xmltok clang: error: linker command failed with exit code 1 (use -v to see invocation) ...failed clang-darwin.link

I tried changing it but can't figure out my a*se from my elbow

— Reply to this email directly or view it on GitHub https://github.com/moses-smt/mosesdecoder/issues/99#issuecomment-84115765 .

Ulrich Germann Senior Researcher School of Informatics University of Edinburgh

hieuhoang commented 9 years ago

looks like it everything is back on track. gonna close the issue if no-one objects

ugermann commented 9 years ago

One thing to keep in mind: bjam now/still uses xmlrpc-c-config to get the installation info, which is hard-coded into that executable at build time. If the installation is moved, things may not work. We'll cross that bridge when we get there.

On Fri, Mar 20, 2015 at 11:48 PM, Hieu Hoang notifications@github.com wrote:

looks like it everything is back on track. gonna close the issue if no-one objects

— Reply to this email directly or view it on GitHub https://github.com/moses-smt/mosesdecoder/issues/99#issuecomment-84196423 .

Ulrich Germann Senior Researcher School of Informatics University of Edinburgh

hieuhoang commented 9 years ago

aye. The --with-xmlrpc-c is there for people who don't have root access. If they're gonna move it around, that their problem, they can just recompile