I'm looking for a "REAL HowTo" to Configuration under Linux (Debian/ubunutu)

Asked by Crazy21

Hi, ask for help to configure my adch++ hub on my preferred system.
4
I'm using ubuntu-server 10.

I have compiled the 2.4 version cause, the 2.5 cannot be compiled be cause the missed fixed in the 2.5 release.
But this should be uninteresting for us now.

I compiled and move the build to /home/dchub/adchpp24/ :

drwxr-xr-x 2 dchub dchub 4,0K 2010-06-10 02:59 adchpp
-rw-r--r-- 1 dchub dchub 823 2010-06-10 02:59 adchpp_cert_generator.7z
drwxr-xr-x 2 dchub dchub 4,0K 2010-06-10 02:59 adchppd
-rw-r--r-- 1 root root 5 2010-06-24 12:57 adchppd.pid
drwxr-xr-x 4 dchub dchub 4,0K 2010-06-10 02:59 bin
drwxr-xr-x 3 dchub dchub 4,0K 2010-06-10 02:59 boost
drwxr-xr-x 3 dchub dchub 4,0K 2010-06-10 02:59 certs
drwxr-xr-x 3 dchub dchub 4,0K 2010-06-10 02:59 config
-rwxrwxr-x 1 dchub dchub 530 2010-06-10 02:59 generat_certs.sh
drwxr-xr-x 2 dchub dchub 4,0K 2010-06-10 02:59 lua
-rw-r--r-- 1 dchub dchub 451K 2010-06-10 02:59 lua_wrap.cc
-rw-r--r-- 1 dchub dchub 2,2M 2010-06-10 02:59 lua_wrap.os
drwxr-xr-x 4 dchub dchub 4,0K 2010-06-10 02:59 plugins
-rw-r--r-- 1 dchub dchub 3,2K 2010-06-10 03:04 privkey.pem
drwxr-xr-x 2 dchub dchub 4,0K 2010-06-24 12:54 Scripts

I follow this introduction: http://adchpp.sourceforge.net/user_guide/index.html#_installing_on_linux

In the moment i had to run the adchppd with the -config parameter with a absolute path means "-conf /home/dchub/adchpp24/bin/config/adchpp.xml"

1. I want to know: Where need the "adchpp.xml"-file to be placed, that i can run without the -conf parameter.
2. I want to know: Where need the scripts to be placed?
3. I want to know: What else has to be done that i can use my "adcs"-connection after i have the certs-generator and i had entered the information to the adchpp.xml?

I am hopefully waiting:

Here are my scripts.xml and my adchpp.xml

Scripts.xml:

<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<ScriptPlugin>
        <Engine language="lua" scriptPath="/home/dchub/adchpp24/Scripts/">
                <Script>access.lua</Script>
                <Script>history.lua</Script>
                <Script>motd.lua</Script>
        </Engine>
</ScriptPlugin>

My adchpp.xml:

<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<ADCHubPlusPlus>
        <Settings>

<!-- Hub name and message of the day -->
                <!-- This is the name of the hub as it should be reported to the clients during
                         login and to the hub registration services. -->
                <HubName type="string">ADCH++</HubName>
                <Description type="string">ADCH++ Test hub</Description>

<!-- Logging -->
                <!-- Enable/disable logging -->
                <Log type="int">1</Log>

                <!-- Logging, when enabled, is done to this file. The filename is first passed
                         through strftime with the current time (see any standard c library reference
                         to find out what works...). There's not much logging done at all btw, but
                         plugins can use the logs as well... -->
                <LogFile type="string">logs/adchpp%Y%m.log</LogFile>

<!-- Advanced connection settings (don't change unless you at least think you know what you're doing) -->
                <!-- Maximum send size, changes how much data is sent at most to a single user per
                         call to the socket api. Experiment with this, lower settings might be more fair
                         in the distribution of available bandwidth at the cost of network/cpu efficiency.
                         Don't set below 256, 0 = disable. Experiment with this, it has many strange effects! -->
                <MaxSendSize type="int">1400</MaxSendSize>

                <MaxBufferSize type="int">16384</MaxBufferSize>
                <BufferSize type="int">256</BufferSize>
                <MaxCommandSize type="int">16384</MaxCommandSize>
                <!-- Milliseconds before a user is disconnected when his/her outgoing buffer
                         becomes larger than MaxRecvSize (outgoing buffer overflow). -->
                <OverflowTimeout type="int">60000</OverflowTimeout>

                <!-- Try to keep slow users from overflowing by not sending searches to them
                         when they're in the overflow state -->
                <KeepSlowUsers type="int">1</KeepSlowUsers>

                <!-- Buffer size, this is the minimum buffer size that is initially assigned to
                         each user. Larger buffer = more memory usage / user, less = a little bit
                         slower performance if the user sends more than these many bytes at a time
                         (in a chat message for instance...). Don't set to lower than 256. -->
                <BufferSize type="int">512</BufferSize>

                <!-- Timeout (ms) before ADCH++ stops trying to empty its send buffer for a user
                         (to send a kick message for example), and disconnects him/her. -->
                <DisconnectTimeout>10000</DisconnectTimeout>
                <LoginTimeout>30</LoginTimeout>
        </Settings>

        <Servers>
                <!--
                One <Server> tag per listening connection.

                To create secure connections, set TLS="1" and define the following (preferably absolute)
                paths: Certificate, PrivateKey, TrustedPath, DHParams. An example secure server setting:
                -->
                <Server Port="1091" TLS="1" Certificate="/home/dchub/adchpp24/certs/cacert.pem" PrivateKey="/home/dchub/adchpp24/certs/privkey.pem" TrustedPath="/home/dchub/adchpp24/certs/trusted/" DHParams=$
                <!--
                Simple OpenSSL commands to generate files used for secure connections:
                openssl genrsa -out privkey.pem 2048
                openssl req -new -x509 -key privkey.pem -out cacert.pem -days 1095
                openssl dhparam -outform PEM -out dhparam.pem 1024

                Alternatively, you can use the cert generator contributed on
                <http://launchpadlibrarian.net/31960965/Cert_Generator.7z>.

                -->
                <Server Port="1090"/>
        </Servers>

<!-- Instead of scripts, ADCH++ uses plugins. Plugins can do the same work
                 as scripts, are more difficult to write, but when it comes to performance,
                 the difference between the two is absurd. This way, it's also possible to
                 write a script plugin, enabling people to choose their own script language,
                 if someone's written a script plugin for it. You must specify the path to your
                 plugins in linux!!! -->
        <Path="/home/run/adchpp24/lib/adchpp/">
        <Plugins>
                <!-- This plugins provides the scripting support. -->
                <Plugin>Script</Plugin>
                <!-- Bloom filter plugin, helps save upload bandwidth at a slight expense of memory and download bandwidth -->
                <Plugin>Bloom</Plugin>
        </Plugins>
</ADCHubPlusPlus>

Question information

Language:
English Edit question
Status:
Answered
For:
ADCH++ Edit question
Assignee:
Toast Edit question
Last query:
Last reply:
Revision history for this message
Toast (swetoast-deactivatedaccount) said :
#1

Toast suggests this article as an answer to your question:
FAQ #704: “ADCH++ 2.x: LUA errors when running under Linux”.

Revision history for this message
Toast (swetoast-deactivatedaccount) said :
#2

Toast suggests this article as an answer to your question:
FAQ #750: “ADCH++ 2.x: How to setup in ADCS mode”.

Revision history for this message
Toast (swetoast-deactivatedaccount) said :
#3
Revision history for this message
Toast (swetoast-deactivatedaccount) said :
#4

Alternatively u can open another thread and suggest stuff missing in the guide after reading it properly that way i can include more detailed info that might be missing but i think most of the stuff is addressed in the guide

Revision history for this message
Crazy21 (hanibal-lector) said :
#5

Hi again,
So, there only two possibilities:
First: I am really to stupid
or Second: that is what I preferred, of cause, the manuals won't do.

The links you give include nothing I do not read till by now, but it was a good idea to read them again.
Do I right that I have to create a folder in /etc/adchpp/ and put into it the adchpp.xml?

I am right that i need scripts to activate the register function? Cause if i try out +regme <username> <pass> in my ApexDc++ Client it will not be recognized.

But how to activate scripts? In the userguide is written that I have to modify the scripts.xml, which is in the same Folder like the adchpp.xml, I found a Script.xml i modified it and i make copies scripts.xml and Scripts.xml
The path of the of the Scrips folder should be absolute, too, right? So I take "/home/dchub/adchpp24/Scripts"

And in the last term the thing with the ssl. I read the userguide i modified my adchpp.xml like it be told, the ports are free, but the hub do not allow a connection. I think there must be an exchange of information on base of the exchange of files right? Public key or Certificate, or sth like this. Any way the description of user guide is not a help.

(Pleas don't ask after 2.5 or 2.5.1, cause both I cannot compile, both crash down)

Revision history for this message
Toast (swetoast-deactivatedaccount) said :
#6

we are actually at 2.5.2 and you should take the time to read how to compile and what tools that are necessary now as for scripts yeah it can be a bit tricky but its all there and best case scenario for linux users is to use absolute paths

Revision history for this message
Toast (swetoast-deactivatedaccount) said :
#7

Toast suggests this article as an answer to your question:
FAQ #704: “ADCH++ 2.x: LUA errors when running under Linux”.

Revision history for this message
Thomas Maerz (thomasmaerz) said :
#8

I'm also having issues with getting the plugins to work in linux, and have tried FAQ #704 (using absolute paths and installing LUA from repo and other related instructions)

I have placed everything from /adchpp/build/release-default/bin/ into /usr/lib/adchpp/
I have the hub running in secure mode, but each time I launch it I have to specify the absolute path to the configuration file with

./adchppd -c /usr/lib/adchpp/config/

I changed the plugins path line to say:
<Plugins Path="/usr/lib/adchpp/scripts">

It runs fine in secure mode, but it doesn't find the plugins, so the hub not too useful yet. No +help, no MOTD.

Can you help with this problem?

Provide an answer of your own, or ask Crazy21 for more information if necessary.

To post a message you must log in.