how do I use CGI on

This is how you use CGI on It is not intended to tell you how to use CGI in general.

Do this:

cd ~
mkdir public_html
mkdir public_html/cgi-bin
cd public_html/cgi-bin
cat > test <<EOD
echo Content-type: text/plain
echo HELLO
chmod a+x test

and then browse to You should see the word “HELLO” in your browser.

CGIs will run under your account, not as the www-data user.