I am writing to report a critical and reproducible stability issue with your DirettaHost when running it on both TinyCore Linux and piCorePlayer, especially during initial startup and device reconnection.
System Environment:
OS 1: TinyCore Linux v16.0
OS 2: piCorePlayer v10.0.0 (which is based on TinyCore RPI)
Software Version: DirettaHost(ReleaseNo: 143_7)
Problem Description:
After ssyncAlsa successfully finds a network target and performs a handshake, it fails and hangs due to a race condition while attempting to create and open the ALSA device node.
A key finding is that launching the application with the command strace -q -e openat ./ssyncAlsa results in a near-100% success rate for the initial startup. However, this is not a complete solution. If the target device disconnects and subsequently reconnects, ssyncAlsa still fails with the open error /dev/diretta-alsa_1 and hangs, necessitating a manual process restart. This proves that the same timing bug exists in both the initial startup and the reconnection logic of the application.
Technical Analysis & Key Findings:
Using the strace utility, we have pinpointed the root cause. After the application requests that the kernel create the /dev/diretta-alsa_1 device node, it does not wait for the operation to complete. It immediately attempts to open() the node, which fails with an -1 ENOENT (No such file or directory) error from the system.
Here is the key strace output during a failure:
openat(AT_FDCWD, "/dev/diretta-alsa", O_RDWR) = 4
openat(AT_FDCWD, "/dev/diretta-alsa_1", O_RDWR) = -1 ENOENT (No such file or directory)
And here is the full log from ssyncAlsa during a failure:
This bug appears to require a fix in the ssyncAlsa source code. After requesting the device node creation from the kernel, a brief, timed retry-loop should be implemented to wait for the device file to exist before attempting to open it. This fix needs to be applied to both the initial startup and the reconnection logic within the application.
I hope you can release a new version with this fix soon. Thank you for your time and consideration.
Y U様
お世話になっております。
Tiny Core Linux および piCorePlayer 環境にて、貴社製品 ssyncAlsa を使用しておりますが、初回起動時およびターゲットデバイスの再接続時に、再現性の高い深刻な安定性の問題が発生しておりますことをご報告いたします。
技術的な分析と主要なログ:
strace ツールによる追跡調査の結果、問題の根本原因を特定いたしました。プログラムは、カーネルに対して /dev/diretta-alsa_1 デバイスの作成を要求した直後、一切待機することなく、そのデバイスを open() しようと試みます。その結果、システムから -1 ENOENT (No such file or directory) エラーが返されます。
以下は失敗時の主要な strace の出力です。
openat(AT_FDCWD, "/dev/diretta-alsa", O_RDWR) = 4
openat(AT_FDCWD, "/dev/diretta-alsa_1", O_RDWR) = -1 ENOENT (No such file or directory)
Telomichi Namu
Dear Y U SAN,
I am writing to report a critical and reproducible stability issue with your DirettaHost when running it on both TinyCore Linux and piCorePlayer, especially during initial startup and device reconnection.
System Environment:
OS 1: TinyCore Linux v16.0
OS 2: piCorePlayer v10.0.0 (which is based on TinyCore RPI)
Software Version: DirettaHost(ReleaseNo: 143_7)
Problem Description: After ssyncAlsa successfully finds a network target and performs a handshake, it fails and hangs due to a race condition while attempting to create and open the ALSA device node.
A key finding is that launching the application with the command strace -q -e openat ./ssyncAlsa results in a near-100% success rate for the initial startup. However, this is not a complete solution. If the target device disconnects and subsequently reconnects, ssyncAlsa still fails with the open error /dev/diretta-alsa_1 and hangs, necessitating a manual process restart. This proves that the same timing bug exists in both the initial startup and the reconnection logic of the application.
Technical Analysis & Key Findings: Using the strace utility, we have pinpointed the root cause. After the application requests that the kernel create the /dev/diretta-alsa_1 device node, it does not wait for the operation to complete. It immediately attempts to open() the node, which fails with an -1 ENOENT (No such file or directory) error from the system.
Here is the key strace output during a failure:
And here is the full log from ssyncAlsa during a failure:
This bug appears to require a fix in the ssyncAlsa source code. After requesting the device node creation from the kernel, a brief, timed retry-loop should be implemented to wait for the device file to exist before attempting to open it. This fix needs to be applied to both the initial startup and the reconnection logic within the application.
I hope you can release a new version with this fix soon. Thank you for your time and consideration.
Y U様
お世話になっております。 Tiny Core Linux および piCorePlayer 環境にて、貴社製品 ssyncAlsa を使用しておりますが、初回起動時およびターゲットデバイスの再接続時に、再現性の高い深刻な安定性の問題が発生しておりますことをご報告いたします。
システム環境:
OS 1: TinyCore Linux v16.0
OS 2: piCorePlayer v10.0.0 (TinyCore ベース)
ソフトウェアバージョン: DirettaHost (ReleaseNo: 143)
問題の詳細: ssyncAlsa は、ネットワーク上のターゲットを発見し、ハンドシェイクに成功した後、ALSAデバイスノードを作成して開こうとする段階で、レースコンディション(競合状態)が原因で失敗し、プロセスがハングアップします。
特に重要な発見として、strace -q -e openat ./ssyncAlsa コマンドを使用してプログラムを起動すると、初回起動の成功率はほぼ100%になります。しかし、これは完全な解決策ではありません。ターゲットデバイスが一度切断され、その後再接続すると、ssyncAlsa はやはり open error /dev/diretta-alsa_1 というエラーを返してハングアップし、プロセスの手動再起動が必要となります。これは、プログラムの初回起動ロジックと再接続ロジックの両方に、同様のタイミングに関するバグが存在することを示唆しています。
技術的な分析と主要なログ: strace ツールによる追跡調査の結果、問題の根本原因を特定いたしました。プログラムは、カーネルに対して /dev/diretta-alsa_1 デバイスの作成を要求した直後、一切待機することなく、そのデバイスを open() しようと試みます。その結果、システムから -1 ENOENT (No such file or directory) エラーが返されます。
以下は失敗時の主要な strace の出力です。
そして、以下が ssyncAlsa の完全な失敗ログです。
このバグの修正は、ssyncAlsa のソースコードレベルで対応する必要があるかと思われます。カーネルにデバイスノードの作成を要求した後、デバイスファイルが実際に作成されるのを待機するための、タイムアウト付きの短いリトライループを実装する必要があると考えられます。この修正は、初回起動と再接続の両方のロジックに適用される必要があります。
この問題を修正したバージョンの早期リリースを期待しております。
ご確認のほど、よろしくお願い申し上げます。