1Perlbal::Manual::InstalUls(e3r)Contributed Perl DocumentPaetrilobnal::Manual::Install(3)
2
3
4

NAME

6       Perlbal::Manual::Install - Steps, dependencies and requirements to
7       install Perlbal
8
9   VERSION
10       Perlbal 1.78.
11
12   DESCRIPTION
13       How to install Perlbal.
14
15   Installing Perlbal for the impatient
16           $ perl -MCPAN -e shell
17
18           cpan> install Perlbal
19
20       App::cpanminus is also good at quickly installing Perlbal and all of
21       its dependencies
22
23           $ cpanm Perlbal IO::AIO Perlbal::XS::HTTPHeaders
24
25       ... will give you an ideal Perlbal environment.
26
27   Installing Perlbal (with a little more detail)
28       You need to have perl on the machine. If you don't have it yet, you can
29       grab it from http://www.perl.org/.
30
31       Having perl on the machine should give you access to the CPAN shell,
32       one of several possible ways to install and upgrade Perl modules.
33
34       Start your CPAN shell:
35
36           $ perl -MCPAN -e shell
37
38       And now tell it to install Perlbal:
39
40           cpan> install Perlbal
41
42       In the end you should see a message stating "make install  -- OK" (if
43       that's not the case, please refer to section Troubleshooting later in
44       this document).
45
46   Installing Perlbal by hand (without using the CPAN shell)
47       Head to <http://search.cpan.org/dist/Perlbal/> and find the download
48       link. Download the file and untar it:
49
50           $ tar zxvf Perlbal-X.XX.tar.gz
51
52       Note that X.XX stands for the version number. Replace that with the
53       latest version you got.
54
55       Now you need to create the Makefile and run it; we're also going to run
56       the tests before installing Perlbal:
57
58           $ cd Perlbal-X.XX.tar.gz
59
60           $ perl Makefile.PL
61
62           $ make
63
64           $ make test
65
66           $ sudo make install
67
68   Installing the latest development version
69       You can clone Perlbal's repository from github and install it by hand
70       by following the next steps:
71
72           $ git clone http://github.com/perlbal/Perlbal.git
73
74           $ cd Perlbal
75
76           $ perl Makefile.PL
77
78           $ make
79
80           $ make test
81
82           $ sudo make install
83
84   Optional Dependencies and Asynchronous IO
85       It is very highly recommended that Perlbal::XS::HTTPHeaders is
86       installed and enabled. If you have poor performance, the first thing to
87       do is install Perlbal::XS::HTTPHeaders.
88
89           $ perl -MCPAN -e shell
90
91           cpan> install Perlbal::XS::HTTPHeaders
92
93       Enable it in your configuration:
94
95           XS enable headers
96
97       Perlbal checks for IO::AIO availability and uses it to perform
98       asynchronous IO operations. If you're performing disk operations (e.g.,
99       using Perlbal as a web server), having IO::AIO will improve your
100       response times.
101
102       The only thing required in order to benefit from this feature is to
103       install IO::AIO:
104
105           $ perl -MCPAN -e shell
106
107           cpan> install IO::AIO
108
109       If you don't have IO::AIO installed a warning message will be displayed
110       when you start perlbal:
111
112           WARNING:  AIO mode disabled or not available.
113                     Perlbal will run slowly under load if you're doing any
114                     disk operations. (e.g. web_server mode).
115                     Install IO::AIO for better performance.
116
117   Checking that Perlbal is succesfully installed
118       Perlbal is shipped with some sample configuration files that reside in
119       the conf directory (of the source).
120
121       You can give Perlbal a try by heading to the directory where the source
122       is and using the following command:
123
124           $ sudo perlbal -c conf/webserver.conf
125
126       By pointing your browser at "localhost:80" you should now see Perlbal
127       responding (showing you the contents of "/usr/share/doc").
128
129       Note that the webserver.conf file sets up a Perlbal web server that
130       listens on port 80. If you already have something listening on port 80
131       you need to either stop that service or change the port number on
132       webserver.conf.
133
134       Also note that if your machine doesn't have a "/usr/share/docs"
135       directory you'll see an "ERROR: Directory not found for service docs"
136       error message. Change the directory in the configuration file to
137       something that exists.
138
139   Troubleshooting
140       Prerequisites not found
141
142       If you're installing Perlbal by hand you may encounter some error
143       messages describing how some prerequisites are not available:
144
145           user@machine:~/Perlbal-X.XX$ perl Makefile.PL
146           Checking if your kit is complete...
147           Looks good
148           Warning: prerequisite BSD::Resource 0 not found.
149           Warning: prerequisite Danga::Socket 1.44 not found.
150           Warning: prerequisite HTTP::Date 0 not found.
151           Warning: prerequisite HTTP::Response 0 not found.
152           Warning: prerequisite Sys::Syscall 0 not found.
153           Writing Makefile for Perlbal
154
155       This is perl's way of telling you that since you're installing Perlbal
156       by hand you'll also need to install its prerequisites by hand. Your
157       first choice is to download each of them separately and perform the
158       same installation procedure for each. Unfortunately, they are all
159       likely to have additional prerequisites. Recursively.
160
161       Alternately, see the following Troubleshooting item: "No connection to
162       the internet".
163
164       No connection to the internet
165
166       If you don't have a connection to the internet you can still install
167       Perlbal, but you'll have to tranfer the source somehow to the machine.
168
169       Given that Perlbal has other module dependencies from CPAN (and those
170       have their own dependencies too), here's a solution for this problem:
171
172       Step 1: On a machine with connection to the internet, install
173       CPAN::Mini:
174
175           $ perl -MCPAN -e shell
176
177           cpan> install CPAN::Mini
178
179       Run "minicpan" to create a minimal CPAN mirror (it contains only the
180       latest version of each module):
181
182           $ minicpan -l /home/user/minicpan/ -r http://cpan.org/
183
184       Now grab that directory and record it to something you can read on the
185       other machine (e.g., a DVD, a hard drive).
186
187       Once you're on that machine, you can run the CPAN shell and tell it to
188       look for distributions on the local directory where you now have your
189       own CPAN mirror:
190
191           $ perl -MCPAN -e shell
192
193           cpan> o conf urllist push file:///home/user/path/to/minicpan
194
195           cpan> install Perlbal
196
197       If you want "cpan" to record this change don't forget to commit:
198
199           cpan> o conf commit
200
201       No compiler available
202
203       If there's no compiler available on the machine you will probably see
204       an error ending in something like:
205
206           Failed during this command:
207            DORMANDO/Perlbal-X.XX.tar.gz : writemakefile NO '/usr/bin/perl Makefile.PL INSTALLDIRS=site' returned status -1
208
209       You need to install something like "gcc" (check <http://gcc.gnu.org/>).
210
211       After installing "gcc", when trying to install Perlbal again you may
212       get another error message:
213
214           cpan> install Perlbal
215           Running install for module 'Perlbal'
216           Running make for D/DO/DORMANDO/Perlbal-X.XX.tar.gz
217             Has already been unwrapped into directory /home/myself/.cpan/build/Perlbal-X.XX-GFko0J
218             '/usr/bin/perl Makefile.PL INSTALLDIRS=site' returned status -1, won't make
219           Running make test
220             Make had some problems, won't test
221           Running make install
222             Make had some problems, won't install
223
224       This is the cpan shell assuming nothing changed in the system and
225       skipping a few steps. You need to let it know you're willing to forget
226       the past:
227
228           cpan> look Perlbal
229
230           $ rm -rf *
231
232           $ exit
233
234       And now you can try installation again:
235
236           cpan> install Perlbal
237
238   SEE ALSO
239       Perlbal::Manual.
240
241
242
243perl v5.34.0                      2021-07-21       Perlbal::Manual::Install(3)
Impressum