4 ms·
> so you can read them with any tool what tool can't you read them with? Why is the fs the fundamental unifying abstraction, as opposed to pipes? > doesn't al
by Chris2048 5y ago
> so you can read them with any tool
what tool can't you read them with? Why is the fs the fundamental unifying abstraction, as opposed to pipes?
> doesn't allow you to do all the things you can do with a real file
like what?
- regularfry 5y agoPipes are files. From the point of view of the consuming process, you're just reading from a file descriptor. Files are more fundamental than pipes.
- Chris2048 5y agoIf lmm shared this opinion, then there should be no problem, as systemd logs can be piped.
- regularfry 5y agoAll pipes are files. Not all files are pipes.
- Chris2048 5y agoSo, back to the original question: what's the problem here? what is disallowed? Also: If all pipes are files, but not all files are pipes, it would seems to me that files are more restrictive. That, and the extra steps you need to take to avoid needless IO.
- regularfry 5y agoI recommend https://www.amazon.co.uk/dp/013937681X/ref=cm_sw_r_cp_apa_glt_fabc_TBGRZ541TK3YAD9G72FW https://www.amazon.co.uk/dp/013937681X/ref=cm_sw_r_cp_apa_gl... as an introduction to the fundamental concepts of the Unix filesystem. Certainly a better education than I could give here.
- Chris2048 5y agoThe original post was: that doesn't allow you to do all the things you can do with a real file I'm not interested in what the differences between a pipe and a file are (I know) - I'm interested in why OP thinks they are relevant in this specific context/case; particularly in context of my statement: seems to me that files are more restrictive Is, for example, a sticky bit relevant to systemd log files?
- lmm 5y agoYou can't do random access through a pipe, so you can't binary search for it, or if you have some kind of probabilistic skip-sampling tool that won't work. Pipes don't have names, so anything that expects to work with them won't work. You can't re-read the same file. I don't know all the things you might want to do, but that's kind of my point - most things work with and expect files, and so if you want to be able to count on being able to use other unknown tools, a file is what you need.