Categories
ranting

Server Migration

After 20 years I have finally migrated off of the original confusion.cc server. Since I was in college confusion.cc has been hosted on a server in California. Originally on a physical box in a managed data centre, what is known as a Server Colocation or just “colo”, and later a virtual machine in the same centre. But I’m lazy and have not kept the server up-to-date since I migrated the family email server to a fully managed service ten years ago. And now the confusion.cc server is so out of date that it’s a hopeless task to try and update all the software. Things came to a head a few months ago with the release of WordPress 5.2 which requires PHP 5.6.20. Confusion.cc was limping along on PHP 5.2.5, from 2007!

So, now comes the end of the colo era for confusion.cc. The site is now running on AWS. And if the website sees high levels of traffic in the future, I can easily switch to dedicated server hosting plans. But one does not move a two decade old website without a few issues…

After setting up a vanilla WordPress installation on an EC2 instance and a MySQL RDS instance I uploaded the confusion WordPress database and viola! What’s with all the funny characters showing up in the posts? Best I can tell the original WordPress version used on confusion (installed sometime around 2004, when WordPress was version 1!) defaulted to latin1 encoding but somewhere along the way I started using Unicode characters in posts. For some reason it all worked. Now however, the default WordPress installation uses UTF8, ergo gobbledygook… there are numerous posts out on the web documenting various ways of fixing the DB. Changing the DB config, the individual table config and even the table row config… and there are grep-sed-awk magic spells to cast on a dump file that you can then load into a new DB instance and after a few prays to the elder gods all your Unicodes are correct!

And then there was the one hack to just define the DB_CHARSET variable in the wp-config.php to ‘latin1’ and Cthulhu continues to dream, un-disturbed, in Rayleigh.

Once the posts were loading it was time to tackle all the other assets; scripts and images which on the old server were loaded from sub domains. Originally this was to allow browsers to download the assets in parallel. This is because browsers limit the number of concurrent connections to a sight. However since I don’t have an image heavy design and most scripts are loaded from other sites or CDNs I don’t think it’s a big issue. So I uploaded all the content to an S3 bucket. I had to replace all the links in the theme and posts and then add a mod_rewrite rule to redirect the requests to the S3 bucket.

I also had to drop the “/wp/” from the URL. Long ago when I setup WordPress on the colo I had other things running at the top level so putting the WordPress installation into a directory made sense. Today WordPress is the CMS for the whole site so this setup doesn’t make sense. So off with the “/wp/”, which meant meant updating any post linking back to a confusion post. (This also means that any link to a post from Google or any other random site would be broken. So I added another mod_rewrite rule). I also updated the WordPress settings. And as soon as I did all of this I couldn’t continue to load the pages using the EC2 instance IP. So I had to update the confusion.cc DNS records to point to the AWS site. So, technically it was at that point that confusion.cc moved over to AWS.

Then there was the issue with XML RPC. The WordPress apps were not working. After much investigation I managed to pin it down to lacking PHP support for XML RPC in the default installation. I had to install additional packages for PHP-XML, PHP-XMLRPC and PHP-GD.

The last two bugs turned out to be caused by the same thing. First there was an issue with the icons for the sharing buttons not displaying. The icons are actually a font loaded via CSS from the Jetpack WordPress plugin. Funny thing is they worked on the plugin configuration page but not the site itself. The second issue was with the navigation menu. Clicking on the categories, archives or search option did not display the DIV containing the forms, so there was no way to navigate via categories or archive links and you couldn’t search. On the bright side “Random” still worked. After much tinkering and investigation I found a PHP opening tag was messed up in the header.php file. What should have been “<?php” was just “<?”. No idea how that happened… gremlins.

There may be other things. With nearly two decades of cruft I’m sure I’ve missed something…

Anyway. Next task is to finally consider updating the theme. I’ve been running on this theme since 2013 and it’s only a minor update if an even earlier version and that was my own hack on the original Kubrick theme from WordPress! HTML and CSS have come a long way since then. As well as Javascript – I don’t think in need to use jQuery anymore. So maybe I will get around to fixing it.

Categories
quotes ranting

We don’t have the bus to ourselves

“I see we have the bus to ourselves,” she said. Julian cringed.

“For a change,” said the woman across the aisle, the owner of the red and white canvas sandals. “I come on one the other day and they were thick as fleas—up front and all through.”

“The world is in a mess everywhere,” his mother said. “I don’t know how we’ve let it get in this fix.”

Flannery O’Conner, in Everything That Rises Must Converge

O’Connor’s story is speaking about racisim in the 50s against blacks in the American south, the line before is “Everybody [on the bus] was white”. But, it would work today for others, Hispanics in America, Polish in England, Africans or Syrians in much of Europe. Bigotry is bad and the world is once again in a mess everywhere; people, even politicians, thinking and saying things like this.

Categories
ranting

Two thoughts on climate change

First an analogy: I’m sure it’s been used before but I was talking about climate change ether other day with a coworker and used this one; climate change is like lifestyle diseases. Like diabetes or high blood pressure or cholesterol, climate change is something we were warned about, that it would be a consequence of our continued bad behavior and, like lifestyle diseases, too many people have ignored the warnings. This is a particularly good analogy for my peers, we are in our forties and all that past bad behavior has started catching up with many of us. Too many of my coworkers are dealing with diabetes, high blood pressure or cholesterol.

So, climate change is like lifestyle diseases: it’s a problem created by the success of the first world, and you have been warned about it for years. Doctors have been telling you that present you needs to eat better to protect future you for most of your life. The doctors told you that you eat too much sugar and salt, that you get too little exercise. But present you figures “I can have one donut, I’m gonna start going to the gym” or “some salty fries won’t kill me, I’ll eat better tomorrow.” But future you never gets a chance to eat better and exercise because when the time comes present you is always making other plans and giving excuses. Then one day present you is pricking your finger every few hours to measure your blood sugar, or taking pills for high blood pressure or cholesterol. Present you has got to live with the consequences of all the bad behavior of past you and there is nothing future you can do about it anymore. Preventing the disease is always better than treating the disease, but past you always assumed future you would be better than present you ever was. Psychology knows this, that future you is always going to be better behaved until present you is future you and then you behave the same as past you always has; present you likes donuts and fries just like past you did.

Like first world lifestyle diseases, climate change was avoidable but past, and indeed, present humanity has failed to curb the bad behavior. The scientist have been warning us for years that we need to take better care of the environment to stop climate change. Now we have passed the point of preventative maintenance, where future humanity could have done better and everything would have been alright. But present humanity continued to be as bad as past humanity and now future humanity will need to manage the chronic disease we have infected the planet with.

Even if you don’t believe that climate change is man made we are to the point where we need to do something to stop the changes if we want to keep living. Just like changing your diet when you get diabetes or high blood pressure we need to change our consumption; less meat, less plastic, less fossil fuels. But once the disease has set in you can’t use change your diet and hope it will all be better, you need some medicine, you have to take pills or insulin shots.

Which brings us to thought two: we can’t rely on stopping our bad habits alone. We need to reduce our use of fossils fuels, stop using plastics, limit meat, and many other things too. But we need some medicine too. And just as science continues to look for a cure to diabetes and high blood pressure, to reverse the disease we need to invest in finding a cure for climate change that we have already caused. Here I want to see America take the lead, to get America out of this funk of “all we have is capitalism, all we have is making money.” I think America needs a collective challenge one a global level to invest itself in.

America needs a nation commitment to tackling a global level challenge to grow, we don’t seem to work well without a grand shared goal: ending the depression, saving the world from Nazis and Kamikaze, or beating the Russians to the moon. Since the fall of communism we have not had any real global challenges to rise to. So, since yesterday was the 50th anniversary of the moon landing, I propose to tackle climate change in a similar way as we tackled the race to the moon. Let’s challenge America to return the atmosphere to the carbon dioxide level of 1900, by the year 2030, and keep it there.

“And keep it there” is an important part of that challenge. It means that we don’t get off the hook for changing our ways. We have to stop adding to the problem; stop adding to the carbon dioxide problem. Even if NASA and NOAA can develop a plan and succeed in sucking the excess carbon dioxide out of the atmosphere we need to find alternatives to putting it back. Even if they can return the atmosphere to 1900 we also need to see how we tackle plastics in the environment, industrial chemicals in the environment and massive distraction of the environment through logging and farming. And how do we help the people who are disaffected by fixing those problems. But “return the atmosphere to to the carbon dioxide level of 1900, by the year 2030, and keep it there” is a mission statement we can remember and America can take up a challenge for the good of all mankind.

Categories
ranting writings

Fish Fetish: The Breatharian

Oh my god. Flashback! I just cam across this article on I Fucking Love Science:

WTF is “breatharianism”? If you are not familiar:

Breatharianism, in the traditional meaning, is a belief that it’s possible for humans to survive without eating food. Breatharians claim that food, and sometimes even water, is not necessary for humans to live, and instead people can keep themselves alive with breathing and sunlight.

James Felton in Please Do Not Attempt The Breatharian Diet, You Need Food To Live [iflscience.com]

I know this delusional bullshit from a IRL encounter with a practitioner before Instagram, before social media, in the age of dialup. I can’t believe this story is not already posted here, but back when I sold fish for s living I met a “breatharian” so here is a factionalized account of that encounter…

It was a slow weekday at the shop, the dry stock delivery was tagged and shelved and it was only two PM. By some coincidence the shop still had a full house: J████ was working. I wasn’t working but O— and I were just hanging out with J████ after lunch till it was time for him to head to work. J███ and D– were waiting for J███’s Girlfriend S—- to come by the shop and they were going off somewhere or other to play tennis or mountain bike or something because they were heard discussing “How do I choose a tennis racket?

S—- is important here so some backstory: S—- was an ex-marine, single mom who was becoming ever more obsessed with new age natural healing. S—- was cool but even among a group of liberal vegetarians we all agreed she had jumped right off the deep end into crystals and raw food diets to try and fix her hypochondriac illnesses. At this point she had been on raw food for a few weeks or a month.

When she showed up at the shop that afternoon she had a friend none of us knew with her. I don’t remember how the conversation went up until S—-‘s friend said something to the effect of “I’m a breatharian.”

J███: “What is a breatharian.”

S—-‘s friend: “It’s a movement to free us from our fear of starving and remind us that all we need is to be open to the Universes energy.”

I think D– finally said something like “what?”

S—-‘s friend: “Yea. You see everything your body, and your mind, needs for nourishment it can get from just breathing in the energy of the universe.”

Beggs: “But you have to eat. Or you’ll starve to death.”

S—-‘s friend: “No, no, no. That’s just fear. The companies and the government they teach everyone this and we all develop this fear of starving if we don’t eat. But it’s just fear. You don’t need to eat or drink.

Beggs: “That’s just not how biology works…”

S—-‘s friend: “That’s just fear and lies. See the founder of Breatharianism, he’s been living without food and water for decades. And he’s not even aging.”

O—: “That’s because he’s fucking dead.”

J████: “So, like, how long have you been starving yourself?”

S—-‘s friend: “I’ve been training for a year now. I still can’t break the fear. Sometimes I go a week without eating, I just drink juices.”

O—: “So you cheat. You should commit to it, one less crazy in the world in a few weeks.”

J████: “You really believe you can live off sunlight?”

Beggs: “Photosynthesis!”

S—-‘s friend: “It’s not photosynthesis, it’s not sunlight it’s more than that. The universe is filled…”

This exchange went on for some time, round and round the loony bin as we all stood around the counter. Eventually it got a bit hostile, S—-‘s friend and Owen raising their voices. As S—- was extracting her friend and heading towards the door O— had the last line, “if there was a way to live without food and water, it wouldn’t have been discovered by some nut in Australia, the Ethiopians would have figured it the fuck out in the eighties!”

D–: “You know, the more I meet S—-‘s friends the more I understand how the Branch Davidians could exist. And the more I realize there is nothing wrong with S—- a cheeseburger wouldn’t fix.”

Categories
ranting

Shit on fire, yo.

Authorities with the regional conservation office suspect the fire started on a farm when a pile of animal manure that wasn’t being properly stored spontaneously self-combusted.

Maddie Stone, in Wildfire Explodes in Spain as Europe Reels From Record Heat [gizmodo.com], on Gizmodo

It’s so hot literal piles of shit are bursting into flames. And while Trump screams “perfectly normal” in the background, the Sahara has come for Europe: It was 45.9 Celsius (that’s 114.6 in ‘Merican) somewhere in France [washingtonpost.com].