======= Update Notes -- --Friday, 05 June 2006 =========

2006-06-05 -- update transpgrid host certificate  file
------------------------------------------------------
Show where host certificate file really is
/etc/grid-security/hostcert.pem 
       -> /var/spool/globus/etc/grid-security/hostcert.pem
/var/spool/globus/etc/grid-security/hostcert.pem
       -> /usr/pppl/cppg/hosts/transpgrid.pppl.gov/etc/grid-security/hostcert.pem

Backup present transpcomp hostcert.pem
# As root on transpgrid 
dir=/usr/pppl/cppg/hosts/transpgrid.pppl.gov/etc/grid-security
/bin/cp -i $dir/hostcert.pem{,_saved_01jul2005}

Get date on new transpcomp host certificate
# As root on transpgrid
module load globus
dir=/usr/pppl/cppg/hosts/transpgrid.pppl.gov/etc/grid-security
grid-cert-info -file $dir/hostnewcert.pem -subject -sd -ed
/DC=org/DC=doegrids/OU=Services/CN=transpgrid.pppl.gov
Jul  3 01:04:29 2005 GMT
Jul  3 01:04:29 2006 GMT

Convert date to PPPL time
/bin/date --date="Jul  3 01:04:29 2005 GMT"
Sat Jul  2 21:04:29 EDT 2005

--- If the new host certificate was gotten by a DOEGrids administrator
--- the start date will be earlier than the old stop date and the
--- update can be made by hand and not use the following script.
Write a script to change host certicate file
/bin/vi /u/randerso/HOSTCERT/updatecert
#!/bin/sh
dir=/usr/pppl/cppg/hosts/transpgrid.pppl.gov/etc/grid-security
cd $dir
/bin/cp  hostcert.pem hostcert.pem_$$
/bin/cp -f hostnewcert.pem hostcert.pem
^Z^Z
/bin/chmod a+x /u/randerso/HOSTCERT/updatecert


# Update crontab on transpgrid
As root on transpgrid
/usr/bin/crontab -l
04 21 02 07 * /u/randerso/HOSTCERT/updatecert