How ZFS scrubs routinely save us
A while back I wrote about how ZFS resilvering saved us and mentioned in passing that there are a number ofways that ZFS routinely saves us in the small. Today I want to talkabout one of them, namely ZFS scrubs.
Put simply, ZFS scrubs are integrity checks of your ZFS pools. Whenyou scrub a pool it checks and verifies all copies of all pool datato make sure that they're fully intact. When it finds a checksuminconsistency it will repair it; if things are really bad and
Procedures are not documentation
In the introduction to this good and interesting Sysadvent entryon automatically testing your web security I hit a sentence that raised my hackles right up:
Writing automated tests for your code is one of those things that,once you have gotten into it, you never want to see code without testsever again. Why write pages and pages of documentation about howsomething should work when you can write tests to show exactly howsomething does work? [...]
(Emphasis mine.)
I cannot put this strongly enough:
The 'entry as file' blog engine problem with tags
I've recently started feeling a desire for DWiki to support someform of tags for entries (for reasons involving my personal site ). This is a problem, because DWiki is verystrongly a file based blog engine , onewhere every entry is a file in a directory hierarchy and everythingyou see is just a wrapper around that. In fact this is yet anotherexample of the metadata problem that filebased engines have in general.
In the abstract the problem with tags is that you want two-way queryingon
A good reason to use write-intent bitmaps
Modern versions of Linux's software RAID support what the documentationcalls ' write-intent bitmaps ' (seealso the md(4) manpage). To summarize the documentation, thisbitmap keeps track of which parts of the RAID array are potentially'dirty', ie where different components of the array may be out ofsync with each other. An array with this information can often beresynchronized much faster after a crash or after a situationwhere one component drops out temporarily . However the drawback of a writeintent
The benefits of using expendable email addresses for most things
One of the big email things that I do as an anti-spam and anti-annoyanceprecaution is that I basically never give places my real emailaddress. Whenever something demands an email address in order forme to sign up, I make up an expendable address for the purpose (Iknow, I'm lucky that I have convenient access to as many expendableaddresses as I want through a local facility that's sort of for this ). All of the expendable addresseswind up in my real inbox,
If you're using Linux's magic SysRq, increase the log level right away
Here is an important thing about using magic SysRq in practice that I recently learned the hard way:
If you're about to use magic SysRq to diagnose a problem, start byusing it to increase the log level .
Specifically, invoke magic SysRq and use 9 to set kernel consolelogging verbosity to maximum. What this does is insure that all kernel messages go to the console, including all messages producedby magic SysRq operations.
(I believe you can also do this through dmesg with ' dmesg -n debug '
A realization: on the modern web, everything gets visited
Once upon a time, a long time ago, you could have public web appsthat exposed a few quite slow heavy-weight operations and expect toget away with this because users would only use those operations veryoccasionally. These might be things like specialized syndication feedsor looking up all resources with a particular label (tag, category,etc). You wouldn't want to be serving those URLs very often, but oncein a while was okay and it wasn't worth the complexity of making eventhe
Your (HTML) template language should have conditionals
You could call this a war story, or just learning from my painfulexperience.
Back when I was first writing DWiki and didn't have enough experienceto know better, I decided that it should have a quite simply templatelanguage because it would be easy to implement and it would avoid thetemptation to do lots of things in templates. As part of this simplicityI decided that there would be no 'if' conditional operator.
(There is a slightly subtle reason for avoiding this. If you have no'
Thinking about what we'll need for reproducible OmniOS installs
We have a thing here where we like all of our fileservers to be exactlyidentical to each other (apart from configuration information), evenif they happen to be installed or reinstalled some time apart. In theold days of basically static systems this was easy to achieve; if youinstalled everything from the media for OS release X.Y, they all woundup the same. Today, in a world of (online) patches and package updatesand security fixes and so on, this is not necessarily all that
You probably don't want to use Make to build your generated files
When I started working here , one of theearly things I worked on was generating files of information for variousthings (such as getting files of all valid local email addresses ). Partly because I was very clever back thenand partly because we were doing this on ancient, underpowered Solarismachines, I did this the obviously efficient way: I used a Makefileto control the whole process and made sure that it did only what itabsolutely needed to. If everything was up to date the whole process didnothing.
(