The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

WHM --> Configure Backup no longer works properly.

Discussion in 'Data Protection' started by jols, Dec 24, 2009.

  1. jols

    jols Well-Known Member

    Joined:
    Mar 13, 2004
    Messages:
    1,111
    Likes Received:
    2
    Trophy Points:
    38
    We only need rolling backups of the server to be put in the /daily directory. But now after this most recent cPanel backup, our (slave) backup drive is always filling up because also the day-to-day directories are also being created, like this:

    daily/
    Tuesday_20091222/
    Wednesday_20091223/

    and so on.

    The day to day directories, e.g. Tuesday_20091222, etc. are being created even though our settings in WHM ---> Configure Backup are exactly the same as before.

    How can we go back to where it was, i.e. when only the daily/ directory was created and the cPanel system just did the incremental backups into this directory, without also creating the day to day directories and thereby filling up our backup drive to 100%???
     
    #1 jols, Dec 24, 2009
    Last edited: Dec 24, 2009
  2. jols

    jols Well-Known Member

    Joined:
    Mar 13, 2004
    Messages:
    1,111
    Likes Received:
    2
    Trophy Points:
    38
    Part two:

    Okay, this is strange. We've got two servers where the WHM ---> Configure Backups is configured exactly the same. One is over flowing our backup drive (see the post above) and the other is not, i.e. we only get the daily/ directory in cpbackups on the backup drive as we always have.

    Here's what's also strange:

    Both servers are running the exact same version of cPanel:
    cPanel 11.25.0-R42399 - WHM 11.25.0 - X 3.9
    REDHAT Enterprise 5.4 i686 standard

    But the one that is giving us the unwanted backup copies in the day to day directories has this extra feature at the botton of the backup configuration page:

    Execute Pre/Post Backup Script ---

    What is going on here? Anyone?
     
  3. jols

    jols Well-Known Member

    Joined:
    Mar 13, 2004
    Messages:
    1,111
    Likes Received:
    2
    Trophy Points:
    38
    part three:

    Yup, I just checked all of our servers - Everywhere this option is available on the WHM ---> Backup Configuration page:

    Execute Pre/Post Backup Script ---

    ... we have this problem.

    I hate to make out all these tickets (for each of our servers with this issue) to cpanel.net support. So if anyone knows a fix for this, it would probably be helpful for all. Thanks.

    By the way, if I could find the backup script and the command in the script that is making the daily directories (duplicates/redundant backups of the daily directories) I would just comment it out, but so far I am unable to find where this script is. I've looked at /scripts/cpbackup but I just don't see which line I would need to comment out to make this happen. Help, anyone?
     
    #3 jols, Dec 24, 2009
    Last edited: Dec 24, 2009
  4. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,458
    Likes Received:
    22
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    The option for Pre/Post backup only shows up in the Configure Backup interface if one of the following scripts exists:

    /scripts/precpbackup
    /scripts/postcpbackup

    Look for those scripts on the affected systems. One of them is the likely culprit for the strange directory naming. cpbackup only creates a daily directory.
     
  5. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    Please don't worry about opening tickets as this will actually help make things smoother since tickets can be used to see trends and make problems easier for us to find and ultimately lead to quicker resolutions.
     
  6. jols

    jols Well-Known Member

    Joined:
    Mar 13, 2004
    Messages:
    1,111
    Likes Received:
    2
    Trophy Points:
    38
    Thanks but there is no such precpbackup script to be found on the affected servers. Perhaps I am not understanding your post correctly.

    CORRECTION - I did however find a postcpbackup script, and shifting this one to /root did indeed make the additional option go away on the WHM backup config page.

    Okay, I think we're on to something here. This is the contents the postcpbackup script:

    #!/bin/sh
    /usr/bin/dowbackup.pl

    And that script contains this toward the top:

    # cPanel backup rotation script
    # v1.2
    #
    # usage: /usr/bin/dowbackup.pl [Monday,Wednesday,Friday]

    my %bconf;
    my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime;
    my @days = ("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday");
    my $today = $days[$wday];

    Hopefully just removing postcpbackup will correct this issue.

    Hey, thanks for your help!
     
    #6 jols, Dec 24, 2009
    Last edited: Dec 24, 2009
  7. cPanelDon

    cPanelDon cPanel Quality Assurance Analyst
    Staff Member

    Joined:
    Nov 5, 2008
    Messages:
    2,557
    Likes Received:
    7
    Trophy Points:
    38
    Location:
    Houston, Texas, U.S.A.
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    On the affected system, please use the following command (via root SSH access) to verify the status of the optional cpbackup "pre" and "post" files that may be involved:
    Code:
    # stat /scripts/precpbackup /scripts/postcpbackup
     
  8. cPanelDon

    cPanelDon cPanel Quality Assurance Analyst
    Staff Member

    Joined:
    Nov 5, 2008
    Messages:
    2,557
    Likes Received:
    7
    Trophy Points:
    38
    Location:
    Houston, Texas, U.S.A.
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    Thank you for the updated information. I agree that removal of the customization should help to alleviate the issue. :)
     
Loading...

Share This Page