Change mariadb's log directory
There are a few reasons this can happen. 

1) The directory does not exist:

mysql&gt; SET GLOBAL general_log_file='/this/directory/does/not/exist/developserver.log';
ERROR 1231 (42000): Variable 'general_log_file' can't be set to the value of '/this/directory/does/not/exist/developserver.log'
mysql&gt; 


2) The directory exists, but you do not have permission to write to it &amp; create the new file:

root@ubuntu-xenial:~# chmod 000 /var/log/newmysqllogdirectory 
root@ubuntu-xenial:~# mysql -p
Enter password: 
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 8
Server version: 5.7.26-0ubuntu0.16.04.1 (Ubuntu)

Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql&gt; SET GLOBAL general_log_file='/var/log/newmysqllogdirectory/foo.log';
ERROR 1231 (42000): Variable 'general_log_file' can't be set to the value of '/var/log/newmysqllogdirectory/foo.log'
mysql&gt;