before shooting any question you should try it by yourself or search in google or searched in this forum itself.
Anyway, here are some tips, you can follow.
1. Install Apache in your system. I you don't have the copy of it, then download the latest from http://httpd.apache.org/download.cgi
installation is very easy. If you are a windows user, then its very easy. Follow the instructions properly and install it.
2. After you install Apache, open your browser, type the URL of your web-server. You will get a Welcome page from Apache.
(for eg: this is what I type on my browser, http://localhost )
3. To run the CGI/Perl script you need to keep your scripts in cgi-bin folder, you can find this folder in the where Apache has installed on your system.
(for eg: http://localhost/cgi-bin/your_script_name.cgi )
4. To start of with, you get 'printenv.pl' after installation, a perl program which you can run.
(for eg: http://localhost/cgi-bin/printenv.pl )