Проблемы установки ejabberd на AWS - PullRequest
1 голос
/ 29 февраля 2020

Я пытаюсь установить ejabberd на компьютере EC2 AWS Linux 2, работающем на общедоступной c su bnet. Я сделал следующее:

  1. Назначил экземпляру EC2 Elasti c IP (52.22.184.194)
  2. Назначьте этот домен для EIP - ejabberddev.strax.co
  3. Изменено имя хоста машины на ejabberddev.strax.co
  4. Установлен ejabberd.
  5. Я получаю сообщение об ошибке:

    20:55:32.313 [error] Failed to open socket at 52.22.184.194:7777 for mod_proxy65_stream: can't assign requested address
    
  6. ejabberd пытается открыть сокет, используя IP-адрес AWS elasti c - это не будет работать.

  7. Я вошел в файл ejabberd.yml и добавлена ​​переменная ip, чтобы ejabberd использовал AWS приватный ip для macine.

    mod_proxy: 
      ip: 10.1.254.240
      access: local
      max_connections: 5
    
  8. Это исправление и ошибка, которые ejabberd смог найти.

  9. Почему-то пользователь, которого я ввел во время установки admin, и домен ejabberddev.strax.co не были в базе данных, поэтому я ввел его с помощью этой команды.

    ejabberdctl register admin ejabberddev.strax.co admin
    
  10. Это, похоже, сработало, поэтому я попытался войти в Интернет, используя эти учетные данные и URL-адрес, содержащий домен * 103 7 *: 5280 / admin

  11. При входе в систему произошла следующая ошибка:

    20:39:13.147 [error] CRASH REPORT Process <0.541.0> with 0 neighbours crashed with reason: bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860
    20:39:13.147 [error] Supervisor ejabberd_http_sup had child undefined started with {ejabberd_http,start_link,undefined} at <0.541.0> exit with reason bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860 in context child_terminated
    20:39:13.252 [info] (none) Accepted connection [::ffff:18.232.45.141]:54109 -> [::ffff:10.1.254.240]:5280
    20:39:13.252 [error] CRASH REPORT Process <0.542.0> with 0 neighbours crashed with reason: bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860
    20:39:13.252 [error] Supervisor ejabberd_http_sup had child undefined started with {ejabberd_http,start_link,undefined} at <0.542.0> exit with reason bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860 in context child_terminated
    20:39:13.459 [info] (<0.543.0>) Accepted connection [::ffff:18.232.45.141]:54110 -> [::ffff:10.1.254.240]:5280
    20:39:13.459 [error] CRASH REPORT Process <0.543.0> with 0 neighbours crashed with reason: bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860
    20:39:13.460 [error] Supervisor ejabberd_http_sup had child undefined started with {ejabberd_http,start_link,undefined} at <0.543.0> exit with reason bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860 in context child_terminated
    20:39:18.582 [info] (none) Accepted connection [::ffff:18.232.45.141]:54113 -> [::ffff:10.1.254.240]:5280
    20:39:18.582 [error] CRASH REPORT Process <0.544.0> with 0 neighbours crashed with reason: bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860
    20:39:18.582 [error] Supervisor ejabberd_http_sup had child undefined started with {ejabberd_http,start_link,undefined} at <0.544.0> exit with reason bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860 in context child_terminated
    20:39:48.712 [info] (none) Accepted connection [::ffff:18.232.45.141]:54122 -> [::ffff:10.1.254.240]:5280
    20:39:48.713 [error] CRASH REPORT Process <0.545.0> with 0 neighbours crashed with reason: bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860
    20:39:48.713 [error] Supervisor ejabberd_http_sup had child undefined started with {ejabberd_http,start_link,undefined} at <0.545.0> exit with reason bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860 in context child_terminated
    20:40:48.899 [info] (<0.547.0>) Accepted connection [::ffff:18.232.45.141]:54143 -> [::ffff:10.1.254.240]:5280
    20:40:48.900 [error] CRASH REPORT Process <0.547.0> with 0 neighbours crashed with reason: bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860
    20:40:48.900 [error] Supervisor ejabberd_http_sup had child undefined started with {ejabberd_http,start_link,undefined} at <0.547.0> exit with reason bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860 in context child_terminated
    20:45:49.083 [info] (none) Accepted connection [::ffff:18.232.45.141]:54241 -> [::ffff:10.1.254.240]:5280
    20:45:49.083 [error] CRASH REPORT Process <0.556.0> with 0 neighbours crashed with reason: bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860
    20:45:49.083 [error] Supervisor ejabberd_http_sup had child undefined started with {ejabberd_http,start_link,undefined} at <0.556.0> exit with reason bad argument in call to maps:from_list([html]) in ejabberd_http:apply_custom_headers/2 line 860 in context child_terminated
    

Не уверен, что это ошибка средства. Исходя из того, что я не могу даже установить пакет ejabberd и войти в систему, я думаю, что что-то идет не так в отношении использования AWS elasti c IP. Я не нашел никакого документа об установке ejabberd на AWS - любая помощь будет оценена.

Tim McClure

1 Ответ

1 голос
/ 02 марта 2020

20: 39: 13.147 [ошибка] У супервизора ejabberd_http_sup дочерний элемент undefined был запущен с {ejabberd_http, start_link, undefined} на <0.541.0> выходе с аргументом «причина плохой» при вызове карт: from_list ([html]) в строке ejabberd_ http:apply_custom_headers / 2 860

Эта ошибка была введена в ejabberd 20.02 при реализации других вещей и сейчас исправлена ​​только в git: https://github.com/processone/ejabberd/commit/00abf5d42c9b9c979b7ac69758a8f6745744f929

Вы можете либо применить это исправление к исходному коду, либо go вернуться к предыдущей версии ejabberd, либо дождаться следующей версии.

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...