Search code examples
batch-fileipip-addressnslookup

Using BATCH to get country and ISP name from an IP or Hostname?


I need to complete this job in Batch.

I use NSLOOKUP command to find the Hostname of an IP, But how I can locate the country of that IP And the ISP Name?

Is it possibly?

Thankyou for read.

EDIT: For example i want to do this in a bat code:

IP address  **.***.30.113
Hostname    **-***-30-113.rdns.blackberry.net
ISP Research In Motion UK Limited
Country United Kingdom United Kingdom

EDIT 2: I accept an external APP to do it, please

I've tryed "whois" from sysinternals, But it's giving me bad info cause if i put my local ip in the program, it gives me the city of the organization (Madrid, Spain), not the most nearest location of mi isp provider (Valencia, Spain), If i geo-locate my ip in internet it gives me the good info (Valencia, Spain)

Any ideas about that?


Solution

  • You cannot get that information without an IP-to-Country table.

    Try http://www.maxmind.com/app/geolitecountry, it is free and works great.