All posts by cormander

tpe-lkm version 2 released

It recently came to my attention that RHEL/CentOS 7 kernels started support for the ftrace system as of version 7.2. This is an in-kernel system to instrument kernel functions in a safe and clean way.

Since using ftrace basically meant a rewrite of most of the tpe-lkm code, and dropping of support of older kernels, this new release has bumped the major version from 1 to 2.

New features in this release include:

* guaranteed safety of kernel function hooking
* better long-term support from future kernels
* added harden_ptrace to tpe.extras
* added hide_uname to tpe.extras
* ability to soften certain TPE checks with filesystem attributes
* default mmap whitelist to allow Gnome Desktop to boot properly
* better logging options

As always, you can download it from the tpe-lkm github project page, or install via yum from

Additionally, the availability for this in-tree method of hooking kernel functions has wider implications for implementing security features in distribution kernels. For more information, read the following whitepaper I drafted:

Distribution Kernel Security Hardening.

Happy TPE’ing!

Solar Panels on an Electric Vehicle

I’ve seen this question asked a ton of times;

Would it be worthwhile to put solar panels on an EV?

It’s a great sentiment, as the two seem to go together quite well. In short, however, the answer is no.

Now, I’m talking specifically about outfitting an Electric Vehicle with photovoltaics. Installing them on your home or business makes a ton of sense, with or without owning an Electric Vehicle. It’s just not sensible to do so on the car itself.


The above photo is of a Fisker, and is basically what a car lined with photovoltaics would look like.

Disclaimer; when you talk about solar energy, the devil is in the details. What’s the rating of the panel? What’s the inverter and wiring efficiency? What’s the distance between the panel, inverter, and meter? What’s the geographical location and time of year? What’s the local weather patterns like? In short, there is no one-size-fits-all answer to questions about solar energy.

With that in mind, I’ll be using data from my own home solar system, so the data matters to me and maybe not so much to someone else. I’m selfish like that. Also, I’m not an electrical engineer so I might be missing certain details. Bah humbug.

With that said, let’s dive right in.

I drive a Tesla Model S. The specs don’t give details of the specific area of the car’s surface that I can find, so I had to grab a tape measure and do it myself. Assuming you’re replacing the sunroof with the panels, and putting them on every inch of the body of the car that isn’t a window,  windshield, or light, here’s the breakdown of my rough measurements (in inches) of various areas of the car:

Hood – 48 x 60
Roof – 46 x 60
Trunk – 10 x 54
Rear – 70 x 28
Back corner – 36 x 30 (twice)
Side – 90 x 32 (twice)

Put it all together and you’ve got about 111 square feet of surface. Any inaccuracies here can be blamed on the fact that I was taking these measurements with my 7 year old son holding the end of the tape measure and I was more concerned about making it fun for him than being precise.

On my home I have SolarWorld 280 panels, which give 280 watts at peak, and 18 square feet each. So, the car has enough area for 6 of these, once they are properly chopped up to fit on the various surfaces. All in all, you’re going to get 15 watts per square foot of panel at peak output with this system.

That’s a 1,680 watt system. I paid about $3.60 per installed watt on my home solar system before government incentives, so this hypothetical Tesla Solar system would run just over $6,000. Being built into the car, it would probably cost a lot more.

However, at any given point, you’re going to have, at most, about 66% of the surface of the car in the path of sunlight. Also, most of it won’t be optimally facing the sun, so you won’t get the peak output. Therefore you have a massive drop in capacity.

So, let’s call it 75 square feet at 10 watts per square foot, or an average output of 750 watts. That’s being incredibly optimistic, and not taking cloudy days into account.

A really good week with lots of sun looks like this:


A bad week with cloudy days and lots of rain looks like this:


A loss of 20% overall production due to weather seems like an accurate estimate.

Additionally, you have added weight and aerodynamic concerns. For arguments sake, let’s say the car’s shell was made of the panels, that they fed directly into the battery (no inverter needed), and there are no changes in weight or aerodynamics to the car, which toes the line of being unrealistic.

On a nice and sunny day during spring or fall, when there is the year’s average amount of daylight, Salt Lake City gets 5.25 hours average of solar radiation. 750 watts x 5.25 hours x 80% weather = 3150 watt hours, or 3.15 kWh in a single day, give or take. That’s an oversimplification of the equation, but is close enough.

What would that power?

Tesla Model S has a range EPA of 300 watt-hour per mile, so 3.15 kWh of energy would give you roughly 10 miles of range. However, if we’re talking about the car just sitting there all day, the topic of vampire drain applies. This is the amount of power the car draws to power its systems even when the car isn’t in use.

I want to say I lose about 10 miles in a 24 hour period while not plugged in. That number varies from day to day depending on a lot of factors, but 10 is an easy to remember number. You’ll lose maybe half that in energy saving mode, which the car automatically after it hasn’t been driven in a while.

In short, my car covered in a magical photovoltaic shell would cover the vampire drain, and maybe add a few miles to the meter during the summertime. And that’s best case scenario. Then again, my car is in covered parking at work all day, getting no sunlight, so really it wouldn’t do me any good.

Now, you can argue that the system I’m analyzing is a far cry from the latest and most efficient, that you may not drive very much on a daily basis, etc etc. The real question ought to be; do you want to spend thousands of dollars to never have to plugin your car for your short daily commute? If you have more dollars than sense, then go for it. Otherwise, you’re better off spending that money properly installing the panels on a roof that will optimally capture that sunlight, and taking the 10 seconds a day it takes to plug and unplug the car.

For comparison, that same $6,000 system when optimally installed on a south facing roof would produce a year-average of at least 6 kWh per day, with the above weather taken into account. That’s twice the energy, and it’s without the cost and headache of figuring out how to line an entire car with photovolatics. Not to mention how ugly it would look. Just pay someone to bolt the panels onto your roof, and you’re done.

Day Trips Galore

It’s the American Dream; a family singing in harmony while on the open road, traveling to a destination everyone wants to go to, and stopping at a series of tourist traps.

Are you kidding me? For my young family, travel has never been anything like that. Years of “I feel carsick!” and “are we there yet?” echo through my mind. Add the cost of gas to that, and it hardly seemed worth it. Why pay a bunch of money just to have everyone constantly complaining? We took a long road trip maybe once or twice each year, and day trips weren’t something of desire.

That is, until we got our Model S.

Four Smiling Faces


You see that? There’s something about the Model S that’s transformed the perception of road trips amongst my children. My best guess is it’s because they don’t get carsick anymore; it was a major problem. Then we got Model S, and suddenly it wasn’t. There’s also the cool factor of a sleek looking environmentally friendly high performance vehicle compared to the sputtering mommy-mobile we were driving before. The car is simply much more fun to be in.

The 6 months since we got the car have been the aforementioned American Dream. Sans the singing, of course – that’s a little too cliche for my taste. Also, I don’t ever hear “are we there yet?” anymore. The kids have figured out how to read the map on the 17 inch touchscreen. I’ve now got four budding orienteering specialists on my hands.

Getting the Travel Giggles

I don’t have the performance Model S, but the car still has plenty of kick. When the stop light turns green and I’m up front, the rear view mirror fills with other cars still seemingly at a stand-still, and I’m not even flooring it. On occasion when I do, like when getting onto the freeway, the car’s interior echos with the giggles of happy children asking for more. Recently when I joked that after regular trips to the local theme park that the car must feel sad that it’s always taking us there, but never getting to ride any of the rides, a child quickly informed me that the car itself is a roller coaster ride.


The Car is a Fortress

You could call Model S a Fortress. Not only because it has the highest safety rating of any car ever made, but because there’s so much room in it! Take the drive-in theater, for example. Most people bring lawn chairs, or sit in the back of their pick-up truck. Few actually stay in their vehicle because it’s cramped and uncomfortable. Not this car – pop the hatchback, fold down all the sets, and you’ve got plenty of space to just veg out.



Frequent Road Trips

Previous to Model S, long road trips were maybe once or twice a year. Now, they’re almost monthly, and that’s not counting weekend day trips. Before, going places was a chore. Now, we’re always going somewhere, and I have the supercharger network to thank for that. Being concerned over the price of gasoline is a distant memory, as now we can go literally anywhere the road can take us without paying a dime for fuel.

In 6 months of ownership, we’ve put over 12,500 miles on the car. The only problem is, we’re only just past halfway through the year, and I’ve used all my vacation days!


Reconnecting With Our Past

In looking for places to go and things to do, we discovered a ghost town nearby with roots to our past. I was raised in the small town of Laie, Hawaii, where two of my kids were born before we left for Utah. In the nearly 10 years we’ve lived here, we hadn’t heard of the place; an old colony of Hawaiians who settled in Utah. The only reason we discovered it is because of Model S motivating us to seek out places to go. It was a great day trip, and we’ll be going back, thanks to the Tesla Supercharger station in Tooele County.

Aloha Iosepa

A Family Legacy

I have no plans to sell Model S, nor buy a gas car ever again. When my little ones outgrow the jump seats, we’ll be buying a Model X. It just so happens that at that time, my oldest daughter will be driving age. Her first driving experience will be in an electric vehicle. It is my hope that all of my children will enjoy the awesomeness that is this car, and never have to press the peddle of a gas powered car in their life.

7 reasons why an Electric Vehicle is not just about the Environment

I live in an area of the United States where most people think “environmentalism” is a dirty word. Ironic, since it’s the opposite of dirty, but it’s something I have to work around should I want to remain cordial with the people in my community.

I bought an Electric Vehicle (EV) just over three months ago, and boy I wasn’t prepared for the constant bombardment of interaction with strangers because of it. I’m perfectly happy to answer questions, or listen to their criticism, but I learned pretty early on the best way to approach the topic in a place with people who have quite a different world view than I do. So when someone starts out with a snide question such as “So, you must be a tree hugger or somethin’, huh?” I begin like this:

Let’s put aside the whole climate change / global warming debate, and let’s talk about the reasons why you might want to buy an EV.

1) Cleaner air

Doesn’t matter what you believe about what’s bad for the earth, it’s a pretty widely accepted fact that polluted air is bad for humans. It’s also a widely accepted fact that air pollution is primarily caused by cars, particularly in urban areas. Certain cities have it pretty bad, including the one I live in. Since we’re in a valley, inversions are common and people die as a result of bad air days.

If everyone in the city drove an EV, there would be far less air pollution, at least on a local level. The coal power plant that’s far away will spew its exhaust for the cow’s to breathe, not us. So, I drive an EV because air pollution is a public health issue.

2) Convenience

The “how far can I go?” question is entirely a moot point for most people. I rarely drive more than 70 miles in a day, and few people need to drive more. Most EVs have more range than that. When I do drive longer, I typically know I’m going to need to ahead of time, and can make plans if that’s what it comes down to. So despite having an EV that can go 265 miles on a single charge (so I don’t have to make plans nearly as much as if I had a car that could only do 100), I never ask myself “am I going to make it?” It’s a simple question of math. You don’t let yourself run out of gas, and you wouldn’t let yourself run out of charge.

That said, I plug my car in when I get home. In the morning, it’s always full. I never have to stop and refuel unless I’m going on a long road trip. And with 4 kids in the car, believe me, I need to stop every couple hours anyway.

People spend more time than they realize at gas stations. It’s not just the time it takes to park, get out, pay, pump, and leave. It’s the detour from your route. It’s the having to hunt around for a gas station on the way home because you drove to work on fumes because you forgot to fill it up over the weekend and you didn’t want to be late to work on Monday.

Then there’s the silly people who drive miles out of the way to get fuel that is a few cents cheaper per gallon. What a waste.

Bottom line, I just get in my car and drive, and snicker whenever I drive past a gas station.

3) Lower Cost

But your EV is very expensive“. Well, so is your enormous SUV. Or your luxury sedan, or sports car, or pickup truck. Nobody ever makes a big deal about the cost of a gas car. The topic didn’t come up at all when my coworker bought his Lexus (which costs more than my car, by the way, and he now has extreme buyers remorse now that he’s ridden in my car). But the moment you start talking about EVs, suddenly cost becomes the center issue. Really?

Up front cost aside, I’m thinking long term costs here. Gas cars cost a lot to maintain compared to EVs; you have oil changes, spark plug replacements, tubes that leak, and any one of over a thousand moving parts . Let’s hope something like your transmission doesn’t go out before the warranty is up; I’ve had to replace one before, they are NOT cheap. And then, of course, there’s the fuel. That’s a cost that never goes away, is never cheap, and has deep economic consequences that nobody likes to talk about.

It costs me a dollar to drive 30 miles, and that’s assuming I paid for the all of the electricity in the first place. Many work places offer free EV charging. EV charging spots in parking spots of shopping malls and grocery stores and becoming more and more common. Essentially, I’m paying a lot more per mile in tire wear and tare than I am in fuel. Thousands upon thousands of dollars in savings per year. And, of course, the higher your mileage requirements, the sooner you’ll get your return on investment in fuel savings alone.

4) Sustainability

I don’t mean environmental sustainability, I’m talking about stable fuel costs. The price of gasoline is incredibly volatile. Electricity, on the other hand, has a very predictable cost.

When the price of gas spikes, and the economy slows. The price of everything goes up, because everything requires transport. Businesses make less money, products costs more so people have less money, and, of course, people have to put more of their already hurting budgets into buying more expensive fuel. It’s a vicious cycle.

I could then start to talk about installing solar to charge your car and how it’s cost has grid parity and the predictable long-term energy costs thereof, but I won’t get into that because, well, solar is another dirty word where I live. I’m the only home owner in my entire neighborhood with solar panels. I’m also pretty sure I’m the only one in the neighborhood with an EV. Considering where I live, a part of me is glad my south facing roof faces away from the road.

5) Independence

Like it or not, the United States lives and breathes oil, and most of it isn’t produced locally. Our country is completely and hopelessly dependent on foreign oil. Why? Because we need it to fuel our transportation. It’s a simple as that. Cut off the oil, people can’t drive places, and a lot of very bad things happen as a result.

They say that “Hell hath no fury like a woman scorned”. I respectfully disagree. Hell hath no fury like an American who has to adhere to fuel rations, or wait in line to buy gas. It’s happened before, and eventually, it will happen again. I fear that next time it does, it’ll be a lot worse.

If everyone drove an EV, we wouldn’t need foreign oil. Not in the way we do today, anyway.

6) Performance

Honestly, this is a thing I used to not care for. I had a Camaro because it looked nice, not because it went fast.

Well, all it takes is one experience in your Dodge Caravan trying to get onto the freeway when a fleet of Semi trucks won’t slow down for you to make you care about performance.

No matter how little horse power your EV has, it has instant torque. There are no gears to shift through; all the power of your motor is instantly available to you, which means you can get going up to a sufficient speed in very little time.

I consider the ability for a car to accelerate in this way a safety feature. Performance matters, even if you don’t use it all that often.

7) Setting an example for my children

It’s one thing to talk to your children about things that are important, it’s entirely something else to make them experience it. It’s about making abundantly clear what your priorities are, and making decisions with them in mind. Buying an EV is an investment in my personal finances, the long term economics of my community and country, and of course, my commitment to the environment. What better way to show my children that if anything is worth doing, it’s worth doing right?

I could take an expensive family vacation every year, and buy every new gadget that comes out. Or, I can drive and EV. I could buy a bigger, nicer house; or I can install solar panels. And you know what? In the long run, I’ll find myself with more money than I would have otherwise due to the return on investment, so we will, one day, get to have our cake and eat it too.

It is said that for true happiness, you should spend your money on experiences rather than things. While an EV is a thing, driving it is an experience in and of itself, one that I have and enjoy every single day of my life. Trust me, if for no other reason than the driving experience, I will never again buy a gas car.

My online “office hours”

I am mentoring the develop a kpatch delivery mechanism for the CentOS Google Summer of Code (GSoC) project. Per my recent “office hours” email to the CentOS GSoC, I’ll be online from 10pm to 11pm US Mountain time on weekdays in the #centos-gsoc and #centos-devel chat rooms on

I’ve decided that I’ll keep these hours even after the project ends. If anyone wants to get in touch with me outside of email, just drop me a chat during those hours. My username is cormander.

tpe-lkm version 1.1.0 released

A few weeks ago I go an email that tpe-lkm didn’t build on EL7. To be honest, I didn’t even know that EL7 had been released, I’ve been so disconnected from things outside of family and work the past few years.

Anyway, I got back to work and now everything is nice and ready for release. You can download it from the tpe-lkm github project page. It has a few new features as well.

Happy TPE’ing!

The winter solstice is my new year

It’s always made more sense to me that the start of the year should happen on a solstice, like it does on the hobbit calendar. That being said, I’ll make my new years resolution today, on Yule, the celebration of the winter solstice and the renewing of the sun.

2012 hasn’t been the best year for me personally. I’ve been in a pretty bad place mentally and while I blame the stress of my job and having a large family, I have to take some personal responsibility too. I’ve been a bit of a sloth, and it’s only hurt my personal relationships.

2013 is going to be the year I turn that around. This next year I’ll start back up coding on open source projects again, being less anti-social, and finding a better work/family/me balance. This next year, I’ll be a better person.

Okay so that’s a generic (and a bit cliche) of a new years resolution, but there you have it. May your 2013 be better than 2012 as well.

Happy Turkey Day!

For those of you who loosen their belts and consume unhealthy amounts of food today, have a merry time! For those of you who don’t, you’re free of all the family drama.

For those of you who say “Happy needless turkey murder day”, the needless turkey murders happened about a month ago. Today would be “needless turkey consumption day”.

Whichever of the above you fall under, have a great day.