Initial setup - Error 500 - "POST" /yunohost/api/postinstall - yunohost-firewall

I tried to install yunohost in a LXC container.


The installation script worked without errors.
The script was started as root
Then during the initial setup in the browser, the error below came up.

Traceback (most recent call last):
  File "/usr/lib/moulinette/yunohost/", line 239, in firewall_reload
    process.check_output("iptables -w -L")
  File "/usr/lib/python3/dist-packages/moulinette/utils/", line 29, in check_output
    subprocess.check_output(args, stderr=stderr, shell=shell, **kwargs)
  File "/usr/lib/python3.7/", line 395, in check_output
  File "/usr/lib/python3.7/", line 487, in run
    output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command 'iptables -w -L' returned non-zero exit status 1.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/moulinette/interfaces/", line 484, in process
    ret = self.actionsmap.process(arguments, timeout=30, route=_route)
  File "/usr/lib/python3/dist-packages/moulinette/", line 600, in process
    return func(**arguments)
  File "/usr/lib/moulinette/yunohost/", line 380, in func_wrapper
    result = func(*args, **kwargs)
  File "/usr/lib/moulinette/yunohost/", line 282, in tools_postinstall
    firewall_upnp("enable", no_refresh=True)
  File "/usr/lib/moulinette/yunohost/", line 364, in firewall_upnp
  File "/usr/lib/moulinette/yunohost/", line 243, in firewall_reload
    prependlines(e.output.rstrip(), "> "),
  File "/usr/lib/python3/dist-packages/moulinette/utils/", line 62, in prependlines
    return "%s%s" % (prepend, prepend.join(lines))
TypeError: sequence item 0: expected str instance, bytes found

If I run diagnostics after setup, I get errors on

Hi, welcome to Yunohost!

LXC directly, or via Proxmox? I run Yunohosts on Proxmox on x86, mostly with no problems.
If you did not do any other configuration, it might be quicker to start another container and do a new install.
What hardware are you using, and how do you install Yunohost? I assume you apt-updated and upgraded before installing Yunohost, is that correct?

The LXC container runs on a Turris Omnia router.
Several LXC containers based on Debian are already running there.
e.g. ADGuard or my Unifi controller.

I have already tried several times to install yunohost on a new container, unfortunately without success.

Once I have created the container, I perform updates.
Additionally I have installed nano and curl.

i tried it via curl | bash.
The installation works.

Naively, the issue appears to be related to iptables and my first guess would be that the container must be priviledged to be able to apply iptable rules

I have executed the script with root rights.
However, according to the error message for the redis service, it says Can't open the log file: Read-only file system

but it is not a Read-only file system

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.