I’m going too Mars again!
I’ve been doing a lot of Drupal work lately. For the last couple of days I’ve been struggling with the deployment of a website I’m working on. For some reason one of the standard Drupal tables in the Postgresql database ended up being owned by another Postgresql role. This resulted in an error in the deployment. I have literally been staring at the error for two days, I could not figure out where it went wrong. After a lot of searching on the internet I finally found out what the problem was!
Postgresql uses a database called
template1 when a new database is created as a template. For some reason there was a relation defined in
template1 for the table that caused the error in the deployment. The relation defined the table to be owned by another Postgresql role. The problem I had could be solved by removing the
template1 database, but this is only possible when you tell Postgresql the template is not a template anymore (because template databases cannot be dropped). So I had to issue the following command:
update pg_database set datistemplate = false where datname = 'template1';
Now you can
drop database template1;
after which you can recreate it using
create database template1 template template0;
Now I was finally able to deploy the website. Well, until another problem raised it’s ugly head. But that is a problem for tomorrow.
I was catching up on some blog posts by Derek when I read this here. So true.
This shows that Mercedes is totally lost when things don’t go their way!
Mercedes messy pit-stop sounds much better with Benny Hill pic.twitter.com/vxO1pzX0Cp— Tancredi Palmeri (@tancredipalmeri) July 29, 2019
Definitely the best move of the weekend! F1 needs to get its act together.
Via Tim Ferris.
Productivity is for machines, not for people. There’s nothing meaningful about packing some number of work units into some amount of time, or squeezing more into less. Think about how effective you’re being, not how productive you’re being.— Jason Fried (@jasonfried) December 2, 2017
What more can you say?
This reminds me to start drawing!