58 |
* monit [options] {arguments} |
* monit [options] {arguments} |
59 |
* |
* |
60 |
* @author Jan-Henrik Haukeland, <hauk@tildeslash.com> |
* @author Jan-Henrik Haukeland, <hauk@tildeslash.com> |
61 |
|
* @author Christian Hopp, <chopp@iei.tu-clausthal.de> |
62 |
* |
* |
63 |
* @version \$Id$ |
* @version \$Id$ |
64 |
* |
* |
144 |
|
|
145 |
} |
} |
146 |
|
|
147 |
/* Inititlize the ssl engine */ |
/* |
148 |
|
* Inititlize the ssl engine |
149 |
|
*/ |
150 |
if ( have_ssl() ) { |
if ( have_ssl() ) { |
151 |
|
|
152 |
start_ssl(); |
start_ssl(); |
153 |
|
|
154 |
} |
} |
155 |
|
|
156 |
/* Controlfile */ |
/* |
157 |
|
* Get the position of the control file |
158 |
|
*/ |
159 |
if ( ! Run.controlfile ) { |
if ( ! Run.controlfile ) { |
160 |
|
|
161 |
Run.controlfile= find_rcfile(); |
Run.controlfile= find_rcfile(); |
162 |
|
|
163 |
} |
} |
164 |
|
|
165 |
/* Initialize proc interface */ |
/* |
166 |
|
* Initialize process information gathering interface |
167 |
|
*/ |
168 |
Run.doprocess= init_process_info(); |
Run.doprocess= init_process_info(); |
169 |
|
|
170 |
/* |
/* |
176 |
exit(1); |
exit(1); |
177 |
|
|
178 |
} |
} |
179 |
|
|
180 |
/* Initialize the log system */ |
/* |
181 |
|
* Check the permissions of the SSL related files |
182 |
|
*/ |
183 |
|
if ( ! check_ssl_files() ) { |
184 |
|
|
185 |
|
exit(1); |
186 |
|
|
187 |
|
} |
188 |
|
|
189 |
|
/* |
190 |
|
* Initialize the log system |
191 |
|
*/ |
192 |
if ( ! log_init() ) { |
if ( ! log_init() ) { |
193 |
|
|
194 |
exit(1); |
exit(1); |
195 |
|
|
196 |
} |
} |
197 |
|
|
198 |
/* Did we find any process ? */ |
/* |
199 |
|
* Did we find any process ? |
200 |
|
*/ |
201 |
if ( ! processlist ) { |
if ( ! processlist ) { |
202 |
|
|
203 |
error("%s: No programs have been specified\n", prog); |
error("%s: No programs have been specified\n", prog); |
205 |
|
|
206 |
} |
} |
207 |
|
|
208 |
/* Initialize Runtime file variables */ |
/* |
209 |
|
* Initialize Runtime file variables |
210 |
|
*/ |
211 |
init_files(); |
init_files(); |
212 |
|
|
213 |
/* Should we print debug information ? */ |
/* |
214 |
|
* Should we print debug information ? |
215 |
|
*/ |
216 |
if ( Run.debug && have_tty ) { |
if ( Run.debug && have_tty ) { |
217 |
|
|
218 |
printrunlist(); |
printrunlist(); |