* Wed Jun 29 2022 Jean-Philippe Pialasse <tests@pialasse.com> 2.0.1.1-9.sme

- fix systemd unit chmod [SME: 11046]
This commit is contained in:
2025-09-03 00:40:10 -04:00
parent 0da9e8f72a
commit e72114facb
18 changed files with 2891 additions and 38 deletions

View File

@@ -0,0 +1,44 @@
diff -Nur --no-dereference bandwidthd-2.0.1.1.old/bandwidthd.c bandwidthd-2.0.1.1/bandwidthd.c
--- bandwidthd-2.0.1.1.old/bandwidthd.c 2021-06-06 00:46:55.812000000 -0400
+++ bandwidthd-2.0.1.1/bandwidthd.c 2021-06-06 01:05:27.761000000 -0400
@@ -1073,35 +1073,35 @@
if (mysql_num_rows(res) != 1) {
mysql_free_result(res);
- ret = mysql_query(conn, "CREATE TABLE bd_rx_log (sensor_id INT, ip INT UNSIGNED, timestamp TIMESTAMP, sample_duration INT, total INT, icmp INT, udp INT, tcp INT, ftp INT, http INT, p2p INT, INDEX bd_rx_log_sensors_id_ip_timestamp_idx (sensor_id, ip, timestamp), INDEX bd_rx_log_sensor_id_timestamp_idx (sensor_id, timestamp)) TYPE=innodb");
+ ret = mysql_query(conn, "CREATE TABLE bd_rx_log (sensor_id INT, ip INT UNSIGNED, timestamp TIMESTAMP, sample_duration INT, total INT, icmp INT, udp INT, tcp INT, ftp INT, http INT, p2p INT, INDEX bd_rx_log_sensors_id_ip_timestamp_idx (sensor_id, ip, timestamp), INDEX bd_rx_log_sensor_id_timestamp_idx (sensor_id, timestamp)) ENGINE=innodb");
if (ret) {
syslog(LOG_ERR, "MySQL CREATE TABLE failed: %s", mysql_error(conn));
mysql_close(conn);
return(NULL);
}
- ret = mysql_query(conn, "CREATE TABLE bd_tx_log (sensor_id INT, ip INT UNSIGNED, timestamp TIMESTAMP, sample_duration INT, total INT, icmp INT, udp INT, tcp INT, ftp INT, http INT, p2p INT, INDEX bd_tx_log_sensors_id_ip_timestamp_idx (sensor_id, ip, timestamp), INDEX bd_tx_log_sensor_id_timestamp_idx (sensor_id, timestamp)) TYPE=innodb");
+ ret = mysql_query(conn, "CREATE TABLE bd_tx_log (sensor_id INT, ip INT UNSIGNED, timestamp TIMESTAMP, sample_duration INT, total INT, icmp INT, udp INT, tcp INT, ftp INT, http INT, p2p INT, INDEX bd_tx_log_sensors_id_ip_timestamp_idx (sensor_id, ip, timestamp), INDEX bd_tx_log_sensor_id_timestamp_idx (sensor_id, timestamp)) ENGINE=innodb");
if (ret) {
syslog(LOG_ERR, "MySQL CREATE TABLE failed: %s", mysql_error(conn));
mysql_close(conn);
return(NULL);
}
- ret = mysql_query(conn, "CREATE TABLE bd_rx_total_log (sensor_id INT, ip INT UNSIGNED, timestamp TIMESTAMP, sample_duration INT, total INT, icmp INT, udp INT, tcp INT, ftp INT, http INT, p2p INT, INDEX bd_rx_total_log_sensors_id_timestamp_idx (sensor_id, timestamp)) TYPE=innodb");
+ ret = mysql_query(conn, "CREATE TABLE bd_rx_total_log (sensor_id INT, ip INT UNSIGNED, timestamp TIMESTAMP, sample_duration INT, total INT, icmp INT, udp INT, tcp INT, ftp INT, http INT, p2p INT, INDEX bd_rx_total_log_sensors_id_timestamp_idx (sensor_id, timestamp)) ENGINE=innodb");
if (ret) {
syslog(LOG_ERR, "MySQL CREATE TABLE failed: %s", mysql_error(conn));
mysql_close(conn);
return(NULL);
}
- ret = mysql_query(conn, "CREATE TABLE bd_tx_total_log (sensor_id INT, ip INT UNSIGNED, timestamp TIMESTAMP, sample_duration INT, total INT, icmp INT, udp INT, tcp INT, ftp INT, http INT, p2p INT, INDEX bd_tx_total_log_sensors_id_timestamp_idx (sensor_id, timestamp)) TYPE=innodb");
+ ret = mysql_query(conn, "CREATE TABLE bd_tx_total_log (sensor_id INT, ip INT UNSIGNED, timestamp TIMESTAMP, sample_duration INT, total INT, icmp INT, udp INT, tcp INT, ftp INT, http INT, p2p INT, INDEX bd_tx_total_log_sensors_id_timestamp_idx (sensor_id, timestamp)) ENGINE=innodb");
if (ret) {
syslog(LOG_ERR, "MySQL CREATE TABLE failed: %s", mysql_error(conn));
mysql_close(conn);
return(NULL);
}
- ret = mysql_query(conn, "CREATE TABLE sensors (sensor_id INT PRIMARY KEY AUTO_INCREMENT, sensor_name VARCHAR(255) UNIQUE NOT NULL, last_connection TIMESTAMP) TYPE=innodb");
+ ret = mysql_query(conn, "CREATE TABLE sensors (sensor_id INT PRIMARY KEY AUTO_INCREMENT, sensor_name VARCHAR(255) UNIQUE NOT NULL, last_connection TIMESTAMP) ENGINE=innodb");
if (ret) {
syslog(LOG_ERR, "MySQL CREATE TABLE failed: %s", mysql_error(conn));
mysql_close(conn);