- Restart Mysql In Windows
- Homebrew Restart Mysql App
- Homebrew Restart Mysql Server
- Homebrew Restart Mysql Server
- Homebrew Restart Mysql Command
There are several ways to install ejabberd:
Automate MySQL backups: autopano-sift-c: 2.5.1: Find control points in overlapping image pairs: autopep8: 1.5.6: Automatically formats Python code to conform to the PEP 8 style guide: autopsy: 2.24: Graphical interface to Sleuth Kit investigation tools: autorest: 3.1.3: Swagger (OpenAPI) Specification code generator: autossh: 1.4g. Here are solutions, most of which require a restart of mysql. Recreate your log files (Delete and restart mysql) Resize your log files (MySql 5.6+ will regenerate the file for you) If you are doing some type of a data migration, make sure you have correctly migrated the right file and given it permissions as others have already stated.
- Quick Start with Binary Installers – recommended when starting development on localhost
- Install from Source Code – recommended for advanced users and developers
- Install with Operating System specific packages – recommended for sysops
Homebrew is a package manager for macOS that aims to port the many Unix & Linux software that is not easily available or compatible. Homebrew installation is simple and the instruction is available on its website. Once you have Homebrew installed, open Terminal. Run brew install ejabberd. This should install the latest or at.
Additionally, this section covers other topics:
- Starting ejabberd – manual and automatically
- Post-install operations – register users, admin, and setting database
Quick Start
The Binary Installer will deploy and configure a full featuredejabberd server and does not require any extra dependencies. Itincludes a stripped down version of Erlang. As such, when usingejabberd installer, you do not need to install Erlang separately.
These tutorials assume installation on localhost
for development purposes.In this document, when mentioning ejabberd-YY.MM
, we assume YY.MM
is the release number, for example 18.01. Also note that the installerscripts support many options useful for production or unattended, scripted installation.You can read more on installer options on unattended installation.
Install on Windows
- Go to ejabberd official download page on ProcessOne website.
- Download the installer for Windows 7 / 2008 64-bits or newer: 'Windows Installer'.
- Double-click the
ejabberd-YY.MM-installer.exe
to start the installer. - On the Windows Security dialog, Allow this application to install.
- Select the installer language you prefer, then click 'Next' to go through necessary installation steps:
- accepting the license agreement,
- selecting the installation directory,
- defining the XMPP domain: by default, it's set to the name of your computer on the local network. if unsure, type
localhost
here, - setting the administrator username,
- setting the administrator password,
- selecting if this ejabberd instance will be part of a cluster: for simple local install, just select 'No',
- start the installation,
- when asked by the Windows Firewall prompt, you can both times click 'Cancel',
- After successful install, you should see on your Desktop two new shortcuts: 'Start ejabberd' and 'Stop ejabberd'. To start or stop ejabberd, righ-click on each shortcut and select 'Run as Administrator', then confirm the Windows dialog by clicking 'Yes'.
- After starting ejabberd, a welcome screen should open in your default browser. You can go to the web dashboard at
http://localhost:5280/admin/
and fill the username field with the full account JID, for exampleadmin@domain
(oradmin@localhost
as above). Then fill the password field with that account'spassword
. The next step is to get to know how to configure ejabberd. - If something goes wrong during the installation, and you would like to start from scratch, you will find the ejabberd
uninstall.exe
in the directory where it was installed. By default, that'sProgram Filesejabberd-YY.MMuninstall.app
. The uninstaller will stop your ejabberd server and remove all its files. Log files may be left behind, so to completely remove ejabberd, just delete its main folder.
Install on Linux
- Go to ejabberd official download page on ProcessOne website.
- Download the 'Linux x86 64-bits Installer'.
- Right-click on the downloaded file and select 'Properties'. Click on the 'Permissions' tab and tick the box that says 'Allow executing file as program'.
Now you are able to double-click the file to execute it and start the installer.You can also set the installer as executable and start it using the command line:
Select the installer language you prefer, then click 'Forward' to go through necessary installation steps:
- accepting the license agreement,
- selecting the installation directory,
- defining the XMPP domain: by default, it's set to the name of your computer on the local network. if unsure, type
localhost
here, - setting the administrator username,
- setting the administrator password,
- selecting if this ejabberd instance will be part of a cluster: for simple local install, just select 'No',
- start the installation,
After successful installation, let's launch ejabberd using the Terminal. In the command line, go to the installation folder and execute
./bin/ejabberdctl live
. This will start ejabberd in an interactive live mode with some useful messages printed in the Terminal.Now you can go to the web dashboard at
http://localhost:5280/admin/
and fill the username field with the full account JID, for exampleadmin@domain
(oradmin@localhost
as above). Then fill the password field with that account'spassword
. The next step is to get to know how to configure ejabberd.If something goes wrong during the installation, and you would like to start from scratch, you will find the ejabberd
uninstall
in the directory where it was installed.
Install on macOS
Using Binary Installer
Before you begin installing ejabberd, make sure your Mac allows apps from identified developers. To do this, go to your Mac Preferences, Security & Privacy and select 'Allow apps downloaded from: App Store and identified developers'. Then you can download ejabberd and proceed with installation:
- Go to ejabberd official download page on ProcessOne website.
- Download the 'Mac OS X Intel Installer'. If your system is older than the minimal requirements specified, search the ejabberd Download Archive for an appropriate version.
- Double-click the
ejabberd-YY.MM-osx-installer.app.zip
to unpack the archive. - Double-click the
ejabberd-YY.MM-osx-installer.app
to start the installer. - Confirm the security dialog by clicking 'Open'.
- If you see a dialog titled 'App is not optimized for your Mac' you can safely discard it – it only applies to the installer, not ejabberd itself.
- Select the installer language you prefer, then click 'Next' to go through necessary installation steps:
- accepting the license agreement,
- selecting the installation directory,
- defining the XMPP domain: by default, it's set to the name of your computer on the local network. if unsure, type
localhost
here, - setting the administrator username,
- setting the administrator password,
- selecting if this ejabberd instance will be part of a cluster: for simple local install, just select 'No',
- start the installation,
- Once the installation script finishes, it attempts to start ejabberd. You may see a prompt asking to allow incoming connections to
beam.smp
. Unless you allow, the installation cannot finish successfully. - If something goes wrong during the installation, and you would like to start from scratch, you will find the ejabberd
uninstall.app
in the directory where it was installed. By default, that's/Apllications/ejabberd-YY.MM/uninstall.app
. The uninstaller will stop your ejabberd server and remove all its files. Log files are left behind, so to completely remove ejabberd, just delete its main folder.
Binary Installers of ejabberd prior to version 18.01 did not have an Apple Developer signature.If macOS complains when you try to install ejabberd older than 18.01 with binary installer withmessage 'ejabberd-installer is damaged and can’t be opened' – then you need to temporarilydisable gatekeeper to be able to install ejabberd:
Using Homebrew
Homebrew is a package manager for macOS that aims to port the many Unix & Linux software that is not easily available or compatible. Homebrew installation is simple and the instruction is available on its website.
- Once you have Homebrew installed, open Terminal. Run
brew install ejabberd
. This should install the latest or at most the one-before-latest version of ejabberd. The installation directory should be reported at the end of this process, but usually the main executable is stored at/usr/local/sbin/ejabberdctl
. - Start your ejabberd by running
/usr/local/sbin/ejabberdctl live
. This interactive mode prints useful messages in the Terminal. The default domain used by Homebrew's ejabberd islocalhost
. - Create an admin account by running
/usr/local/sbin/ejabberdctl register admin localhost password
. This creates an accountadmin@localhost
with the specifiedpassword
. - Now you can go to the web dashboard at
http://localhost:5280/admin/
and fill the username field with the full account JID, for exampleadmin@localhost
, then fill the password field with that account'spassword
. Without configuration there's not much to see here, therefore the next step is to get to know how to configure ejabberd.
Install from Source Code
The canonical form for distribution of ejabberd stable releases isthe source code package. Compiling ejabberd from source code isquite easy in *nix systems, as long as your system have all thedependencies.
Requirements
To compile ejabberd on a ‘Unix-like’ operating system, you need:
- GNU Make
- GCC
- Libexpat 1.95 or higher
- Libyaml 0.1.4 or higher
- Erlang/OTP 19.3 or higher. We recommend using Erlang OTP 21.2.
- OpenSSL 1.0.0 or higher, for STARTTLS, SASL and SSL encryption.
- Zlib 1.2.3 or higher, for Stream Compression support (
XEP-0138
). Optional. - PAM library. Optional. For Pluggable Authentication Modules (PAM). See PAM Authentication section.
- ImageMagick’s Convert program and Ghostscript fonts. Optional. For CAPTCHA challenges. See section CAPTCHA.
Downloading
Released versions of ejabberd are available on ProcessOneejabberd official download page.
Alternatively, the latest development source code can be retrievedfrom the Git repository using the commands:
Compilation
To compile ejabberd execute the commands:
This tells the configuration to prepare the installed programto run with a user called ejabberd, so please create that useror tell to use another local user.It isn't recommended to run ejabberd with root
user.
Note: To build ejabberd, you will need Internet access, as dependencies will be downloaded depending on the selected options.
The build configuration script allows several options. To get the fulllist run the command:
Options
There are many options to modify the default compilation behaviour:
-–bindir=/
: Specify the path to the user executables(whereepmd
andiex
are available).-–prefix=/
: Specify the path prefix where the files will becopied when running themake install
command.-–enable-user[=USER]
: Allow this normal system user to executethe ejabberdctl script (see section ejabberdctl), read theconfiguration files, read and write in the spool directory, read andwrite in the log directory. The account user and group must exist inthe machine before runningmake install
. This account doesn't needan explicit HOME directory, because/var/lib/ejabberd/
will beused by default.-–enable-group[=GROUP]
: Similar to the previous option, but forsystem groups.–-enable-all
: Enable many of the database and dependenciesoptions described here, this is useful for Dialyzer checks:--enable-debug --enable-elixir --enable-mysql --enable-odbc--enable-pam --enable-pgsql --enable-redis --enable-sip--enable-sqlite --enable-stun --enable-tools --enable-zlib–-disable-debug
: Compile without+debug_info
.–-enable-elixir
: Build ejabberd with Elixir extension support.–-disable-erlang-version-check
: Don't check Erlang/OTP version.-–enable-full-xml
: Use XML features in XMPP stream (ex:CDATA). This requires XML compliant clients).–-enable-hipe
: Compile natively with HiPE. This is anexperimental feature, and not recommended.-–enable-lager
: Use lager Erlang logging tool instead ofstandard error logger.--enable-latest-deps
: Makes rebar use latest versions ofdependencies developed alongside ejabberd instead of versionspecified in rebar.config. Should be only used when developingejabberd.-–enable-mssql
: Enable Microsoft SQL Server support, thisoption requires --enable-odbc (see [Supported storages][18]).-–enable-mysql
: Enable MySQL support (see [Supported storages][18]).-–enable-new-sql-schema
: Use new SQL schema.-–enable-odbc
: Enable pure ODBC support.-–enable-pam
: Enable the PAM authentication method (see PAM Authentication section).-–enable-pgsql
: Enable PostgreSQL support (see [Supported storages][18]).-–enable-redis
: Enable Redis support to use for externalsession storage.-–enable-roster-gateway-workaround
: Turn on workaround forprocessing gateway subscriptions.-–enable-sip
: Enable SIP support.-–enable-sqlite
: Enable SQLite support (see [Supported storages][18]).-–disable-stun
: Disable STUN/TURN support.--enable-system-deps
: Makes rebar use locally installeddependencies instead of downloading them.-–enable-tools
: Enable the use of development tools.-–disable-zlib
: Disable Stream Compression (XEP-0138) using zlib.
Installation
To install ejabberd in the destination directories, run the command make install
.
Note that you probably need administrative privileges in the system toinstall ejabberd.
The files and directories created are, by default:
/etc/ejabberd/
: Configuration directory:ejabberd.yml
: ejabberd configuration fileejabberdctl.cfg
: Configuration file of the administration scriptinetrc
: Network DNS configuration file for Erlang
/lib/ejabberd/
:ebin/
: Erlang binary files (*.beam)include/
: Erlang header files (*.hrl)priv/
: Additional files required at runtimebin/
: Executable programslib/
: Binary system libraries (*.so)msgs/
: Translation files (*.msgs)
/sbin/ejabberdctl
: Administration script (see section ejabberdctl)./share/doc/ejabberd/
: Documentation of ejabberd/var/lib/ejabberd/
: Spool directory:.erlang.cookie
: Erlang cookie file (see section cookie)acl.DCD, ...
: Mnesia database spool files (*.DCD, *.DCL, *.DAT)
/var/log/ejabberd/
: Log directory (see section [logfiles]):ejabberd.log
: ejabberd service logerlang.log
: Erlang/OTP system log
Specific notes
BSD
Restart Mysql In Windows
The command to compile ejabberd in BSD systems is gmake
.
macOS
If compiling from sources on macOS, you must configure ejabberd to use custom OpenSSL, Yaml, iconv.The best approach is to use Homebrew to install your dependencies, thenexports your custom path to let configure and make be aware of them.
Install with OS specific packages
Some Operating Systems provide a specific ejabberd package adaptedto the system architecture and libraries. It usually also checksdependencies and performs basic configuration tasks like creating theinitial administrator account. Some examples are Debian andGentoo. Consult the resources provided by your Operating System formore information.
ProcessOne now provides RPM and DEB all in one packages as well, sinceejabberd version 15.06. This is self-sufficient packages alsocontaining a minimal Erlang distribution. It ensures that it does notinterfere with your existing Erlang version. This is also a good wayto make sure ejabberd will run with the latest Erlang version. You candownload the packages from theejabberd official download page.
Starting ejabberd
ejabberd can be started manually at any time, or automatically bythe operating system at system boot time.
To start and stop ejabberd manually, use the desktop shortcutscreated by the installer. If the machine doesn't have a graphicalsystem, use the scripts ’start’ and ’stop’ in the ’bin’ directorywhere ejabberd is installed.
You can also use the ejabberdctl
command line administration script tostart and stop ejabberd. If you provided the configure option–enable-user=USER
(see compilation options), you can execute ejabberdctl
with either that system account or root.
Usage example:
If ejabberd doesn't start correctly and a crash dump file isgenerated, there was a severe problem. You can try starting ejabberdwith the script bin/live.bat
in Windows, or with the commandbin/ejabberdctl live
in other Operating Systems. This way you seethe error message provided by Erlang and can identify what is exactlythe problem.
The ejabberdctl
administration script is included in the bin
directory. Please refer to the sectionejabberdctlfor detailsabout ejabberdctl
, and configurable options to fine tune the Erlangruntime system.
Homebrew Restart Mysql App
Autostart on Linux
On a *nix system, create a system user called 'ejabberd', give it write accessto the directories database/
and logs/
, and set that as home.
If you want ejabberd to be started as daemon at boot time with that user,copy ejabberd.init
from the bin
directory to something like /etc/init.d/ejabberd
.Then you can call /etc/inid.d/ejabberd start
to start the server.
Or if you have a systemd distribution:
Homebrew Restart Mysql Server
- copy
ejabberd.service
to/etc/systemd/system/
- run
systemctl daemon-reload
- run
systemctl enable ejabberd.service
- To start the server, you can run
systemctl start ejabberd
When ejabberd is started, the processes that are started in the systemare beam
or beam.smp
, and also epmd
. For more informationregarding epmd
consult the section relating toepmd.
Autostart on Windows
The Windows installer also adds ejabberd as a system service, and ashortcut to a debug console for experienced administrators. If youwant ejabberd to be started automatically at boot time, go to theWindows service settings and set ejabberd to be automaticallystarted. Note that the Windows service is a feature still indevelopment, and for example it doesn't read the fileejabberdctl.cfg
.
On Microsoft Windows, the Erlang processes for ejabberd are namederl.exe
and epmd.exe
.
Post-install operations
Homebrew Restart Mysql Server
Administration account
ejabberd binary installer prompts you for an admin account, so in that case,you can probably skip this step.
However, if you use another way of installing ejabberd you may need to create anadmin XMPP account.
Homebrew Restart Mysql Command
You need an XMPP account with administrative privileges toenter the ejabberd Web Admin. Here are the steps to create it:
Register an XMPP account on your ejabberd server, for example
admin1@example.org
. There are two ways to register an XMPPaccount:Using an XMPP client and In-Band Registration (see section (/admin/configuration/modules/#mod-register)).
Using
ejabberdctl
(see section ejabberdctl):
Edit the ejabberd configuration file to give administrationrights to the XMPP account you created:
You can grant administrative privileges to many XMPP accounts, andalso to accounts in other XMPP servers.
Restart ejabberd to load the new configuration.
Open the Web Admin (usually
http://localhost:5280/admin/
) in your favouritebrowser. Make sure to enter the full JID as username (in thisexample:admin1@example.org
). The reason that you also need toenter the suffix is due to ejabberd’s virtual hosting support. You canmanage several XMPP domains on a single instance.
Backend database
By default, ejabberd uses its own database to store runtime data. In many casesyou may need to let ejabberd use an external SQL database.Supported SQL backends are MySQL, PostgreSQL, SQlite, MS SQL.
When using external database backend, ejabberd does not create schema and tablesby itself. You must create the schema before you run ejabberd.
If installing ejabberd from sources, you will find sql script for your backendin the installation directory. By default:
/usr/local/lib/ejabberd/priv/sql
If installing ejabberd from Process-One installer, the init scripts are locatedin the ejabberd's installation path under
<base>/lib/ejabberd*/priv/sql
See ejabberd SQL Database Schemafor details on database schemas.