Chris's Wiki :: blog/linux/LinuxSATANames Commentshttps://utcc.utoronto.ca/~cks/space/blog/linux/LinuxSATANames?atomcommentsDWiki2017-05-14T21:25:54ZRecent comments in Chris's Wiki :: blog/linux/LinuxSATANames.By Georg Sauthoff on /blog/linux/LinuxSATANamestag:CSpace:blog/linux/LinuxSATANames:fd00912d81e15c9f3833e515ef47c0f33e1a662fGeorg Sauthoffhttps://gms.tf/<div class="wikitext"><blockquote><p>(s)ATA port and disk names, which look like 'ata5' [..] These names do not appear in sysfs at all as far as I can see; they only appear in kernel messages.</p>
</blockquote>
<p>Actually, they do - under /sys/devices.</p>
<p>Basically you can grep for paths that match a pattern like '/ata[0-9]/.*/sd[a-zA-Z]$'</p>
<p>See also my answer on Unix-SE: <a href="https://unix.stackexchange.com/a/13988/1131">https://unix.stackexchange.com/a/13988/1131</a></p>
<p>I don't know if 2011-ish kernels already exposed this sysfs structure. FWIW, at that time I also searched for something like this and didn't notice it.</p>
</div>2017-05-14T21:25:54Z