This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

I need to change when backups run
#1
I need to change when backups run
I need to change when the backups run from daily at midnight to Sunday at 1:00am.

Currently the backup setting do not have a provision for this. I can turn off the daily backups, but I am not sure how to fire them off myself. I have done some digging around, and i think I might be able to add a cron job that calls /etc/sentora/panel/modules/backup_admin/hooks/OnDaemonDay.hook.php, but I am not sure what happens if I run that file manually.

How do I go about doing this? Thank you.
Reply
Thanks given by:
#2
RE: I need to change when backups run
The startup time for backup is stored under sentora db settings.

M B
No support using PM (Auto adding to IGNORE list!), use the forum. 
How to ask
Freelance AWS Certified Architect & SysOps// DevOps

10$ free to start your VPS
Reply
Thanks given by:
#3
RE: I need to change when backups run
(10-31-2017, 06:42 AM)Shasta.com Wrote: I need to change when the backups run from daily at midnight to Sunday at 1:00am.

Currently the backup setting do not have a provision for this. I can turn off the daily backups, but I am not sure how to fire them off myself. I have done some digging around, and i think I might be able to add a cron job that calls /etc/sentora/panel/modules/backup_admin/hooks/OnDaemonDay.hook.php, but I am not sure what happens if I run that file manually.

How do I go about doing this? Thank you.

A cron job also can do that for you mate!
'' Life is full of important choices ''
Help Sentora Donate now => http://sentora.org/donate Blush
Reply
Thanks given by:
#4
RE: I need to change when backups run
(10-31-2017, 01:23 PM)wormsunited Wrote: A cron job also can do that for you mate!

Thanks for your reply, but your reply just restated my question without providing any answer.

What happens when I run /etc/sentora/panel/modules/backup_admin/hooks/OnDaemonDay.hook.php manually? Is this the script I want to run from the cron job?

(10-31-2017, 07:38 AM)Me.B Wrote: The startup time for backup is stored under sentora db settings.

M B

Wonderful, but where? When I go to: Database: sentora_core » Table: x_settings I see no field relating to backup or the scheduling thereof either. I have also looked all all the other tables in the sentora_core database and not found anything that resembles what I think I would be looking for.
Reply
Thanks given by:
#5
RE: I need to change when backups run
it's a timestamp TGates
No support using PM (Auto adding to IGNORE list!), use the forum. 
How to ask
Freelance AWS Certified Architect & SysOps// DevOps

10$ free to start your VPS
Reply
Thanks given by:
#6
RE: I need to change when backups run
(11-01-2017, 01:46 AM)Me.B Wrote: it's a timestamp @[TGates]

Oh yes, the whole UNIX timestamp thing I read about in another thread. Now, just how does that change my backup from daily to once a week on Sunday again? I'm pretty sure it doesn't. All it can do is change when during the day it happens.
Reply
Thanks given by:
#7
RE: I need to change when backups run
If I remember correctly it is not in the DB. It uses the OnDaemonDayRun.hook and runs every night at midnight.
The timing is hard coded into the module. Looking into it now.

This is a required fix for the backups manager if you have not done it yet: http://forums.sentora.org/showthread.php...0#pid13220

Still looking for the timing routine...
-TGates - Project Council

SEARCH the Forums or read the DOCUMENTATION before posting!
Support Sentora and Donate: HERE

Find my support or modules useful? Donate to TGates HERE
Developers and code testers needed!
Contact TGates for more information
Reply
Thanks given by:
#8
RE: I need to change when backups run
(11-01-2017, 03:30 AM)TGates Wrote: If I remember correctly it is not in the DB. It uses the OnDaemonDayRun.hook and runs every night at midnight.
The timing is hard coded into the module. Looking into it now.

This is a required fix for the backups manager if you have not done it yet: http://forums.sentora.org/showthread.php...0#pid13220

Still looking for the timing routine...

Thank you.

I have replaced the two files mentioned in the linked thread with the new versions.

I will wait to hear how I can schedule when this is called on my own via cron.
Reply
Thanks given by:
#9
RE: I need to change when backups run
I can't seem to find the code anywhere. But it had to do with changing the OnDaemonDay.hook.php to OnDaemonWeek.hook.php and some timestamp changes.

But that would not run at the time you specifically want.

To run a backup at your specific time, Me.B's custom bash script may be what you need: https://github.com/MBlagui/Sentora-tools...erfiles.sh
-TGates - Project Council

SEARCH the Forums or read the DOCUMENTATION before posting!
Support Sentora and Donate: HERE

Find my support or modules useful? Donate to TGates HERE
Developers and code testers needed!
Contact TGates for more information
Reply
Thanks given by:
#10
RE: I need to change when backups run
(11-01-2017, 05:21 AM)TGates Wrote: I can't seem to find the code anywhere. But it had to do with changing the OnDaemonDay.hook.php to OnDaemonWeek.hook.php and some timestamp changes.

But that would not run at the time you specifically want.

To run a backup at your specific time, Me.B's custom bash script may be what you need: https://github.com/MBlagui/Sentora-tools...erfiles.sh

I preliminary look through of Me.B's script makes me think this is the route for me to take.

Currently this install is a KVM VM on the same ProxMox server as 5 CloudLinux/cPanel VMs and a Windows 2016/Plesk VM. I made the mistake of making my image storage drive a raw ZFS ZRAID1 block storage. I need to rebuilt the whole thing as a ZRAID Stripe+Mirror mounted as a directory. Until I do, I/O Delay is killing me and I have to ensure that no two VMs are performing either an upgrade or backup at the same time.

Thank you for your help. If I need further assistance, I am sure I will be back. Otherwise I will report back with my results.
Reply
Thanks given by:


Possibly Related Threads…
Thread Author Replies Views Last Post
change username from email umarzuki@gmail.com 0 1 ,247 11-25-2022, 05:46 PM
Last Post: umarzuki@gmail.com
Number of backups kept frasina92 1 3 ,612 09-18-2019, 11:20 PM
Last Post: Ron-e
Database - Change localhost to %localhost% JSmith 1 4 ,480 09-11-2019, 09:19 AM
Last Post: TGates

Forum Jump:


Users browsing this thread: 1 Guest(s)