After a more careful look, I see that my first two paragraphs are
not correct. After looking at your output more carefully, I see
that you are running MariaDB, and at the moment Bacula does not
officially support MariaDB. My suggestions for correcting the
problem other than 2 and 4 are probably still valid.
Hello,
It sounds like this is another change in MySQL in a newer
version. Previously they prohibited a DEFAULT 0 for the start
time, because zero is not a permitted value, even though the
field is a Unix Time stamp, where 0 is a perfectly valid time.
Consequently we removed the DEFAULT. Apparently, they now
require a start time. The problem is that Bacula counts on the
default start time to be zero in some of the database records
(the Media record I think). Note: in the Job record, there is
no start time when the Job is created. The start time is known
only when the Job begins running, so the default value must be
zero.
So, I can see a few possible solutions:
1. Modify the make_mysql_tables that creates the Job record to
include DEFAULT '0000-00-00 00:00:00'.
2. Fall back to an older version of MySQL.
3. Research if they permit some other way of setting a default
value of zero.
4. Use MariaDB but not version 10.2.x
5. Use PostgreSQL (this is my preferred solution).
Best regards,
Kern
On 07/16/2017 09:28 AM, Mick wrote:
Hi,
I've managed to compile and install 9.0.0 (with much appreciated
help) however now the jobs fail.
I have run the update_bacula_tables script
--------------------------------------
Error Message:
JobId 0: Fatal error: sql_create.c:84 Create DB Job record
INSERT INTO Job
(Job,Name,Type,Level,JobStatus,SchedTime,JobTDate,ClientId,Comment)
VALUES
('Client1.2017-07-16_00.05.00_04','Client1','B','D','C','2017-07-16
00:05:00',1500159900,3,'')
failed. ERR=Field 'StartTime' doesn't have a default value
--------------------------------------
OS: openSUSE Leap 42.1 (x86_64)
-----------------------------------------
MySQL version info
innodb_version 5.6.34-79.1
protocol_version 10
slave_type_conversions
version 10.0.29-MariaDB
version_comment SLE 12 SP1 package
version_compile_machine x86_64
version_compile_os Linux
version_malloc_library system
Any help appreciated.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users