Published the 2021-05-28 on Stacy Harper's blog

Perfect ZNC Multi-Client Setup

By default, ZNC handle the playback. When no client is connected, it will store missed messages and play them back when you log in with an IRC client.

But if you got multiple IRC client in multiple device, login with one of them will make the others to never receive the messages.

clientbuffer is a module to fix that ! It will track what message all of your IRC clients received.

Configure clientbuffer

We have to compile it as it is not a base module.

$ apt install unzip znc-dev
$ curl -o
$ unzip
$ cd znc-clientbuffer-1.0.48/
$ znc-buildmod clientbuffer.cpp
$ mkdir -p /var/lib/znc/modules/
$ cp /var/lib/znc/modules/

Connect to ZNC

Use this as username: "username@CLIENTNAME/network"

Here CLIENTNAME will be used by clientbuffer to identify this client. Make it unique per client.

Enable clientbuffer on each network

/msg *controlpanel set AutoClearChanBuffer $me False
/msg *controlpanel set AutoClearQueryBuffer $me False
/msg *status LoadMod clientbuffer autoadd timelimit=86400

- AutoClearChanBuffer and AutoClearQueryBuffer must be toggled to false. It make ZNC to not mark every messages as read cause we want clientbuffer to handle them.

- autoadd make clientbuffer to automatically load a client when a new one connect itself.

- timelimit make the history size to not exceed one day. You could remove it if you want all history in all of your clients.

If this post inspired you, feels free to leave a comment !

The Cogitatis mailing list

This website is my Gemini Capsule mirror.
Embark now
Join the capsule gemini://