Overview
...
If you were using Hexonet module to sell and manage domains in HostBill procedure below describes how to migrate your existing domains/tlds to CentralNic Reseller (rrpproxy) module
- Make sure that the RRPProxy module is enabled.
- Create App Connection for RRPProxy.
- Connect to the database.
- You should run the query which is below.
Query
Code Block |
---|
language | sql |
---|
title | Migration from Hexonet to RRPProxy |
---|
linenumbers | true |
---|
|
SET @rrpproxy = (SELECT `id` FROM hb_modules_configuration WHERE `filename` = 'class.rrpproxy.php'),
@hexonet = (SELECT `id` FROM hb_modules_configuration WHERE `filename` = 'class.hexonet.php'),
@server_group = (SELECT `id` FROM hb_server_groups WHERE module = IF(@rrpproxy IS NOT NULL, @rrpproxy, @hexonet)),
@serv = (SELECT `id` FROM hb_servers WHERE group_id = @server_group AND `default` = 1);
DELETE w.* FROM hb_widgets w LEFT JOIN hb_widgets_config wc ON (w.widget_id = wc.id)
WHERE wc.`widget` IN ('emailforwarding', 'registernameservers') AND w.`target_type` = 'Product'
AND w.`target_id` IN (SELECT `product_id` FROM hb_products_modules WHERE `module` = @hexonet);
UPDATE hb_config_items_cat cc SET cc.variable = UPPER(cc.variable)
WHERE cc.product_id IN (SELECT `product_id` FROM hb_products_modules WHERE `module` = @hexonet);
UPDATE hb_products_modules p, hb_domains d, hb_domain_prices dp
SET p.`module` = IF(@rrpproxy IS NOT NULL, @rrpproxy, @hexonet),
p.`server` = @serv,
dp.`module` = IF(@rrpproxy IS NOT NULL, @rrpproxy, @hexonet),
d.`reg_module` = IF(@rrpproxy IS NOT NULL, @rrpproxy, @hexonet),
d.server_id = @serv
WHERE p.`module` = @hexonet OR dp.`module` = @hexonet OR (d.`reg_module` = @hexonet AND d.tld_id = p.product_id); |
If you do not have any program to connect to the database, you can execute this query using the command line.
- Log in to the server where you have the HostBill installation.
- Then use the commands:
Code Block |
---|
|
use {$database_name}; |
Info |
---|
Where {$database_name} is the name of the database you want to connect to. You can find the name of your database in the file public_html/includes/config.php |
Then execute the SQL query that is above.