News for hackers. Stuff that matters.
Re:Posix Has Become Outdated (2016) [pdf] by kccqzy on Saturday February 11, 2017 @04:43AM (#13621942)
That's what majority of computer users (smartphones included) use though. As for developer-oriented CLI tools, I've also seen more and more GNU-isms and macOS-isms creeping in.
Re:Posix Has Become Outdated (2016) [pdf] by tmalsburg2 on Saturday February 11, 2017 @06:45AM (#13622208)
Counter example: Almost everyone uses the Apache webserver when they browse the web, but hardly anyone even knows what that is. We could easily compile a long list of similar crucial infrastructure software that virtually everyone is using and that doesn't have graphical user interfaces.
Re:Posix Has Become Outdated (2016) [pdf] by johannes1234321 on Saturday February 11, 2017 @09:50AM (#13622822)
Even if everybody is using Apache: Apache httpd doesn't use POSIX but APR (Apache Portable Runtime) which removes the POSIX-dependenc from the core of httpd.
Re:Posix Has Become Outdated (2016) [pdf] by pjmlp on Saturday February 11, 2017 @07:06AM (#13622258)
How much of Apache is pure POSIX and how much are #ifdef around OS specific APIs?
Re:Posix Has Become Outdated (2016) [pdf] by nickpsecurity on Saturday February 11, 2017 @11:19AM (#13623211)
Apache uses the Apache Portable Runtime:

https://en.wikipedia.org/wiki/Apache_Portable_Runtime

That's one of the competitors to POSIX for application portability. Unlike POSIX, it was totally open as well vs people telling me The Open Group will sell me a copy of full standard.

Re:Posix Has Become Outdated (2016) [pdf] by mikekchar on Saturday February 11, 2017 @10:03AM (#13622885)
Interestingly, I took a random tour through the source code and didn't find a single OS specific API. Which is not to say that the code was intrinsically POSIX specific. It is a surprisingly good example of multi-platform code. The #ifdefs that I saw were all to do with defining functionality from scratch if it didn't exist rather than the more usual massively indented list of platform specific hacks. Although I had fairly high expectations, I was fairly surprised at how nice the code was.

I didn't spend all that much time, so I'm sure I missed a lot, but I recommend taking a look for yourself as it is quite interesting.

Re:Posix Has Become Outdated (2016) [pdf] by ycmbntrthrwaway on Saturday February 11, 2017 @06:56AM (#13622236)
Count sendmail in:

> There is some sort of perverse pleasure in knowing that it's basically impossible to send a piece of hate mail through the Internet without its being touched by a gay program. That's kind of funny.

Re:Posix Has Become Outdated (2016) [pdf] by nj923f on Saturday February 11, 2017 @11:31AM (#13623272)
sendmail is dead at this point though.
Re:Posix Has Become Outdated (2016) [pdf] by ci5er on Saturday February 11, 2017 @02:03PM (#13624127)
How so? As recently as 2015, sendmail, Microsoft Exchange Server, Postfix, and Exim together represented over 90% of SMTP service.

Or is this one of those pre-emptive "called it first!" kind of comments?

Re:Posix Has Become Outdated (2016) [pdf] by yosamino on Saturday February 11, 2017 @02:34PM (#13624290)
I think the point is that out of these 90% not so many ones are "sendmail" anymore.
Re:Posix Has Become Outdated (2016) [pdf] by justinator on Saturday February 11, 2017 @12:37PM (#13623645)
As a suggestion, let's keep the homophobia to a nonexistent level, please.
Re:Posix Has Become Outdated (2016) [pdf] by detaro on Saturday February 11, 2017 @12:43PM (#13623690)
That's a quote by the (gay) developer of sendmail, I don't see how quoting that is homophobic?
Re:Posix Has Become Outdated (2016) [pdf] by Avshalom on Saturday February 11, 2017 @10:16AM (#13622957)
Apache almost certainly uses epoll/kqueue.
Re:Posix Has Become Outdated (2016) [pdf] by gm-conspiracy on Saturday February 11, 2017 @07:22AM (#13622303)
Almost everyone uses the Apache webserver when they browse the web

No.

https://news.netcraft.com/archives/category/web-server-surve...

Re:Posix Has Become Outdated (2016) [pdf] by tmalsburg2 on Saturday February 11, 2017 @07:31AM (#13622332)
Reading comprehension. I did not say that people only visit pages that are served by Apache. Even if Apache has just 20% market share there is a very high chance that you will hit some pages served by Apache. Plus, the same argument really applies to most alternatives to Apache.
Re:Posix Has Become Outdated (2016) [pdf] by yellowapple on Saturday February 11, 2017 @10:03AM (#13622883)
To be fair, Apache not having an overwhelmingly-majority market share is (according to that site) a relatively recent trend.
Re:Posix Has Become Outdated (2016) [pdf] by gkya on Saturday February 11, 2017 @09:37AM (#13622782)
Nitpicking 101.
Re:Posix Has Become Outdated (2016) [pdf] by geezerjay on Saturday February 11, 2017 @10:14AM (#13622937)
> That's what majority of computer users (smartphones included) use though.

Most computer users access countless sites which run on deep software stacks running on any flavour of linux.

...which run POSIX.

Re:Posix Has Become Outdated (2016) [pdf] by bluejekyll on Saturday February 11, 2017 @11:40AM (#13623327)
> ...which run POSIX.

More accurate to say, expose a POSIX compliant API.

I remember BeOS had a 100% compliant POSIX layer. Impressive for a non-UNIX.

Re:Posix Has Become Outdated (2016) [pdf] by yamaneko on Saturday February 11, 2017 @08:30AM (#13622503)
Just curious, can you give me some examples of GNU-isms/macOS-isms? I have a suspicion what they might be, but I'm not sure.
Re:Posix Has Become Outdated (2016) [pdf] by bluejekyll on Saturday February 11, 2017 @08:50AM (#13622599)
Asynchronous IO, hardly anyone uses the POSIX standard of select and poll anymore, and instead use kqueue (bsd/macOS) and epoll (Linux).

I should add that this is for performance critical software.

Re:Posix Has Become Outdated (2016) [pdf] by JdeBP on Saturday February 11, 2017 @10:15AM (#13622945)
I'll agree that a lot of people prefer and recommend things like kqueue+kevent over select/poll. But my experience is that the statement that "hardly anyone uses" select/poll is still erroneous.

On an out-of-the-box installation of FreeBSD/TrueOS, most processes listed by "ps" show a wchan of things like ttyin, select, poll, pause, uwait, wait, or nanslp. On the FreeBSD machine that I am typing at right now exactly one program is waiting in kqread, one of the inner processes of Chrome.

Install my nosh toolset, and a fair amount of that changes, because my programs use kqueue+kevent and suddenly the "ps" output is full of kqreads. But what's left is still not "hardly anyone", by a long chalk.

Would that it were! There's a nasty kernel panic somewhere in the innards of the kevent system on FreeBSD, where a sleeping thread holds a non-sleepable lock, that only manifests itself (at least for me) when there are a lot of programs using kqueue+kevent on a system that is doing a lot of stuff. If more people used kqueue+kevent in more programs, there would be more people wanting it fixed. (-:

Re:Posix Has Become Outdated (2016) [pdf] by bluejekyll on Saturday February 11, 2017 @11:31AM (#13623273)
Yeah. I considered this critique, which is why I added the performance caveat. The thing is, libraries of other languages are being written abstractly over the native eventing systems on the OSes.

For example, the MIO library in Rust, is an abstraction over epoll, kqueue, and the MS primative. Not one over the POSIX standard. This means that if you use that in a Rust library, you get that platform independence for free.

Re:Posix Has Become Outdated (2016) [pdf] by cperciva on Saturday February 11, 2017 @01:46PM (#13624038)
The standard select and poll syscalls perform just fine if you only have a handful of sockets. Heck, they perform just fine as long as a nontrivial proportion of your sockets are ready at any given time.

The place you need kqueue and epoll is when most of your connections are idle -- IRC servers and web servers with large keepalive times. But the vast majority of processes are not IRC or web servers.

Re:Posix Has Become Outdated (2016) [pdf] by jmgao on Saturday February 11, 2017 @05:10PM (#13625145)
One hilarious one is basename(3), which is two functions with different behavior, but the same name. The one you get depends on which headers you include, and what _GNU_SOURCE is set to.

See http://man7.org/linux/man-pages/man3/basename.3.html for the manpage.

Re:Posix Has Become Outdated (2016) [pdf] by astrange on Saturday February 11, 2017 @03:15PM (#13624536)
dispatch and XPC are very popular macOS APIs that are "POSIX level". At least one of those is open source.