News for hackers. Stuff that matters.

jimis

Re:Lightning Memory-Mapped Database Manager (LMDB) 1.0 on Friday July 03, 2026 @06:53AM (#48773497)
If you use the default mode MDB_SYNC then it's reliable but can be slow for writes. For max write performance you need MDB_NOSYNC (IIRC that's what the official benchmarks use) but then the whole database can be unrecoverable in case of crash. It has happened to me.

Sqlite in WAL mode will never lose all your data and performance can be configured vs durability by setting pragma synchronous to full or normal.

Re:Unison 1.0 Release on Tuesday November 25, 2025 @03:53PM (#46050642)
"Unison" is the legendary file sync tool from the 90s, written in OCaml, reliable and efficient as rsync but supporting bi-directional sync. https://en.wikipedia.org/wiki/Unison_(software)
Re:How to Install TrueNAS on a Raspberry Pi on Thursday August 28, 2025 @09:12PM (#45058888)
So each enclosure hosts its own RAIDZ2. Have you tested if it can survive loss of USB connectivity? It can happen because of cable damage or movement, and also because of any failure in the enclosure's electronics.
Re:How to Install TrueNAS on a Raspberry Pi on Thursday August 28, 2025 @09:02PM (#45058811)
Each drive shows up as an external USB mass storage device?
What is the systemd equivalent for `service crond stop` and later `service crond start`?

In other words, I want to disable all jobs for some time (for benchmarking) and then bring them back up.

Re:RISC-V CPU arrives on a tablet starting at $149 on Tuesday August 27, 2024 @09:22AM (#41367250)

  > The DC-ROMA RISC-V Pad II starts at $149 for the 4GB RAM version and is already available for pre-order on the DeepComputing store. 
  > If you get the 16GB RAM variant, the tab is compatible with the Android Open-Source Project (AOSP) Android 15 operating system.
Weird, isn't 4GB RAM enough for Android 15? Or is AOSP compatibility completely separate from Android compatibility?
Re:I turned an old phone into a NAS on Thursday August 08, 2024 @09:13AM (#41191139)
Who are the phone/tablet manufacturers that are friendliest to rooting or installing open-source Android clones? It's a pain to do that on my Samsung Galaxy devices...

I'm looking to buy a (new) 10'' tablet for that purpose.

Re:Double Standards on Friday December 08, 2023 @04:16PM (#38574526)
It's not the same buying a new product from official supplier, to buying something old and/or used from an unknown entity on eBay.
Re:Benchmarking Cheap SSDs for Fun, No Profit (Be Warned) on Monday March 27, 2023 @10:41AM (#35327273)
> bloat their io buffer size to several GiB, set the eviction priority to 1

How do you tweak these? I'm aware of dirty_writeback_centisecs and the likes, but you are most likely referring to something different.

Re: on Thursday November 03, 2022 @11:43AM (#33452762)
> after paying more money than it would cost to buy a basic laptop

No need to be imprecise, unless you are trying to push some agenda. The cost is CHF 198, which is around USD 195.

Re:Zstandard Worked Example on Thursday May 19, 2022 @12:06PM (#31436463)
They are only slow to compress. They are as fast to decompress, or even faster sometimes. Source: I tested.
Re:Why Is C Faster Than Java (2009) on Monday December 27, 2021 @06:01AM (#29701392)
JGit has advanced a lot, and is in use in software handling huge repositories like Gerrit code review system. Java has also had numerous advancements in the past 10 years.

It would be interesting to measure git vs JGit performance today.

It would also be interesting to have JGit developers comment on performance after all this time.

Re:Linux Foundation spends just 3.4% of its money on Linux on Tuesday December 14, 2021 @06:19PM (#29559521)
The main complaint still stands: the report provides very few details about the incomes and expenses. Out of almost 100 slides, I only see one, titled "Financial Disclosures". And it does not contain many disclosures.
Re:Linux Foundation spends just 3.4% of its money on Linux on Tuesday December 14, 2021 @03:34PM (#29557227)
Their financial report appears to be quite opaque and closed, as opposed to the Linux project and community.
Re:Western Digital HDD boss mentions archive disk drive idea on Tuesday December 14, 2021 @02:33PM (#29556272)
Now that SSDs are ubiquitous, hard disk drive manufacturers should up their game:

  * 5.25'' drive  which is taller (more platters) and wider (more sectors per platter)
  * Slow rotational speed to reduce consumption and vibration
  * SMR again, but label the products accordingly
  * Small (64-128GB) SSD embedded, acting as transparent cache especially for quick response to write commands.
    * Possibility to disable this caching layer with a SATA command.
Defaulting to root UID is not an understandable default.

Systemd requiring polkit is a valid issue.

I find this article hard to read. But I believe its point stands. In Rust:

  - You bubble up errors using `?` operator,
  - then you get a nice error message.
  - However the location of the error is lost, the more complex the program, the harder it is to figure out where "permission denied" for example comes from.

  I had implemented it once in 2 lines of Python. some 25 years ago. If I can shake the rust maybe I'll be able to rederive it. 
Please do! I would love to see a concise and readable implementation in Python.
Re:Blërg, a microblogging platform on Saturday January 16, 2021 @05:08AM (#25801304)
Awesome to see you answering here! It's obvious that your little experiment has had the honour to be hammered many times by thousands of people, so I'm curious to hear your experience.

Has it been running on a single node all these times? What are the hardware specs? How many requests per second did it handle? Has it gone down because of the load? What was the bottleneck (network, cpu io)? How did it fail (crash, slowness, fire ;-)? Do you have monitoring data to show? How many twitter-like active users would it be able to serve from that single node?

Thanks, and Blërg! :-)

Re:Blërg, a microblogging platform on Monday January 11, 2021 @02:28AM (#25725811)
I was looking for Twitter alternatives and found this one, which is old and stale but looks like a very interesting experiment! Quoting its frontpage:

  But what's wrong with Twitter?

  I'M GLAD YOU ASKED. There are two aspects of Twitter that just bug me as an engineer:

    Ruby on Rails - Using rails to prototype a system is fine — scaling up to a million hits a day with it is just a bad idea. As the service grew, I'm sure it cost them a lot more time than it saved.
    140 characters is not enough - I routinely write sentences longer than 140 characters, so I can't even begin to imagine making a point in such a small space. This textual confinement has led to the rise of URL shorteners, which are breaking the internet. 

  Blërg solves these problems by applying absurd reactionary engineering. Blërg's database backend is a custom C program that handles requests over HTTP and stores data in a very small and efficient indexed log-structured database. The frontend is done entirely in client-side Javascript. A single post can be up to 65535 bytes in length.

  Which is not to say that I believe writing your service in C is the solution to all your problems. Clearly, this approach has just as many hairy problems that will bite you in the ass sooner or later. The best way, as with most things, lies somewhere in the middle of high-level abstraction and ZOMGHARDCORE OPTIMIZATION.
Or more politely described in the documentation page:

   Blërg is a minimalistic tagged text document database engine that also pretends to be a microblogging system. It is designed to efficiently store small (< 64K) pieces of text in a way that they can be quickly retrieved by record number or by querying for tags embedded in the text. Its native interface is HTTP — Blërg comes as either a standalone HTTP server, or a CGI. Blërg is written in pure C.
Re:Msmtp: About Authentication Methods on Thursday December 31, 2020 @04:54PM (#25597613)
Thanks for the link to OPAQUE. It looks indeed much better than SCRAM-SHA, I like how the draft underlines that "clients never disclose their password to the server, even during registration."

Do you know if/when it is considered for implementing in the major browsers? Given that even SHA256 digest implementation is missing and that OPAQUE seems much harder to implement, I wouldn't be surprised if it takes another decade.

Regarding not using passwords at all, unfortunately this is not something I can use as a web user with 100s of logins.

Re:Msmtp: About Authentication Methods on Thursday December 31, 2020 @04:20PM (#25597279)
> If you use SCRAM-, you're committing your password storage to only* use that method for storing the plaintext.

I consider this an advantage. I know how the password is stored, and if the service wants to update the storage, than it has to ask me to reset my password. If it doesn't ask me so, how can I know that they are up to date?

> The entire process is invisible to the user, who gets a security upgrade in the process

or never gets a security upgrade, and he has no idea.

Re:Msmtp: About Authentication Methods on Thursday December 31, 2020 @02:42PM (#25596292)
I would personally want to see the opposite: disable PLAIN or LOGIN or HTTP basic auth methods or plaintext HTML password-entry forms, and never ever send a password without a digest challenge-response method, even over TLS. Of course first the browsers would have to implement safer alternatives:

https://bugzilla.mozilla.org/show_bug.cgi?id=472823

https://bugs.chromium.org/p/chromium/issues/detail?id=116047...

Why? Because I can't trust all the 100s of companies and I login to, and their 1000s of employees. I don't want them to choose storing my password securely or not. I want them to be forced to do that. Like I choose "HTTPS everywhere", I want to choose "SCRAM-SHA-512 everywhere" or similar.

It's technology that has to provide me guarantees, and user education must only complement that.

Unfortunately we are far from that. Passwords are flying plaintext-inside-HTTPS, with various risks:

* database storing passwords insecurely

* passwords being stolen on the authenticating server (either because of server being pwned or from internal eyes).

* passwords flying fully in plaintext (no TLS) in the internal network behind the authenticating server.

* self-signed HTTPS MITM attacks on already self-signed-cert websites (especially dangerous on intranet websites inside companies; you'd be surprised how difficult it is to setup proper PKI and internal CAs).

Re:Show HN: Dicom Medical Image Library in Go on Monday November 30, 2020 @09:35AM (#25254092)
Aeskulap was the best one, I used it successfully a couple of years ago, despite the home page making it look like abandonware.

http://www.nongnu.org/aeskulap/

Unfortunately it seems it's no longer available in Fedora repositories.

Re:Why SQLite succeeded as a database (2016) on Wednesday February 19, 2020 @05:38PM (#22370863)
> (including features like undo)

Can you please elaborate on this?

Re:Avoiding a transit of the United States on Tuesday January 15, 2019 @02:10PM (#18913915)
Don't you have the right to remain silent and not answer?
Re:LMDB – Lightning Memory-Mapped Database Manager on Sunday November 11, 2018 @01:48PM (#18427844)
LMDB is a very good choice for many well-known reasons. I don't need to expand here, the advantages are well documented, and more and more projects are choosing LMDB.

However LMDB does not solve all problems, and can be a bad choice for some, and I couldn't find this documented anywhere. Specifically write-intensive workload. Why?

- LMDB by default provides full ACID semantics, which means that after every key-value write committed, it needs to sync to disk. Apparently if this happens tens of times per second, your system performance will suffer.

- LMDB provides a super-fast asynchronous mode (`MDB_NOSYNC`), and this is the one most often benchmarked. Writes are super-fast with this. But a little known fact is that you lose all of ACID, meaning that a system crash can cause total loss of the database. Only use `MDB_NOSYNC` if your data is expendable.

In short, I would advise against LMDB if you are expecting to have more than a couple of independent writes per second. In this case, consider choosing a database that syncs to disk only occasionally, offering just ACI semantics (without Durability, which means that a system crash can cause loss of only the last seconds of data).

Re:Design Review: Key-Value Storage on Thursday November 08, 2018 @11:15PM (#18412288)
Isn't this from the paper "all filesystems are not created equal"? [1] If you search the tables for "sqlite-wal" you will see that it shows zero vulnerabilities.

[1] https://www.usenix.org/system/files/conference/osdi14/osdi14...

Re:Design Review: Key-Value Storage on Thursday November 08, 2018 @10:38PM (#18412165)
Agreed for the read workloads, I have the same experience. It was designed primarily for an LDAP directory after all, an application that is very read-heavy.

Older »