Server configuration file syntax Checking commands

2 comments

SERVER CONFIGURATION FILE SYNTAX CHECKING COMMANDS.

I have planned to write this post some long time ago, now the time has come to do it.

Basically configuring servers in Linux/*nix include editing of configuration files and saving them. Once editing the files if any syntax error is there and when we start the service they will show some wearied errors which we cant resolve.
For counter attacking this type of issues for each service there will be one command to check this syntax errors before starting of the service/server, I have collected these commands from my experience and from some of my friends. Please feel free to comment on this if you know some other commands so that I will update my post.

SSHD server check for syntax error
=========================
sshd -t

FTP server check for syntax error
=========================
#vsftpd

DNS server check for syntax error
==========================

For checking syntax errors in main configuration file..
#named-checkconf main-config-file

Example:
#named-checkconf named.conf

Syntax OK

#named-checkzone domain zonefile-loc

Example:
#named-checkzone example.com /var/named/chroot/var/named/exaple-zone.frd

SAMBA server check for syntax error
=============================
#testparm

APACHE server check for syntax error
=============================
httpd -t

For virtual hosts

httpd -t -D DUMP_VHOSTS

TCP Wrappers check for syntax error
============================
tcpdchk
tcpdchk -v


Postfox server check for syntax error
============================
postfix check
postfix -vv


LIGHTTPD
server check for syntax error
=============================
lighttpd -t -f /etc/lighttpd/lighttpd.conf

Squid
server check for syntax error
==========================
squid -k check
squid -k parse


NAGIOS server check for syntax error
====================================
/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg

  • Like the post? Please Subscribe to free RSS feed to get updates
  • Get a free shell account online

    0 comments

    GET A FREE SHELL ACCOUNT ONLINE.
    A shell is an utility from where you can access Linux/*Nix servers from any where and execute the commands/scripts etc.

    This post is for the users who are new to linux/Nix and want to feel/work on the Linux with out installing on the system. "Rootshell.be" is free online BSD(Berkeley Software Distribution) server where you can request a shell account and explore your self.

    There are so many free shell providers on net but most of the servers/service providers will not give you free account simply, you have to prove your self to them that you are not a spamer and you are really in need of shell account to explore Unix.

    Here are some advantages:

    1. No need to install any unix systems.
    2. Good for beginers.
    Some disadvantages:

    1. You can work on only limited commands provided by the system administrator.
    2. Require any SSH clients(such as Putty) and internet connection.
    Here are the links from where you can get your free Shell accounts


    1. rootshell.be (I personally used their service and its preaty good)
    2. http://www.red-pill.eu/freeunix.shtml
    Please comment on this so that I can improve the blog quality.

  • Like the post? Please Subscribe to free RSS feed to get updates
  • Distro's

    0 comments

    DISTRO'S.
    This is my first post on Distro's. To discuss about Distributions, there is lots and lots of information about them which is beyond this blog. But I will try to cover as much good and best distros in the market on weekly basis.

    To start with.. what is a Distro actually?
    A "Linux distribution" (also called GNU/Linux distribution by some vendors and users) is a member of the family of Unix-like software distributions built on top of the Linux kernel. A distro some times refferd as "Distribution" or "Flavor".

    1. For General public purpose(like Ubuntu & Fedora).
    2. For Corporate purpose(like Cisco Linux & Oracle Linux).
    3. For Regionality purpose(like swecha Linux for People whose mother tongue is Telugu).
    4. For Basic routing purpose(like Linux router project).
    A distro is nothing but linux kernel(in general it is considerd as core of operating system)+Applications(such as mail clients,servers, browsers office suite etc).

    Suppose if we say Redhat linux it is equal to Linux kernel developed by linus torvalds + Applications developed by Redhat people.
    For your information here are some details about Distro.
    There are more than 500 Distro's in Linux followed by Unix with 150 flavors then with Windows around 50

    Please keep an eye on this session to see coming Distro's.

  • Like the post? Please Subscribe to free RSS feed to get updates
  • Archive

    Translate this page

     

    The Linux Juggernaut | Copyright 2006-2009 Surendra Kumar Anne | Surendra's Home Page | Give us feedback how we are doing, Click here