Error when running as non-root user for the first time.
To Reproduce
- Follow install instructions that build from source.
- Try to start tinyice using the supplied rc script.
Expected behavior
Just work.
Desktop (please complete the following information):
- OS: FreeBSD
- Browser N/A
- Version N/A
I have built and have successfully configured tinyice. That is not the issue. The issue is that when I install it for the first time, and try to run it as user 'tinyice', it fails with the following error:
2026-07-13T22:30:32.535Z FATAL server/server.go:129 Failed to initialize history manager: unable to open database file: out of memory (14)
I am running on FreeBSD using the following rc script:
#!/bin/sh
#
# Tinyice FreeBSD Service Script
#
# PROVIDE: tinyice
# REQUIRE: NETWORKING
# KEYWORD: shutdown
#
# Optional settings:
# tinyice_enable (YES/NO): Enable or disable the service.
# tinyice_host (IP): Service host.
# tinyice_port (port): Service port.
# tinyice_config (path): Path to application config directory.
# tinyice_user (user): User to run the service as.
# tinyice_group (group): Group to run the service as.
#
. /etc/rc.subr
name=tinyice
desc="Tinyice Streaming Server"
rcvar=tinyice_enable
load_rc_config $name
: ${tinyice_enable:="NO"}
: ${tinyice_user:="tinyice"}
: ${tinyice_group:="tinyice"}
: ${tinyice_host:="0.0.0.0"}
: ${tinyice_port:="8000"}
: ${tinyice_config:="/usr/local/etc/tinyice/tinyice.json"}
pidfile="/var/run/${name}/${name}.pid"
command="/usr/sbin/daemon"
command_args="-P ${pidfile} -H -o /var/log/${name}/${name}.log /usr/local/bin/${name} --config ${tinyice_config} --host ${tinyice_host} --port ${tinyice_port}"
start_precmd="tinyice_startprecmd"
tinyice_startprecmd()
{
mkdir -p /var/run/${name}
mkdir -p /var/log/${name}
chown -R ${tinyice_user}:${tinyice_group} /var/run/${name}
chown -R ${tinyice_user}:${tinyice_group} /var/log/${name}
}
run_rc_command "$1"
If, however I change the tinyice_user variable to root and start the server, then stop it, I can the change the user back to tinyice and it will work.
Why does it not work on the first service start though?
Error when running as non-root user for the first time.
To Reproduce
Expected behavior
Just work.
Desktop (please complete the following information):
I have built and have successfully configured tinyice. That is not the issue. The issue is that when I install it for the first time, and try to run it as user 'tinyice', it fails with the following error:
I am running on FreeBSD using the following rc script:
If, however I change the
tinyice_uservariable torootand start the server, then stop it, I can the change the user back totinyiceand it will work.Why does it not work on the first service start though?