qsgeo (1) - Linux Manuals
qsgeo: an utility to lookup a client's country code.
qsgeo - an utility to lookup a client's country code.
SYNOPSISqsgeo -d <path> [-l] [-s] [-ip <ip>]
DESCRIPTIONUse this utility to resolve the country codes of IP addresses within existing log files. The utility reads the log file data from stdin and writes them, with the injected country code, to stdout.
- -d <path>
- Specifies the path to the geographical database files (CSV file containing IP address ranges and country codes).
- Writes a summary of the requests per country only.
- Writes the database to stdout (ignoring stdin) inserting local (127.*) and private (10.*, 172.16*, 192.168.*) network addresses.
- -ip <ip>
- Resolves a single IP address instead of processing a log file.
EXAMPLEReading the file access_log and adding the country code to the IP address field:
Reading the file access_log and showing a summary only:
Resolving a single IP address:
AUTHORPascal Buchbinder, http://opensource.adnovum.ch/mod_qos/