# One parameter missing from GeoIP data via FCGI

**URL:** <https://www.ruby-forum.com/t/one-parameter-missing-from-geoip-data-via-fcgi/193767>\
**Category:** NGINX\
**Created:** [August 24, 2010, 3:01am UTC](https://www.ruby-forum.com/t/one-parameter-missing-from-geoip-data-via-fcgi/193767 "2010-08-24T03:01:22Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dean](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/3be4f8/32.png) [@dean](https://www.ruby-forum.com/u/dean)\
**Post date:** [August 24, 2010, 3:01am UTC](https://www.ruby-forum.com/t/one-parameter-missing-from-geoip-data-via-fcgi/193767/1 "2010-08-24T03:01:22Z")

</div>

I’m running v.0.8.49 with GeoIP using both a city and a country  
database. All of the GeoIP-generated parameters passed via FGCI seem to  
work great, except that $geoip\_postal\_code comes through empty.

I’ve checked my fastcgi\_param declarations several times (my symptoms  
seem to point to a config issue since only one variable is impacted) but  
everything looks in order. MaxMind states that they don’t have postal  
codes for all IPs, but I’ve tried on a few different IPs in the same  
general area here in the US with the same results–no postal code  
reported. I don’t believe it’s an issue on the FCGI application side,  
since I’m just doing a dump of the whole environment at this point.

Looking at the logfiles (debug level logging), the only thing out of  
order is

```
2010/08/23 17:39:03 [notice] 13420#0: getrlimit(RLIMIT_NOFILE):

```

1024:1024

which does not seem like an issue given that the number of served files  
will be less than 10 on this machine.

Any suggestions as to how to debug the parameter issue?

Posted at Nginx Forum:

> **[one parameter missing from GeoIP data via FCGI](https://forum.nginx.org/read.php?2,122988,122988#msg-122988)**
>
> I'm running v.0.8.49 with GeoIP using both a city and a country database. All of the GeoIP-generated parameters passed via FGCI seem to work great, except that $geoip\_postal\_code comes through empty. I've checked my fastcgi\_param declarations several...

---

<div class="post-metadata">

**Author:** ![dean](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/3be4f8/32.png) [@dean](https://www.ruby-forum.com/u/dean)\
**Post date:** [August 24, 2010, 8:11am UTC](https://www.ruby-forum.com/t/one-parameter-missing-from-geoip-data-via-fcgi/193767/2 "2010-08-24T08:11:37Z")

</div>

On Mon, Aug 23, 2010 at 09:00:26PM -0400, Dean wrote:

> since I’m just doing a dump of the whole environment at this point.  
> Any suggestions as to how to debug the parameter issue?  
> Could you test the IPs here:  
> [http://www.maxmind.com/app/locate\_demo\_ip](http://www.maxmind.com/app/locate_demo_ip)  
> Does the page show postal codes for these IPs ?

–  
Igor S.

> **[Igor Sysoev](http://sysoev.ru/en/)**

---

<div class="post-metadata">

**Author:** ![dean](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/3be4f8/32.png) [@dean](https://www.ruby-forum.com/u/dean)\
**Post date:** [August 24, 2010, 5:06pm UTC](https://www.ruby-forum.com/t/one-parameter-missing-from-geoip-data-via-fcgi/193767/3 "2010-08-24T17:06:47Z")

</div>

Thanks for the suggestion, Igor.

I tried 5 IPs on the MaxMind site. One of them had a postal code  
record–the rest were blank. When using that IP with nginx/GeoIP, the  
postal code field was empty.

Using the MaxMind website, the city and lat/long of the IP are reported  
differently from the same fields from the free MaxMind database used by  
the GeoIP module. The MaxMind online lookup site states that the data  
is from their commercial product, as opposed to the free one that I’m  
using with nginx.

So…it seems that the databases are somewhat different, and there may  
simply be no postal code data in the free database for the IPs that I’m  
testing with.

Cheers

Posted at Nginx Forum:

> **[Re: one parameter missing from GeoIP data via FCGI](https://forum.nginx.org/read.php?2,122988,123149#msg-123149)**
>
> I'm running v.0.8.49 with GeoIP using both a city and a country database. All of the GeoIP-generated parameters passed via FGCI seem to work great, except that $geoip\_postal\_code comes through empty. I've checked my fastcgi\_param declarations several...

---

<div class="post-metadata">

**Author:** ![dean](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/3be4f8/32.png) [@dean](https://www.ruby-forum.com/u/dean)\
**Post date:** [August 24, 2010, 11:51pm UTC](https://www.ruby-forum.com/t/one-parameter-missing-from-geoip-data-via-fcgi/193767/4 "2010-08-24T23:51:56Z")

</div>

On Tue, Aug 24, 2010 at 11:05:52AM -0400, Dean wrote:

> using with nginx.
> 
> So…it seems that the databases are somewhat different, and there may  
> simply be no postal code data in the free database for the IPs that I’m  
> testing with.

Could you tell the IP address which has a postal code on the MaxMind  
site ?

–  
Igor S.

> **[Igor Sysoev](http://sysoev.ru/en/)**
