KQL
1 TopicOracle VM / Azure Backup / Application Consistent/ Script to monitor when database is running/frozen
Hello everyone, I’ll need help with a technical context. I have a Linux 7/ Azure VM "Oracle DB" on which I test Microsoft Azure Backup (without Azure File Share for Point-in-Time recovery) My Oracle database is running. I have my /etc/azure/workload.conf (by default) My json file with VMSnapshotPluginConfig.json in the directory. (https://github.com/MicrosoftAzureBackup/VMSnapshotPluginConfig) Azure Portal : • Snapshot : 8 minutes • Application Consistent : 4 I want to know when the Oracle database is frozen (8 minutes seems long) I find nothing concrete in the logs of the Linux VM (directory alert.log) I saw this Github repo that allowed you to customize the script with output codes : https://github.com/MicrosoftAzureBackup/Oracle/blob/master/script.sh With a command sh -x script.sh, I saw : [root@VM2-Test /]# sh -x /scripts/script.sh + config_file_path= + pre_or_post= + success=0 + error=1 + warning=2 + status=0 + log_path=/config_error.log + '[' -eq 0 ']' /scripts/script.sh: line 15: [: -eq: unary operator expected + '[' -a ']' + . /scripts/script.sh: line 21: .: filename argument required .: usage: . filename [arguments] I believe that I have missing elements in my code and that in addition, I will not have the times when the database is started/ frozen/ stopped. If anyone can help me with my problem, that would be nice I also saw this way to collect times I want but I'm not sure to query correctly after setting up. https://github.com/MicrosoftDocs/azure-docs/blob/main/articles/virtual-machines/workloads/oracle/oracle-database-backup-azure-backup.md#remove-the-database-files sqlplus / as sysdba SQL> CREATE PROCEDURE sysbackup.azmessage(in_msg IN VARCHAR2) AS v_timestamp VARCHAR2(32); BEGIN SELECT TO_CHAR(SYSDATE, 'YYYY-MM-DD HH24:MI:SS') INTO v_timestamp FROM DUAL; DBMS_OUTPUT.PUT_LINE(v_timestamp || ' - ' || in_msg); SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.ALERT_FILE, in_msg); END azmessage; / SQL> SHOW ERRORS Any assistance would be most welcome. Have a good day !2.2KViews0likes3Comments