Using whois can be a valuable tool to find out more information about a domain via the command line in Linux. A typical whois query can be performed to find out where the domain was purchased and using it again with the -h (host switch) can provide more detailed information about the domain. Using the -h switch will typically provide information such as who purchased the domain, when the domain was purchased, when the domain expires, etc. Below are a couple basic examples of how whois can be used followed by whois queries with the output.
Basic whois Query:
- [root@hunter ~]# whois networksolutions.com
In the output of the above command you will learn that the whois server for the networksolutions.com domain is whois.networksolutions.com. The output will look similar to the below.
Domains Whois Server Detail:
- Whois Server: whois.networksolutions.com
Once you know the “Whois Server” you can add that to your whois query as shown below.
Using Host Switch With whois Query:
- [root@hunter ~]# whois -h whois.networksolutions.com networksolutions.com
Below are the same command as listed below along with the output provided by each command.
Basic whois Query:
- [root@hunter ~]# whois networksolutions.com
- [Querying whois.verisign-grs.com]
- [whois.verisign-grs.com]
- Whois Server Version 2.0
- Domain names in the .com and .net domains can now be registered
- with many different competing registrars. Go to http://www.internic.net
- for detailed information.
- Domain Name: NETWORKSOLUTIONS.COM
- Registrar: NETWORK SOLUTIONS, LLC.
- Whois Server: whois.networksolutions.com
- Referral URL: http://www.networksolutions.com
- Name Server: NS1.NETSOL.COM
- Name Server: NS2.NETSOL.COM
- Name Server: NS3.NETSOL.COM
- Status: clientDeleteProhibited
- Status: clientTransferProhibited
- Status: clientUpdateProhibited
- Updated Date: 26-apr-2009
- Creation Date: 27-apr-1998
- Expiration Date: 26-apr-2019
- >>> Last update of whois database: Thu, 22 Oct 2009 02:04:14 UTC <<<
- NOTICE: The expiration date displayed in this record is the date the
- registrar's sponsorship of the domain name registration in the registry is
- currently set to expire. This date does not necessarily reflect the expiration
- date of the domain name registrant's agreement with the sponsoring
- registrar. Users may consult the sponsoring registrar's Whois database to
- view the registrar's reported date of expiration for this registration.
- TERMS OF USE: You are not authorized to access or query our Whois
- database through the use of electronic processes that are high-volume and
- automated except as reasonably necessary to register domain names or
- modify existing registrations; the Data in VeriSign Global Registry
- Services' ("VeriSign") Whois database is provided by VeriSign for
- information purposes only, and to assist persons in obtaining information
- about or related to a domain name registration record. VeriSign does not
- guarantee its accuracy. By submitting a Whois query, you agree to abide
- by the following terms of use: You agree that you may use this Data only
- for lawful purposes and that under no circumstances will you use this Data
- to: (1) allow, enable, or otherwise support the transmission of mass
- unsolicited, commercial advertising or solicitations via e-mail, telephone,
- or facsimile; or (2) enable high volume, automated, electronic processes
- that apply to VeriSign (or its computer systems). The compilation,
- repackaging, dissemination or other use of this Data is expressly
- prohibited without the prior written consent of VeriSign. You agree not to
- use electronic processes that are automated and high-volume to access or
- query the Whois database except as reasonably necessary to register
- domain names or modify existing registrations. VeriSign reserves the right
- to restrict your access to the Whois database in its sole discretion to ensure
- operational stability. VeriSign may restrict or terminate your access to the
- Whois database for failure to abide by these terms of use. VeriSign
- reserves the right to modify these terms at any time.
- The Registry database contains ONLY .COM, .NET, .EDU domains and Registrars.
- [root@hunter ~]#
- [/sourcecode]
- Again once the whois server is determined by the first query you can issue a more detailed query using -h to specify the whois server of the domain to obtain more detailed results such as below.
- <strong>Specifying A Whois Server Host With A whois Query:</strong>
- [sourcecode language="BASH"]
- [root@hunter ~]# whois -h whois.networksolutions.com networksolutions.com
- [Querying whois.networksolutions.com]
- [whois.networksolutions.com]
- NOTICE AND TERMS OF USE: You are not authorized to access or query our WHOIS
- database through the use of high-volume, automated, electronic processes. The
- Data in Network Solutions' WHOIS database is provided by Network Solutions for information
- purposes only, and to assist persons in obtaining information about or related
- to a domain name registration record. Network Solutions does not guarantee its accuracy.
- By submitting a WHOIS query, you agree to abide by the following terms of use:
- You agree that you may use this Data only for lawful purposes and that under no
- circumstances will you use this Data to: (1) allow, enable, or otherwise support
- the transmission of mass unsolicited, commercial advertising or solicitations
- via e-mail, telephone, or facsimile; or (2) enable high volume, automated,
- electronic processes that apply to Network Solutions (or its computer systems). The
- compilation, repackaging, dissemination or other use of this Data is expressly
- prohibited without the prior written consent of Network Solutions. You agree not to use
- high-volume, automated, electronic processes to access or query the WHOIS
- database. Network Solutions reserves the right to terminate your access to the WHOIS
- database in its sole discretion, including without limitation, for excessive
- querying of the WHOIS database or for failure to otherwise abide by this policy.
- Network Solutions reserves the right to modify these terms at any time.
- Get a FREE domain name registration, transfer, or renewal with any annual hosting package.
- http://www.networksolutions.com
- Visit AboutUs.org for more information about NETWORKSOLUTIONS.COM
- <a href="http://www.aboutus.org/NETWORKSOLUTIONS.COM">AboutUs: NETWORKSOLUTIONS.COM </a>
- Registrant:
- Network Solutions, LLC
- Network Solutions LLC
- 13861 Sunrise Valley Drive, Suite 300
- HERNDON, VA 20171
- US
- Domain Name: NETWORKSOLUTIONS.COM
- ------------------------------------------------------------------------
- Promote your business to millions of viewers for only $1 a month
- Learn how you can get an Enhanced Business Listing here for your domain name.
- Learn more at http://www.NetworkSolutions.com/
- ------------------------------------------------------------------------
- Administrative Contact, Technical Contact:
- Network Solutions, LLC nocsupervisor@networksolutions.com
- Network Solutions LLC
- 13861 Sunrise Valley Drive, Suite 300
- HERNDON, VA 20171
- US
- 570-708-8788 fax: 703-668-5817
- Record expires on 27-Apr-2019.
- Record created on 27-Apr-1998.
- Database last updated on 21-Oct-2009 22:03:06 EDT.
- Domain servers in listed order:
- NS1.NETSOL.COM 205.178.190.164
- NS2.NETSOL.COM 205.178.184.21
- NS3.NETSOL.COM 205.178.190. 165
- [root@hunter ~]#
As you can see the output of the second query is much more useful when attempting to locate more information about the domain or the company behind the domain. Some domains are registered privately which will limit the information available about the domain.