romanbsd / kannel-mongodb Goto Github PK
View Code? Open in Web Editor NEWKannel mirror with MongoDB DLR storage support and other features
License: Other
Kannel mirror with MongoDB DLR storage support and other features
License: Other
README for Kannel: Open Source WAP and SMS Gateway Abstract This README describes Kannel, the Open Source WAP and SMS gateway, and how it can be used and installed. Introduction The Kannel Open Source WAP and SMS gateway works as both an SMS gateway, for implementing keyword based services via GSM text messages, and a WAP gateway, via UDP. The SMS part is fairly mature, the WAP part is early in its development. In this release, the GET request for WML pages and WMLScript files via HTTP works, including compilation for WML and WMLScript to binary forms. Only the data call bearer (UDP) is supported, not SMS. Requirements You need a Unix-like operating system that supports POSIX threads (pthreads.h). We use RedHat Linux and Debian GNU/Linux systems. There is also support for the Cygwin 1.3 POSIX emulation layer for the Win32 platforms. You need GNU make, other make's tend not to work. For example, the FreeBSD and Solaris versions of make do not work. Check the version of your make with "make --version"; if it does not reply with "GNU Make version x.y.z", then it is not GNU make. On Solaris, you probably want to install gcc, GNU make and GNU binutils from www.sunfreeware.com. On MacOS X, you may have problems in compiling the latest libxml (2.4.23). There may be linking errors for those library. A work- arround is either using an older version of libxml (2.3.9 for example) or to build it as static library without the dynamic one being built. Documentation The user manual is in the doc/userguide directory and although it is not complete, explain almost all parts of Kannel. Developer documentation (currently very outdated) is in the doc/arch directory. In order to convert the documentation from DocBook (a markup language) to HTML and PostScript, you need some tools. On a Debian GNU/Linux system, you need to install the following packages via: $ sudo apt-get install docbook-stylesheets On a Red Hat Linux (RHEL) system, you need to install the following packages, in order: sgml-common psgml docbook stylesheets jade jadetex transfig See http://www.rpmfind.net to find the packages. On a Fedora Core system, you need to install the following packages: $ sudo yum install openjade jadetex docbook-style-dsssl \ texlive-dvips transfig ImageMagick On a Gentoo system, the following should do: $ sudo emerge transfig jadetex docbook-dsssl-stylesheets On a Mandrakelinux system, the following should do: $ urpmi transfig jadetex docbook-style-dsssl Then apply this change to /usr/share/texmf/web2c/texmf.cnf: hash_extra.jadetex = 15000 hash_extra.pdfjadetex = 15000 pool_size.jadetex = 500000 pool_size.pdfjadetex = 500000 string_vacancies.jadetex = 45000 string_vacancies.pdfjadetex = 45000 max_strings.jadetex = 55000 max_strings.pdfjadetex = 55000 pool_free.jadetex = 47500 pool_free.pdfjadetex = 47500 nest_size.jadetex = 500 nest_size.pdfjadetex = 500 param_size.jadetex = 1500 param_size.pdfjadetex = 1500 save_size.jadetex = 5000 save_size.pdfjadetex = 5000 stack_size.jadetex = 1500 stack_size.pdfjadetex = 1500 On other systems, you'll have to figure it out yourself. Getting the gateway sources You can download the sources from http://www.kannel.org/download.shtml. Note that you also need the Gnome-xml library from http://xmlsoft.org/xml.html. That one probably requires zlib, depending on how it is configured. You need at least version 2.2.0 Compiling and installing the gateway See the file INSTALL for generic installation instructions. The short form: ./configure touch .depend make depend make make bindir=/somewhere/suitable install See the User Guide (doc/userguide/ or http://www.kannel.org/userguide.shtml) for Kannel specific options to configure. For developers only: autoconf, configure, config.status, and Makefile We use the GNU autoconf tool to make it easier to adapt Kannel to each platform. The `autoconf' program reads the file configure.in, and generates a corresponding shell script called configure, which investigates the system it runs on to see what it supports and what it does not. configure then reads Makefile.in and config.h.in and writes out Makefile, config.h, and a shell script config.status. If you modify configure.in, you need to run autoconf. If you modify Makefile.in or config.h.in, you need to run config.status. If you modify any source files to add or change any header includes, you need to run "make depend". You always need to run "make" (which is the same as "make all"). If you have trouble building things and suspect that there is a problem with the Makefile, run "make clean all". If that solves it, report it as a bug (see the end of this README). For developers only: adding new SMS Center protocol support As Kannel does not support all the SMSC protocols that exists, it might become necessary to add new kind of protocols, including support to use mobile phones as SMSCes. When doing this, read interface specification in gw/smscconn_p.h. Drivers should stick to these rules as good as they can. For developers only: "make check" The Kannel Makefile contains a target called "check", which is used to run a series of automatic, non-interactive tests on various subsystems. Each test program MUST stored in the `checks' subdirectory. Each test MUST be written either as a C program named `check_*.c' or a Bourne shell script named `check_*.sh'. The C programs are compiled by the Makefile, the shell scripts MUST be executable. The test programs MUST output nothing to stdout, and MUST use a zero exit code to indicate that the test was successful, and a non-zero exit code to indicate a failure of the test. This way, if one runs "make -s check", one can easily see which tests are run and which tests work. The test programs MUST output error messages to stderr and they MUST mention which test program and which subtest failed. In case of failure, they may leave log files or other auxiliary files, and these MUST be listed in the error messages to stderr, so that the user has a reasonable way to diagnose the error. The Makefile captures the stderr output to `check.log'. The tests SHOULD take a reasonable time, preferably less than fifteen seconds each. This way, one can run "make -s check" before each commit. If there is a need to run longer tests, then the tests need to be divided into fast and slow ones. These tests are meant to test whether subsystems mostly work, stress testing needs to be done separately, and tends to require testing against real applications. For developers only: Source tree organization The source tree is organized as follows: gateway root of source tree: some docs, no sources |-- contrib contributed extra material |-- doc documentation |-- gw the gateway itself |-- gwlib utility functions |-- test programs for testing the gateway `-- utils utility programs For developers only: WMLScript references WMLScript Specification Wireless Application Protocol WMLScript Language Specification Version 1.1 http://www.wapforum.org/ WMLScript Standard Libraries Specification Wireless Aplication Protocol WMLScript Standard Libraries Specification Version 1.1 http://www.wapforum.org/ RFC-2279 UTF-8, a transformation format of ISO 10646 rfc/iana/assignments/character-sets The official names for character sets that may be used in the Internet and may be referred to in Internet Documentation. ANSI/IEEE Std 754-1985 IEEE Standard for Binary Floating-Point Arithmetic. Institute of Electrical and Electronics Engineers, New York (1985). Configuring and running the gateway See the user guide in doc/userguide or on the web at http://www.kannel.org/doc.shtml. For test use, you can see sample configurations gw/smskannel.conf (SMS gateway) and gw/wapkannel.conf (WAP gateway). Using the gateway with a Nokia 7110 To configure a Nokia 7110 to use the gateway, fill in the following (note that you need to provide your own dialup line): Home page: http://www.kannel.org/wap/hello.wml (or any other WML page) Connection type: continuous Connection security: off Bearer: data Dial-up number: <your dialup line> IP address: <IP number of the host running bearer box> Authentication type: normal Data call type: <analog or isdn, depending on your line> Data call speed: 9600 User name: <username for your dialup line> Password: <password for your dialup line> After you have modified the profile, activate it and load the home page. If you use the sample page above, you should see "hello, world" on the screen after a few moments. Modifications to old Kannel (0.8 and older) After release 0.8 Kannel architecture has been modified considerably, resulting changes in basic running of the standard WAP or WAP gateway. In new design, there is only one configuration file (to be more exact, you can have several of them, one for each kind of box, but that is advanced feature, which is not very usable) for bearerbox, smsboxes and wapboxes. Details of that file is in doc/userguide/newconf.txt. As a quick reference, you just put all your old configuration files into same file, remove some rows and add 'group = xxx' variables into it. Moreover, there is no internal smsbox in new Kannel. So, when running SMS services you MUST run separate smsbox. This is most easily done with Kannel as daemon, launched with init.d. See utils/ directory for any supplied systems. Feedback and more information You may want to subscribe the announce and devel lists at www.kannel.org. If you need help or want to participate in the development of Kannel. Send e-mail to [email protected] [email protected] (You'll get further instructions via automatic reply mails.)
Sir,
now i am trying to make sqlbox compatible with mongodb but when i used to configure kannel again after installing sqlbox is is having error
libgw.a(dlr_mongodb.o): In function dlr_mongodb_remove': /root/kannel-mongodb/gw/dlr_mongodb.c:274: undefined reference to
bson_buffer_init'
/root/kannel-mongodb/gw/dlr_mongodb.c:282: undefined reference to bson_from_buffer' libgw.a(dlr_mongodb.o): In function
dlr_mongodb_update':
/root/kannel-mongodb/gw/dlr_mongodb.c:231: undefined reference to bson_buffer_init' /root/kannel-mongodb/gw/dlr_mongodb.c:239: undefined reference to
bson_from_buffer'
/root/kannel-mongodb/gw/dlr_mongodb.c:241: undefined reference to bson_buffer_init' /root/kannel-mongodb/gw/dlr_mongodb.c:247: undefined reference to
bson_from_buffer'
libgw.a(dlr_mongodb.o): In function dlr_mongodb_get': /root/kannel-mongodb/gw/dlr_mongodb.c:160: undefined reference to
bson_buffer_init'
/root/kannel-mongodb/gw/dlr_mongodb.c:168: undefined reference to bson_from_buffer' libgw.a(dlr_mongodb.o): In function
dlr_mongodb_add':
/root/kannel-mongodb/gw/dlr_mongodb.c:114: undefined reference to bson_buffer_init' /root/kannel-mongodb/gw/dlr_mongodb.c:129: undefined reference to
bson_from_buffer'
libgw.a(dlr_mongodb.o): In function dlr_mongodb_ensure_index': /root/kannel-mongodb/gw/dlr_mongodb.c:72: undefined reference to
bson_buffer_init'
/root/kannel-mongodb/gw/dlr_mongodb.c:75: undefined reference to `bson_from_buffer'
collect2: ld returned 1 exit status
make: *** [gw/bearerbox] Error 1
in make step please tell me there coding problem or c driver error..
I had tried to configure kannel with mongodb put it is not working logs reports showing that it cannot find mongodb client libraries but i had configured the mongo db c driver and it is properly working with normal c programs but not for kannel my complete log of configuration is....
./configure --with-mongodb
checking git checkout revision...
Configuring for Kannel gateway version git- ...
Running system checks ...
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
./configure: line 2466: AC_PROG_CC_C99: command not found
checking for a BSD-compatible install... /usr/bin/install -c
checking for ranlib... ranlib
checking for bison... bison -y
checking for flex... flex
checking for yywrap in -lfl... yes
checking lex output file root... lex.yy
checking whether yytext is a pointer... yes
checking for ar... ar
checking for convert... no
checking for perl... /usr/bin/perl
checking for inline... inline
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... no
checking for _LARGE_FILES value needed for large files... no
checking how to run the C preprocessor... gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for short... yes
checking size of short... 2
checking for int... yes
checking size of int... 4
checking for long... yes
checking size of long... 8
checking for long long... yes
checking size of long long... 8
checking for log in -lm... yes
checking for accept in -lsocket... no
checking for inet_ntoa in -lnsl... yes
checking for inet_ntop in -lresolv... yes
checking for inet_ntop in -lbind... no
checking for pthread_exit in -lpthread... yes
checking for ANSI C header files... (cached) yes
checking sys/ioctl.h usability... yes
checking sys/ioctl.h presence... yes
checking for sys/ioctl.h... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking for sys/types.h... (cached) yes
checking for unistd.h... (cached) yes
checking sys/poll.h usability... yes
checking sys/poll.h presence... yes
checking for sys/poll.h... yes
checking pthread.h usability... yes
checking pthread.h presence... yes
checking for pthread.h... yes
checking getopt.h usability... yes
checking getopt.h presence... yes
checking for getopt.h... yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking zlib.h usability... yes
checking zlib.h presence... yes
checking for zlib.h... yes
checking execinfo.h usability... yes
checking execinfo.h presence... yes
checking for execinfo.h... yes
checking for stdlib.h... (cached) yes
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking sys/sockio.h usability... no
checking sys/sockio.h presence... no
checking for sys/sockio.h... no
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking for net/if.h... yes
checking sys/ucontext.h usability... yes
checking sys/ucontext.h presence... yes
checking for sys/ucontext.h... yes
./configure: line 7301: AM_ICONV: command not found
checking for gettimeofday... yes
checking for select... yes
checking for socket... yes
checking for strdup... yes
checking for getopt_long... yes
checking for localtime_r... yes
checking for gmtime_r... yes
checking for backtrace... yes
checking for srandom... yes
checking for initgroups... yes
checking for strtoll... yes
checking for strtoq... yes
checking for getopt... yes
checking for gethostbyname_r... yes
checking for which type of gethostbyname_r... 6
checking for socklen_t in <sys/socket.h>... yes
checking for getopt in <stdio.h>... no
checking for getopt in <unistd.h>... yes
checking regex.h usability... yes
checking regex.h presence... yes
checking for regex.h... yes
checking for regcomp... yes
Checking for POSIX threads support ...
checking for working pthreads... yes
checking for pthread_spinlock support... yes
checking for pthread_rwlock support... yes
checking for sem_init in -lrt... yes
checking for semaphore support... yes
Checking for libxml2 support ...
checking for xml2-config... /usr/bin/xml2-config
checking libxml version... 2.6.26
Configuring for PCRE support ...
checking whether to compile with PCRE support... disabled
Configuring DocBook support ...
checking for jade... jade
checking for jadetex... jadetex
checking for pdfjadetex... pdfjadetex
checking for dvips... dvips
checking for fig2dev... fig2dev
checking for convert... no
checking for /usr/lib/sgml/stylesheet/dsssl/docbook/nwalsh/html/docbook.dsl... no
checking for /usr/lib/sgml/stylesheets/nwalsh-modular/html/docbook.dsl... no
checking for /usr/share/sgml/docbook/dsssl-stylesheets-1.79/html/docbook.dsl... yes
checking for /usr/lib/sgml/stylesheet/dsssl/docbook/nwalsh/print/docbook.dsl... no
checking for /usr/lib/sgml/stylesheets/nwalsh-modular/print/docbook.dsl... no
checking for /usr/share/sgml/docbook/dsssl-stylesheets-1.79/print/docbook.dsl... yes
Not building documentation.
Configuring parameters ...
checking which malloc to use... native malloc
enabling local time
enabling cookies
enabling HTTP/1.1 keep-alive
Configuring OpenSSL support ...
checking whether to compile with SSL support... trying /usr/lib64 /usr/include/openssl
checking for openssl... /usr/bin/openssl
checking for CRYPTO_lock in -lcrypto... yes
checking for SSL_library_init in -lssl... yes
checking for SSL_connect in -lssl... yes
checking openssl/x509.h usability... yes
checking openssl/x509.h presence... yes
checking for openssl/x509.h... yes
checking openssl/rsa.h usability... yes
checking openssl/rsa.h presence... yes
checking for openssl/rsa.h... yes
checking openssl/crypto.h usability... yes
checking openssl/crypto.h presence... yes
checking for openssl/crypto.h... yes
checking openssl/pem.h usability... yes
checking openssl/pem.h presence... yes
checking for openssl/pem.h... yes
checking openssl/ssl.h usability... yes
checking openssl/ssl.h presence... yes
checking for openssl/ssl.h... yes
checking openssl/err.h usability... yes
checking openssl/err.h presence... yes
checking for openssl/err.h... yes
checking openssl/hmac.h usability... yes
checking openssl/hmac.h presence... yes
checking for openssl/hmac.h... yes
checking whether the OpenSSL library is multithread-enabled... yes
checking whether to compile with SSL support... yes
Configuring DB support ...
checking whether to compile with MySQL support... disabled
checking whether to compile with LibSDB support... disabled
checking whether to compile with SQLite2 support... disabled
checking whether to compile with SQLite3 support... disabled
checking whether to compile with Oracle support... disabled
checking whether to compile with PostgresSQL support... disabled
checking whether to compile with MongoDB support... searching
checking /usr/include/mongo/mongo.h usability... no
checking /usr/include/mongo/mongo.h presence... no
checking for /usr/include/mongo/mongo.h... no
checking for mongo_connect in -lmongo... no
configure: error: Unable to find MongoDB client libraries
please response your answer will be appreciated and awaited......
regard
garima
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.