Skip to content
This repository has been archived by the owner on Nov 5, 2024. It is now read-only.

Moved to the Wikimedia Foundation Labs server infrastructure #17

Closed
wants to merge 1 commit into from

Conversation

Mailaender
Copy link
Contributor

These are the necessary changes to the configuration required to run it at http://tools.wmflabs.org/. This is meant for documentation purposes. Deployment is not yet automatized although I wrote some scripts so I don't forget.

  • Change the configuration files as stated in this pull request.
  • Get the password (does not work via SFTP, permission denied):
ssh username@tools-login.wmflabs.org
become languagetool
nano replica.my.cnf
  • Build the WAR as instructed in Documented build and dependencies #16 locally. I have not yet managed to get grails/mvn to work on the WMF server although it may be preferable to just update from git and build there to avoid a 100 MB upload with slow ADSL.
  • Upload the WAR and deploy as following. The exact file name is important.
scp target/ltcommunity-0.1.war username@tools-login.wmflabs.org:/data/project/languagetool/
ssh username@tools-login.wmflabs.org
become languagetool
webservice -tomcat stop
rm -rf public_tomcat/webapps/*
mv ltcommunity-0.1.war public_tomcat/webapps/languagetool.war
webservice -tomcat start
webservice -tomcat restart

Wait a moment. This takes several minutes. Almost every deployment/configuration error results in 404 for no apparent reason and is not properly displayed on the web. I found /data/project/languagetool/error.log to be the most helpful one. There are also some in /data/project/languagetool/public_tomcat/logs/

Most parts of http://tools.wmflabs.org/languagetool/ already work. I could not find the corpus files and the recent changes feed is not setup correctly, but now that we have access to live Wikipedia DB replicates, this has to be re-implemented anyway.

@danielnaber
Copy link
Member

Default memory is 128M, it needs to be increased in public_tomcat/bin/setenv.sh to e.g. 500m, otherwise the service works but is very slow.

@Mailaender
Copy link
Contributor Author

Ah, that is much better. Well done.

@danielnaber
Copy link
Member

Recent changes script is now running from feedchecker/check-de.sh. All jobs need to be started with jstart (the script does that). qstat lists current jobs. qstat -j <id> lists details for a given job id. jstop <job_name> stops a job. Details here. All paths need to be absolute, otherwise errors like Could not find or load main class org.languagetool.dev.wikipedia.atom.AtomFeedCheckerCmd happen.

DB can be manually connected with this command: mysql -h tools-db -u s52131 -p s52131__ltcommunity

DB collation and default values for version column needed to be fixed manually once (ALTER TABLE...).

@danielnaber
Copy link
Member

New version has been deployed, code at https://github.com/languagetool-org/languagetool-wikicheck

@Mailaender Mailaender closed this Jun 19, 2014
@Mailaender Mailaender deleted the wmflabs branch June 19, 2014 06:43
@danielnaber
Copy link
Member

The MySQL feed_matches table (and probably other tables with a lot of data) need to use type MyISAM. The default of InnoDB is too slow.

@Mailaender
Copy link
Contributor Author

Better post that into a separate ticket I guess.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants