What version of ejabberd are you using?17.07
What operating system (version) are you using?Win7
How did you install ejabberd (source, package, distribution)?
Installing ejabberd with Binary Installer
I want adding 20k users to Ejabberd enternal DB (Mnesia).What should I do?
From ejabberdctl live or ejabberdctl debug:
lists:foreach(fun(I) -> N = integer_to_binary(I), ejabberd_auth:try_register(<<"user", N/binary>>, <<"localhost">>, <<"pass", N/binary>>) end, lists:seq(1, 20000)).
1) This will create user1...user20000 with passwords pass1...pass20000
2) Replace "localhost" with your current virtual host
3) The command is database agnostic, you can use it for SQL too.
Thanks dear zinid.
Output:
`C:\Program Files\ejabberd-17.07\bin>ejabberdctl lists:foreach(fun(I) -> N = integer_to_binary(I), ejabberd_auth:try_register(<<"user", N/binary>>, <<"localhost">>, <<"pass", N/binary>>) end, lists:seq(1, 20000)).
<< was unexpected at this time.`
No.
Run ejabberd, then from command line run ejabberdctl debug, you will get into remote Erlang shell where you should run this command.
Dear zinid : I apologize to say I,m amature in Ejabberd, I 've not work with Erlang anytime. I don't know where I run this script?
Then why do you need to create 20k accounts? To stress load? Configuring stress loading tool is much harder than to use ejabberdctl. Also, it's pointless to perform stress loading on Windows, ejabberd is not expected to work great in this OS. Furthermore, Mnesia is not designed for high-load. You're doing almost everything wrong.
I'm researching for comparing Ejabberd and Openfire.So I decided to try some tests.For example the time of broadcast to recieve a message to 20k users was 35sec in Openfire.Then I wanted to try Ejabberd, but I faced with a problem in adding 20k users. After days and some researching I underestood Ejabberd is better than Openfire.but we are a Dotnet team and I should bring some reson to my boss the he would be agree using Ejabberd on Linux Server.The first reson would be DB.because Ejabberd doesn't work with sql on Win.So I force using MySql.Is it ok if you help me to find another resons?
Thanks a lot..
I think I have no reason for you, alas. In your situation Openfire fits you more:
1) It's written in a popular language your developers can deal with more easily
2) It works great in Windows due to JVM, while BEAM (Erlang VM) has some limitations on Windows
3) ejabberd's support for MSSQL is sub-optimal, cannot say about Openfire, but I think there are great MSSQL drivers for Java unlike Erlang
4) Your devs/admins are probably not very comfortable with command line or configuration files, since the common practice in Windows is to provide GUI for configuration, which Openfire has and ejabberd doesn't have (well, not as great as in Openfire).
5) I'm not great at advertisement :disappointed:
Dear zinid thanks very much for you responding
OK, maybe I will help you a little, by providing pros of using ejabberd, so your management can weigh out pros and cons:
1) ejabberd is very popular, has large community, having around half of installation world-wide
2) On this bugtracker we try our best to handle every issue as long as the issue is defined well (with all information we need)
3) it can scale almost infinitely, all largest installations have ejabberd (including Whatsapp, although severely customized)
4) Even though you need to spend more time learning on how to configure ejabberd and other components (like OS or databases), this will be rewarded: you will have eventually a service with very little need to maintain: lots of installations have ancient ejabberd versions because they forgot about them - it just works :)
5) customizing ejabberd is not that hard as it can be seen at a first glance:
a. there is the developers guide
b. Erlang is a simple language, much simpler than Java and is designed for the exactly single task: massive concurrency. I think it's as simple as python or TCL/Tk if you accept functional paradigm (and in my opinion, popular OOP concept fits terribly in massive concurrency model, that's why I had a choice between Openfire or ejabberd developement and I chose the latter)
c. We always answer developers' questions on this github issue tracker, even the simplest ones: you can check - I personally skipped no question regarding ejabberd customization as long as the question is well defined.
6) After all, if you don't want to mess with linuxes or ejabberd configuration, ProcessOne is providing SaaS: you can check prices and decide what will be cheaper eventually: paying for SaaS or having a stand-alone dev team
Thanks.
Good Luck.
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.