ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/XCMSI/modules/GridInstall_help.pm
Revision: 1.2
Committed: Fri Dec 10 15:14:10 2004 UTC (20 years, 4 months ago) by nowack
Content type: text/plain
Branch: MAIN
CVS Tags: XCMSI_0_9_pre4, XCMSI_0_9_PRE3, XCMSI_0_9_PRE2
Changes since 1.1: +1 -0 lines
Log Message:
inserted $Id:$-Tags in order to be able to use "ident"

File Contents

# User Rev Content
1 corvo 1.1 #!/usr/bin/perl
2 nowack 1.2 # $Id: $
3 corvo 1.1 package GridInstall_help;
4    
5     use Cwd;
6     use site_utils qw(&execSys);
7     our (@ISA, @EXPORT, @EXPORT_OK);
8     use Exporter;
9     @ISA = qw(Exporter);
10     @EXPORT_OK = qw(&help);
11    
12     sub help {
13    
14     my $option = shift or 'man';
15     $helpStr = "
16    
17     =pod
18    
19     =head1 NAME
20    
21     B<" . $::exec . " > - (version 0.0.1).
22    
23     =head1 SYNOPSIS
24    
25     B<$::exec> [I<options>]
26    
27     =head1 DESCRIPTION
28    
29     I<". $::exec ."> is a Perl program intended to simplify the process
30     of creation and submission of CMS software installation jobs.
31     The program is able to generate scripts for different CMS
32     software types (tar, DAR, RPM) and submit them to the a given site.
33    
34     This script is based on queries on LCG BDIIs, that is on LCG Information system. It asks a given site, or site set,
35     for the published software tags (e.g. VO-cms-ORCA_8_6_0) and, according to the answer, performs the
36     best action, either full \"from scratch\" installation, or a simple upgrade.
37    
38     Then it updates the site Information System with the latest installed software tag.
39    
40     Multiple software installations are supported. The core installation script is I<cmsi>.
41    
42     B<". $::exec . "> relies on a set of different perl fragments, which can be combined to perform the right installation
43     according to the chosen software flavour.
44    
45     Once perl scripts and jdl files have been assembled, jobs are submitted to the target Computing Elements. Once landed on Worker Nodes
46     the scripts check the environment, basically an anvironment variable called \$VO_CMS_SW_DIR where CMS software is supposed
47     to be installed. Then I<cmsi> starts installing rpms.
48    
49     Finally the Information System is updated with the publishing of the new software tags.
50    
51     =head1 OPTIONS
52    
53     =over 4
54    
55     =item B<-i, --install> I< software name >
56    
57     Declares the software you want to install. It's possible to declare multiple software
58     (e.g. --install \"ORCA_8_6_0 OSCAR_3_6_1\")
59    
60     =item B<-u, --uninstall> I< software name >
61    
62     Declares the software you want to uninstall.
63    
64     =item B<-t, --type> I< software type >
65    
66     Declares the kind of distribution you're going to install. Possible value are tar, dar and rpm.
67    
68     =item B<-s, --site > I<site>
69    
70     Declares where you would like to install the given software. It can be a full URL or a domain name, e.g.
71     gridit001.pd.infn.it or infn.it.
72    
73     =item B<-l, --label> I< software tag >
74    
75     Defines the software tag you're going to publish on a site Information System. Conventionally CMS adopted:
76     VO-cms-I< software name >
77    
78     =item B<-b, --bdii> I<bdii>
79    
80     Defines the BDII to retrieve sites' software tag. LCG has no hierarchical Information System, so one has to define
81     \'a priori\' the BDII containing the choosen site to install. CMS has a official BDII, that is lxn1187.cern.ch. There's also
82     a \'test zone\' BDII, lxn1189.cern.ch, containing sites which are not yet LCG certified.
83    
84     =item B<-o, --org> I< virtual organization>
85    
86     Your Virtual Organization. Default is \'cms\'. The script selects for installation only those sites belonging to the given VO.
87     The user must have a valid grid certificate to be recognized by the information system.
88    
89     =back
90    
91    
92     =head1 EXAMPLES
93    
94     $::exec --install ORCA_8_6_0 -t rpm --site pd.infn.it --label VO-cms-ORCA_8_6_0\n
95    
96     installs Orca, version 860 and rpm flavour, in Padova.
97    
98     $::exec --install ORCA_8_6_0 -t rpm --site fzk.de --label VO-cms-ORCA_8_6_0 --bdii lxn1189.cern.ch\n
99    
100     installs Orca, version 860 and rpm flavour, in FZK querying the \"test BDII\" at Cern.
101    
102     $::exec --install CMKIN_3_2_0 -t tar --site pd.infn.it --label VO-cms-CMKIN_3_2_0_dar\n
103    
104     installs CMKIN, version 320 and tar flavour, in Padova.
105    
106     $::exec --uninstall ORCA_8_2_0 -t rpm --site pd.infn.it --label VO-cms-ORCA_8_2_0\n
107    
108     uninstalls Orca from Padova and removes the software tag from the Information System.
109    
110     =head1 ENVIRONMENT
111    
112     If user wants to submit jobs in GRID, which is default, it is necessary
113     to create a proxy certificate
114    
115     grid-proxy-init
116    
117     =cut";
118    
119     my $pod = getcwd() . '/CmsSwGridInstall.pod';
120     open($fh, ">$pod");
121     print ($fh $helpStr);
122     close $fh;
123     my $man = getcwd() . '/CmsSwGridInstall.man';
124     my $pod2man = 'pod2man --center=" " --release=" " ' . $pod . ' > ' . $man;
125     &execSys($pod2man);
126     my $cmd = 'man '. $man;
127     system($cmd);
128     exit;
129     }