How to check server configuration files through command line.

Following commands can be use to check the syntax of the configuration files of different services:
1) To check the syntax of APACHE:

httpd -t

In order to check the syntax of virtualhost:

httpd -t -D DUMP_VHOSTS

2)To check syntax for DNS:
a) checking syntax errors in the main configuration file..

named-checkconf main-config-file

main-config-file : Mention the path of the main configuration file.
b)To check the zone file for a domain.

named-checkzone domain zonefile-location

zonefile-location: The exact location of the zone file to be checked
3)To check syntax of SAMBA:

testparm

4)To check syntax of SQUID server:

squid -k check
squid -k parse