A gadget that displays IP geolocation information under Linux-nali

Source: Internet
Author: User
Tags nslookup

First of all, this is not the original HA, the attention of bloggers too much, or put on their own blog more convenient, but also hope to have more people see good text.

First, Introduction

Nali, the name is taken from the Chinese "where" pinyin. Nali contains a set of command-line programs whose main function is to attach the IP strings of the output of some network tools to the location information (using the Pure database QQWry.Dat). For example, 74.125.128.104 will become 74.125.128.104[the California Mountain View of the United States Google Inc.]. Queries are made locally and do not make networked queries, so efficiency does not affect the original command.

The following commands are currently included:

    • Nali
    • Nali-dig
    • Nali-nslookup
    • Nali-traceroute
    • Nali-tracepath
    • Nali-ping

The premise of using these commands is that their corresponding command must exist. For example, if you want to use Nali-dig, you must ensure that dig is present. Their usage is the same as the original command. For example Nali-dig, usage is the same as dig. (Nali-dig equivalent to dig |nali)

Second, download

# wget--no-check-certificate http://qqwry.googlecode.com/files/nali-0.2.tar.gz

Third, installation

# tar ZXVF nali-0.2.tar.gz

# CD nali-0.2

#./configure

# Make && make install

Iv. Updating IP databases

You can use the Nali-update command to update the IP database

/usr/local/share/qqwry.dat This file needs to be updated frequently, otherwise the error will be relatively large.

V. Use of

5.1. Nali

# Nali 74.125.128.106

# Nali 61.135.169.105

5.2. Nali-dig

# Nali-dig www.google.com

5.3. Nali-nslookup

# nali-nslookup www.google.com

5.4. Nali-traceroute

# Nali-traceroute www.google.com

5.5. Nali-tracepath

# Nali-tracepath Www.baidu.com

5.6. Nali-ping

# nali-ping Www.163.com

5.7. Other program calls Nali Display IP physical location can use redirection mode, such as:

# mtr Www.google.com|nali

In other words, Nali This command, you can attach the geo-information to the standard output IP. Similarly, if you do not like to use Nali-dig, then you can also use dig Ip|nali such commands.

VI. Alias

If you think the input nali-xxx trouble, then you can do some alias, for example:

# alias Traceroute= ' Nali-traceroute '
# alias dig= ' Nali-dig '

Vii. Reference

Https://www.surfchen.org/nali

A gadget that displays IP geolocation information under Linux-nali

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.