Tech:Handbook: Difference between revisions

From Orain Meta
Jump to navigation Jump to search
Content added Content deleted
imported>Addshore
No edit summary
m (Wikilink)
 
(6 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Most of the stuff below should be done automatically. If you do it manually please say so at [[Server_admin_log]]
Most of the stuff below should be done automatically. If you do it manually please say so at [[Tech:Server admin log]]


When trying to debug something, take a look at the logs... Everything is logged! (see /var/log)
When trying to debug something, take a look at the logs... Everything is logged! (see /var/log)
Line 6: Line 6:


'''Manual Pull'''
'''Manual Pull'''
<blockquote>ansible all -i "localhost," -c local -m git -a "name=https://github.com/Orain/ansible-playbook.git dest=/root/ansible-playbook version=master"</blockquote>
<blockquote>/root/ans-pull</blockquote>


'''Manual Update''' (doesnt pull changes from the repo)
'''Manual Update''' (doesn't pull changes from the repo)
<blockquote>ansible-playbook -c local --limit "localhost:prod2.orain.org:127.0.0.1" /root/ansible-playbook/local.yml -i "/root/ansible-playbook/production"</blockquote>
<blockquote>ansible-playbook -c local --limit "<<HOSTNAMEHERE>>" /root/ansible-playbook/local.yml -i "/root/ansible-playbook/production"</blockquote>


==Mediawiki Stuff==
==MediaWiki Stuff==

'''Reload the dblist from metawiki'''
<blockquote>su www-scripts -c "python3 ~/get_db_list.py"</blockquote>


'''Flush the job queue'''
'''Flush the job queue'''
<blockquote>/home/www-scripts/db_loop.sh /usr/share/nginx/.orain.org/w/maintenance/runJobs.php</blockquote>
<blockquote>/home/www-scripts/db_loop.sh /srv/mediawiki/w/maintenance/runJobs.php</blockquote>


'''Run update.php on all wikis'''
'''Run update.php on all wikis'''
<blockquote>/home/www-scripts/db_loop.sh /usr/share/nginx/.orain.org/w/maintenance/update.php --quick</blockquote>
<blockquote>/home/www-scripts/db_loop.sh /srv/mediawiki/w/maintenance/update.php --quick</blockquote>


'''Run update.php on a single wiki'''
'''Run update.php on a single wiki'''
<blockquote>/usr/bin/php /usr/share/nginx/.orain.org/w/maintenance/update.php --wiki extloadwiki</blockquote>
<blockquote>php5 /srv/mediawiki/w/maintenance/update.php --wiki extloadwiki</blockquote>


'''Rebuild Localisation Cache for extloadwiki'''
'''Rebuild Localisation Cache for extloadwiki'''
<blockquote>/usr/bin/php /usr/share/nginx/.orain.org/w/maintenance/rebuildLocalisationCache.php --wiki extloadwiki</blockquote>
<blockquote>php5 /srv/mediawiki/w/maintenance/rebuildLocalisationCache.php --wiki extloadwiki</blockquote>

Latest revision as of 16:20, 9 July 2015

Most of the stuff below should be done automatically. If you do it manually please say so at Tech:Server admin log

When trying to debug something, take a look at the logs... Everything is logged! (see /var/log)

Ansible Stuff

Manual Pull

ansible all -i "localhost," -c local -m git -a "name=https://github.com/Orain/ansible-playbook.git dest=/root/ansible-playbook version=master"

Manual Update (doesn't pull changes from the repo)

ansible-playbook -c local --limit "<<HOSTNAMEHERE>>" /root/ansible-playbook/local.yml -i "/root/ansible-playbook/production"

MediaWiki Stuff

Reload the dblist from metawiki

su www-scripts -c "python3 ~/get_db_list.py"

Flush the job queue

/home/www-scripts/db_loop.sh /srv/mediawiki/w/maintenance/runJobs.php

Run update.php on all wikis

/home/www-scripts/db_loop.sh /srv/mediawiki/w/maintenance/update.php --quick

Run update.php on a single wiki

php5 /srv/mediawiki/w/maintenance/update.php --wiki extloadwiki

Rebuild Localisation Cache for extloadwiki

php5 /srv/mediawiki/w/maintenance/rebuildLocalisationCache.php --wiki extloadwiki