Outcomment

From Linuxintro
Revision as of 16:16, 20 January 2012 by imported>ThorstenStaerk (Created page with "If you ''outcomment'' a line in a script or configuration file, you set it inactive. Scripts and configuration files typically allow you to write a comment if the line starts...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

If you outcomment a line in a script or configuration file, you set it inactive. Scripts and configuration files typically allow you to write a comment if the line starts with a #. The line is ignored then. If you do not want to delete a line (maybe to be able to add it again), you just use this feature and add a # as the first character into the line.

As an example, let's take /etc/xinet.d/vnc. In the following example, the line disabling this service has been outcommented, thus the service will be active:

service vnc1
{
        #disable        = yes
        socket_type     = stream
        protocol        = tcp
        wait            = no
        user            = nobody
        server          = /usr/bin/Xvnc
        server_args     = -SecurityTypes None -inetd -once -query localhost -geometry 1024x768 -depth 16
        type            = UNLISTED
        port            = 5901
}