1 |
3956
|
tao
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
2 |
|
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
3 |
|
|
|
4 |
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
5 |
|
|
<head>
|
6 |
|
|
<meta http-equiv="Content-Type" content=
|
7 |
|
|
"text/html; charset=us-ascii" />
|
8 |
|
|
<meta name="generator" content="pandoc" />
|
9 |
|
|
<style type="text/css">
|
10 |
|
|
/*<![CDATA[*/
|
11 |
|
|
ol.decimal { list-style-type: decimal; }
|
12 |
4607
|
walbridge
|
li { padding-bottom: 5px; }
|
13 |
|
|
blockquote {
|
14 |
|
|
background-color: #f5f5f5;
|
15 |
|
|
margin: 10px 15px 5px 20px;
|
16 |
|
|
padding: 1px 0px 1px 10px;
|
17 |
|
|
}
|
18 |
|
|
|
19 |
|
|
.keyword {
|
20 |
|
|
color: #00008b;
|
21 |
|
|
}
|
22 |
|
|
|
23 |
|
|
.type {
|
24 |
|
|
color: #2b91af;
|
25 |
|
|
}
|
26 |
|
|
|
27 |
|
|
.string {
|
28 |
|
|
color: #810541;
|
29 |
|
|
}
|
30 |
|
|
|
31 |
3956
|
tao
|
/*]]>*/
|
32 |
|
|
</style>
|
33 |
|
|
|
34 |
|
|
<title>Metacat Install - Registry</title>
|
35 |
|
|
<link rel="stylesheet" type="text/css" href="default.css" />
|
36 |
|
|
</head>
|
37 |
|
|
|
38 |
|
|
<body>
|
39 |
|
|
<table class="tabledefault" width="100%">
|
40 |
|
|
<tr>
|
41 |
|
|
<td rowspan="2"><img src="images/KNBLogo.gif" /></td>
|
42 |
|
|
|
43 |
|
|
<td colspan="7">
|
44 |
|
|
<div class="title">
|
45 |
|
|
Metacat Installation - Registry
|
46 |
|
|
</div>
|
47 |
|
|
</td>
|
48 |
|
|
</tr>
|
49 |
|
|
|
50 |
|
|
<tr>
|
51 |
|
|
<td><a href="/" class="toollink">KNB Home</a></td>
|
52 |
|
|
|
53 |
|
|
<td><a href="/data.html" class="toollink">Data</a></td>
|
54 |
|
|
|
55 |
|
|
<td><a href="/people.html" class="toollink">People</a></td>
|
56 |
|
|
|
57 |
|
|
<td><a href="/informatics" class=
|
58 |
|
|
"toollink">Informatics</a></td>
|
59 |
|
|
|
60 |
|
|
<td><a href="/biodiversity" class=
|
61 |
|
|
"toollink">Biocomplexity</a></td>
|
62 |
|
|
|
63 |
|
|
<td><a href="/education" class="toollink">Education</a></td>
|
64 |
|
|
|
65 |
|
|
<td><a href="/software" class="toollink">Software</a></td>
|
66 |
|
|
</tr>
|
67 |
|
|
</table>
|
68 |
|
|
<hr />
|
69 |
|
|
|
70 |
|
|
<table class="tabledefault" width="100%">
|
71 |
|
|
<tr>
|
72 |
|
|
<td class="tablehead" colspan="2">
|
73 |
|
|
<p class="emphasis">Installing the Metacat Registry</p>
|
74 |
|
|
</td>
|
75 |
|
|
</tr>
|
76 |
|
|
|
77 |
|
|
<tr>
|
78 |
|
|
<td>Author: Shaun Walbridge<br />
|
79 |
|
|
Date: 06/06/2008<br /></td>
|
80 |
|
|
</tr>
|
81 |
|
|
</table>
|
82 |
|
|
|
83 |
|
|
<h1 id="registry-installation">Registry Installation</h1>
|
84 |
|
|
|
85 |
|
|
<h2 id="whats-it-for">What's it for?</h2>
|
86 |
|
|
|
87 |
|
|
<p>The Metacat Registry provides an easy mechanism to create and
|
88 |
|
|
edit simple EML metadata documents, and accounts for your Metacat
|
89 |
|
|
users. It is an optional component of Metacat, but is useful when
|
90 |
|
|
you need very low barriers to creating simple EML, or have users
|
91 |
|
|
unable to use Morpho. The LDAP account management interface is
|
92 |
|
|
useful if you are authenticating users against LDAP, and need to
|
93 |
|
|
provide a basic mechanism for managing user accounts.</p>
|
94 |
|
|
|
95 |
|
|
<h2 id="installation-instructions">Installation Instructions</h2>
|
96 |
|
|
|
97 |
|
|
<p>The Registry can be installed on any machine Metacat runs on,
|
98 |
|
|
but does require additional legwork to get it installed. It
|
99 |
|
|
requires that Metacat is set deployed behind Apache, as our
|
100 |
|
|
recommended installation platform, and the instructions assume
|
101 |
|
|
Apache is already installed and working correctly.</p>
|
102 |
|
|
|
103 |
|
|
<h2 id="steps">Steps</h2>
|
104 |
|
|
|
105 |
|
|
<ol class="decimal">
|
106 |
|
|
<li>
|
107 |
|
|
<p>Download and extract the Metacat release:</p>
|
108 |
4607
|
walbridge
|
<blockquote>
|
109 |
|
|
<pre><span class="type">mkdir</span> metacat && cd metacat
|
110 |
|
|
<span class="type">wget</span> http://knb.ecoinformatics.org/software/dist/metacat-src-1.8.0.zip
|
111 |
|
|
<span class="type">unzip</span> metacat-src-1.8.0.zip
|
112 |
|
|
<span class="type">cd</span> metacat-1.8.0
|
113 |
|
|
<span class="type">export</span> METACAT=`pwd`
|
114 |
3956
|
tao
|
</pre>
|
115 |
4607
|
walbridge
|
</blockquote>
|
116 |
3956
|
tao
|
</li>
|
117 |
|
|
|
118 |
|
|
<li>
|
119 |
|
|
<p>Build the Metacat Perl client library:</p>
|
120 |
4607
|
walbridge
|
<blockquote>
|
121 |
|
|
<pre><span class="type">cd</span> $METACAT/src/perl/Metacat
|
122 |
|
|
<span class="type">perl</span> Makefile.PL
|
123 |
|
|
<span class="type">sudo make</span>
|
124 |
|
|
<span class="type">sudo make install</span>
|
125 |
3956
|
tao
|
</pre>
|
126 |
4607
|
walbridge
|
</blockquote>
|
127 |
3956
|
tao
|
</li>
|
128 |
|
|
|
129 |
|
|
<li>
|
130 |
4607
|
walbridge
|
<p>Install the system libraries needed. On Redhat:
|
131 |
|
|
<blockquote>
|
132 |
|
|
<pre><span class="type">sudo yum install</span> gcc libxml2-devel libxslt-devel ant -y
|
133 |
3956
|
tao
|
</pre>
|
134 |
4607
|
walbridge
|
</blockquote>
|
135 |
3956
|
tao
|
|
136 |
4607
|
walbridge
|
On Debian:
|
137 |
|
|
<blockquote>
|
138 |
|
|
<pre>
|
139 |
|
|
<span class="type">sudo apt-get install</span> ant libappconfig-perl libxml-libxml-perl libxml-libxslt-perl \
|
140 |
|
|
libtemplate-perl libcgi-session-perl libdigest-sha1-perl libnet-ldap-perl \
|
141 |
|
|
libterm-readkey-perl libxml-dom-perl libsoap-lite-perl -y
|
142 |
|
|
</pre>
|
143 |
|
|
</blockquote>
|
144 |
4366
|
daigle
|
You will need to install one package using cpan
|
145 |
4607
|
walbridge
|
<blockquote><pre><span class="type">sudo cpan</span> -i Config::Properties</pre></blockquote>
|
146 |
4366
|
daigle
|
|
147 |
4615
|
walbridge
|
Debian users should skip ahead to step 6.
|
148 |
4009
|
walbridge
|
</p>
|
149 |
3956
|
tao
|
</li>
|
150 |
|
|
|
151 |
|
|
<li>
|
152 |
|
|
<p>Install CPAN, which allows us to install the Perl
|
153 |
|
|
dependencies for the registry and account management parts of
|
154 |
|
|
Metacat. If asked to manually configure cpan, type 'no' and
|
155 |
|
|
CPAN will be setup with its default values.</p>
|
156 |
4607
|
walbridge
|
<blockquote>
|
157 |
|
|
<pre><span class="type">sudo yum install</span> perl-CPAN
|
158 |
|
|
<span class="type">sudo cpan</span>
|
159 |
3956
|
tao
|
</pre>
|
160 |
4607
|
walbridge
|
</blockquote>
|
161 |
3956
|
tao
|
|
162 |
|
|
<p>You should now see a prompt which looks like:</p>
|
163 |
4607
|
walbridge
|
<blockquote>
|
164 |
|
|
<pre><span class="string">cpan></span>
|
165 |
3956
|
tao
|
</pre>
|
166 |
4607
|
walbridge
|
</blockquote>
|
167 |
3956
|
tao
|
|
168 |
|
|
<p>The rest of the commands will assume you're inside of
|
169 |
|
|
CPAN. Let's get the most recent version of the CPAN software.
|
170 |
|
|
Just press return after any prompts you recieve during this
|
171 |
|
|
process.</p>
|
172 |
4607
|
walbridge
|
<blockquote>
|
173 |
|
|
<pre>install Bundle::CPAN
|
174 |
|
|
reload cpan
|
175 |
3956
|
tao
|
</pre>
|
176 |
4607
|
walbridge
|
</blockquote>
|
177 |
3956
|
tao
|
</li>
|
178 |
|
|
|
179 |
|
|
<li>
|
180 |
|
|
<p>Install the required modules. Here we're installing an old
|
181 |
|
|
LibXSLT, as the current one requires a newer libxslt than is
|
182 |
|
|
available on Redhat 4 & 5. Again, just answer 'yes' to
|
183 |
|
|
any questions.</p>
|
184 |
4607
|
walbridge
|
<blockquote>
|
185 |
|
|
<pre>install AutoLoader
|
186 |
3956
|
tao
|
install CGI
|
187 |
|
|
install CGI::SEssion
|
188 |
4009
|
walbridge
|
install LWP::UserAgent
|
189 |
3956
|
tao
|
install Net::LDAP
|
190 |
|
|
install Template
|
191 |
|
|
install URI
|
192 |
|
|
install MSERGEANT/XML-LibXSLT-1.58.tar.gz
|
193 |
|
|
</pre>
|
194 |
4607
|
walbridge
|
</blockquote>
|
195 |
3956
|
tao
|
</li>
|
196 |
|
|
|
197 |
4615
|
walbridge
|
<li>
|
198 |
|
|
<p>Double check that Metacat's temporary folder, <code><span class="string">application.tempDir</span></code>, is writable by the apache user, usually <code><span class="string">www-data</span></code> or <code><span class="string">apache</span></code>.
|
199 |
3956
|
tao
|
<li>
|
200 |
|
|
<p>Now visit the resulting URL:</p>
|
201 |
4607
|
walbridge
|
<blockquote>
|
202 |
4610
|
walbridge
|
<pre>http://localhost/knb/cgi-bin/register-dataset.cgi?cfg=nceas
|
203 |
3956
|
tao
|
</pre>
|
204 |
4607
|
walbridge
|
</blockquote>
|
205 |
3956
|
tao
|
|
206 |
|
|
<p>If everything worked correctly, you should see a page like
|
207 |
|
|
this: <img src="images/registry-login.jpg" alt=
|
208 |
|
|
"Registry Login Page" /></p>
|
209 |
|
|
</li>
|
210 |
|
|
</ol>
|
211 |
|
|
|
212 |
|
|
<h2 id="installing-the-nceas-registry">Installing the NCEAS
|
213 |
|
|
Registry</h2>
|
214 |
|
|
|
215 |
|
|
<p>These are special instructions required for the NCEAS skin to
|
216 |
|
|
get a current projects list from the AdminDB, and can safely be
|
217 |
|
|
ignored in all other uses.</p>
|
218 |
|
|
|
219 |
|
|
<ol class="decimal">
|
220 |
|
|
<li>
|
221 |
|
|
<p>Download and install the Oracle Instant Client RPMs. These
|
222 |
|
|
can be obtained from the <a href=
|
223 |
|
|
"http://www.oracle.com/technology/software/tech/oci/instantclient/htdocs/linuxsoft.html">
|
224 |
|
|
oracle website</a>.</p>
|
225 |
4607
|
walbridge
|
<blockquote>
|
226 |
4610
|
walbridge
|
<pre><span class="type">rpm -i</span> oracle-instantclient-basic-10.2.0.3-1.i386.rpm
|
227 |
|
|
<span class="type">rpm -i</span> oracle-instantclient-devel-10.2.0.3-1.i386.rpm
|
228 |
|
|
<span class="type">rpm -i</span> oracle-instantclient-sqlplus-10.2.0.3-1.i386.rpm
|
229 |
3956
|
tao
|
</pre>
|
230 |
4607
|
walbridge
|
</blockquote>
|
231 |
3956
|
tao
|
</li>
|
232 |
|
|
|
233 |
|
|
<li>
|
234 |
4607
|
walbridge
|
<p>Next, we'll need an <pre>tnsnames.ora</pre> file for
|
235 |
3956
|
tao
|
Oracle to locate the server we're connecting to. In this
|
236 |
|
|
example, we'll copy it from a remote location:</p>
|
237 |
4607
|
walbridge
|
<blockquote>
|
238 |
4610
|
walbridge
|
<pre><span class="type">mkdir -p</span> /usr/lib/oracle/10.2.0.3/network/admin/ && <span class="type">cd !$</span>
|
239 |
|
|
<span class="type">scp</span> walbridge@knb.ecoinformatics.org:/usr/lib/oracle/10.1.0.4/network/admin/tnsnames.ora .
|
240 |
3956
|
tao
|
</pre>
|
241 |
4607
|
walbridge
|
</blockquote>
|
242 |
3956
|
tao
|
</li>
|
243 |
|
|
|
244 |
|
|
<li>
|
245 |
|
|
<p>The AdminDB is accessed via Perl, so install the needed
|
246 |
|
|
Oracle driver using CPAN:</p>
|
247 |
4607
|
walbridge
|
<blockquote>
|
248 |
|
|
<pre>cpan
|
249 |
3956
|
tao
|
install DBI
|
250 |
|
|
install DBD::Oracle
|
251 |
|
|
</pre>
|
252 |
4607
|
walbridge
|
</blockquote>
|
253 |
3956
|
tao
|
</li>
|
254 |
|
|
|
255 |
|
|
<li>
|
256 |
|
|
<p>Now we can install the AdminDB module itself:</p>
|
257 |
4607
|
walbridge
|
<blockquote>
|
258 |
|
|
<pre>mkdir -p ~/projects/admindb && cd !$
|
259 |
3956
|
tao
|
export CVSROOT=:ext:walbridge@cvs.nceas.ucsb.edu:/cvsnceas
|
260 |
|
|
cvs co admindb
|
261 |
|
|
cd admindb/perl/NCEAS/AdminDB
|
262 |
|
|
perl Makefile.PL
|
263 |
|
|
make
|
264 |
|
|
sudo make install
|
265 |
|
|
</pre>
|
266 |
4607
|
walbridge
|
</blockquote>
|
267 |
3956
|
tao
|
</li>
|
268 |
|
|
|
269 |
|
|
<li>
|
270 |
|
|
<p>Finally, set the correct properties in the
|
271 |
4607
|
walbridge
|
<pre>nceas.cfg</pre> file:</p>
|
272 |
|
|
<blockquote>
|
273 |
|
|
<pre>nceas_db = //hyperion.nceas.ucsb.edu:1521/nceasp.nceas.ucsb.edu
|
274 |
3956
|
tao
|
nceas_db_user = admowner
|
275 |
|
|
nceas_db_password = NCEAS_DB_READ_PASSWORD_HERE
|
276 |
|
|
</pre>
|
277 |
4607
|
walbridge
|
</blockquote>
|
278 |
3956
|
tao
|
</li>
|
279 |
|
|
|
280 |
|
|
<li>
|
281 |
4607
|
walbridge
|
<p>A quick check of <pre>register-dataset.cgi</pre> should
|
282 |
3956
|
tao
|
now show a complete list of projects: <img src=
|
283 |
|
|
"images/registry-nceas-projects.png" alt=
|
284 |
|
|
"NCEAS Project list" /></p>
|
285 |
|
|
</li>
|
286 |
|
|
</ol>
|
287 |
|
|
|
288 |
|
|
<h2 id="notes">Notes</h2>
|
289 |
|
|
|
290 |
|
|
<p>Redhat based, tested on Centos 5</p>
|
291 |
|
|
|
292 |
|
|
<p>Debian based, tested on Ubuntu 8.04</p>
|
293 |
|
|
</body>
|
294 |
|
|
</html>
|