View the commented lines of text in a config file
Use grep to display lines in a configuration file that begin with particular characters. This lets you see what has been commented and makes it easier to search and check your settings. Command syntax
[root@Ezylinux ~]# grep -v "^#" myfile.conf | cat -s | less
For example, to display comments in a configuration file that uses #:
[root@Ezylinux ~]# grep -v "^#" /etc/CONFIGFILE.conf | cat -s | less
Or, to display comments in sendmail.mc, type:
[root@Ezylinux ~]# grep -v "^dnl" /etc/mail/sendmail.mc | cat -s | less