-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathrunOfflineConverter
executable file
·80 lines (71 loc) · 1.92 KB
/
runOfflineConverter
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
#! /usr/bin/env perl
################################################################################
#
# runOfflineConverter
# ------------------
#
# 07/24/2008 Philipp Schieferdecker <[email protected]>
################################################################################
my $db_host = "";
my $db_name = "";
my $db_user = "";
my $db_pwrd = "";
my $args = "";
if (@ARGV==0) {
print "provide one of: --hltdev, --orcoff, --rcms, --int2r, --int9r, or --test2r!\n";
exit(0);
}
while (@ARGV)
{
my $arg = shift @ARGV;
if ($arg eq "--hltdev") {
$db_host = "cmsr1-s.cern.ch";
$db_name = "cms_cond.cern.ch";
$db_user = "cms_hltdev_reader";
$db_pwrd = "convertme!";
}
elsif ($arg eq "--orcoff") {
$db_host = "cmsr1-s.cern.ch";
$db_name = "cms_cond.cern.ch";
$db_user = "cms_hlt_gui_r";
$db_pwrd = "convertme!";
}
elsif ($arg eq "--rcms") {
$db_host = "cmsonr1-v.cms";
$db_name = "cms_rcms.cern.ch";
$db_user = "cms_hlt_r";
$db_pwrd = "convertme!";
}
elsif ($arg eq "--rcms_tunnel") {
$db_host = "localhost";
$db_name = "cms_omds_tunnel.cern.ch";
$db_user = "cms_hlt_r";
$db_pwrd = "convertme!";
}
elsif ($arg eq "--int2r") {
$db_host = "int2r1-v.cern.ch";
$db_name = "int2r_nolb.cern.ch";
$db_user = "cms_hlt_reader";
$db_pwrd = "convertme!";
}
elsif ($arg eq "--int9r") {
$db_host = "int9r1-v.cern.ch";
$db_name = "int9r_nolb.cern.ch";
$db_user = "cms_hlt_reader";
$db_pwrd = "convertme!";
}
elsif ($arg eq "--test2r") {
$db_host = "int2r1-s.cern.ch";
$db_name = "int2r_nolb.cern.ch";
$db_user = "cms_hltdev";
$db_pwrd = "Magnum2Classic";
}
else { $args = $args . " " . $arg; }
}
my $cmd =
"java " .
"-cp ../ext/ojdbc8.jar:../lib/cmssw-evf-confdb-converter.jar " .
"confdb.converter.OfflineConverter " .
"-t oracle -h $db_host -d $db_name -u $db_user -s $db_pwrd $args";
print STDERR $cmd . "\n";
system($cmd);