Menu

Tree [c78dc8] master /
 History

HTTPS access


File Date Author Commit
 subprojects 2024-10-05 Petr Silhavy Petr Silhavy [a1dbb9] works
 .gitmodules 2024-10-05 Petr Silhavy Petr Silhavy [a1dbb9] works
 COPYING 2024-10-06 Petr Silhavy Petr Silhavy [3e3e51] clean up
 README.md 2024-10-06 Petr Silhavy Petr Silhavy [c78dc8] no console-colors lib
 consolecolors.d 2024-08-17 Petr Silhavy Petr Silhavy [ba505e] ADD
 dmd.ini 2024-08-17 Petr Silhavy Petr Silhavy [ba505e] ADD
 main.d 2024-10-06 Petr Silhavy Petr Silhavy [c78dc8] no console-colors lib
 meson.build 2024-10-06 Petr Silhavy Petr Silhavy [c78dc8] no console-colors lib
 py.d 2024-10-06 Petr Silhavy Petr Silhavy [c78dc8] no console-colors lib
 svc.d 2024-10-06 Petr Silhavy Petr Silhavy [c78dc8] no console-colors lib

Read Me

https://sourceforge.net/projects/loop-finder-s6/

Purpose

s6-rc service definition directories dependency debugger.

When s6-rc-compile https://skarnet.org/software/s6-rc/s6-rc-compile.html
exits with error, it gives you an error message - hint to the neighbors of bug,
but no exact pointer to problematic service if you are out of luck.
loop-finder-s6 is attempt to solve this problem, it loads services one by one
to directed acyclic graph, and after each load it checks if the graph
is still acyclic, if graph becomes cyclic problematic service found.

Bundles handling

loop-finder-s6 expands bundles : if service S depends on bundle B,
it scans for bundle B contents ( B0, B1 for example ) and internally
creates dependencies from S to B0 and from S to B1. So you may get
error message about such dependency S ==> B1 ( not found in your dependencies ).

Required software

D compiler ( dmd v2.109.1 tested ) https://dlang.org
Python3 ( 3.11 here ) https://python.org

Building

There is currently source code distribution only

Get code

$ git clone git://git.code.sf.net/p/loop-finder-s6/code loop-finder-s6-code
$ cd loop-finder-s6-code
$ meson setup [--prefix=/usr/local/whacks] . Build
$ ninja -C Build -j4
$ ninja -C Build install # (Optional)

Running

[./Build/] loop-finder-s6 [directory with service definition directories - default '/etc/s6-service']

Output

Sample message if loop found :

IS NOT DAG AFTER fsck-remount-root ==> static-devices

translation :

Service 'fsck-remount-root' depends on service 'static-devices' and this causes loop .

Miscelanous

loop-finder-s6 currently creates G.png, G.dot and G.ps (worth viewing) in current directory.

Exit code

0 if graph is acyclic
1 if graph is cyclic

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.