Contenu | Rechercher | Menus

Annonce

Si vous avez des soucis pour rester connecté, déconnectez-vous puis reconnectez-vous depuis ce lien en cochant la case
Me connecter automatiquement lors de mes prochaines visites.

À propos de l'équipe du forum.

#1 Le 22/02/2008, à 21:08

x@v

installez geoip sur apache2

Bonsoir,
j'aimerai installer le module geoIp
http://www.maxmind.com/app/php
http://fr3.php.net/manual/fr/ref.geoip.php
Mais une fois dl la base et le module, je ne suis pas très sur de moi ?
tar xvfz mod_geoip...tar.gz
mais ensuite je ne sais plus.
./configure -enable-module=so
Après y a t-il quelque chose à faire ou à ne pas faire ?
Parce qu'il dit :
To build mod_geoip as a dynamically loadable module:

apxs -i -a -L/usr/local/lib -I/usr/local/include -lGeoIP -c mod_geoip.c

-I/usr/local/include is where the GeoIP.h header file is installed
-L/usr/local/lib is where the libGeoIP library is located

donc mon fichier doit être ici
-I/usr/local/include is where the GeoIP.h header file is installed
avant de lancer cette commande ?
apxs -i -a -L/usr/local/lib -I/usr/local/include -lGeoIP -c mod_geoip.c

===========================================================================
Requirements:

Apache 2.0.40 installed  If using RPM, the httpd-devel package containing apxs may need to be installed
GeoIP 1.3.x or higher installed, download from http://maxmind.com/download/geoip/api/c

===========================================================================
To build mod_geoip as a dynamically loadable module:

apxs -i -a -L/usr/local/lib -I/usr/local/include -lGeoIP -c mod_geoip.c

-I/usr/local/include is where the GeoIP.h header file is installed
-L/usr/local/lib is where the libGeoIP library is located

This will put the correct LoadModule statement.

You will need to add:

===========================================================================
Configuration

To enable the module, place

<IfModule mod_geoip.c>
  GeoIPEnable On
</IfModule>

inside your httpd.conf file. ( You don't have to have the <IfModule> block, 
but it's always a good idea.

( You can optionally specify the data file by using: 

<IfModule mod_geoip.c>
  GeoIPEnable On
  GeoIPDBFile /usr/tmp/GeoIP.dat
</IfModule>

)

See the README file for more details on the configuration

===========================================================================

Troubleshooting

On RedHat 9, apxs places 

LoadModule geoip_module       /usr/lib/httpd/modules/mod_geoip.so

Inside a

<IfModule worker.c>
</IfModule>

Block.

If mod_geoip doesn't work, try taking the LoadModule geoip_module line outside
the <IfModule worker.c> block.

If you get the following errors:
  parse error before "geoip_module"
  warning: data definition has no type or storage class
Or
  syntax error before "geoip_module"

Make sure that the apxs script belongs to the Apache server you are using.
These error messages result from using a Apache 1.3 apxs script with
a Apache 2.0 server.

Merci

Dernière modification par x@v (Le 22/02/2008, à 21:15)


[-- qwerty user --]

Hors ligne