Well you have just downloaded HAMweather 2.0 and now are getting ready for the fun filled installation. The process isn't too bad, but if you do not have experience setting up CGI scripts or just do not have the time you may want to check out HAMweather, LLC's HAMweather Installation Services. Before installing you should use the HAMweather Pre-install Test script to ensure that you will be able to run HAMweather on your server.
NOTE: To add US zipcode searching capability you will need to also download the HWzipdb add-on and install it per its instructions. It is also recommended to install the HWaltplaces add-on. This add on will allow for more US "place, state" combinations than normally available in HAMweather. Both of these add-ons can be downloaded from http://www.hamweather.com/downloads
|Installation : Requirements|
HAMweather requires that your web site pass the following minimum requirements before
you will be able to use the HAMweather scripts:
NOTE: With HAMweather Version 2.0 Beta 1.05 or later the LWP::Simple Module is no longer needed.
NOTE: If you are unsure if your web site has the correct perl version and/or the needed modules then you use the HAMweather Pre-Installation test script to test your web site.
If your web site meets the above requirements then to fully install HAMweather 2.0 follow the next four easy steps. Following these steps should get a working version of HAMweather on your web site. After the demo is working then you can use the HAMweather web based administration to set and/or customize some of the various settings.
|Installation : STEP 1 : Uncompressing the package.|
The first step is to uncompress the software package. You can use Winzip or something similar. Once unzipped you should have a directory structure similar to the directory tree shown in Step 3.
|Installation : STEP 2 : Pre-Install Test|
Before you begin installing HAMweather on your server you should use the pre-install test script (hw2test.cgi) to test your server to make sure what version of HAMweather you should use and how to set it up.
Steps to perform the pre-install test:
Step 1. Set Perl path in the hw2test.cgi
You will need to change the first line of the pre-install test script (hw2test.cgi) to match the perl path for your server. This is usually something like: /usr/bin/perl or /usr/local/bin/perl. After modifying the first line it should look similiar to:
Step 2. Upload the HAMweather Pre-Install Test Script to your Server.
You will now use your FTP client to transfer the hw2test.cgi file from your local machine to your servers CGI-BIN directory (or equivalent) because it needs to be executed as a cgi script (Preferably upload the script to the same directory that you are going to put your HAMweather scripts in). Make sure you transfer the hw2test.cgi file in ASCII mode.
Next set the permissions on the hw2test.cgi file to 0755 (rwxr-xr-x). If you are on an NT server you can most likely skip this step.
NOTE: If your server requires an extension other than ".cgi" for perl scripts, you will need to rename the script. Calling it hw2test.pl or whatever the proper extensions is on your server. You will find that the ".cgi" extension works on most systems.
Step 3. Access the Pre-Install Test Script with your Browser
View the output of the script in your web browser by entering the URL to the script in your web browser. This URL will be determined by the directory to which you uploaded the hw2test.cgi script and the URL may look similar to: http://www.yourserver.com/cgi-bin/hamweather/hw2test.cgi.
If successful you will be presented with a web page detailing the version of perl on your system, what (if any) needed modules are available on your server. From this information the test script will attempt to inform you of which version of HAMweather you may use on your sever as is.
NOTE: The HW2test.cgi script will test to see if GD.pm, LWP modules and Socket.pm are available server wide. If you have installed these modules locally (mainly GD.pm) in your server space then the script may not find them. If you have installed them locally you can try adding the "use lib 'path/to/local/directory/containing/the/modules';" line as the second or third line of the script. Then try the accessing the script again, if the modules are found this time, then you will need to add this line to the hamweather.cgi file as well.
Trouble Shooting The Pre-Install Test Script
If you get a 500 Error (Internal Server Error), then one of the following is likely the problem:
If you get a 404 Error (File Not Found), then the URL that you entered does not correspond to the location where you put the hw2test.cgi script in step 2. You should double check the URL even the spleen and capitalization of the URL.
If you get a 403 Error (Forbidden), then you most likely forgot to change the permissions to 0755(executable) or you did not put the script in a directory with the appropriate CGI permissions.
If you see the source code of the script and not an information page, then either the extension that you gave the script is incorrect (if you tried ".cgi" try ".pl" instead), or you did not put the script in a directory with appropriate CGI permissions.
|Installation : STEP 3 : Setup Configuration Files|
NOTE: Be on the look out for the upcoming HAMweather Install Tool. It will help in the configuration of these setup files.
With the software package uncompressed it is now time for the hardest step of the installation process. Here you will need to set up the configuration files. In particular the default.txt file located in the "/users/" directory. Then you will need to edit the first 3 lines in CGI script files themselves.
You will need to gather the following four pieces of information and add them to the default.txt file in the user directory as stated::
- You will now need the URL to the cgi directory above that holds the HAMweather scripts. For Example: If the URL to the HAMweather script on your system will be: http://www.hamweather.com/cgi-bin/weather/hamweather.cgi then you will need to know the http://www.hamweather.com/cgi-bin/weather portion.
You will use this information to set the $hw_cgi_dir_url variable in the default.txt file. The line will look similar
$hw_cgi_dir_url = "http://www.hamweather.com/cgi-bin/weather";
- You will now need the full path name to the directory where the HAMweather cgi scripts will be. This is not the URL and does not include "http://." For Example: If the full path to the HAMweather html files directory on your system will be: /usr/www/users/hamnet/hamweather/hamweatherhtmlfiles.html then you will need to know the /usr/www/users/hamnet/hamweather/weather portion. (On Microsoft NT and W95/98 platforms you will also need to include the drive letter.)
NOTE: This is not the path to the HAMweather HTML templates but to the html files that lead into HAMweather. The HAMweather "images" directory and all its subdirectories must be in this directory as well. For Example: the images path would be /usr/www/users/hamnet/hamweather/weather/images.
You will use this information to set the $hw_html_dir_path variable near the top of the default.txt file. The line will look similar to :
- You will now need the URL to the cgi directory above that holds the HAMweather html files and images directory. For Example: If the URL to the HAMweather script on your system will be: http://www.hamweather.com/weather/hamweatherhtmlfiles.html then you will need to know the http://www.hamweather.com/weather portion.
You will use this information to set the $hw_html_dir_url variable in the default.txt file. The line will look similar
$hw_html_dir_url = "http://www.hamweather.com/weather";
- You will now need the URL to the HAMweather administration script. For Example: If the URL to the HAMweather administration script on your system will be: http://www.hamweather.com/cgi-bin/weather/hwadmin5340/hwadmin.cgi then you will need to know this. You sould change the 'hwadmin5340' portion to a different name for security reasons. You could change it to something similiar to: http://www.hamweather.com/cgi-bin/weather/hwadmin1256/hwadmin.cgi or such.
You will use this information to set the $admin_script_url variable in the default.txt file. The line will look similar
$admin_script_url = "http://www.hamweather.com/cgi-bin/weather/hwadmin1256/hwadmin.cgi";
NOTE: Technically you can leave this setting as " hwadmin.cgi" and it will usually work fine.
Now you will need to gather two pieces of information and add this to the first couple lines of the following cgi scripts:
hamweather.cgi In the main HAMweather cgi path. hwgetstate.cgi In the main HAMweather cgi path. (not in HAMweather Lite) metarlister.cgi In the main HAMweather cgi path hwadmin.cgi In the admin directory of the HAMweather cgi path.
- You will need the path to perl on your on your system. This is usually something like: /usr/bin/perl or /usr/local/bin/perl. You will add this as the first line in the above cgi files. it will look as follows on:
- The full path name to the directory where the HAMweather cgi scripts will be. This is not the URL and does not include "http://." For Example: If the full path to the HAMweather script on your system will be: /usr/www/users/hamnet/hamweather/cgi-bin/weather/hamweather.cgi then you will need to know the /usr/www/users/hamnet/hamweather/cgi-bin/weather portion. (On Microsoft NT and W95/98 platforms you will also need to include the drive letter.)
You will use this information to set the $hw_cgi_dir_path variable near the top of the each of the cgi files (The second or third line from the top). The line will look similar to :
$hw_cgi_dir_path = "/usr/www/users/hamnet/hamweather/cgi-bin/weather";
You may find that you will need to change the http_mode. This is the way that HAMweather connect to the Weather servers. Since a lot of servers do not have the LWP modules installed the default is for HAMweather to use normal sockets. But on some servers this will not work properly. If you find that you cannot connect (you will recieve protocol errors) using the default sockets mode then you will need to have the LWP modules installed and then you will need to set HAMweather to use the LWP http_mode.
To switch to the LWP mode, browse to the web based administration (browse to the
administration URL you just previously entered into the users/default.txt file). Next
click on the "System settings" link and then you can set the http_mode. If
you are having trouble with with the web based admin you can simply open up the hwconfig.txt
file and set the $http_mode variable to 1 thus it would look like: NOTE: This mode
requires that you have the LWP Modules installed.
NOTE: Users of the HYPERMART free webservers should use HAMweather in the LWP mode.
Continue To Installation Step 4
HAMweather copyright © 2000 by HAMweather, LLC, all rights reserved