Adding an SLOG… or not

Build Log:

Let me preface this: for most home NAS users, any kind of cache devices with ZFS are a waste. Only if you are frequently copying a lot of files to your NAS or modifying those files in place will an SLOG help. And a read cache device (L2ARC) has very few use cases where they are beneficial, almost none of which apply to home NAS.

And this is especially true if you don’t have a faster than Gigabit connection to the NAS. Without that, an SLOG or L2ARC is all cost and no benefit.

I’m a photographer, meaning I’m backing up several tens of gigabytes of initial RAW files from my camera to later be culled and edited. I also have a lot of movies backed up onto my NAS and recently started doing the same with my PS3 and PS2 games. So that’s a lot of medium and large writes going outbound. I also have a 10GbE network connection to the NAS.

Recently I also discovered that NFS is available on Windows 10 Pro, which I have on my desktop system. So I decided to enable that and remount my file shares using NFS since it’s supposed to be better than SMB in terms of performance.

And it…. wasn’t. Far from, actually.

But NFS is faster than SMB! That’s what everyone says at least.

Well, yes, overall it is. There are plenty of metrics that prove such. But why is it slow on Nasira?

It involves a third acronym: ZIL. The ZFS Intent Log. How it works and the kind of performance you’ll get will depend on the “sync” setting for the pool. Here’s the long and short of it:

  • “disabled” = all writes are treated as asynchronous
  • “standard” = only writes declared as “synchronous” are treated as such, asynchronous otherwise
  • “always” = all writes are treated as synchronous

“Disabled” is fastest but least safe, and “always” is slowest but most safe. And “standard” is going to vary between the two depending on what you’re copying and what’s doing the copy.

Let’s get a little technical. ZFS writes data to your pool in “transaction groups”. If you’re familiar with relational databases, it’s a similar concept. With synchronous writes, the intent log is a mirror copy of the transaction groups stored in memory. If something goes wrong, having that mirror copy allows some level of data recovery. This is definitely a good thing.

And unless you have a separate log device, the ZIL sits in the pool itself.

On the platter HDDs.

And based on my testing and that of others, the NFS Client in Windows always operates synchronously. Meaning write speeds were… not even close to fast enough to saturate a GbE connection, let alone a 10GbE connection. Set “sync” to “disabled” and write speeds to the NAS were coming in around 300 to 400 MB/s. It was also a sustained speed as well, holding about steady around that mark. Whereas SMB file transfers would peak early then drop down to around 200 MB/s unless I used robocopy to force more data down SMB’s throat.

So the solution, then, is simple, right? Just add an SLOG device?

Latent issues

Now if you’ve been researching whether to integrate an SLOG device to your NAS, you’ve probably come across the term “latency”. A lot. And you’ve probably even come across a lot of web and Reddit posts that boil down to, in short, if you’re not using an Optane, you might as well not have an SLOG.

Yeah there’s a lot of religious undertones with TrueNAS and ZFS. I mentioned it in my first article discussing Nasira with regard to ECC RAM, and you can say the same about using an SLOG.

So what gives?

Well it’s namely because Intel’s Optane devices are some of the best in terms of latency and throughput. But how much does latency matter? It’s important, don’t get me wrong. But not to nearly the degree so many people think. And this all or nothing thinking does nothing to further the conversation.

Now obviously there are options you absolutely should not be using as an SLOG. Any SSD that is actually slower than your pool in overall write throughput (check by turning sync to “Disabled”) is a setup you definitely should not touch. This means that in any decent NAS setup, most any SATA SSD on the market is breaking even unless you’re striping two or more together, while most any NVMe SSD is going to be adequate. Just pay attention to write throughput.

And why do I say that? Why am I not joining in on saying “Optane or don’t bother”?

Because the metric that matters isn’t latency and throughput, but latency and throughput compared to your pool. It doesn’t matter if the drive you select has the best metrics available, but whether it’s better than your pool.

Since the idea is to give ZFS a location better than your pool for writing the intent log.

And the latency and write throughput of most any NVMe SSD on the market should easily outpace a pool of HDDs.

And if you’re lucky enough to have terabytes of SSD storage in your pool, why are you even thinking of adding an SLOG? Well, there is one benefit to it that I’ll touch on later. You’ll probably have to stripe NVMe SSDs together, though.

What about all that other stuff?

Oh you mean things like power loss protection and mirroring the SLOGs? None of that matters nearly as much as the zealots like to believe.

Again, a lot of talk about ZFS and “best practices” has taken on religious and apocalyptic undertones with talks about specific risks being thrown out the window with an all-or-nothing “no risk is acceptable” type point of view – hence the “ECC or don’t bother” type thinking I saw when first building Nasira. But then I shouldn’t be horribly surprised by the risk aversion of the average person (let alone our governments) given how things played out during the COVID-19 pandemic, and still are even today (as of when I write this).

Yes, I went there.

And it’s this near-complete “no risk is acceptable” type of risk aversion that seems to have flooded discussions on whether you need to mirror your SLOG and whether you need power loss protection. So let’s inject some sanity back into this, starting with mirroring the SLOG.

“Mirror, mirror of the SLOG”

How could data loss occur without a mirrored SLOG? Well two things have to happen pretty much simultaneously: your NAS crashes or loses power before the in-flight transaction groups are written to the pool, and the SLOG device dies either at the same time or it dies on reboot.

Since having a copy of the synchronous transaction groups in case the system does crash or lose power is the purpose of that intent log. Asynchronous transaction groups are lost regardless.

So if the SLOG gives up the ghost, meaning in-flight transactions cannot be recovered, you’ve got some corrupted or lost data, depending on what was in-flight. Provided there were in-flight synchronous transactions when that happened. Having a mirrored SLOG should protect you from that to a degree. And there’s always the chance the mirror completely gives up the ghost.

Here’s the million-dollar question, though: how likely is that to actually happen?

In actuality, it’s so low a likelihood I’m surprised people actually give it any thought. And there are steps you can take when building and deploying your NAS to keep the risk of that as low as possible. And it goes back to what I said when I built Nasira: use quality parts!

And primary storage devices normally don’t just up and die without any kind of warning from your system, especially if they’ve been in service for a significant period of time. So make sure you have S.M.A.R.T. monitoring turned ON and that you’re not ignoring the alerts your system is generating.

How bad of a time you’re going to have should that happen depends entirely on your use case. If a backup was in progress, then it’s not a huge deal. Just redo the backup when everything is back online. If you’ve just ripped a 4K UHD disk and was in the middle of copying the file to the NAS when everything went down, redo the copy when everything is back online. If you were ripping the disk to the NAS, just delete the partial output file and redo it.

If you’re editing photos or video straight from your NAS, then you’re in a bit more of a bind.

If your SLOG dies while the system is still live, though, ZFS will revert to putting the intent log back onto the pool and detach the log device. You may notice some performance degradation on writes, depending on your workflow, but the system will otherwise keep chugging away and you’ll get a notification that you need to replace the device.

So what about power loss protection, then?

Keep the power on!

Power loss protection is supposed to keep the SSD powered on just long enough to flush its internal cache should the system power off unexpectedly. Typically this is in the form of capacitors or an external battery. And the controller or adapter may have this as well in case the drive does not.

But do you really need that? Likely not. No, seriously, you very likely don’t need that. Since there are ways to protect your system from just losing power.

For starters, have an uninterruptible power supply (UPS) externally, and use a quality power supply internally with quality power cables. Again, use quality parts!

And like storage devices, power supplies generally don’t die without any kind of warning. And that warning comes in the form of system instability. So ignore that at your own peril! And that system instability could signal a problem with the power cables or the power supply itself.

If you really want to go all-out, use redundant power supplies. But I’ll leave you to determine if that’s worth the cost to you and your use case. For most people, the answer will generally be a No. You’ll likely know if your answer is a hard YES.

But whether you need power loss protection on your SLOG drives comes down to your use case. If you’re not working directly with the files on the pool, such as, again, editing photos and videos straight from it rather than using a scratch disk on your workstation, then not having power loss protection on the SLOG is likely not a big deal.

It all comes down to how much risk you’re willing to accept. Since losing the SLOG only risks losing in-flight synchronous writes. But then, if you’re talking about a mission-critical system where losing in-flight synchronous writes means a really bad time, I really hope you’re not using a DIY storage solution.

Never interrupt a writer!

And there’s one other detail as well: interrupted writes/saves = corrupted data.

And mirrored SLOGs and power loss protection cannot protect against that.

Interrupt the rip of a BluRay or 4K UHD disc to… anywhere, for example, and the output file is basically useless. And interrupting writes to a file would produce the same result for most file types. Interrupt the writes to database files stored on your pool and you might as well just restore from a backup.

Adding the overkill drive

So… what did I select?

To ensure I had write speeds in excess of what 10GbE could give, while not spending a substantial amount of money (e.g. Samsung, WD Black, etc.), I went with the HP EX900 Pro. 256GB. Absolute overkill on space. But rated at up to 1,900 MBps on sequential writes. More than enough to handle a fully-saturated 10GbE link.

Now the process to actually add the drive is beyond the scope of this article. I’m taking this as a chance to merely mention the upgrade and how I selected the drive, some pointers to keep in mind. And one place where you need to pay attention is PCI-E link speeds. For Nasira’s mainboard, it’s this chart in the manual:

Initially when I added the SSD with its adapter card to the system, write speeds were… not what I expected. At first I thought I did something wrong adding the SSD. Well initially I added it as a cache device, not a log device. But once I corrected that, write speeds were again far below what I hoped.

So what was the issue? PCI-Express lanes. I first added the card to the system in the 2.0x16_4 slot thinking the operating mode that would apply is the first line. The SAS card is in 2.0x16_1 and the 10GbE card is in 2.0x16_2. So then I looked at the PCI configuration to see how many lanes the drive was getting.

Just 1 lane. If this was a PCI-E 3.0 mainboard, that wouldn’t be a huge deal. Not ideal, but not crippling. Being a 2.0 mainboard, though, it needs all the lanes it can get.

So I moved the drive to the 2.0x16_3 slot. This meant having 3 cards crowded together, so not ideal. Did that improve write performance? Over NFS compared to no SLOG, it did. Like order of magnitude improvement.

Pool topography matters

In all the articles describing how SLOG devices improve write performance to the pool, they all omit one. key. detail. The pool topography. And along with topography is how fragmented or balanced, or not, your pool is.

And Nasira is arguably a worst-case scenario on all of that. Six (6) vdevs, all mirrored pairs, no common size (4TB to 12TB), with each pair added at different times as space filled up on the pool. This means heavy imbalance or fragmentation, with no way to alleviate except dump the pool to the cloud, wipe it, and pull everything back down. A process that would take… probably 2 weeks both ways. Even copying off to a pair of high-capacity HDDs would not change that.

After accounting for network throughput, write performance to your pool is throttled first by the intent log, then second by the actual writes to the pool. Without an SLOG, you’re doing writes to the pool twice. With the SLOG, you’re writing first to that device, then to the pool. This improves performance… to a degree. It’ll never be faster than full asynchronous writes, and that metric can give you an overall idea of how well your pool is performing.

And, again, pool fragmentation matters. ZFS will write data out according to the free space available per vdev. The more imbalanced your pool, the slower your writes (and reads) will be regardless of whether you have an SLOG or not.

But one benefit no one seems to mention about having the SLOG: it reduces the overall I/O going to your vdevs, helping their lifespan. So even if you don’t get a substantial performance increase adding an SLOG, you at least get that benefit. This could matter more with SSD-based storage, which will grow in popularity as prices continue to come down.

Conclusions and TL;DR

Let’s summarize.

First, it’s not entirely correct to say that any SSD as an SLOG is better than none. You need an SSD that will be faster than the write speed to your pool, or you’re not doing yourself any favors. Since, again, the idea is to give ZFS a better spot than your pool for writing the intent log.

For most everyone, this means most any NVMe on the market should suffice. Just make sure to go with a quality brand and read reviews to make sure you’re getting one with decent throughput.

Do you need power loss protection? Likely not.

If your NAS is light duty, you’re not writing to it much and only really using it for backups, power loss protection is extra cost for no extra benefit. Just make sure you have a quality power supply and watch out for symptoms it may be failing. And have a quality UPS as well that outputs pure sine wave power to keep your power supply running well for years.

Do you need to mirror your SLOG? Likely not.

Like with power loss protection, mirroring your SLOG is extra cost for no added benefit if your NAS is light duty. The risk of actual data loss should your SLOG device die is minimal because the risk your SLOG will die without any kind of advance warning is also minimal.

And the possibility it’ll die at the same time your NAS crashes or loses power while you have synchronous writes in-flight is so low you really shouldn’t be giving it much thought. Just make sure you have S.M.A.R.T. enabled and pay attention to any warnings the service sends out. And if it dies while your system is still live, you lose performance, but all your data should still otherwise survive.

So, again, if you want to add an SLOG device, just pick a quality NVMe SSD, buy an adapter board if you need it to put it in a PCI-E slot, and call it a day.

USB type-C to Milwaukee M12 adapter

In figuring out a portable light wand, I discovered some very small USB type-C power boards, one specifically locked at 12V. And I’ve used them in testing to power a light strip and I’ve got other ideas in mind for using them.

Well one idea I had is using them to power a Milwaukee M12 device. So how to do that? The simplest solution is soldering a couple spade connectors to the power board and just plugging it up that way. And while that would work, it’s obviously far from ideal. Ideal is having an M12 battery shell with some kind of 12V input on the bottom. Or USB type-C, which supports 12V.

So that’s what I’m discussing here.

Bill of materials

Limitations

The USB type-C power boards will do 3A (36W) without issue with any USB type-C charging cable, but needs an “active” USB type-C cable for up 5A (60W). 18650 cells can do 10A typically without issue, making Milwaukee’s M12 capable of over 100W of power delivery. So this adapter is best suited for the lighter M12 devices. It works fine with my borescope, which draws only a couple watts of power. But it definitely should NOT be used with anything with a motor, since they have a surge current when powering on. And absolutely do not use this with the AXIS jacket. Keep to light power devices like lights and the aforementioned borescope and you should be fine.

Preparing the shell

The panel mount plug I linked is keystone size, so you’re going to be drilling a pretty sizeable hole in the bottom of the battery shell. You’ll need a step bit that has a 1″ step. I do not recommend using a 1″ hole saw. Just drill out the bottom through the center divot (see below), though I’d recommend using a 1/4″ drill bit to start the hole. And I highly recommend using a drill press if you have one. Without the lid, the battery shell should sit flat on your drill press platform.

That divot!

Once the hole is drilled out and cleaned, the panel mount plug should fit, though it’ll be a loose fit. I followed up with a drill and M3 tap for using M3x6mm screws.

Now for the wiring.

Wiring it up

This is pretty straightforward. Positive to battery positive, negative to battery negative. The 4V and 8V connectors are used only with charging the batteries to balance them, so don’t worry about those.

Once you have it wired up, push the battery board into the shell’s lid. Then connect the power board to the USB plug in the shell body – you may need to use a tool to fully seat the plug. Then snap the lid into place and you’re golden.

The portable charger is a 65W portable charger from Baseus. It works reasonably well, though it seems to inexplicably lose its charge. And the USB type-C cable is, obviously, from Anker.

Conclusions

While I built this partly as a curiosity, I can definitely see a use case for this. Since a lot of us have USB type-C portable chargers anymore, and even the Milwaukee Top-Off becomes an option for powering M12 items from an M18 battery.

Though that brings up another idea for which parts are already on the way as I write this: an M18 to M12 battery adapter. I’m surprised Milwaukee doesn’t already already make one, though it does mean selling a lot fewer M12 batteries if they did. But it would mean selling a lot more M18 batteries, though, since they have higher capacities and can handle higher wattage draws.

So how easy is it to build one? You’ll see when I publish the article on it.

But with the limitations listed above about how you should use this only with the lower-power devices, why did I build this? In part as a curiosity, but also in part as an alternate means of powering devices I build using Milwaukee M12 battery adapters. But if you’re wanting a light-power Milwaukee M12 device but don’t want to buy into another battery system, this at least gives you a viable alternative.

Misunderstanding how insurance works

It’s pretty bad when a practicing attorney is far, far off the mark in how insurance works. So time to revisit firearm liability “insurance”, something this attorney has apparently been advocating for over 20 years.

Article: https://www.yahoo.com/news/gun-safety-mandatory-arms-insurance-193610382.html

So first of all, here’s one thing to get out of the way: insurance will not cover an insured where intentional acts are involved. It will only cover you where there is negligence or it results from someone else’s actions. Intentionally burn down your own house, for example, and your homeowner’s insurance will basically tell you that you’re on your own. Intentionally crash your own car and your auto insurance will say the same.

Intentionally take your own life and your life insurance policy is void. (Except in physician-assisted suicide, in States where that is allowed.)

And since the vast majority of firearms injuries and deaths result from the intentional actions of the person pulling the trigger, that makes that whole discussion entirely moot. Which makes it utterly baffling that a practicing attorney, of all people, would be advocating for an insurance policy that covers someone’s intentional actions.

Insurance has never worked that way!

So this leaves unintentional actions. And generally where someone’s unintentional actions lead to the death or injury of another person, it is the result of either negligence or ignorance of the person taking the actions, or a malfunction or failure of whatever they are using that led to such.

And injuries and deaths caused by a firearm are strict liability torts and crimes under the law in pretty much every State. This means intent is largely immaterial unless there was an unforeseeable malfunction of the firearm. And even that might not save you since a malfunction of a firearm leading to the death or injury of someone else violates the cardinal rules of handling firearms.

One other detail that’ll be very relevant later: virtually all instances where a firearm discharge results in injury, let alone death, are felonies. And, to reiterate, they are strict liability crimes as well, meaning being unintentional won’t save you from criminal charges. And that is true in every State. And convicted felons are prohibited persons with regard to firearm ownership under the laws of every State and the Federal government.

Okay, so let’s get into his article.

Mandatory insurance makes people be responsible for choices that impose risks on others. We must require gun owners at any instant (maker, seller or buyer) have liability insurance to cover any harms that weapon causes.

Liability insurance pays out only when someone is liable for a loss. As such, including the “maker” and “seller” in the list means they, and probably everyone else along the chain of ownership, should be held liable for every firearm homicide and suicide. Yeah… no. That’s like holding Fiat and State Line Jeep here in Kansas City liable if I get into a car accident that kills the other driver.

But, again, liability insurance doesn’t cover the intentional actions of the person carrying the insurance. So this would only pay out in a very small minority of all firearm-related injuries and deaths.

The insurance will be from a private firm, not the government. Each insurer will seek to earn more premiums with fewer claims.

Apparently he’s never heard of the insurance loss ratio. That is the ratio of money that is paid on claims versus revenue from premiums. And that loss ratio is dictated by government regulation.

So if the government mandates a loss ratio of, for example, 80%, that means for every $5 in premiums, $4 must be paid to claims. If an insurer finds themselves lax on claims and awash in cash with a topped-up reserve, then they must refund money back to their customers (either directly or as credits against future premiums) in order to maintain their loss ratio. They can’t just keep that money.

It’s why auto insurers were issuing refunds or credits in 2020. And dental insurers as well, and probably vision insurers, too.

As such, insurance companies actually do NOT have an incentive to “earn more premiums with fewer claims” since they won’t be able to keep that money. Their profit margins are effectively capped by government regulation. The only way they can increase their profit is reducing their operating costs. Contrary to popular belief, health insurance companies in the US aren’t making money hand over fist.

Insurance payouts would go to the crime victims’ compensation fund, whenever a crime involving guns is committed or a gun mishap occurs.

Why not pay the victims directly? Why put the money into a fund where there is a statutory cap on how much crime victims can get? Here in Kansas, that cap is $25,000, $5,000 for funeral expenses. And that amount is reduced if you receive compensation from other sources. Such as insurance!

So you’re requiring insurance presumably for payouts to crime victims, many of whom will likely not be able to benefit from it due to having other forms of insurance that will cover the losses and other expenses. So this isn’t about helping crime victims, but putting another financial barrier in front of gun owners.

Or, rather, white gun owners. More on that later.

Rates will vary according to the gun we want to insure, our expertise, and claims history.

So ban “assault weapons” and require a certain level of training without actually going through the legislative process. Gotcha!

In a way, this could actually end up backfiring on gun control advocates calling for “liability insurance”. Because it’ll show what is already readily apparent from the FBI statistics: so-called “assault weapons” aren’t the problem they make them out to be. Any “claims history” would show this.

Instead pistols are the firearm of choice for gun crimes and suicides. But police also carry pistols, but I’m sure we’ll exempt them from this whole thing per usual.

But the “claims history” is basically about making “insured” gun owners pay for the actions of the uninsured. Since we all know that the gangs, mafias, and cartels aren’t going to go along with buying this “insurance”.

And it also puts another legal and financial barrier in the way of the lower class and minorities from exercising a CONSTITUTIONAL RIGHT. It’s another example of a white person in their ivory tower mistakenly thinking that white gun owners are the problem, and so coming up with a policy proposal that will disproportionately affect Latinos and blacks, making it – say it with me! – RACIST.

Quoting an article on the idea of liability insurance I wrote back in 2015:

Gun owners are not just white people living in well-off areas. Yet many of the policy ideas seem to think this is their assumption. When you make it more expensive to exercise a right, those who are lesser-off will be less likely to exercise their right. That’s exactly how poll taxes used to work, yet because we’re talking about guns, no one is seeing it the same way.

Yeah I went there again. It’s impossible to not whenever someone proposes a financial barrier of any kind to the exercise of a right.

Since, again, much of the policy ideas that white gun control advocates conjure seem to think that all gun owners are just well-off white people, benefiting from white privilege and so having a comfortable enough existence that they can afford to give up some more money to own their guns. When in actuality gun owners are a very diverse group of people, and only became more so in 2020 and 2021.

The whole idea of “firearm liability insurance” is pushing the cost of gun crimes onto all gun owners rather than onto the people committing those crimes. And while the push-back might be “we push the cost of all car accidents onto all car owners through insurance”, you’re again missing the intent factor if you present such an argument. Since the vast majority of vehicle collisions are unintentional whereas the vast majority of firearm injuries and deaths are clearly intentional.

Now that’s not to say there isn’t any role for insurance with regard to firearm crimes. But it’s a role they already take: covering the victims. Property and business insurance, for example, covers the victims of crimes. Health insurance (or property or business insurance, where applicable) covers any injuries requiring medical attention. Then the insurance companies may try to go after the perpetrators for whatever they can get to make up that loss, to the extent they’re allowed by law.

And as already noted, those already covered by other forms of insurance will see reduced or eliminated liability for reimbursements from their State’s crime victim compensation fund.

I understand the push for this kind of thing as well: it’s to make victims of crime (or their survivors) as whole as possible. But the main flaw in any call for “liability insurance” is simply that you’re talking about an insurance payout for someone’s intentional actions. And regulations in most (if not all) States – e.g. California – specifically preclude the ability for insurers to cover intentional actions.

But even if the regulations or statutes were updated to eliminate that preclusion, you’re still talking about a financial barrier to the exercise of a constitutional right. The equivalent of a “poll tax”, so to speak. And once you start including intentional actions under the umbrella of insurable events, the cost of such insurance will skyrocket. Since, again, those who are actually committing gun crimes aren’t going to buy the insurance, leaving the cost of those crimes on those who are willing and able to.

And that’s the point.

It’s similar to all the calls for per-round taxes on ammunition and additional taxes on firearms: make it financially infeasible to exercise a constitutional right.

DIY audio input switch

Courtesy of the pandemic, I’ve been a full-time work from home (WHF) software engineer for coming up on 2 years. I previously wrote that I have a pair of 4K televisions I use for desktop monitors. And for my work laptop, I have a universal docking station that supports 4K output. To allow me to use my peripherals between both, I have an audio switch for my headphones and a USB switch for the keyboard, mouse, and microphone.

The USB switch works great! But the audio switch started getting… flaky.

The physical switch is the audio switch’s weakness. It got to the point where getting it to fully actuate onto one of the two inputs with full audio was a bit of a chore. So… what to do? Well as the title suggests, I went DIY.

Sure it’s more expensive than just replacing what I have – the original switch was only 14 USD. But it comes with some exploration! And employing a double throw toggle switch that should give a solid connect or cut-off to either audio input that won’t wear out in the same fashion as what it’s replacing.

Bill of materials

For this I used:

The three-pole switch is what’s important here as a stereo audio jack has three connections: ring, sleeve, and tip. And it’s important to be able to cut off all of them to avoid audio interference. There are versions of this switch with screw terminals. Don’t use them. Get the one with spade terminals since you can also use those terminals as solder lugs, giving you a solid connection.

I used 1/4″ stereo phone jacks instead of the typical 1/8″ (3.5mm) as it seemed finding one of the latter that would latch onto a standard 15mm male plug was going to come down to trial and error. Yes it means I need to use adapters, but it’s more flexible if I decide to repurpose it for something else later. Plus it requires adapting from the smaller to larger connector, not the other way around.

And I went with the open-body connectors as they were most capable of supporting 14ga wire. Larger wire will provide for a better audio connection. And the terminals on the switch and the size of the open connectors could probably allow for even 10ga if you wanted to go absolute overkill. I used stranded core, but solid core would work just as well here.

Wiring it up

The middle set of terminals on the switch is connected to the output while the outer terminals are connected to each of the inputs. While they are made for spade terminals, I used solder to make sure there would not be any connection issues or a connection that could get just slightly loose and cause problems, such as completely losing one side.

On the jacks, you’re connecting point-to-point: ring to ring, tip to tip, sleeve to sleeve. Basically just make sure all the jacks are wired the same to their specific set of terminals on the switch and you should be golden.

And with the open-body jacks, again they’re capable of supporting 14ga wire. (As already mentioned, they can handle larger without issue.) And I didn’t rely on the solder lugs for the tip and ring connectors. Instead I soldered wire to the connectors directly, which I feel gave a much more solid connection – which is important with the larger-gauge wire. The solder lug was the only option for the sleeve connector.

And with the shallowness of the junction box – it’s less than 1-1/2″ internal depth – get the wires as flat as possible.

I chose the simplest wiring route. This means the center connector is the headphone output while the left and right are the inputs. The downside with the switch as well is the toggle will not point to the active input. But you can wire yours up however you choose. For example in the first image below, the leftward audio connection will be the active input, not the rightward connection.

Yeah my soldering and wiring could’ve been a little cleaner… Solder connections give you the most solid connection, though, compared to the aforementioned screw terminal version of this switch. (Yes, I tried using that switch and it was nothing but issues and I could not get solid, reliable audio switching no matter how much I tried.)

Testing and Troubleshooting

When testing this, make sure to test with different types of music and audio. And of course test everything before closing it into the box.

While the audio is playing, I’d recommend tapping the box on your table or desk along with flipping the switch back and forth so the audio goes in and out. If audio channels come in and out doing either, or parts of the audio drop out, check the connections on your switch.

If you lose audio or it drops out plugging and unplugging any of the audio connections, check your solder joints.

It isn’t a right if it’s compulsory

In the United States there are several rights codified in our Constitution. And one concept about rights many seem to forget is they are entirely voluntary. You have the choice of whether to exercise those rights. Once you take away the choice, it is no longer a right.

Yet such is the topic of a recent “Letter to the Editor” in the Los Angeles Times:

Columnist Jonah Goldberg’s fear of mandatory voting can be summed up in the belief that it would be “coerced speech” and therefore something contrary to America’s basic values.

That seems to ignore other coerced activities that the majority believes “promote the general welfare,” in the words of the preamble to the Constitution.

Does Goldberg hold that education should be voluntary? Does he oppose licensing drivers? Would he make jury duty a totally voluntary undertaking? Does he think all Americans would freely send in their taxes because they believe, as Oliver Wendell Holmes stated, they are the “price we pay for civilized society.”

Mandatory voting should be a requirement of citizenship like so many other duties we willingly perform for the greater good of our family, our neighbors and our compatriots. If voters don’t like the ballot choices, they can leave the boxes blank rather than stay home in a righteous funk.

Godfrey Harris, Encino

This also shows much the same logic I’ve seen out of a lot of people: a lot of other things are compulsory, so [insert thing I want compulsory] should be as well.

I also wonder if Mr Harris would also use the word “right” to describe education, despite pointing out herein that education is compulsory in the United States – up till you turn 16 or 17, depending on the State.

Let’s take the right of free speech. In an earlier article – okay, a much earlier article on this blog, I said the right includes “the right to express, [and the] right to withhold expressing”. And that you have the right to not speak is so sacred that police are required to inform you of it before interrogating you. And the government cannot compel you to say anything. (A lot of people try to counter with “oaths of office” here, but those are conditions on taking a job or appointment with the government, not something you are punished for not doing.)

I’ve said the same about the Second Amendment as well: that the right to keep and bear arms includes the right to choose whether you will do so. The government cannot compel you to own firearms, or any particular firearms or any particular quantities of ammunition. Nor can they restrict what firearms you can own (that they currently do does not mean it’s a legitimate exercise of power) or what quantities of ammunition.

The same with the right to vote. If you don’t have a choice in whether to vote, it isn’t a right. Doesn’t matter what justifications you can make to support your assertion. It stops being a right when it starts being mandatory.

Which is why I’ve said “parental rights” don’t exist:

[P]arent’s don’t actually have “rights”. Instead they have only responsibilities and duties to their children. They have some discretion in making decisions over how to care for their children, such as in determining meals and clothing styles, but only to the extent that it does not come into conflict with their duty to provide an adequate level of care for their children.

But let’s grant the proposal for a brief moment. That voting should be compulsory. What should be the penalty for noncompliance?

And Mr Harris’s idea of submitting a blank ballot is completely indistinguishable from abstaining in the end. So why waste the time submitting a blank ballot, which wastes time with processing as well (more so when talking about mail-in ballots), when outright abstaining is just more efficient all-around?

Simple wiring for a 3-way switch

As mentioned in a previous product review, the current ongoing project is attic insulation. Part of this project – and a significant source of delays – is rewiring.

First a little background. My home was built in 1951, making it older than my parents. And most of the insulation I’m removing is… original to the house. There was also a lot of wiring original to the house as well, meaning not grounded. According to what I could find, grounded wiring and outlets became required for new homes in 1974 when the updated electrical code went into effect.

So I’ve been replacing the non-grounded wiring as I found it. Along with splitting out the wiring so I don’t have… say, seven (yes, seven!) power lines coming to one junction box. (In all seriousness, if you think that’s a good idea, get some help.)

A lot of homes (most, I presume) have at least one 3-way switch pair. I have two, actually: the dining room and kitchen.

3-way switches need to be wired in series. And a lot of images and diagrams I’ve found show this. (Such as the one above, from The Family Handyman.) And I think it’s safe to say that most 3-way switches are wired like this. Which is all well and good, in theory. But the switches are typically on the opposite ends of a room, and wiring them directly in series means running two (2) power lines to each switch, one of them going between the switches, making things a bit… complicated.

And if you’re replacing older wiring (like me!), you probably want to avoid pulling two wires down through a wall. So is there a way to still connect the switches in series as needed that requires only one power line to each component?

Well you’re reading this, so the answer is obviously Yes.

Warning: I really shouldn’t have to say this, but I will anyway because people are stupid, and stupid people are litigious. Take any and all reasonable safety precautions when working with your house wiring. This means identifying and turning off the circuit breaker and using proper tools. These instructions are provided for informational purposes only, and you follow them at your own risk.

If you aren’t comfortable doing this on your own, why are you reading this article? Just call an electrician or a good friend who will do it for you in exchange for some beer.

Bill of materials

Note: If you’re rewiring, make sure the switches you have are actually 3-way and not 2-pole switches and that both have a ground connector. If you’re unsure, or unsure about how old they are, just buy new 3-way switches from your local hardware store so you know you have a matched pair.

I had to do that as one of the two switches in the pair was a 2-pole, not a 3-way. Plus I have no idea how old they were.

Sanely wiring a 3-way switch

Step 1. Set the junction box and bring power to it.

The power delivery will be divided at the junction box. The power main will be coming to it, and the power to the light will be going away from the junction box with both switches being wired here as well. This will make your life so much easier than working inside a lighting fixture box.

Step 2. The light fixture.

The light fixture should be pretty straightforward. You’ll first want to wire the ground to the box. Then wire the light fixture according to its instructions.

Step 3. Wiring the switches.

A grounded 3-way switch has four (4) contacts: two brass, one black, and ground. The brass terminals are called “traveler terminals” and are used to connect the two switches together. The switch position determines which terminal power travels through.

Per the diagram above, if you were using separate power lines between the switches, you’d be using the red and black wires to connect them while passing through the white and ground. But here there is only one power line to the switch. That means you’ll be hijacking the white and red conductors for the “traveler terminals”. So connect separate lines to each switch as such:

  • Ground to green
  • Black to black
  • Red and white to brass.

If you wire the brass terminals the same on both switches, they will need to be in the same position for the light to turn on. Wire them opposite each other, they will need to be in the opposite position for the light to turn on. Personal preference dictates what to do here. I personally have them wired the same just for the sake of simplicity.

Step 4. The junction box

Now to bring it all together.

  1. White from the power main to white on the light fixture
  2. Red to red, white to white on the power lines going to the 3-way switches
  3. Black from the power main to black to one switch
  4. Black to the light fixture to black to the other switch

And obviously the grounds get connected together as well. If you used a junction box with ground lugs, per the bill of materials above, connect all the grounds there. Though you are talking about 4 grounds, so things could be a little tight.

In the end it should be something like this diagram (from the aptly-named HowtoWireALightSwitch.com), only using a separate junction box instead of the light fixture box as the central point:

Step 5. Enjoy

Don’t forget to close up the junction box and secure the switches. Just be sure to turn the breaker back OFF before doing so. Just in case.

Zenith Self-Prying Pro-Bar

Buy it now at Home Depot or Amazon.com.

This year’s major house project has been attic insulation. And getting all of the old out to put down the new has been a chore unto itself. But to get to all of the old and make sure I could lay down the new, I needed to pull up floor boards.

And the Zenith Self-Prying Pro-Bar made that task super easy.

The wide base and thin beveled edge made it very easy to get under the boards and pry them up. Far better than using a claw hammer or other pry tool. Just use a rubber mallet to push it under the board you’re lifting. The groove in the front made it easy to get far enough under the board with nails in the way to still use the joist for leverage.

The wide base also spreads the force out over a wider area compared to typical pry tools, so the board comes up with less effort. And if you’re trying to pull up old boards, such as what was in my attic, the boards are far less likely to splinter apart compared to a typical pry tool with a much smaller surface.

I used the tool to raise one edge of the board enough that I could then use a hammer or pry bar to get the nails out. Then when one row of nails was out of the way, the pry tool could get leverage under the board to lift up the other row of nails, allowing me to pry those out and get the board out of the way in tact. (Most of the time.)

Its short handle is my only complaint given its use cases. It’s 16″. So Zenith should consider a new version of this tool with a longer handle. I think 24″ would be ideal here, as the longer arm would allow for more leverage. That combined with the wide base would make short work of any floor boards with still less effort, which would be far better for the largest jobs. They should also consider just getting rid of the small pry head on the handle as well as it only gets in the way given the use cases this tool was obviously designed for.

Let’s be honest about who this tool is for, though. It’s is a niche product with a >40 USD price tag. Don’t get me wrong, though. It’s definitely well worth its price given the time and effort saved compared to typical pry tools.

But let’s be realistic. The typical DIY homeowner will only be using it for one or two projects. For me, once the attic floor boards are all out of the way, I don’t see anything else I could use this for. So I’ll most likely be selling it on rather than keeping it around.

If you’re a professional, though, this tool should absolutely be part of your arsenal.

Buy it now at Home Depot or Amazon.com.

Bernie doesn’t understand the drug market

I’ll say this up front: if you’re complaining about the cost of something today compared to several decades ago, and your explanation doesn’t include change in demand and the FDA, you’re out of touch with how things work.

Enter Senator Bernie Sanders.

So how can we explain this? Let’s start with inflation. Now inflation alone doesn’t account for a 14-fold increase in price. 21 USD in 1996 is equivalent to about 37 USD today. So that’s only about 16 USD of the nearly 300 USD increase. Hmm…

So what about change in demand? Across the last 25 years, how has the demand for insulin changed? A. Fucking. Lot. But enough to account for a 14-fold increase in price?

According to the Centers for Disease Control, about 10.5% of the population in 2018 has diabetes – about 34.2 million people – and about 1.5 million people are newly diagnosed each year. And the prevalence of diabetes has gone up significantly over the last 20 years among adults, from about 9.5% to 12%.

Now that alone also doesn’t account for a 14-fold increase. According to the United States Census Bureau, there were approximately 209 million adults in 2000, compared to 258 million in 2020. That means the total number of diabetics increased from shy of 20 million in 2000 to almost 31 million in 2020. A greater than 50% increase.

Okay so change in demand plus inflation should mean the price of insulin should be… about 55 USD, right? Not quite. Because there are a ton of other factors that determine the price of insulin.

First is the capability to meet that demand. Making insulin isn’t easy. Just like… really any drug that needs to be synthesized in mass. Drug makers, just like all manufacturers, have only so much manufacturing capacity. I mean it isn’t like we can just conjure it via a Star Trek replicator. (Boy wouldn’t that solve a lot of problems!) The price they charge to buyers acts as a valve on that demand. So it becomes a balancing act.

So if drug makers cannot meet demand, we just need more insulin makers, right? Well yes, that’s the easy answer. But reality isn’t so simple.

Enter the United States Food and Drug Administration – the FDA. They are the gatekeepers to the drug market in the United States and one of the primary gatekeepers to the health care market. Anyone who wants to make insulin or a vaccine or anything to be offered as a treatment for anything must go through them. First to be licensed as a drug maker (along with any State licensing) with periodic renewal fees, then the insulin you do make has to be licensed before it can be offered for sale.

Insurance definitely doesn’t help here either. And the effect insurance has on the price of everything in health care is pretty well established. (Hint: it’s one of the leading reasons health care costs so much.)

So why is insulin up 14-fold over 25 years ago? A combination of factors.

  1. Substantially increased demand
  2. FDA preventing new insulin makers from entering market
  3. Insurance hiding the cost of insulin allowing drug makers to inflate the price merely because they can

So greed is a factor, but it isn’t the ONLY factor. And I wouldn’t consider it a substantial factor either. Especially since the drug makers also have programs wherein they give away drugs to those who need them (with a proper prescription, of course) if they are low-income and meet other qualifications. And the cost of those programs is passed onto everyone else.

Then there’s the cost of what is needed to produce insulin. And not just the components, but the labor and machinery. I’ve already mentioned the FDA, but regulatory compliance is also another hidden cost. And all costs of business get passed onto the customers. Meaning the cost of the product goes up with the cost of production.

So there are a ton of factors going into why the cost of insulin – and really everything in health care – is higher compared to 25 years ago.

Yeah I get snarky at times

This was an email I recently received:

Hi,

My name is [REDACTED] and I’m an account manager at [REDACTED].

One of our clients has shown interest in being featured on an article on  your website.

Is that something you are able to accommodate?

We have a great inhouse team of writers and we can provide the content, or if you prefer, you can also write it and feature our client.

Can you please send me a price quote for an article? Please keep in mind we are an agency and require competitive pricing as we resell them to our clients.

I look forward to hearing from you,

Best regards,

[REDACTED]

Account Manager

And with that, I decided to send this as a response:

With all due respect, do you walk into a car dealership and, without any preamble, say “Quote me a price for a car…”? Not anything specific. Not providing any details of whether you’ve got a specific make or model in mind. Not listing out your needs. Just “a car”.

So care to tell me the name of your client and how they’re expecting to be featured on my site? Are they looking for me to review a product? A mention in an article relevant to their primary market? (On which knowing their name would allow me to research.) It would’ve been very helpful having that information up front, since that’s what I need to provide a price quote.

Thanks.

That was 5 days ago. Not expecting to hear from them.

And I’ll state this again: no one should be asking me about paid custom content given the very few hits per day my site gets. Which tells me the email they sent me is just another form email that gets cast out into the void to a mailing list.

Quieting the MikroTik CRS317

Build Log:

I actually never thought I’d be writing this article. Almost three years ago when I wrote my review of the MikroTik CRS317, I said it’s “quiet”. Even with SFP modules for GbE connections, since SFP modules do run hotter than optical modules.

Once I put the CSS610 into service, the fans on the CRS317 came on very infrequently.

So what changed?

Internet Upgrade

The whole 10GbE project started back in late 2016. Google Fiber came to Kansas City in 2015, and my apartment complex was part of the early rollout. Since having Google Fiber, with Gigabit up and down, it was the feature we looked for when shopping for another apartment with W/D hookups, and eventually our house.

Plus Google Fiber came with the benefit of it being locked at $70/mo. And that rate NEVER went up.

They recently introduced 2Gb service. (It’s 2Gb down, 1Gb up.) Having a 10GbE switch as the backbone on my home network meant taking advantage of that service bump was easy since one of the connectors on the new router is 10GbE RJ45. (I wish it also had an SFP+ cage so I could use optical fiber, but oh well.)

The switch being SFP+ with no 10GbE RJ45 port meant I just needed to buy an SFP+ RJ45 module. Specifically I bought MikroTik’s S+RJ10. Just plug and play with a Cat6A or Cat7 cable.

So what’s the issue?

It’s hot!

Pretty much all 10GbE RJ45 SFP+ modules run hot. There really isn’t any getting around since they also consume far more power. It takes more power to modulate a signal across a copper wire than through fiber. And more energy consumption means more heat. Active cooling on the SFP modules is the only way to counter this. Which I don’t know of a switch that actually does that.

So it was no surprise, then, that the fans were screaming as the module ran at 70°C or hotter. And with the linen closet where I have the networking equipment being right outside my office door, you can probably imagine how annoying that got. Even with good headphones.

Rigging for silent running

My MikroTik switch has two Chiefly Choice CC4020B12M fans. The manufacturer rates them at around 28.5dB/A on noise, pushing shy of 9 cfm at 7000 rpm. The CRS317 uses two 4-pin fan headers as well, but these are 3-pin fans. So up front these are nowhere near as bad as the fans in the Quanta LB6M.

And they were running at max RPM pretty much all the time after installing the SFP+ module.

Only one name came to mind for replacing the fans: Noctua. Against which I compared other 40mm fans for both airflow and noise. Despite the premium, Noctua had the best balance of both noise and airflow. (In my opinion as of this writing.)

The Noctua NF-A4x20 FLX is rated at around 15dB/A and pushes about 5.5 cfm at 5000 rpm. Much less airflow, which is the unfortunate tradeoff in trying to reduce noise by replacing these small fans. At even just 60mm or 80mm, the tradeoff isn’t nearly as steep, and you can easily find quiet 80mm fans with good airflow. One such fan with an adapter would easily replace both 40mm fans.

But the switch is now much more tolerable compared to the stock fans. And this is still a good upgrade to make even if the fans don’t run all the time. It’ll just mean the switch is virtually inaudible when they do. Which is perfect if the switch is being used as a desktop switch near workstations or in a home office.

So what about that active cooling on the SFP+ module?

Cooling things down

There’s about 20mm of space between the SFP cages and the switch’s lid. So no clearance for typical fans you’d find on the market. And I again wanted a quiet fan. So back to Noctua and the 10mm thick NF-A4x10 FLX. I used VHB tape to hold it in place over the SFP+ module, taping it to the front side of the switch blowing down.

A splitter cable connected the two rear fans to one of the fan connectors – there are only two on the mainboard. And the SFP+ fan is plugged into the second fan connector. With the three 40mm fans, even running at full blast, it is not audible from my office. The stock fans absolutely were.

And that dropped the operating temperature of the SFP+ module by about 15°C. It still runs hot, but the reported temperature is in the low 60s as opposed to the mid to high 70s.