1

On my Drupal 7.78 I installed the GeoIP module https://www.drupal.org/project/geoip I followed the steps in the Install.txt

1. Enable this module as usual.

2. Install one of the Maxmind php API:
   - GeoIP2 [https://github.com/maxmind/GeoIP2-php]:
     -- # phar package:
          Download the latest phar package:
          https://github.com/maxmind/GeoIP2-php/releases
          Place the file geoip2.phar here:
          sites/all/libraries/GeoIP2-phar/geoip2.phar
    
3. Download one of the GeoLite database files (matching the API):
   - GeoIP2: http://dev.maxmind.com/geoip/geoip2/geolite2/#Downloads
   - Legacy: http://dev.maxmind.com/geoip/legacy/downloadable/

On step 3 I downloaded the file GeoLite2-ASN.mmdb from maxmind.com

4. Create the directory 'sites/all/libraries/geoip' and extract the database
   file into this directory.
   You can use other locations too e.g. to share a database with varnish or
   other tools - to do so you can configure the path to the database to use in
   the module configuration (admin/config/system/geoip).

After step 4 I get the following error:

Warning:  stream_wrapper_register(): class 'TYPO3\PharStreamWrapper\PharStreamWrapper' is undefined in /home/customer/www/mydomain/public_html/misc/typo3/phar-stream-wrapper/src/PharStreamWrapper.php on line 509
    
Error: Class 'Database' not found in _registry_check_code() (line 3503 of /home/customer/www/mydomain/public_html/includes/bootstrap.inc

Before step 4 there was no error, what am I doing wrong? why do I get this error? how can I fix it?

3
  • Have you rebuilt the registry?
    – Kevin
    May 13, 2021 at 20:49
  • Thank you Kevin, after rebuilding the registry I get the same warning and the error: Error: Class 'SelectQuery' not found in DatabaseConnection->select() (line 854 of /home/customer/www/mydomain/public_html/includes/database/database.inc
    – MMT
    May 15, 2021 at 7:29
  • It seems like there can be some problems with geoip module after SA-CORE-2019-002. Please check these issues on Drupal.org, if one of them would help: 3028265 , 3026489 , 3026443 May 31, 2021 at 22:54

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.