This repository was archived by the owner on Jul 2, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 12
Debugging Guam
Timotheus Pokorra edited this page Jun 17, 2016
·
13 revisions
https://cgit.kolab.org/guam/tree/README.md: "Guam is an IMAP proxy and filter written in Erlang developed by Kolab Systems."
see also https://git.kolab.org/diffusion/G/browse/master/docs/ for Design overview, Functional description, and deployment.
some useful commands:
systemctl status guam
journalctl -f -u guam
some important files:
/usr/lib/systemd/system/guam.service
/etc/guam/sys.config (referenced by symbolic link /opt/kolab_guam/releases/0.9/sys.config)
/opt/kolab_guam/bin/kolab_guam
starts /usr/bin/run_erl, Erlang
processes:
ps xaf | grep guam
2483 ? Ssl 8:36 /opt/kolab_guam/erts-7.3.1/bin/beam.smp -Bd -- -root /opt/kolab_guam -progname kolab_guam -- -home /opt/kolab_guam/ -- -noshell -noinput -boot /opt/kolab_guam/releases/0.9/kolab_guam -config /opt/kolab_guam/releases/0.9/sys.config -name kolab_guam@127.0.0.1 -setcookie kolab_guam -- foreground
2527 ? S 0:00 /opt/kolab_guam/erts-7.3.1/bin/epmd -daemon
Sources:
the sources are compiled to .beam files:
kolab_guam_session.erl becomes /opt/kolab_guam/lib/kolab_guam-0.8/ebin/kolab_guam_session.beam
Testing fixes (see https://cgit.kolab.org/guam/tree/README.md):
# setup environment
make deps-up
# build guam
make
# adjust configuration
# vi app.config
# run it
make run
# or stop guam
systemctl stop guam
# copy the compiled file
cp /root/guam/apps/kolab_guam/ebin/kolab_guam_session.beam /opt/kolab_guam/lib/kolab_guam-0.8/ebin/
systemctl start guam
Test conneting:
telnet 127.0.0.1 143
should show something like:
* OK [CAPABILITY STARTTLS IMAP4rev1 LITERAL+ ID ENABLE AUTH=PLAIN AUTH=LOGIN SASL-IR] 052-centos7k16.kolab.pokorra.de Cyrus IMAP 2.5.8.12-Kolab-2.5.8-13.1.el7.kolab_16 server ready
imtest -p 143 -m login 127.0.0.1
similar, asks for password, etc
Listing the ports:
yum install net-tools
netstat -atploun | grep beam
shows guam listening on port imap (143) and imaps (993)
netstat -atploun | grep cyrus
shows cyrus listening on port 9993