There is no easy way at this point, although Test of MySupport MOD may be faster.
There are three ways of doing this:
1:
You could upgrade one account and she can manually move all of her sites and databases manually to the upgraded account. You will need to use the Deleted Records Manager module to help her out. Once she has backed up all the sites and databases you would delete the old accounts normally, then use Deleted Records Manager to clean up the database of all her old information. Then she can re-create the domains and ftp, etc. on the new account.
-OR-
2:
Untested!
(Make a backup of YOUR entire panel sentora_core database!)
Then you could go through each table and change *_acc_fk where her old account number is and change it to the new or upgraded account number and move all domain folders from the old accounts to the new one and run the daemon.
In theory, you are manually re-assigning the old account's information to the new account.
For example, you go into the x_accounts table and find her new (or upgraded) account ID (ac_id_pk) and write it down and do the same with her old account numbers.
Then, you would go into the next table (x_aliases) and look for her old account numbers in al_acc_fk and change them all to her new account number. Do this for every DB table as needed.
You could make a small DB query that you could execute on each database table.
Something like:
You would need to edit this for every table but it will change all the references in that table instead of manually changing each individual one. (Remember to replace new# with her new/upgraded account and old# with her old account number)
So the next one would be:
And so on.
-OR-
3:
You could even write a php script that would do this for you.
(Make a backup of YOUR entire panel sentora_core database!)
You would put this file in your /etc/sentora/panel/ folder
and run it by entering: http://panel.domain.com/move_client.php
Example move_client.php file: (delete this file after you use it!!)
There may be an easier way, this is just a basic idea.
I haven't had much time lately, but I will plan to make a module that will accomplish this task. I think there is one similar, but it is for reseller accounts (I think).
There are three ways of doing this:
1:
You could upgrade one account and she can manually move all of her sites and databases manually to the upgraded account. You will need to use the Deleted Records Manager module to help her out. Once she has backed up all the sites and databases you would delete the old accounts normally, then use Deleted Records Manager to clean up the database of all her old information. Then she can re-create the domains and ftp, etc. on the new account.
-OR-
2:
Untested!
(Make a backup of YOUR entire panel sentora_core database!)
Then you could go through each table and change *_acc_fk where her old account number is and change it to the new or upgraded account number and move all domain folders from the old accounts to the new one and run the daemon.
In theory, you are manually re-assigning the old account's information to the new account.
For example, you go into the x_accounts table and find her new (or upgraded) account ID (ac_id_pk) and write it down and do the same with her old account numbers.
Then, you would go into the next table (x_aliases) and look for her old account numbers in al_acc_fk and change them all to her new account number. Do this for every DB table as needed.
You could make a small DB query that you could execute on each database table.
Something like:
Code:
UPDATE x_alias SET al_acc_pk=new# WHERE al_acc_pk=old#
So the next one would be:
Code:
UPDATE x_bandwidth SET bd_acc_pk=new# WHERE bd_acc_pk=old#
-OR-
3:
You could even write a php script that would do this for you.
(Make a backup of YOUR entire panel sentora_core database!)
You would put this file in your /etc/sentora/panel/ folder
and run it by entering: http://panel.domain.com/move_client.php
Example move_client.php file: (delete this file after you use it!!)
PHP Code:
<?php
// set account number variables
$old_account = "old#"; // change from this account number
$new_account = "new#"; // change to this account number
// get DB info
include('cnf/db.php');
// DB connect
$conn = new PDO("mysql:host=$host;dbname=$dbname", $user, $pass);
// set the PDO error mode to exception
$conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
// do the table updates
// update aliases
$sql = "UPDATE x_alias SET al_acc_pk='$new_account' WHERE al_acc_pk='$old_account'";
$stmt = $conn->prepare($sql);
$stmt->execute();
// update bandwidth
$sql = "UPDATE x_bandwidth SET bd_acc_pk='$new_account' WHERE al_acc_pk='$old_account'";
$stmt = $conn->prepare($sql);
$stmt->execute();
// update cronjobs
$sql = "UPDATE x_cronjobs SET ct_acc_pk='$new_account' WHERE al_acc_pk='$old_account'";
$stmt = $conn->prepare($sql);
$stmt->execute();
//update distribution lists
$sql = "UPDATE x_distlists SET dl_acc_pk='$new_account' WHERE al_acc_pk='$old_account'";
$stmt = $conn->prepare($sql);
$stmt->execute();
[the rest of the updates here]
$conn = null;
?>
I haven't had much time lately, but I will plan to make a module that will accomplish this task. I think there is one similar, but it is for reseller accounts (I think).