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.

Fastest Way To Zap Multiple Accounts [Urgent]

Discussion in 'General Discussion' started by bugmaster, Dec 29, 2005.

  1. bugmaster

    bugmaster Member

    Joined:
    Dec 29, 2005
    Messages:
    9
    Likes Received:
    0
    Trophy Points:
    1
    I recently acquired 15 servers with massive amounts of accounts
    98% unused, over 4000 per server

    I need to delete 3800 of these on each server but the problem is because they
    were unmanaged for so long, deleting 1 account via WHM or /scripts/killacct
    takes 15 minutes to remove 1 account

    due to something like mkvhostspasswd or something taking forever to rehash

    Is there any way I can get these accounts removed faster?
     
  2. oulzac

    oulzac Well-Known Member

    Joined:
    Aug 7, 2005
    Messages:
    131
    Likes Received:
    0
    Trophy Points:
    16
    Yes, with the terminate multiple accounts feature in whm, in the Multi-Account Functions section.
     
  3. bugmaster

    bugmaster Member

    Joined:
    Dec 29, 2005
    Messages:
    9
    Likes Received:
    0
    Trophy Points:
    1
    That does not help, it takes 15 minutes per remove (mass terminate still does one at a time, just get to select ahead of time), the web app will run for 6 hours to remove 50 accounts and takes 99.9% of the cpu PER USER once it hits that mkvhostspasswd stage
     
    #3 bugmaster, Dec 29, 2005
    Last edited: Dec 29, 2005
  4. bugmaster

    bugmaster Member

    Joined:
    Dec 29, 2005
    Messages:
    9
    Likes Received:
    0
    Trophy Points:
    1
    geez

    i started mass terminate since last post
    at this time it has only removed 3 accounts in total
     
  5. bugmaster

    bugmaster Member

    Joined:
    Dec 29, 2005
    Messages:
    9
    Likes Received:
    0
    Trophy Points:
    1
    peeking

    just peeking at the mkvhostspasswd code, didnt get far but

    opendir(PROFTPDVHOSTS,"/etc/proftpd");
    my @NAMELESS=readdir(PROFTPDVHOSTS);
    @NAMELESS=grep(!/^\.+$/, @NAMELESS);
    closedir(PROFTPDVHOSTS);

    Could this be whats slowing it down and if i just zap all the bad accounts here prior to terminating, that will speed up the proccess?
     
  6. bugmaster

    bugmaster Member

    Joined:
    Dec 29, 2005
    Messages:
    9
    Likes Received:
    0
    Trophy Points:
    1
    not a coder

    I'm not a coder or a engineer, or whatnot, but if you ask me this procedure is useless to be run in this predicament...... sure it might be a part of some sorta test that needs to be done when managing accounts, but in certain conditions such as rmeoving 1 account, why 1000 others have to be checked for a nameless account is beyond me, seeing how
    it just deleted the proftpd file that it really should be checking before even running this...
    thats my 2 cents... but then again, i have worked with programmers for 10 years and i know how that scene goes,

    my problem was solved with my own 10 lines of code to find and rmeove ununsed accounts... and this was indeed the bottleneck

    15 minutes now down to 2 minutes per terminate
    still slow but tolerable
     
  7. forlinuxsupport

    forlinuxsupport Well-Known Member
    PartnerNOC

    Joined:
    Dec 22, 2004
    Messages:
    386
    Likes Received:
    0
    Trophy Points:
    16
    cPanel Access Level:
    Root Administrator
    hey

    How about backing up the accounts you want,
    Then move the backup off the server and wipe it
    then reinstall the OS and then cpanel and restore the accounts you need.

    :)
    Cheers
    Andy
     
  8. bugmaster

    bugmaster Member

    Joined:
    Dec 29, 2005
    Messages:
    9
    Likes Received:
    0
    Trophy Points:
    1
    pointless

    pointless and expensive, the drives are multiple 200 gigs+ per server

    a better solution would be to learn how to program, kinda sad someone who has
    no programming knowledge and used cpanel for less than a month can code better than someone making 150k+ a year specifically on the project and a cpanel supposed expert
     
  9. randomuser

    randomuser Well-Known Member

    Joined:
    Jun 25, 2005
    Messages:
    147
    Likes Received:
    0
    Trophy Points:
    16
    Oh how I wish one day cPanel would fix this code
     
Loading...

Share This Page