2017-04-12 56 views
0

Heyo,ejabberd:似乎无法实现流管理

我有一个有点头疼试图让流管理(XEP-0198)在ejabberd 17.04工作在Ubuntu 16.10中,虽然我已经自ejabberd 17.03以来一直存在这个问题,尽管在任何地方搜索,但我似乎无法找到一个明确的答案,除了明确地将stream_management: true添加到我的配置或将其忽略并让该设置默认为true。但是,其中任何一个似乎都没有取得任何成功。

我唯一的迹象表明,流管理目前无法正常工作是通过Android应用程序对话,其中列出的扩展名为Unavailable,尽管应用程序从另一台服务器捡起扩展就好了。我似乎无法在ejabberd的日志中看到任何错误,除非有一次我导致了一个语法错误,这个错误从那以后就被纠正了。

这是我目前的配置(是的,我知道,它的改编形式的样本,我需要清理一些垃圾了):

## 
###    ejabberd configuration file 
###   Archipel Sample default condiguration 

define_macro: 
    'CERT_LOCATION': "/certs/live/social.diskseven.com/ejabberd.pem" 
    'DH_PARAMS':  "/certs/live/social.diskseven.com/dhparams.pem" 

###  ========= 
###  DEBUGGING 

# Increase this if you want sone insane erlang debug 
loglevel: 3 

###  ================ 
###  SERVED HOSTNAMES 

# Change it for you FQDN 
hosts: 
    - "xmpp.diskseven.com" 

###  =============== 
###  LISTENING PORTS 

listen: 
    - 
     #it's a good idea to put xmlrpc behing a reverse proxy 
     #because you can't use tls directly, make it listen to localhost 
     ip: "::1" 
     # and read the Security section on the wiki 
     port: 4560 
     module: ejabberd_xmlrpc 
     access_commands: 
      xmlrpcaccess: 
       all : [] 


## ejabberd c2s 
    - 
     ip: "::" 
     port: 5222 
     stream_management: true 
     module: ejabberd_c2s 
     resend_on_timeout: if_offline 

     ## 
     ## If you installed a SSL 
     ## certificate, specify the full path to the 
     ## file and uncomment this line: 
     ## 

     certfile: 'CERT_LOCATION' 
     starttls: true 
     starttls_required: true 
     ciphers: "EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH" 
     protocol_options: 
     - "no_sslv2" 
     - "no_sslv3" 
     - "no_tlsv1" 
     - "no_tlsv1_1" 
     max_stanza_size: 65536000 
     shaper: c2s_shaper 
     access: c2s 

## ejabbed s2s 
    - 
     ip: "::" 
     port: 5269 
     module: ejabberd_s2s_in 
     max_stanza_size: 65536000 

## ejabberd http/s and websocket/s 
    - 
     ip: "::" 
     port: 5280 
     module: ejabberd_http 
     request_handlers: 
     "/xmpp": ejabberd_http_ws 
     # if you want to use starttls with websock 
     # the URI will be wss:// 
     # please be sure that the certificate belong 
     # to a trusted AC in your browser 
     certfile: 'CERT_LOCATION' 
     dhfile: 'DH_PARAMS' 
     # tls: true 
     web_admin: true 
     http_bind: true 

###  === 
###  S2S 
s2s_access: all 
s2s_use_starttls: required 
s2s_certfile: 'CERT_LOCATION' #concantinated cert. 
s2s_dhfile: 'DH_PARAMS' 
s2s_ciphers: "EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH" 
s2s_protocol_options: 
- "no_sslv2" 
- "no_sslv3" 
- "no_tlsv1" 
- "no_tlsv1_1" 


## domain_certfile: Specify a different certificate for each served hostname. 
## 
##host_config: 
## "xmpp.diskseven.com": 
##  domain_certfile: 'CERT_LOCATION' 
## "conference.xmpp.diskseven.com": 
##  domain_certfile: 'CERT_LOCATION' 

###  ============== 
###  AUTHENTICATION 

auth_method: internal 

###  =============== 
###  TRAFFIC SHAPERS 

shaper: 
    # in B/s 
    normal: 1000 
    fast: 50000000 

###  ==================== 
###  ACCESS CONTROL LISTS 

acl: 
    admin: 
     user: 
      - "admin": "xmpp.diskseven.com" 
    local: 
     user_regexp: "" 


###  ============ 
###  ACCESS RULES 

access: 
    max_user_sessions: 
     all: 5 
    local: 
     local: allow 
    c2s: 
     blocked: deny 
     all: allow 
    c2s_shaper: 
     admin: none 
     all: fast 
    s2s_shaper: 
     all: fast 
    s2s_access: 
     all: allow 
    announce: 
     admin: allow 
    configure: 
     admin: allow 
    muc_admin: 
     admin: allow 
    muc_create: 
     local: allow 
    muc: 
     all: allow 
    pubsub_createnode: 
     all: allow 
    register: 
     all: deny 
    xmlrpcaccess: 
     admin : allow 

### Frequency of account registration 
registration_timeout: 600 

###  ================ 
###  DEFAULT LANGUAGE 

language: "en" 

###  ======= 
###  MODULES 

modules: 
    mod_adhoc: [] 
    mod_announce: 
     access: announce 
    mod_blocking: [] 
    mod_caps: [] 
    mod_client_state: [] 
    mod_carboncopy: [] 
    mod_configure: [] 
    mod_disco: [] 
    mod_http_bind: 
     max_inactivity: 400 # timeout valie for BOSH usefull for a large number of VM 
    mod_http_upload: [] 
    mod_irc: [] 
    mod_last: [] 
    mod_mam: [] 
    mod_muc: 
     host: "[email protected]@" 
     access: all 
     access_create: muc_create 
     access_persistent: muc_create 
     access_admin: muc_admin 
    mod_offline: [] 
    mod_privacy: [] 
    mod_private: [] 
    mod_pubsub: 
     access_createnode: pubsub_createnode 
     ignore_pep_from_offline: true 
     last_item_cache: false 
     max_items_node: 1000 
     plugins: 
      - "flat" 
      - "hometree" 
      - "pep" 
     pep_mapping: 
      "urn:xmpp:microblog:0": "mb" 
    mod_ping: 
     send_pings: true 
     ping_interval: 60 
     ping_ack_timeout: 30 
     timeout_action: kill 
    mod_register: 
     access: register 
    mod_roster: 
     versioning: true 
    mod_shared_roster: [] 
    mod_time: [] 
    mod_vcard: [] 
    mod_version: [] 
    mod_admin_extra: [] 
# mod_fail2ban: 
#  c2s_auth_ban_lifetime: 1300 
#  c2s_max_auth_failures: 5 
+0

android客户端也启用流管理?如果没有,那么你必须启用它的客户端也。 –

+0

我还没有发现切换流管理的应用程序中的任何设置,我想应用程序的开发人员已经启用它,因为它正在完全不同的服务器上正好接收扩展(正在运行的服务器别人)没有任何输入到我的应用程序。 –

回答

0

在ejabberd 17.03+流管理作为单独的模块来实现: mod_stream_mgmt。你应该已经阅读发布说明;)

+0

或者ejabberd的开发人员可以更新文档以反映新安装的情况。虽然你的不必要的居高临下的反应被注意到。 :^) –