ejabberd - Comments for "muc mangement" https://www.ejabberd.im/forum/29687/muc-mangement en thanks a lot, It takes a lot https://www.ejabberd.im/forum/29687/muc-mangement#comment-67686 <p>thanks a lot, It takes a lot of time to load the groups from mysql (single thread), Do you think reading groups(from mysql) through a few cpu(multi threading) will decrease the time?</p> Tue, 24 Oct 2017 05:10:42 +0000 nets comment 67686 at https://www.ejabberd.im When you say group, I guess https://www.ejabberd.im/forum/29687/muc-mangement#comment-67685 <p>When you say group, I guess you want to say MUC room.</p> <div class="quote-msg"> <div class="quote-author"><em>nets</em> wrote:</div> <p>Hello, I have 100.000 groups in ejabberd cluster can I balance groups on ejabberd nodes? </p></div> <p>Each room lives only in one node of the cluster: in the node where the user that created it is connected. That room is visible and can be joined from the other nodes, but lives only where it was created.</p> <p>From what I know, it isn't possible to move a room to another node.</p> <div class="quote-msg"> <div class="quote-author"><em>nets</em> wrote:</div> <p>or uses dedicated ejabberd servers for groups in cluster? </p></div> <div class="quote-msg"> <div class="quote-author"><em>nets</em> wrote:</div> <p>how can I see number of groups on each nodes? </p></div> <p>There is no easy way to get that information. If you apply this patch, you can see it in the WebAdmin:</p> <pre> diff --git a/src/mod_muc_admin.erl b/src/mod_muc_admin.erl index a8dbc24..62531ed 100644 --- a/src/mod_muc_admin.erl +++ b/src/mod_muc_admin.erl @@ -422,7 +422,8 @@ make_rooms_page(Host, Lang, {Sort_direction, Sort_column}) -&gt; &lt;&lt;"Persistent"&gt;&gt;, &lt;&lt;"Logging"&gt;&gt;, &lt;&lt;"Just created"&gt;&gt;, - &lt;&lt;"Room title"&gt;&gt;], + &lt;&lt;"Room title"&gt;&gt;, + &lt;&lt;"Node"&gt;&gt;], {Titles_TR, _} = lists:mapfoldl( fun(Title, Num_column) -&gt; @@ -467,6 +468,7 @@ build_info_room({Name, Host, Pid}) -&gt; S = get_room_state(Pid), Just_created = S#state.just_created, Num_participants = length(dict:fetch_keys(S#state.users)), + Node = node(Pid), History = (S#state.history)#lqueue.queue, Ts_last_message = @@ -486,7 +488,8 @@ build_info_room({Name, Host, Pid}) -&gt; Persistent, Logging, Just_created, - Title}. + Title, + Node}. get_queue_last(Queue) -&gt; List = p1_queue:to_list(Queue), @@ -502,7 +505,8 @@ prepare_room_info(Room_info) -&gt; Persistent, Logging, Just_created, - Title} = Room_info, + Title, + Node} = Room_info, [NameHost, integer_to_binary(Num_participants), Ts_last_message, @@ -510,7 +514,8 @@ prepare_room_info(Room_info) -&gt; misc:atom_to_binary(Persistent), misc:atom_to_binary(Logging), misc:atom_to_binary(Just_created), - Title]. + Title, + misc:atom_to_binary(Node)]. %%---------------------------- <pre></pre></pre> Mon, 23 Oct 2017 10:11:57 +0000 badlop comment 67685 at https://www.ejabberd.im