Search results

  1. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    Oh, thanks! )) My problem is, we stuck with 3.3 (test for 3.4 given some unstable results so we decided to wait for 3.4+). I can't "just upgrade" server so I have to play with 3.3. So, may I somehow upgrade scripts (not the kernel) of PVE so this functions will be available to my scripts? The...
  2. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    Oh, sad to know that. So, I can use qga (say, for flush mysql as per link I was given above) but it 1) will work since 3.4 and 2) will work only on qm snapshot, not on backup. That is, all I can do is quietly ignore nice featurs of qga and try to create such a shell script: ssh...
  3. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    Unlucky me again, we stuck with 3.3 due to kind of instability we faced in 3.4. Once we already upgraded a test server from 3.3 to 3.4 but we were unsatisfied with the result. We decided to wait for 3.5 and test again. But I suspect this is due to kernel and binary PVE utils (zfs support etc.)...
  4. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    Unlucky me, I can't see qma working while standard PVE backup. I have "agent: 1" line in VM's .conf file, and I see VM started with qga support (note the bold chars): /usr/bin/kvm -id 403 -chardev socket,id=qmp,path=/var/run/qemu-server/403.qmp,server,nowait -mon chardev=qmp,mode=control -vnc...
  5. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    THANK YOU! I'll try to do that! P.S. Sorry for missing the pint fist time!
  6. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    Just did a small test: I created a script that ssh to VM and add line with current timestamp to the text file. I run vzbackup in snapshot mode with this script as --script parameter so on each invocation there should be a line added to the file in VM. The idea was a simple one: as there was...
  7. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    Got the idea. Will try to play with qga. But again, as I try to run vzdump with demo script as --script I see there are a lot of 'events' in the log (I've listed them above). Any documentation which events fires before/after which backup stages? Playing blind may give me weird result afterwards.
  8. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    I think we talk wrong things. qga can work or not, but snapshot mode of backup itself works just like fs freeze. This way, I see no good in extra freezing (as far as I see no difference with or without qga) What I do not understand and what I would like to do is have some hook in vzdump script...
  9. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    I took another VM (KVM, qcow2, virtio, CentOS 7) and did install qm agent, but I still can't see anything about agent of fs freeze in the log. Here is the dump log: INFO: starting new backup job: vzdump 101 --remove 0 --mode snapshot --compress lzo --storage backup_daily --node proxmox INFO...
  10. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    Yes, but no traces in log. Strange. I see there is -script parameter on vzdump execution, and as I come to test it I see it run on: - job-start - backup-start - pre-stop - pre-restart - backup-end - log-end - job-end events. If I treat that right, and the vzdump run to create backup via...
  11. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    I'd wish I can afform myself to do that. But the truth is, my DB is quite big and will be dumped for long time. On the other hand, I hate to backup such huge space of data keeping in mind I can't trust sql binary data files itself so I'll need to recreate it on my restore (and it will take...
  12. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    I guess I miss the point. What I can get is qm snapshot will snapshot the virt. disks, but MySQL server is partly in memory (so unless I did FLUSH and LOCK on MySQL, I' not sure it start correctly next time). Freezing filesystem is good idea but I just don't understand how sql server will...
  13. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    Ok, I see. May I please ask which script exactly does the backup (should be the one which output I see in the browser log window as I start the backup) so I can use it as a draft? I understand this is not the thing you should support or even help with, I just hope this is not hard to suggest and...
  14. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    Oh, I see. Thank you for explaining me that, but this way I'd prefer to issue "FLUSH ..." and "LOCK ..." in the MySQL inside the VM before Agent will freeze the fs. Are there any smallest way to do that? Surely I don't like to duplicate original backup script.
  15. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    That's the news, thank you! I've never heard about this feature. But may I ask you again to prove my mind: this way the database setup will be completely consistent? I mean, if I freeze fs it will not necessary results in consistent database files on disk, and as I start the restored VM it may...
  16. A

    On backup run a command before and after snapshot to lock mysql db inside VM

    Hello, may I please ask for a little advice? I have a KVM VM (Centos 7 on ext4 fs, no LVM inside VM) with mysql server running inside. I'd like to create whole host backup (via snapshot method to minimize mysql server downtime) but what I afraid of, when I do snapshot of VM the fs consistency...
  17. A

    Possible to create quick copy of KVM VM by using snapshot?

    That's tha catch. My tests confirmed that, too. No, this is not the problem I try to overcome. Here is the example: Say, I have a running VM with some software in it. It is running continuously day by day and there is no reason to stop it. But, for example, we want to check what is we do some...
  18. A

    Possible to create quick copy of KVM VM by using snapshot?

    So if I got the idea right, all I need is to have qcow2 volumes in my VM and that's all, even no requirements like need to have LVM underneath? Good news, really! I've tried that but with raw disks so clone creation was very long since Proxmox copied the whole disks. Will check with qcow2 now...
  19. A

    Possible to create quick copy of KVM VM by using snapshot?

    Recently I faced situation when I needed to create exact copy of running VM for maybe 5 minutes to test some setting in it. The common way was to create the backup via snapshot, then create new machine and "restore" this new VM from recently created backup. It is quite easy to understand but it...