diff --git a/db/CMakeLists.txt b/db/CMakeLists.txt index c7ed10a5f..82fa1fefa 100644 --- a/db/CMakeLists.txt +++ b/db/CMakeLists.txt @@ -6,6 +6,7 @@ configure_file(zm_update-1.31.30.sql.in "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1 configure_file(zm_update-1.35.24.sql.in "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.35.24.sql" @ONLY) configure_file(zm_update-1.37.4.sql.in "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.37.4.sql" @ONLY) configure_file(zm_update-1.37.69.sql.in "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.37.69.sql" @ONLY) +configure_file(zm_update-1.37.74.sql.in "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.37.74.sql" @ONLY) # install zm_create.sql install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_create.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db") @@ -21,6 +22,8 @@ install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.35.24.sql" DESTINATION "$ install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.37.4.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db") # install zm_update-1.37.69.sql install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.37.69.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db") +# install zm_update-1.37.74.sql +install(FILES "${CMAKE_CURRENT_BINARY_DIR}/zm_update-1.37.74.sql" DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db") # Install the database upgrade scripts install(FILES ${dbfileslist} DESTINATION "${CMAKE_INSTALL_DATADIR}/zoneminder/db") diff --git a/db/zm_update-1.37.74.sql.in b/db/zm_update-1.37.74.sql.in new file mode 100644 index 000000000..12c09d8cd --- /dev/null +++ b/db/zm_update-1.37.74.sql.in @@ -0,0 +1,22 @@ +SELECT 'This update may make changes that require SUPER privileges. If you see an error message saying: + +ERROR 1419 (HY000) at line 298: You do not have the SUPER privilege and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable) + +You will have to either run this update as root manually using something like (on ubuntu/debian) + +sudo mysql --defaults-file=/etc/mysql/debian.cnf zm < /usr/share/zoneminder/db/zm_update-1.37.69.sql + +OR + +sudo mysql --defaults-file=/etc/mysql/debian.cnf "set global log_bin_trust_function_creators=1;" +sudo zmupdate.pl + +OR + +Turn off binary logging in your mysql server by adding this to your mysql config. +[mysqld] +skip-log-bin + +'; + +source @PKGDATADIR@/db/triggers.sql