[MXS-373] If config file is non-existent, maxscale crashes. Created: 2015-09-17  Updated: 2015-09-22  Resolved: 2015-09-22

Status: Closed
Project: MariaDB MaxScale
Component/s: Core
Affects Version/s: 1.2.1, 1.3.0
Fix Version/s: 1.3.0

Type: Bug Priority: Major
Reporter: Johan Wikman Assignee: markus makela
Resolution: Fixed Votes: 0
Labels: None


 Description   

If maxscale is started with a non-existent configuration file and if the /var/log/maxscale directory is missing, it exits in an ugly fashion.

wikman@jwi-mariadb:maxscale $ bin/maxscale -d 
Info : MaxScale will be run in the terminal process.
*
* Warning : Failed to read the configuration file /etc/maxscale.cnf. No such file or directory.
*
* Opening file /var/log/maxscale/error1.log failed due 2, No such file or directory.
Error : opening logfile /var/log/maxscale/error1.log failed.
Error : opening log file /var/log/maxscale/error1.log failed. Exiting MaxScale
*
* Error : Initializing log manager failed.
*
...
skygw_log_write_flush failed.
* Opening file /var/log/maxscale/error1.log failed due 2, No such file or directory.
Error : opening logfile /var/log/maxscale/error1.log failed.
Error : opening log file /var/log/maxscale/error1.log failed. Exiting MaxScale
*
* Error : Initializing log manager failed.
*
skygw_log_write failed.
Segmentation fault (core dumped)
wikman@jwi-mariadb:maxscale $ 

Whatever prerequisites are missing - configuration files, directories, etc. - maxscale should exit cleanly.


Generated at Thu Feb 08 03:58:48 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.