Howdy helpandrersearch!
Here is the step-by-step process to install a CGI
script on a ATL Networks Linux (UNIX) server site.
The following are excerpts from various Frequently
Asked Questions (FAQ) links on the ATL Networks
website, plus comments.
http://www.atlnetworks.com/support/helpdesk/faq.php
You should carefully read any instructions that
might have come with the CGI script you are using,
as this will save you lots of headaches and give
you essential information, such as permissions for
the files, variables that need to be modified, etc.
You might have to replace a line of the CGI script
you are using, and that will appear similar to the
following, to the following line. You will want to
modify a copy of the CGI script and make a backup copy
of the original left unmodified.
#!/usr/bin/perl -w
Once done with the above, you will need to tranfer the
files from your computer to the computer that contains
your website. You will use a process called FTP or
File Transfer Protocol, and will use an FTP program to
accomplish this process.
ATL Networks suggests using the free (for personal use)
FTP program called SmartFTP from SmartFTP.com.
http://www.smartftp.com/
SmartFTP features:
http://www.smartftp.com/features.php
- Windows XP / IE like user interface
- XP Theme Support
- Multilingual (more than 20 languages)
- TLS / SSL (128 bit)
[and much more]
Their download page is at:
http://www.smartftp.com/download/
"The setup routine automatically checks which files are
required for SmartFTP, then downloads and installs them
on your computer."
If you do not have an FTP program, you should download
and install SmartFTP. Here is some information modified
from the ATL Networks PDF manual. If you do not have
the free Adobe Acrobat Reader that you need to read the
manual, you can download it at:
http://www.adobe.com/products/acrobat/readstep2.html
The ATL Networks manual is at:
http://www.atlnetworks.com/support/manual.pdf
For SmartFTP, there will be three text boxes at the top
which is used to enter your hostname (ftp.yourdomain.com),
your username (usually the beginning of your domain name
(yourdomain), and your password. No matter which FTP
program you use, there will be a place to enter the above
information. You will replace the words "yourdomain" with
your domain name, such as google.com, etc. and use the
username and password assigned to you. Note the domain
name is in the format of ftp.yourdomain.com and not the
more familiar www.yourdomain.com format.
Once you run your FTP program and have logged on to your
FTP area, you will have a window which will show your
files on the server (remote) side. One of these will be
a folder named "cgi-bin" which you will want to click
on to open and is the folder to which you will upload
your CGI files.
In SmartFTP you will have a local directory on the left
side of the window. You will want to change to the
folder/directory that contains your CGI files, and then
upload those files to your remote cgi-bin folder. In
SmartFTP you can do that through the Commands menu, and
the Upload command.
ATL Networks has the following suggestions from
their PDF manual.
CGI - Perl/CGI scripts should only be run from the
cgi-bin directory of your hosting account. You will
also have to change the permission of the cgi files
to get them to run. This can easily be done through
your FTP client.
- Try right clicking on a cgi file and you should see
an option called CHMOD.
- The highest you are allowed to go is 755 which gives
users (yourself) full permissions, the group (plesk)
read and execute, and other (visitors) read and execute.
- No script needs to be higher than 755 because then an
outside person could potentially write to the script and
damage the server.
- Cgi scripts should also be uploaded in ASCII mode.
This is an option that all FTP clients have should have.
As per the instructions that might have been provided
with your CGI script, you might have to modify the
permissions of some of the files you just uploaded, and
within SmartFTP, you should be able to right click on
the file that you need to modify, click on the CHMOD
menu option, and then input the permissions, such as
755, etc.
That is about it. You will need to modify the web
page that is using the CGI script to properly run
the CGI script, but the CGI script instructions or
web page that it came from will usually have some
sample code.
Here are some entries from the ATL Networks FAQs
that might help answer any questions you still
might have. In worse case, they do have an entry
which states:
Will you install Perl modules?
Yes we will, we will first verify its compatibility
and also its impact on the server and then install.
From the ATL Networks FTP FAQ web page.
http://www.atlnetworks.com/support/helpdesk/faq.php?_c=2
What is FTP?
FTP stands for File Transfer Protocal. It is the
means which you are going to transfer your files
to our servers from your computer.
...
How do I FTP?
First are you going to need a FTP program. Some
popular ones are smartftp (smartftp.com), WS-FTP
(ipswitch.com) or cuteftp. We recommend using
smartftp.
...
When you open the program you will need to enter
your host location ftp.domain.com where domain.com
is your actual domain name.
...
Then enter the username and password you were
assigned.
...
What FTP software can I use?
There is a lot of FTP clients out there. One version
we recommend is smartFTP from smartftp.com. This is
free software and is very well documented.
...
You can also use cuteftp, ws-ftp and many others. A
search at downloads.com will reveal many more applications.
From the ATL Networks Scripting FAQ web page.
http://www.atlnetworks.com/support/helpdesk/faq.php?_c=7
Where do I put CGI-Perl files?
You should publish all cgi, perl files into your
cgi-bin directory. Your scripts will not work
anywhere else.
Why do none of my scripts work?
You should first make sure they are chmod'd to no
more than 755. If they are chmod'd more than 755,
the server will not execute it.
Where is Perl?
#!/usr/bin/perl -w
This should be the first line of your script.
...
How can I find what is causing an error in my
script?
Go into your shell or go into your FTP client
and go into your logs folder, there is a file
called error_logs that is very helpful. The most
recent logs are found at the bottom of the file.
This file could be quite large for some people.
...
How do I change the permissions of a file or
directory?
You can usually do this through your ftp client
by right clicking the file or folders and then select
chmod and click the desired permissions.
You can also do it from the command line in a telnet
session by using
chmod 755 filename
to change the permissions on a whole directory and
its contents it is:
chmod -R 755 foldername/
755 is just an example and is not always the solution
Search Strategy:
Went to the ATL Networks web page at:
http://www.atlnetworks.com
and read through their FAQs, and reviewed the website
of their recommend FTP program at:
http://www.smartftp.com
and combined that with my web hosting experience as a
former ISP owner.
If you need any clarificatiom, feel free to ask.
Looking Forward, denco-ga |