Getting the size of MySql databases and tables

Getting the size of MySql databases and tables

Friday, Jan 4, 2019
Getting accurate results about the size and growth of your database tables enabled you to make smart decisions about partitioning and management of storage. I can guarantee that no-one wants to run out of storage on a database server. Show the largest database from a database server This has the assumption that you have access to the root account on the database server. You can normally look inside /var/lib/mysql to get an idea of the overall disk space, however, you will likely get more reliable results from querying the information_schema table inside MySql. ...

Read more
Testing UDP port connections using netcat

Testing UDP port connections using netcat

Wednesday, Dec 5, 2018
Sending messages over the Internet can be fun (we are doing it now). However, testing that connections are correctly established behind a mask of firewalls, load balancers and application servers can be challenging. Netcat offers a simple way to test the sending of messages between two servers and it is already available on the majority of server installs. Using netcat is relatively straightforward. The core thing we are doing here is using both UDP -u and listening -l. So when you use the command netcat -ul you are telling netcat to listed on UDP rather than TCP. ...

Read more
My Most Popular Command Line Commands

My Most Popular Command Line Commands

Tuesday, Sep 4, 2018
What commands do you use most on command line? As a daily (hourly) linux user, I use command line tools for almost everything that I do. Opening files, copying, moving, making connections (ssh), starting containers (docker). But what ones do I use most? Here is a little command to find out for yourself. Find out your top 10: history | awk '{CMD[$2]++;count++;}END { for (a in CMD)print CMD[a] " " CMD[a]/count*100 "% " a;}' | grep -v "./" | column -c3 -s " " -t | sort -nr | nl | head -n10 My Top 10 1 488 16.1857% cd 2 425 14.0962% git 3 371 12.3051% ssh 4 337 11.1774% docker 5 335 11.1111% ls 6 118 3.91376% aws 7 115 3.81426% sudo 8 94 3.11774% code 9 65 2.15589% docker-compose 10 60 1.99005% vim What does this say about me? Well, first off, I should say that this is not necessarily unexpected. I use cd a lot, which is mainly to move between directories. You can also see that I use docker and docker-compose quite often. And also that almost everything is in git. ...

Read more
Build, Test, Store and Distribute Docker Containers with GitLab

Build, Test, Store and Distribute Docker Containers with GitLab

Friday, Mar 2, 2018
The use of Docker containers has exploded (at least within Web Development) and therefore we have a whole bunch of new tools that can be used to manage the DevOps process. However, there are a massive range of tools that can be used to achieve all of these. Be it Git hosting (GitHub, Bitbucket); Continuous Integration and Delivery and Build Tools (Jenkins, CircleCI, Drone); Docker Registry (Docker EE, Quay.io), or a range of other add-on tools, there sometimes seem as many new, great products in the DevOps area as there are Javascript frameworks(!). However, I feel that GitLab offers a single solution that is able to compete with other established tools and potentially enable you to have a full professional delivery platform for free (within some restrictions on numbers). ...

Read more
What I Learnt from DockerCon Europe in Copenhagen

What I Learnt from DockerCon Europe in Copenhagen

Sunday, Nov 12, 2017
It has been a while since I returned from DockerCon Europe in Copenhagen, and despite doing a presentation 4 days after arriving home for Docker Cambridge meetup group, I haven’t yet done a blog post for it. However, that is about to change. So, here is my review of DockerCon Europe. Overall, what I love to see in software is passion and ideas around everything. I remember feeling how exciting it was to be involved in a massive open-source project like Drupal in 2011 at DrupalCon London and to me it seems that Docker is around the same stage of growth now (in terms of number of attendees), however, its potential as a software solution is far different to Drupal. My involvement with Docker started seriously around 2 years ago, when looking for scalable solutions for deploying the same parts of software and I am probably even more committed to it as a solution than I was in 2015. DockerCon left me with 3 things: ...

Read more
Docker DevTools: Docker as part of your development toolset

Docker DevTools: Docker as part of your development toolset

Wednesday, Jul 26, 2017
The use of tools seems to have exploded in the past few years. Simple web applications take 5 tools just to build and more complex setup are even more prevalent. Add to that that we also end up configuring our tools to better suit our needs and you are faced with a big dependency problem. How do you manage those dependencies? My most recent answer is Docker. It’s not easy for developers and users to use tools Tools were invented to make doing tasks easier. And in software we often abstract those tools further. However, making sure that everyone can use those tools is challenging. Just look at how long people spend setting up machines and every time they have a new project the mess starts again. It’s not easy for developers and users to use tools. Onboarding ...

Read more
Tidying Docker Containers and Images without Filling Your Disk Space

Tidying Docker Containers and Images without Filling Your Disk Space

Tuesday, Jun 13, 2017
Docker. You know that I love it. I guess maybe sometimes I love it a little too much because on some of my test servers I have been filling up a lot of GB with new images and containers. All of which hang around indefinitely if you don’t clear them. Add to that if you have a continuous integration pipeline that builds a new container every time you do a commit/push and you have an ever growing disk of redundant Docker containers and images. ...

Read more
Digital: The Stack and The Roles

Digital: The Stack and The Roles

Sunday, Jun 4, 2017
The most recent buzz word around is digital, however, it is often used as a catch all term for almost anything that is related to computers. So, what is the scope of digital and where do different roles exist inside the landscape? Generally speaking, I term digital to be anything that uses the wider Internet, however, that does not mean anything that is networked. So, simply accessing a file server is not using digital services, however, using a web application to access a file server is. ...

Read more
Starting Docker: Making Drupal PHPCS Docker Container

Starting Docker: Making Drupal PHPCS Docker Container

Thursday, Dec 29, 2016
Making your own containers can be a super useful way of not only understanding more about docker, but also for understanding more about the systems administration of your applications or docker images. Maybe you want a specific container for running configured services on your machine, or maybe you want to look at packaging your entire system inside a docker container to make it super easy to run. In this quick post, I am going to dover making a Dockerfile and also what to write in it so that you can start making your own containers, today! ...

Read more
Starting Docker: Using tools from inside your containers

Starting Docker: Using tools from inside your containers

Wednesday, Dec 14, 2016
So far we have been discussing using containers, largely from inside the container. However, sometimes you simply want to use tools from inside your docker container rather than having the dependency nightmare of having everything installed locally (or on your server). Attaching/mounting into your Docker container The process of attaching or mounting local files into your container will give you the ability to use those files inside your container. Or store new files created from inside your container to the local file system. This can be really useful in two ways. Firstly, you can look at using the container to run processes such as npm/yarn or composer or ruby gems or you can look at services, such as a webserver. It gives you the ability to have multiple, separate installations of the same software, and simply and easily manage those processes or services with minimal pain of upgrade or management. ...

Read more