Skip to content
Switch branches/tags
Go to file
Cannot retrieve contributors at this time

libkrisp Database management

KRISP database used two external databases. One is KRNIC(KISA) isp database and another is GeoLiteCountry database in Maxmind, available from

Database update cycle

update database every month, between 7th and 14th.

Database download

Get krisp.csv.gz or krisp-geoip.csv.gz at follow url:

Each database has features as follows:

  • krisp.csv.gz
    • only Korea allocated information
    • enable ISP inforamtion
    • small size (< 1MB)
  • krisp-geoip.csv.gz
    • world wide Country information
    • only Korean ISP information eanbled
    • big size (>20MB)

Database building

First, download krisp database

    [root@host ~]$ # blocking wget user agent, be carefull.
    [root@host ~]$ wget -U mozilla '`

And, uncompress download database.

    [root@host ~]$ gzip -d krisp-geoip.csv.gz

And, build database with libkrisp scheme in libkrisp source

The scheme file is located in current directory by named 'table'

    [root@host ~]$ # make scheme
    [root@host ~]$ cat <<EOF > scheme
    CREATE TABLE krisp
        start unsigned integer NOT NULL DEFAULT '0',
        end unsigned integer NOT NULL DEFAULT '0',
        data varchar,
        PRIMARY KEY (start DESC),
        UNIQUE (end)

    .sep "\t"
    .imp krisp-geoisp.csv krisp
    [root@host ~]$ # build krisp-geoip.dat
    [root@host ~]$ sqlite3 krisp-geoip.dat < ./scheme

Last, move data file to libkrisp data directory. ($prefix/share/krisp)