Live data from Hacker News

How to corrupt an SQLite database file

sqlite.org

21–30 of 45 posts

Re: How to corrupt an SQLite database file

#21
post #20

> One example of this occurred circa 2013-08-30 on the canonical repository for the Fossil DVCS. In that event, file descriptor 2 (standard error) was being erroneously closed (by stunnel, we suspect) prior to sqlite3_open_v2() so that the file descriptor used for the repository database file was 2. Later, an application bug caused an assert() statement to emit an error message by invoking write(2,...). But since fil…

POSIX compatibility

> https://pubs.opengroup.org/onlinepubs/000095399/functions/op...

> The open() function shall return a file descriptor for the named file that is the lowest file descriptor not currently open for that process.

Re: How to corrupt an SQLite database file

#23
post #10
post #9

Earlier quoted context omitted.

So is the official pronunciation of SQLite spelling out the letters then? I’d expect “a” not “an”…

I have never heard it pronounced in any other way than "s-q-lite".

Officially it’s S-Q-L-ite, as if it were a mineral.

Re: How to corrupt an SQLite database file

#26
I just finished building an open-source project using SQLite, and this makes me a little nervous. Is SQLite generally considered a reliable system? I've only had one experience with the DB becoming corrupted and that was because I used the Task Manager to force kill the process while it was running under a heavy load, and I felt that was understandable.

Re: How to corrupt an SQLite database file

#27

I just finished building an open-source project using SQLite, and this makes me a little nervous. Is SQLite generally considered a reliable system? I've only had one experience with the DB becoming corrupted and that was because I used the Task Manager to force kill the process while it was running under a heavy load, and I felt that was understandable.

[flagged]

Re: How to corrupt an SQLite database file

#28

To make the corruption more efficient, store the file on a RAID.

Why do people shit on raid? I have been running RAID servers for over a decade with no issues, including a personal server with 5x16tb drives.

It's a joke. By using RAID, more bits will be corrupted, thus more efficient.

Re: How to corrupt an SQLite database file

#29

To make the corruption more efficient, store the file on a RAID.

Why do people shit on raid? I have been running RAID servers for over a decade with no issues, including a personal server with 5x16tb drives.

Usually because people think it’s a backup.

Re: How to corrupt an SQLite database file

#30

I just finished building an open-source project using SQLite, and this makes me a little nervous. Is SQLite generally considered a reliable system? I've only had one experience with the DB becoming corrupted and that was because I used the Task Manager to force kill the process while it was running under a heavy load, and I felt that was understandable.

> Is SQLite generally considered a reliable system?

It is arguably the most battle-tested piece of software on the planet. It's deployed basically on every single piece of tech out there.

Post reply on HN