Skip to content

Comment on Website hosted on a 24 year old Linux serverparent

Comments

I feel like you could do this without a database using the Linux kernel inotify API. Every time a file is accessed trigger an increment. It’s too beautiful of a day outside to try this right now but an interesting brain teaser!

Pretty sure Linux didn't have inotify then.

Probably a CGI script updates a counter in a file.

Pretty sure Linux didn't have inotify then.

Did FUSE exist yet? You could hack it up in userspace...

(Have the HTML on a FUSE filesystem, and every time it gets a read it updates the HTML)

Can confirm, that's how it was done. A simple text file.

What about dnotify? I think that predated inotify. If so, I think it has the ability to notify a process when a file was accessed, so could fill a similar role.

It’s too beautiful of a day outside to try this right now

That's what laptops are for!

If you're just sitting outside, you may as well be inside.

My mood says otherwise.

Only if your laptop has some e-ink/e-paper tech screen really.

Sitting in the shade works for me, but yes, e-ink or STN works well (decades-old tech).

Would be flying with all the bots trying to hack Wordpress bugs

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.