IP Address cannot be found
portait - April 17, 2008 - 14:07
| Project: | GeoUser |
| Version: | 6.x-1.4-beta |
| Component: | Code |
| Category: | bug report |
| Priority: | critical |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
I am getting the following error when clicking on a user profile: "
IP address of the user cannot be found.
"
When a user logs into his account he get's this error message on top of the site: "
user warning: Unknown column 'region' in 'field list' query: insert into geouser (uid, addr, country, region, city) values (2, '77.25.243.21', 'Germany' ,'', '') in /var/www/web2/web/sites/all/modules/geouser/geouser.module on line 153.
"

#1
Yeah, I'm having the same problem. I don't think this module should be listed as being in beta.
#2
I have same problem.
I see that this topic is kind of old. Is this module still supported ?
Thanks for any answer.
#3
Ok, i guess this module is not supported any more, and is dead ?
#4
This module works fine for me., I used the latest GeoUser from today and the latest GeoLiteCity.
In my opinion this module is up to date and usable.
Keep in mind your using a trial version of GeoLiteCity., so many IP's will not be recognizable
and errors such as "IP address of the user cannot be found" should be expected. If you use
the paid version of the IP database this error may go away - if the IP is in the database.
You can also turn off your PHP errors if you do not want the user to see the error,
a map without markers will be visible to the user.
#5
subscribing
#6
if you use this module, expect many of theses errors...
for me, every second user had this error message
#7
#8
Also having this error...
#9
It looks like not every ip address is included in the database, which is understandable. This module should:
1) Not give a displayed error when an ip address can't be found
2) Handle no ip in a more elegant way
#10
Having looked at the code in
geouser.inc, it seems that this error is being thrown because there is no IP address of the user in the database and not because of the GeoLite City database.From what I can guess, the module works like this:
1) User accesses your site
2) geouser module uses Drupal core function
ip_address()to retrieve user IP and stores it in a table calledgeouser, in a row calledaddr.3) geouser module then:
- a) retrieves the user IP from the table (using the function
getUserIP($uid))- b) does a lookup of the physical location against the GeoLite City database.
So, this error is being thrown at step 3a because no IP for the user was stored in the database at step 2. Due to the
ip_address()not being able to assign an IP for the user.So, this error has nothing to do step 3b, the GeoLite City database itself.
Does anyone else see it differently?
@XerraX: The MaxMind site claims the that on a city level for the US (within a 25 mile radius) it will locate your users 79% of the time - which should be an unknown location about every 5th user. To me is seems your problem is related to the issue I outlined above, not due to the GeoLite City database.
Andrew
#11
@andrewsuth: my visitors are from Germany (60%) and USA (20%). so the city level plays a role?
#12
@XerraX: I assumed you had mostly US visitors, but still the correct resolution for Germany is quite high: 71%. And 26% matched to a location that is incorrect. Which makes a total of 97% of German user IPs SHOULD match to a location! (whether the location is totally accurate or not).
The issue is not with the GeoLite database - it is because the function
ip_address()(from Drupal core) cannot assign an IP to the user.MaxMind have put all of the accuracy values into a table with 3 columns explaining the percentages:
http://www.maxmind.com/app/geolite_city_accuracy
They explain the columns like this:
1) Correctly Resolved Within 25 Miles of True Location: refers to the IP addresses that are correctly resolved within 25 miles of the actual city.
2) Incorrectly Resolved More Than 25 Miles From True Location: refers to IP addresses that were incorrectly resolved by more than 25 miles of the actual city.
3) Not Covered on a City Level: refers to the percentage of the data of select country that does not contain city information. We leave these data ranges without city information to prevent false positives. The city information is not available for AOL IP address or when Internet Service Providers (ISPs) route traffic through proxies thus masking the originating location.
From my understanding they mean:
1) Matches IP to a location and it is accurate to 25 miles of the matched city. eg. it says "Berlin" and the user is from Berlin or very close to Berlin - so the IP to location result is highly accurate.
2) Matches IP to a location but the location is > 25 miles from the city - so it is not totally accurate. eg. it might say "Bonn" when in actual fact they are in "Cologna".
3) The user IP is not matched to a city location.
So according to my interpretation of this, the actual percentage of unmatched IPs to a location (whether it is accurate or not) is actually very small. eg. 3% for Germany.
But without an IP for the user from
ip_address()it will not find any location.Andrew
#13
I noticed after installing again it had to do with logging out and logging in? After re-logging in I did not get this problem, while my ip address remained the same,,,,