JonDos GmbH thanks www.secure-internet.org for the right to publish the following article. We made some changes in it but the original text was provided www.secure-internet.org
Contents |
This HowTo describes the installation of the mix server and related software for FreeBSD using Jails. We prefer the installation of related software from ports (not packages), because compilation does not take much time and ports are sometimes more up to date than packages. The software for mix servers for FreeBSD is distributed as source code.
To compile the mix sources the libraries OpenSSL (at least v.0.9.7) and Xerces-C++ are required. Additionally a C++ compiler, automake and subversion are required, too. It may be useful to install subversion from ports, to disable BDB.
cd /usr/ports/security/openssl && make install clean
cd /usr/ports/textproc/xerces-c2-devel && make install clean
cd /usr/ports/devel/automake19 && make install clean
cd /usr/ports/devel/subversion && make install WITHOUT_BDB=YES && make clean
For premium mixes PostgreSQL database server, client and C-libraries for PostgreSQL clients are required, too.
cd /usr/ports/databases/postgresql84-client && make install clean
cd /usr/ports/databases/postgresql84-server && make install clean
cd /usr/ports/databases/postgresql-libpq++ && make install clean
Checkout the latest stable version from our subversion repository. We recommend the use of the directory /home/mix for sources.
mkdir /home/mix
cd /home/mix
svn checkout https://svn.jondos.de/svn/proxytest/proxytest/branches/stable
Afterwards compile and install the mix software:
cd /home/mix/stable
./configure --enable-new-channel-encryption --enable-new-flow-control
make
make install
Depending on the features needed by your mix, you can enable some more features for your mix:
./configure --enable-payment .... ....
Mandatory feature for premium services:
Monitoring your mix:
Additional Logging features:
Other features:
It is not a good solution to run the mix server with root privileges. Create a new system user account (recommended name: mix) and specify this user account in the mix configuration file. After startup, the mix server will switch to this UID.
Create a system user account with useradd:
adduser --quiet --system --disabled-password --shell=/bin/false --group mix
The directory and file for log messages will be specified in the mix configuration file. You have to create the directory and set safe permissions:
mkdir /var/log/mix
chown mix:adm /var/log/mix
chmod 0750 /var/log/mix
No logrotate configuration is necessary. The mix server creates a new file, if the log file size exceeded the configured limit.
You have to create a mix configuration, become root, raise the number of max. open descriptors to the value specified in the mix configuration file and you can start the mix.
For Csh (FreeBSD default) use:
limit descriptors 32768
mix -c /path/to/config.xml
If Bash is installed and preferred, use:
ulimit -HSn 32768
mix -c /path/to/config.xml
After startup the mix server will switch to the sytem UID specified in the mix configuration file.
Like other software the mix is updated time by time. New features will be added, bugs will be fixed ... and so on. Join the operator mailing list to stay up-to-date about software updates. If an update is announced, run the following steps.
cd /home/mix/stable
make distclean
svn update
./configure --enable-server_monitoring --enable-payment .... ....
make
make install
After successful update restart the mix.
