There is no exec >, no > redirection, and no tee anywhere in the launch script.
Root cause
Found in app/consapp/rtkrcv/rtkrcv.c:
#define STATFILE "rtkrcv_%Y%m%d%h%M.stat" /* solution status file */
#define TRACEFILE "rtkrcv_%Y%m%d%h%M.trace" /* debug trace file */
#define LOGFILE "rtkrcv_%Y%m%d%h%M.log" /* Deamon log file */
And later:
static void deamonise(void)
{
...
}
...
if (deamon) deamonise();
The deamonise() function unconditionally creates these files when --deamon is set, regardless of .conf settings or command-line flags.
Workarounds
Since filenames and behavior are hardcoded, current options are:
- Change
WorkingDirectory (in systemd or shell) to isolate these files in a dedicated folder
- Periodic cleanup via cron or logrotate:
find /path/to/rtklib -maxdepth 1 -name "rtkrcv_*.log" -mtime +7 -delete
find /path/to/rtklib -maxdepth 1 -name "rtkrcv_*.stat" -mtime +7 -delete
find /path/to/rtklib -maxdepth 1 -name "rtkrcv_*.trace" -mtime +7 -delete
- Avoid
--deamon — daemonize externally via nohup ... &, setsid, or systemd Type=simple. The hardcoded files are only created in deamon mode.
- Patch the source — comment out the relevant lines in
deamonise() or redirect to /dev/null in a custom build
Suggested improvements
Note on the --deamon spelling
For reference: the flag is spelled --deamon, not --daemon. This typo originates from the upstream RTKLIB by T. Takasu and is preserved in demo5 for backward compatibility. Passing --daemon is silently ignored by the argument parser:
else if (!strcmp(argv[i], "--deamon")) deamon=1;
Accepting both spellings as aliases would be a minor but welcome improvement.
Happy to submit a PR for any of the above if there's interest in the direction.
There is no
exec >, no>redirection, and noteeanywhere in the launch script.Root cause
Found in
app/consapp/rtkrcv/rtkrcv.c:And later:
The
deamonise()function unconditionally creates these files when--deamonis set, regardless of.confsettings or command-line flags.Workarounds
Since filenames and behavior are hardcoded, current options are:
WorkingDirectory(in systemd or shell) to isolate these files in a dedicated folder--deamon— daemonize externally vianohup ... &,setsid, or systemdType=simple. The hardcoded files are only created in deamon mode.deamonise()or redirect to/dev/nullin a custom buildSuggested improvements
rtkrcv -houtput--deamon-quietor via.confoption)deamon-logdir, or reusefile-tracefile/file-statfile)app/consapp/rtkrcv/readme.txtand/or the wikiNote on the
--deamonspellingFor reference: the flag is spelled
--deamon, not--daemon. This typo originates from the upstream RTKLIB by T. Takasu and is preserved in demo5 for backward compatibility. Passing--daemonis silently ignored by the argument parser:Accepting both spellings as aliases would be a minor but welcome improvement.
Happy to submit a PR for any of the above if there's interest in the direction.