Last active
December 7, 2016 11:41
-
-
Save harekumar/0b131d7cdd2bbfca38b70306c15c7083 to your computer and use it in GitHub Desktop.
Revisions
-
harekumar revised this gist
Dec 7, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -3,7 +3,7 @@ i.e needed to communicate nodes internally. Steps: 1. Ensure all the node has the same erlang-cookies. 2. Now go to any one of the node let's say we wish to add NodeB to NodeA cluster. Then go to the NodeB & run the following command in debug mode i.e by running ./bin/ejabberdctl debug Node = NodeAName. net_adm:ping(Node). #==> Check if node can connect with each other. If the response is Pang abort & fix the issue first & then comeback. -
harekumar renamed this gist
Dec 7, 2016 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
harekumar created this gist
Dec 7, 2016 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,28 @@ Let's say we need to join two node nodeA & nodeB. Then makesure both the node has the same erlang-cookies & basics ports are open i.e needed to communicate nodes internally. Steps: 1. Ensure all the node has the same erlang-cookies. 2. Now go to any one of the node let's say we wish to add NodeB to NodeA cluster. Then go to the NodeB & run the following command. Node = NodeAName. net_adm:ping(Node). #==> Check if node can connect with each other. If the response is Pang abort & fix the issue first & then comeback. application:stop(ejabberd). application:stop(mnesia). mnesia:delete_schema([node()]). # Delete old schema application:start(mnesia). mnesia:change_config(extra_db_nodes, [Node]). mnesia:change_table_copy_type(schema, node(), disc_copies). spawn(fun() -> lists:foreach(fun(Table) -> Type = call(Node, mnesia, table_info, [Table, storage_type]), mnesia:add_table_copy(Table, node(), Type) end, mnesia:system_info(tables)--[schema]) end). application:start(ejabberd). After running all the above command successfully. You can check if the node has been added to the cluster or not by running mnesia:info() command. This should list all the clustered node under "running db nodes" key.