HNHacker News
TopNewBestAskShowJobs

riobard

2,847 karma · joined November 10, 2007

submissionscomments
riobard··on Networking I/O with Virtual Threads – Under the hood
It's not about which way is better, but which default is more useful in practice.
riobard··on Networking I/O with Virtual Threads – Under the hood
> on modern processors a couple thousand mostly idle (due to IO blocking) Java threads are fine

This “mostly idle” assumption is gonna break the moment you hit a load spike and wake up most of those “idle” threads.

The success of async is often (mis)attributed to eliminating unnecessary resources, but in practice it's actually because async model implicitly enforces an invisible job queue, where usually only a single process/thread per core is heavy lifting the actual work, and async I/O will feed processing pressure back to the load source via network (e.g. TCP ACK).

riobard··on WD My Book users wake up to find their data deleted
The WD My Book Live series NAS has two models, a single-disk one called just My Book Live where the disk is not user-replaceable, and a dual-disk one called My Book Live Duo where the two disks can be replaced tool-free. AnandTech had a pretty thorough review of the single-disk one https://www.anandtech.com/show/4952/wd-my-book-live-network-....

I had the MBL Duo. It ran on an 800MHz Applied Micro APM821XX PowerPC processor with 256MB RAM. The stock firmware was a customized version of Debian. I couldn't remember exactly which version of Debian but it's definitely older than Debian 9. Maybe 6 or 7? Anyway, you can enable SSH access via web UI and directly login to the device and see everything running there.

IIRC WD used OpenVPN to establish a connection to their servers to allow remote access to these devices behind NAT and firewalls. I had always been wondering what if their servers were hacked and then hackers could theoretically access the NAS via that VPN connection and by extension my LAN behind firewalls so I disabled the remote access feature.

A couple of years back I finally got tired of the ancient Debian, and since WD had already deprecated the device without further updates/patches, I was looking for alternatives. There were people on WD forums trying to compile and install newer versions of Debian. But since the device does not have video out or console port, it was very easy to mess up and got bricked.

Eventually I found OpenWRT (yes, the linux-based router OS) had official support for both MBL models (https://openwrt.org/toh/western_digital/mybooklive) and the installation seems pretty safe (especially for the Duo with replaceable disks). So I went with OpenWRT and never looked back.

My MBL Duo now sits at my parents-in-law's place running OpenWRT. I had setup WireGuard to connect it to my LAN in another city and used it as a remote backup destination in case of either place catching fire or whatever other disasters.

And now I feel pretty lucky for my decision to ditch the original firmware. Good riddance!

riobard··on What every programmer should know about SSDs
If I partition the entire drive, eventually all blocks will be used, depending on how the filesystem allocates, right? So to guarantee some free space it's better to over-provision by under-partitioning. Now how do I make sure that on a used drive?
riobard··on What every programmer should know about SSDs
So over-provisioning has to be done before any writes to the drive? What if I want to over-provision a used drive? Discard all blocks first?
riobard··on What every programmer should know about SSDs
One thing I'm still puzzled about SSD over-provisioning, which is also mentioned by the tutorial (https://codecapsule.com/2014/02/12/coding-for-ssds-part-4-ad...) recommended by the article:

> A drive can be over-provisioned simply by formatting it to a logical partition capacity smaller than the maximum physical capacity. The remaining space, invisible to the user, will still be visible and used by the SSD controller.

Does the controller read the partition table to decide that the space beyond logic partition is safe to use as scrap?

riobard··on Execute Docker Containers as QEMU MicroVMs
I'm not familiar with later development, but AFAIK Firecracker came much later and now you can actually use Firecracker as Kata Container's hypervisor in addition to QEMU.
riobard··on Execute Docker Containers as QEMU MicroVMs
That's the approach taken by Google's gVisor (at the cost of I/O and network performance).
riobard··on Execute Docker Containers as QEMU MicroVMs
A few years ago I invested in a small startup called `hyper.sh`. It open sourced a container runtime called `runV` which provided exactly this: security of virtual machines plus convenience of containers.

The project later merged with Intel Clear Container to become what's now called Kata Containers (https://katacontainers.io/) and is now widely used by several Internet giants like Alibaba and Baidu.

The startup was acquired by Ant Finance a couple of years ago.

(I recorded a podcast with one of hyper.sh engineer if you can listen to Mandarin https://pan.icu/25)

riobard··on FragAttacks: new security vulnerabilities that affect wi-fi devices
By now it's probably easier in mind to treat any Wi-Fi as Open Network and always use something like WireGuard/Tailscale for secure communication between devices.
riobard··on M1 Mac owners are experiencing high SSD writes over short periods of time
A dumb question regarding flash programming: assume the erase block is 16MB, and there is a fresh block to write to. If I slowly append-write (not modifying existing data) to the block, would subsequent writes require the whole block to be erased/reprogrammed?

The use case is usually about append-only logs: MacOS constantly generates tiny log lines and those must go somewhere? Does Write Amplification make logging a bad use case on SSD?

riobard··on M1 Mac owners are experiencing high SSD writes over short periods of time
> I really don't understand why Apple is apparently incapable of making these laptops use standard, replaceable m.2 NVMe SSDs.

Coz there's no standard M.2 form factor NVMe SSDs without a controller chip, and even if you can find one, there's no standard protocol to talk to it.

Recall that 3rd-party drive manufacturers are really bad at properly making Self-Encrypting Drives (lots of HN stories previously, just search for SED). It's very likely a factor for Apple to decide to implement its own SSD controller inside the T1/T2 chip on recent Intel Macs, and directly on die on Apple Silicon, so that Apple can fully control the data written to raw flash and be confident in its own implementation of encryption.

Charging a premium for more capacity is a standard Apple practice anyway, and the fact that such security-focused approach makes it unavoidable is a side-effect.

riobard··on Understanding how AES encryption works
Is there any software-base implementation of AES that is NOT vulnerable to timing attacks and other side channel weakness and with reasonable performance (to the limit of the hardware)?
riobard··on USB drives with no phantom load (2018)
Does any integrated USB hub support per-port power control? I'd like to control a directly-attached USB external hard drive to my Linux box.
riobard··on SwiftNIO SSH
https://github.com/apple/swift-nio-ssh/issues/48

The dev said it's basically because Swift Crypto API does not support chacha20-poly1305@openssh.com, which is a non-standard construction (compared to chacha20-ietf-poly1305).

riobard··on Go standard library benchmarks – Intel vs. M1
It explains why at the second paragraph.

> A top level takeaway from this data is that for things that rely on pure Go the M1 machine is, in general, a good bit faster than the Intel machine. For code that relies on highly optimized assembly, like a good chunk of the crypto/ code, the Intel machine wins (although I wouldn’t be surprised to see significant gains for the M1 as arm64 assembly implementations get more attention and are further polished).

Basically Go lacks lots of optimized assembly code for ARM64.

riobard··on My fiber optical modem broadcasts a poem via ethernet frame 0x8300
Thanks for the explanation! It certainly made more sense now :)
riobard··on My fiber optical modem broadcasts a poem via ethernet frame 0x8300
That's the other (and arguably more interesting) part of the puzzle! :)
riobard··on My fiber optical modem broadcasts a poem via ethernet frame 0x8300
But the modem is not made by Huawei. Its model number is G-140W-UD and it's made by Shanghai Nokia-Bell Co.,Ltd.

Could it be from the ISP-side devices?

riobard··on My fiber optical modem broadcasts a poem via ethernet frame 0x8300
I'm the owner of the modem. I've found about this a couple of months back when I moved the modem to its own vlan and noticed the broadcast frames. I did some research into the author of the poem on Twitter (https://twitter.com/riojot/status/1268821579724541954), but nothing fruitful.

If anyone knows how the poem ended up in my modem, or even just what's ethertype 0x8300 all about, please comment!

riobard··on My fiber optical modem broadcasts a poem via ethernet frame 0x8300
I've traced the author to be Erin Hanson. Her other works can be found at https://www.poemhunter.com/i/ebooks/pdf/erin_hanson_2006_2.p...
riobard··on My fiber optical modem broadcasts a poem via ethernet frame 0x8300
I believe it's from the firmware of the optical modem. I just couldn't figure out why. Please help investigate, HN! :D
riobard··on My fiber optical modem broadcasts a poem via ethernet frame 0x8300
That's also me. Still couldn't figure out the story behind this, so I'm posting to HN for help! :D
riobard··on Show HN: Mimestream, a native macOS email client for Gmail
Is there a plain text composing mode? Or is it by default plain text if I don't turn on the rich text toolbar?
riobard··on Let’s implement a Bloom Filter
Optimal for space usage without considering hardware details, like most CS algo analysis?
riobard··on Briar Project
> The classic example is pointing a high speed camera at an office window across the street and recording the brightness of the walls. Even if the office computer is hidden out of sight the attacker can reconstruct what’s on screen by analysing subtle changes in brightness reflected off the wall.

Is this feasible now?

riobard··on WireGuard Merged into OpenBSD
That's what I'd assume but I've never seen anyone doing that yet.
riobard··on WireGuard Merged into OpenBSD
What's the performance situation of the wg-go implementation now? I recalled there's a utun device API limitation that each packet requires a syscall. Is there any progress to avoid the overhead?
riobard··on Helium shortage has ended, at least for now
I'm wondering what's the effect of helium-filled hard drive causes on the demand?
riobard··on macOS Catalina 10.15.5
Thanks for the suggestion. I figured it's actually less painful to just cmd+K in Finder to manually connect to NAS via its local host name before Apple got time to fix the bug…
← PreviousPage 7 of 30Next →