DirectSlave - solution to add and remove zones on slave without DirectAdmin

Nice to hear it works now.
Before you start to work on the SSL, first test the stop and start and especially restart of the init.d and see if it doesn't complaint about the .pid file.

About the help.... you're welcome! ;)
 
yup, I have rebooted the slave server and init.d works fine. also ssl works perfectly.

one more thing, is there any auto script to auto sync ( delete, update and add) the dns zone?
 
Maybe Sellerone knows that.
As far as I know it is kept up to date by multiserver itself on every DNS hup when a change is made.
Or maybe you can issue the line which is also used on the master for synching the multi server servers.
Code:
echo "action=rewrite&value=named" >> /usr/local/directadmin/data/task.queue

If this is not doing what you want then maybe Sellerone has some idea's left.
 
Richard is right, as soon as you add a domain, the MultiServer function notify the DNS Slave, when you just add a record is the bind that notify the other server (thats why is needed allow transfer and also notify options in named.conf).

The command that Richard gave you, you need to run it on DA node, it will force the MultiServer option to send all the Domains/DNS to the Slaves nodes.

So, you dont need script, you need the initial sync, than, everything will be automatic ;)

Regards
 
Im try setup on centos 7 and have error:
Code:
/usr/local/directslave/bin/directslave --check
defined(@array) is deprecated at /usr/local/directslave/bin/../lib//DSGI.pm line 528.
	(Maybe you should just omit the defined()?)
Base class package "Net::Server::HTTP" is empty.
    (Perhaps you need to 'use' the module which defines that package first,
    or make that module available in @INC (@INC contains: /usr/local/directslave/bin/../lib/ /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .).
 at /usr/local/directslave/bin/directslave line 11.
BEGIN failed--compilation aborted at /usr/local/directslave/bin/directslave line 11.

Please help
 
Have you install the required packages?
try:
Code:
cpan
install Net::Server::HTTP

Regards

Code:
perl -MCPAN -e shell
Terminal does not support AddHistory.

cpan shell -- CPAN exploration and modules installation (v1.9800)
Enter 'h' for help.

cpan[1]> install Net::Server::HTTP
Reading '/root/.cpan/sources/authors/01mailrc.txt.gz'
............................................................................DONE
Reading '/root/.cpan/sources/modules/0****kages.details.txt.gz'
  Database was generated on Tue, 15 Mar 2016 12:29:02 GMT
  HTTP::Date not available
..............
  New CPAN.pm version (v2.10) available.
  [Currently running version is v1.9800]
  You might want to try
    install CPAN
    reload cpan
  to both upgrade CPAN.pm and run the new version without leaving
  the current session.


..............................................................DONE
Reading '/root/.cpan/sources/modules/03modlist.data.gz'
Catching error: "Can't locate object method "data" via package "CPAN::Modulelist" (perhaps you forgot to load "CPAN::Modulelist"?) at (eval 18) line 1.\cJ at /usr/share/perl5/CPAN/Index.pm line 524.\cJ\cICPAN::Index::rd_modlist('CPAN::Index', '/root/.cpan/sources/modules/03modlist.data.gz') called at /usr/share/perl5/CPAN/Index.pm line 85\cJ\cICPAN::Index::reload('CPAN::Index') called at /usr/share/perl5/CPAN.pm line 976\cJ\cICPAN::exists('CPAN=HASH(0x2fe2b28)', 'CPAN::Module', 'Net::Server::HTTP') called at /usr/share/perl5/CPAN/Shell.pm line 1256\cJ\cICPAN::Shell::expandany('CPAN::Shell', 'Net::Server::HTTP') called at /usr/share/perl5/CPAN/Shell.pm line 1681\cJ\cICPAN::Shell::rematein('CPAN::Shell', 'install', 'Net::Server::HTTP') called at /usr/share/perl5/CPAN/Shell.pm line 1977\cJ\cICPAN::Shell::__ANON__('CPAN::Shell', 'Net::Server::HTTP') called at /usr/share/perl5/CPAN.pm line 376\cJ\cIeval {...} called at /usr/share/perl5/CPAN.pm line 373\cJ\cICPAN::shell() called at -e line 1\cJ" at /usr/share/perl5/CPAN.pm line 392.
	CPAN::shell() called at -e line 1
Reading '/root/.cpan/sources/authors/01mailrc.txt.gz'
............................................................................DONE
Reading '/root/.cpan/sources/modules/0****kages.details.txt.gz'
Warning: Your /root/.cpan/sources/modules/0****kages.details.txt.gz does not contain a Line-Count header.
Please check the validity of the index file by comparing it to more
than one CPAN mirror. I'll continue but problems seem likely to
happen.
Warning: Your /root/.cpan/sources/modules/0****kages.details.txt.gz does not contain a Last-Updated header.
Please check the validity of the index file by comparing it to more
than one CPAN mirror. I'll continue but problems seem likely to
happen.
2E~�g���ViJ�D�\\�\cT��\cT,��S���Q���zI�a4m�U)\cG�\cT)om�2�q�\cQ\c]5�{\cG.I\cY��\cV|L�FQ|��ci�/\cX%)�\cCMy"]\cK�\\�\cT.s�S`��`\\�
Could not split line["3�G"]
Could not split line["?�\c?K�\cW��Y�\cN����\cT�)�r��L��'^�|1i�{=��o%��\cTj�\cH�"]
Could not split line["��K�%\cH�B}P\cG��\c?�\c]�\cF�6�5��m��W\cX��<\cQs���d������9b��\cM�D'�0�<\cC"`�\cA\cGa+?J��`\c?(\cR�\\}\cY\\\cOn��\\�P�'�\c@�T!"]
Giving up parsing your /root/.cpan/sources/modules/0****kages.details.txt.gz, too many errorsTerminal does not support GetHistory.
Lockfile removed.

[root@ns2 ~]# /usr/local/directslave/bin/directslave --check
defined(@array) is deprecated at /usr/local/directslave/bin/../lib//DSGI.pm line 528.
	(Maybe you should just omit the defined()?)
Base class package "Net::Server::HTTP" is empty.
    (Perhaps you need to 'use' the module which defines that package first,
    or make that module available in @INC (@INC contains: /usr/local/directslave/bin/../lib/ /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .).
 at /usr/local/directslave/bin/directslave line 11.
BEGIN failed--compilation aborted at /usr/local/directslave/bin/directslave line 11.
 
Well it clearly didnt install..

Try update CPAN with:

Code:
cpan
install Bundle::CPAN

Then try again to install the package

Regards
 
Well it clearly didnt install..

Try update CPAN with:

Code:
cpan
install Bundle::CPAN

Then try again to install the package

Regards

Code:
cpan
Terminal does not support AddHistory.

cpan shell -- CPAN exploration and modules installation (v1.9800)
Enter 'h' for help.

cpan[1]> install Bundle::CPAN
Reading '/root/.cpan/sources/authors/01mailrc.txt.gz'
............................................................................DONE
Reading '/root/.cpan/sources/modules/0****kages.details.txt.gz'
  Database was generated on Tue, 15 Mar 2016 12:29:02 GMT
  HTTP::Date not available
..............
  New CPAN.pm version (v2.10) available.
  [Currently running version is v1.9800]
  You might want to try
    install CPAN
    reload cpan
  to both upgrade CPAN.pm and run the new version without leaving
  the current session.


..............................................................DONE
Reading '/root/.cpan/sources/modules/03modlist.data.gz'
Catching error: "Can't locate object method \"data\" via package \"CPAN::Modulelist\" (perhaps you forgot to load \"CPAN::Modulelist\"?) at (eval 19) line 1.\cJ at /usr/share/perl5/CPAN/Index.pm line 524.\cJ\cICPAN::Index::rd_modlist('CPAN::Index', '/root/.cpan/sources/modules/03modlist.data.gz') called at /usr/share/perl5/CPAN/Index.pm line 85\cJ\cICPAN::Index::reload('CPAN::Index') called at /usr/share/perl5/CPAN.pm line 976\cJ\cICPAN::exists('CPAN=HASH(0x2dfca70)', 'CPAN::Bundle', 'Bundle::CPAN') called at /usr/share/perl5/CPAN/Shell.pm line 1356\cJ\cICPAN::Shell::expand_by_method('CPAN::Shell', 'CPAN::Bundle', 'ARRAY(0x2f04868)', 'Bundle::CPAN') called at /usr/share/perl5/CPAN/Shell.pm line 1273\cJ\cICPAN::Shell::expand('CPAN::Shell', 'Bundle', 'Bundle::CPAN') called at /usr/share/perl5/CPAN/Shell.pm line 1254\cJ\cICPAN::Shell::expandany('CPAN::Shell', 'Bundle::CPAN') called at /usr/share/perl5/CPAN/Shell.pm line 1681\cJ\cICPAN::Shell::rematein('CPAN::Shell', 'install', 'Bundle::CPAN') called at /usr/share/perl5/CPAN/Shell.pm line 1977\cJ\cICPAN::Shell::__ANON__('CPAN::Shell', 'Bundle::CPAN') called at /usr/share/perl5/CPAN.pm line 376\cJ\cIeval {...} called at /usr/share/perl5/CPAN.pm line 373\cJ\cICPAN::shell() called at /usr/share/perl5/App/Cpan.pm line 295\cJ\cIApp::Cpan::_process_options('App::Cpan') called at /usr/share/perl5/App/Cpan.pm line 364\cJ\cIApp::Cpan::run('App::Cpan') called at /usr/bin/cpan line 11\cJ" at /usr/share/perl5/CPAN.pm line 392.
	CPAN::shell() called at /usr/share/perl5/App/Cpan.pm line 295
	App::Cpan::_process_options('App::Cpan') called at /usr/share/perl5/App/Cpan.pm line 364
	App::Cpan::run('App::Cpan') called at /usr/bin/cpan line 11
Reading '/root/.cpan/sources/authors/01mailrc.txt.gz'
............................................................................DONE
Reading '/root/.cpan/sources/modules/0****kages.details.txt.gz'
Warning: Your /root/.cpan/sources/modules/0****kages.details.txt.gz does not contain a Line-Count header.
Please check the validity of the index file by comparing it to more
than one CPAN mirror. I'll continue but problems seem likely to
happen.
Warning: Your /root/.cpan/sources/modules/0****kages.details.txt.gz does not contain a Last-Updated header.
Please check the validity of the index file by comparing it to more
than one CPAN mirror. I'll continue but problems seem likely to
happen.
2E~�g���ViJ�D�\\�\cT��\cT,��S���Q���zI�a4m�U)\cG�\cT)om�2�q�\cQ\c]5�{\cG.I\cY��\cV|L�FQ|��ci�/\cX%)�\cCMy"]\cK�\\�\cT.s�S`��`\\�
Could not split line["3�G"]
Could not split line["?�\c?K�\cW��Y�\cN����\cT�)�r��L��'^�|1i�{=��o%��\cTj�\cH�"]
Could not split line["��K�%\cH�B}P\cG��\c?�\c]�\cF�6�5��m��W\cX��<\cQs���d������9b��\cM�D'�0�<\cC\"`�\cA\cGa+?J��`\c?(\cR�\\}\cY\\\cOn��\\�P�'�\c@�T!"]
Giving up parsing your /root/.cpan/sources/modules/0****kages.details.txt.gz, too many errorsTerminal does not support GetHistory.
Lockfile removed.

[root@ns2 ~]# /usr/local/directslave/bin/directslave --check
defined(@array) is deprecated at /usr/local/directslave/bin/../lib//DSGI.pm line 528.
	(Maybe you should just omit the defined()?)
Base class package "Net::Server::HTTP" is empty.
    (Perhaps you need to 'use' the module which defines that package first,
    or make that module available in @INC (@INC contains: /usr/local/directslave/bin/../lib/ /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .).
 at /usr/local/directslave/bin/directslave line 11.
BEGIN failed--compilation aborted at /usr/local/directslave/bin/directslave line 11.
 
Apparently CPAN is not working properly, you should try to reinstall it.

Code:
yum -y reinstall perl-CPAN

Than try again.

Regards
 
Apparently CPAN is not working properly, you should try to reinstall it.

Code:
yum -y reinstall perl-CPAN

Than try again.

Regards

Code:
yum-y reinstall perl-CPAN
Modules are loaded: fastestmirror
base | 3.6 kB 00:00:00     
epel/x86_64/metalink | 21 kB 00:00:00     
epel | 4.3 kB 00:00:00     
extras | 3.4 kB 00:00:00     
updates | 3.4 kB 00:00:00     
(1/3): epel/x86_64/updateinfo | 512 kB 00:00:00     
(2/3): epel/x86_64/primary_db | 3.9 MB 00:00:00     
(3/3): updates/7/x86_64/primary_db | 3.2 MB 00:00:00     
Loading mirror speeds from cached hostfile
 * base: centos.serverspace.co.uk
 * epel: epel.mirrors.ovh.net
 * extras: centos.serverspace.co.uk
 * updates:                                                                                                                                                                                                                                                           | 3.4 kB  00:00:00     
(1/3): epel/x86_64/updateinfo                                                                                                                                                                                                                                       | 512 kB  00:00:00     
(2/3): epel/x86_64/primary_db                                                                                                                                                                                                                                       | 3.9 MB  00:00:00     
(3/3): updates/7/x86_64/primary_db                                                                                                                                                                                                                                  | 3.2 MB  00:00:00     
Loading mirror speeds from cached hostfile
 * base: centos.serverspace.co.uk
 * epel: epel.mirrors.ovh.net
 * extras: centos.serverspace.co.uk
 * updates: centos.serverspace.co.uk
Permit of dependences
-> Check of the script
---> the Package perl-CPAN.noarch 0:1.9800-286.el7 is marked for reinstallation
-> Check of dependences is ended

Dependences are certain

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    
 Package Architecture the Version the Repository the Size
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    
Reinstallation:
 perl-CPAN noarch 1.9800-286.el7 base 292 k

Total for operation
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    
To reinstall 1 package

Volume of loading: 292 k
Volume of variations: 745 k
Downloading packages:
perl-CPAN--1.9800-286.el7.noarch.rpm | 292 kB 00:00:00     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installation: perl-CPAN--1.9800-286.el7.noarch 1/1 
  Check: perl-CPAN--1.9800-286.el7.noarch

It is established:
  perl-CPAN.noarch 0:1.9800-286.el7                                                                                                                                                                                                                                                        

It is executed!

[root@ns2 ~]# /usr/local/directslave/bin/directslave --check
defined(@array) is deprecated at /usr/local/directslave/bin/../lib//DSGI.pm line 528.
	(Maybe you should just omit the defined()?)
Base class package "Net::Server::HTTP" is empty.
    (Perhaps you need to 'use' the module which defines that package first,
    or make that module available in @INC (@INC contains: /usr/local/directslave/bin/../lib/ /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .).
 at /usr/local/directslave/bin/directslave line 11.
BEGIN failed--compilation aborted at /usr/local/directslave/bin/directslave line 11.

im translate some output to english
 
Last edited:
No i meant that you need to try the cpan command to instal the Net::Server:HTTP package...

Regards

Code:
cpan
Terminal does not support AddHistory.

cpan shell -- CPAN exploration and modules installation (v1.9800)
Enter 'h' for help.

cpan[1]> install Net::Server::HTTP
Reading '/root/.cpan/sources/authors/01mailrc.txt.gz'
............................................................................DONE
Reading '/root/.cpan/sources/modules/0****kages.details.txt.gz'
  Database was generated on Tue, 15 Mar 2016 12:29:02 GMT
  HTTP::Date not available
..............
  New CPAN.pm version (v2.10) available.
  [Currently running version is v1.9800]
  You might want to try
    install CPAN
    reload cpan
  to both upgrade CPAN.pm and run the new version without leaving
  the current session.


..............................................................DONE
Reading '/root/.cpan/sources/modules/03modlist.data.gz'
Catching error: "Can't locate object method \"data\" via package \"CPAN::Modulelist\" (perhaps you forgot to load \"CPAN::Modulelist\"?) at (eval 19) line 1.\cJ at /usr/share/perl5/CPAN/Index.pm line 524.\cJ\cICPAN::Index::rd_modlist('CPAN::Index', '/root/.cpan/sources/modules/03modlist.data.gz') called at /usr/share/perl5/CPAN/Index.pm line 85\cJ\cICPAN::Index::reload('CPAN::Index') called at /usr/share/perl5/CPAN.pm line 976\cJ\cICPAN::exists('CPAN=HASH(0x33f6a70)', 'CPAN::Module', 'Net::Server::HTTP') called at /usr/share/perl5/CPAN/Shell.pm line 1256\cJ\cICPAN::Shell::expandany('CPAN::Shell', 'Net::Server::HTTP') called at /usr/share/perl5/CPAN/Shell.pm line 1681\cJ\cICPAN::Shell::rematein('CPAN::Shell', 'install', 'Net::Server::HTTP') called at /usr/share/perl5/CPAN/Shell.pm line 1977\cJ\cICPAN::Shell::__ANON__('CPAN::Shell', 'Net::Server::HTTP') called at /usr/share/perl5/CPAN.pm line 376\cJ\cIeval {...} called at /usr/share/perl5/CPAN.pm line 373\cJ\cICPAN::shell() called at /usr/share/perl5/App/Cpan.pm line 295\cJ\cIApp::Cpan::_process_options('App::Cpan') called at /usr/share/perl5/App/Cpan.pm line 364\cJ\cIApp::Cpan::run('App::Cpan') called at /usr/bin/cpan line 11\cJ" at /usr/share/perl5/CPAN.pm line 392.
	CPAN::shell() called at /usr/share/perl5/App/Cpan.pm line 295
	App::Cpan::_process_options('App::Cpan') called at /usr/share/perl5/App/Cpan.pm line 364
	App::Cpan::run('App::Cpan') called at /usr/bin/cpan line 11
Reading '/root/.cpan/sources/authors/01mailrc.txt.gz'
............................................................................DONE
Reading '/root/.cpan/sources/modules/0****kages.details.txt.gz'
Warning: Your /root/.cpan/sources/modules/0****kages.details.txt.gz does not contain a Line-Count header.
Please check the validity of the index file by comparing it to more
than one CPAN mirror. I'll continue but problems seem likely to
happen.
Warning: Your /root/.cpan/sources/modules/0****kages.details.txt.gz does not contain a Last-Updated header.
Please check the validity of the index file by comparing it to more
than one CPAN mirror. I'll continue but problems seem likely to
happen.
2E~�g���ViJ�D�\\�\cT��\cT,��S���Q���zI�a4m�U)\cG�\cT)om�2�q�\cQ\c]5�{\cG.I\cY��\cV|L�FQ|��ci�/\cX%)�\cCMy"]\cK�\\�\cT.s�S`��`\\�
Could not split line["3�G"]
Could not split line["?�\c?K�\cW��Y�\cN����\cT�)�r��L��'^�|1i�{=��o%��\cTj�\cH�"]
Could not split line["��K�%\cH�B}P\cG��\c?�\c]�\cF�6�5��m��W\cX��<\cQs���d������9b��\cM�D'�0�<\cC\"`�\cA\cGa+?J��`\c?(\cR�\\}\cY\\\cOn��\\�P�'�\c@�T!"]
Giving up parsing your /root/.cpan/sources/modules/0****kages.details.txt.gz, too many errorsTerminal does not support GetHistory.
Lockfile removed.
 
Ok, let's try in a drastic way:

Code:
mv /root/.cpan/ /root/.cpan_OLD/
yum -y reinstall perl-CPAN
cpan
install Bundle::CPAN
install Net::Server:HTTP
 
Still same errors?
Code:
/usr/local/directslave/bin/directslave --check
defined(@array) is deprecated at /usr/local/directslave/bin/../lib//DSGI.pm line 528.
	(Maybe you should just omit the defined()?)
Base class package "Net::Server::HTTP" is empty.
    (Perhaps you need to 'use' the module which defines that package first,
    or make that module available in @INC (@INC contains: /usr/local/directslave/bin/../lib/ /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .).
 at /usr/local/directslave/bin/directslave line 11.
BEGIN failed--compilation aborted at /usr/local/directslave/bin/directslave line 11.
 
I was still talking about CPAN.

There is no point to check on DirectSlave untill the problem with CPAN and this Perl packages isn't fixed.

Regards
 
Back
Top