ShareGrid Peer is the component that locates available resources needed by MyGrid, the user front-end, to run a distributed application. This means that only resources made known to the Peer will ever be used.
Requirements
- user account – you must have an account on the machine on which you want to install the Peer
- disk space – you will need 4MBs for the installation plus additional space for log files
- operating system – Linux. We have verified that the Peer runs on Mandrake, RedHat Fedora, Debian, and Conectiva distributions.
the Peer will not work on Microsoft Windows. - Java – version 1.5 or later
- tools – decompression tools (i.e. tar/gzip/gunzip)
Before to start
- Check the Java version installed on Peer machine doing: java -version
- If Peer machine is behind a firewall be sure that it is possible to estabilsh and to accept connections to/from corepeer machine ramses.di.unipmn.it (193.206.55.107). Please be aware that your machine might be running a personal firewall (e.g. iptables ). The corepeer machine is responsable to provide a directory service for all Peers in the ShareGrid community.
- If the hostname of the Peer machine is not resolved by public DNS, you have to send us the hostname and IP address of your machine.
Installation
- Download ShareGridPeer.tgz 1.84 Mb
- cd peerSG/
- Edit the peer.properties file and update the peer.name, peer.port and peer.label properties to reflect your local configuration.
- The default values for all other properties should be OK.
Test your installation
After peer.properties customization, you can start the Peer by typing:
- ./bin/peer start
if successful, you will see the following message:
Starting OurGrid Peer 3.3…
OurGrid Peer 3.3 is Up and Running!
Adding machines to the Peer
The easiest way to add machines to the Peer consists to modify the file mysite.sdf located in Peer direcotry. Edit the mysite.sdf and update site, port, and name for each machine fo each User Agent.
Once you are satisfied with your SDF, use the following command to load it into the Peer:
- ./bin/peer setgums mysite.sdf
and check the peer’s status
- ./bin/peer status
if successful, you will see the following informations:
- the gums that are local to the Peer;
- a list of gums received by the Peer from other OurGrid Peers;
- information about the network of favors accounting.
Installation for the execution at machine boot time (optional)
This section let you configure your system in order to run the peerSG at machine boot time.
- Download and unzip the archive for the companion script rc.peerSG: rc.peerSG.zip [4.64 KB]
- Inside the rc.userAgentSG script, change the name of the user used for running the peerSG program.
[Default: user=sharegrid]
If the default value is not for you, you need to change the $user variable inside the rc.peerSG script. - Inside the rc.peerSG script, change the path to the peerSG program.
[Default: peer="/home/$user/shareGrid/peerSG/bin/peer"]
If the default value is not for you, you need to change the $peer variable inside the rc.peerSG script. - Inside the rc.peerSG script, change the path to the Site Description (SDF) file.
[Default: sdf="/home/$user/shareGrid/peerSG/mysite.sdf"]
If the default value is not for you, you need to change the $sdf variable inside the rc.peerSG script. - Gain root privileges.
Log-in as root user or, alternatively, use the sudo command. - Add the script in the ‘start-up script’ directory of your operating system.
This location is operating-system dependent. In many Linux operating systems it is typically named ‘/etc/init.d’. If this is your case, simply run:cp rc.peerSG /etc/init.d/.
Otherwise, refer to your operating system administration guide.
- Change the script attributes.
In order to execute the script, you need to add the execution attribute:chmod u+x /etc/init.d/rc.peerSG
- Tell your operating system to run the script at boot time.
If you run a RedHat-like operating system, you can simply run the following command:chkconfig –add rc.peerSG
If not, please consult your operating system administration guide.
- Test your installation by running (with ‘root’ privileges):
/etc/init.d/rc.peerSG start
If the output shows the message OK, the installation is done. Otherwise, try to repeat the installation steps (maybe using the detailed instructions contained inside the rc.peerSG.README file).
That’s all folks!
Your Peer is successfully installed and configured. After approximately 10 minutes, you should be able to see it on the ShareGrid status page here . More details about the Peer role can be found here