VK4PK Maintaining the LyonsComputer Web Site

  1. Prerequisites
  2. Setting up the Platform Environment
  3. The bldidx.sh script
  4. The h3.sh Script
  5. Using "checksum" State to Control Uploads
  6. Editing the sitecopy configuration file
  7. Initialising Sitecopy
  8. The "bldidx.sh" Script
  9. Recovering from "sitecopy" Database Corruptions
  10. Link Checkers
  11. Usefull Linkchecker Commands
  12. References



  1. ARADIO enviorment variable set to the Amateur Radio Folder
  2. $ARADIO/bin on Path
  3. The application linkchecker and sitecopy must be installed
  4. "bldisx.sh" and "h3.sh" scripts in $ARADIO/bin folder
  5. Diskspace and permission to create temporary folder $HOME/www-build
  6. Create and populated $HOME/.sitecopyrc

Setting up the Platform Environment

Add an environment variable, "ARADIO" to .bashrc file in the home directory


The bldidx.sh script

The bldidx.sh script requires linkchecker and sitecopy applications.

Run the bldidx.sh script to make a temporary copy of the html file tree to the ~/www-build folder. Only required html files and their dependant files (images, pdf's, etc) will be copied.


The h3.sh Script

The h3.sh scrips, should be copied to $ARADIO


Using "checksum" State to Control Uploads

Important Note: Because the bldidx script copies all web page files to a temporary build directory if the "timesize" method is used, sitecopy will copy every file to the live website every time. Therefore, the "checksum" method is required if only modified files are to be uploaded.


Editing the sitecopy configuration file

The files state is stored in the files in ~/.sitecopy folder and is used to discover when a file has been changed. Two methods are supported, and can be selected using the state option, with either parameter: "timesize" (the default), and "checksum".

"timesize" uses the last-modification date and the size of files to detect when they have changed.
"checksum" uses an MD5 checksum to detect any changes to the file contents.

Note that MD5 checksumming involves reading in the entire file, and is slower than simply using the last-modification date and size. It may be useful for instance if a versioning system is in use which updates the last-modification date on a 'checkout', but this doesn't actually change the file contents.
Source: "man sitecopy"

*** NOTE the .sitecopy has to be implemented on one workstation for the site state
to be current. ***

Setup sitecopy's configuration file, ~./sitecopyrc


Initialising Sitecopy

Sitecopy must be initialises before use. This will create a status file in the ~/.sitecopy folder with the domain name ofr the website.

Initialise Sitecopy:


The "bldidx.sh" Script


Recovering from "sitecopy" Database Corruptions

If the the uploaded site becomes out of sync with the local database run the commands:

/home/glenn/www-build This can occur when an sitecopy update is interrupted or fails to complete. The fetch option can take some time as it has to recalculate the checksum for every file and folder on the server. The update may have to be run a few times to complete the process.


Link Checkers

W3C - Check links and anchors in Web pages or full Web sites:

LinkChecker - Check websites for broken links:


Usefull Linkchecker Commands



sitecopy - maintain remote copies of web sites:
Man page: https://linux.die.net/man/1/sitecopy

Glenn Lyons VK4PK
Ver:gnl20181201 - pre published v0.9