How to enable mod_muc_log in old room?

I want to write logs of muc-chatrooms. But logs don't write. What is wrong? Please, help.
This is my config:

  mod_muc:
    host: "conference.myserver.com"
    access:
      - allow
    access_admin:
      - allow: admin
    access_create: muc_create
    access_persistent: muc_create
    history_size: 30
    default_room_options:
      allow_user_invites: true
      anonymous: true
      logging: true
      persistent: true
      public: true
  mod_muc_log:
    access_log: muc
    dirtype: plain
    dirname: room_jid
    file_format: html
    outdir: "/var/log/ejabberd/muclog"
    timezone: local
  mod_muc_admin: {}

Permissions of directory:
drwxrwsrwx 2 root adm 4096 muclog

UPDATE: logs write only for new created rooms, but not for old. How can i fix it?

You can configured mod_muc so

You can configured mod_muc so that the new rooms will have logging enabled by default.

Now you need to join your old room, and configure it specifically to enable logging in it. How to configure a room? This depends on the Jabber client you use, maybe if you use a simple client it doesn't allow to configure the room. Try Psi, Gajim or Tkabber: they allow you to configure a room when you join it, if you are admin of the room.

Syndicate content