ManyCodes.com – codes & scripts Get free programming codes and tutorials!

21Jul/090

How to Install dig on a CentOS Linux Server?

Installing dig on a CentOS Linux server is easy with yum. Dig is actually a bind tool so you will be required to install some bind libraries along with the bind utility package.

 [root@server ~]# yum install bind-utils  

Now you can run something like the below using dig to find MX records.

 [root@server ~]# dig @NAMESERVER EXAMPLE.COM MX  

Your install will look something like the below showing how yum looks for dependencies and installs them automatically.


[root@server ~]# yum install bind-utils
Loading "installonlyn" plugin
Setting up Install Process
Setting up repositories
Reading repository metadata in from local files
Parsing package install arguments
Resolving Dependencies
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for bind-utils to pack into transaction set.
bind-utils-9.3.4-6.0.2.P1 100% |=========================| 40 kB 00:00
---> Package bind-utils.x86_64 30:9.3.4-6.0.2.P1.el5_2 set to be updated
--> Running transaction check
--> Processing Dependency: libisccc.so.0()(64bit) for package: bind-utils
--> Processing Dependency: bind-libs = 30:9.3.4-6.0.2.P1.el5_2 for package: bind-utils
--> Processing Dependency: libbind9.so.0()(64bit) for package: bind-utils
--> Processing Dependency: libdns.so.22()(64bit) for package: bind-utils
--> Processing Dependency: libisccfg.so.1()(64bit) for package: bind-utils
--> Processing Dependency: liblwres.so.9()(64bit) for package: bind-utils
--> Processing Dependency: libisc.so.11()(64bit) for package: bind-utils
--> Restarting Dependency Resolution with new changes.
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for bind-libs to pack into transaction set.
bind-libs-9.3.4-6.0.2.P1. 100% |=========================| 41 kB 00:01
---> Package bind-libs.x86_64 30:9.3.4-6.0.2.P1.el5_2 set to be updated
--> Running transaction check

Dependencies Resolved

=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
bind-utils x86_64 30:9.3.4-6.0.2.P1.el5_2 updates 171 k
Installing for dependencies:
bind-libs x86_64 30:9.3.4-6.0.2.P1.el5_2 updates 874 k

Transaction Summary
=============================================================================
Install 2 Package(s)
Update 0 Package(s)
Remove 0 Package(s)

Total download size: 1.0 M
Is this ok [y/N]: y
Downloading Packages:
(1/2): bind-libs-9.3.4-6. 100% |=========================| 874 kB 00:35
(2/2): bind-utils-9.3.4-6 100% |=========================| 171 kB 00:04
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing: bind-libs ######################### [1/2]
Installing: bind-utils ######################### [2/2]

Installed: bind-utils.x86_64 30:9.3.4-6.0.2.P1.el5_2
Dependency Installed: bind-libs.x86_64 30:9.3.4-6.0.2.P1.el5_2
Complete!



Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Webnews
  • Digg
  • del.icio.us
  • StumbleUpon
  • Reddit
  • Ask
  • Facebook
  • Technorati
  • YahooBuzz