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.

Resold accounts..

Discussion in 'General Discussion' started by DigiCrime, May 5, 2006.

  1. DigiCrime

    DigiCrime Well-Known Member

    Joined:
    Nov 27, 2002
    Messages:
    399
    Likes Received:
    0
    Trophy Points:
    16
    Someone moved a reseller from a shared server into their own system but left their resold accounts on the original server, and terminated their main reseller account, so there are 97 phantom accounts on the shared server. I could list them all by owner/reseller so I re-created the resold account, went into reseller center to give it resold priviledges and go back and do a suspend all accounts from the reseller section and place them all on hold for the time being.

    Problem, after adding resold privs to the account, now all the 97 accounts are owned by root, so I have to go thru them one by one and do it all manually. Is there any other quicker way? Why would doing this swap all those accounts owned by someone else back to root all of a sudden

    Either way I look at it, probably have to do it all manually but wondered if theres another way
     
  2. ivankovalenko

    ivankovalenko Active Member

    Joined:
    Jul 19, 2005
    Messages:
    38
    Likes Received:
    0
    Trophy Points:
    6
    You can create script to call from Accounting or simply with wget. All you have to do is to construct proper url to call and you're on to it. I was doing it on my own server
    wget --http-user=root --http-passwd=<root passwd> "http://localhost:2086/scripts/dochangeowner?user=<usertomove>&owner=<resseller account>"
    That is a bit insecure, so you may want to hide your password in .netrc or .wgetrc file in /root.
    Also you've got to obtain a list of users to switch and then a bit of shell coding will make you happy like that:
    for i in `cat file.with.usernames`;do wget ..?user=$i&owner=.. ;done;
     
  3. DigiCrime

    DigiCrime Well-Known Member

    Joined:
    Nov 27, 2002
    Messages:
    399
    Likes Received:
    0
    Trophy Points:
    16
    Would be great to switch them all over from the reseller back to root, trouble is their already owned by root, somehow they switched themselves from the resellers ownership back to root :eek:

    ill keep that in mind however for future stuff
     
Loading...

Share This Page