Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View fernandoaleman's full-sized avatar

Fernando Aleman fernandoaleman

View GitHub Profile
@fernandoaleman
fernandoaleman / mysql2-m1.md
Last active April 22, 2024 23:15
How to install mysql2 gem on m1 Mac

Problem

Installing mysql2 gem errors on Apple silicon M1, M2 or M3 Mac running macOS Sonoma.

Solution

Make sure mysql-client, openssl and zstd are installed on Mac via Homebrew.

Replace mysql-client with whichever mysql package you are using

@fernandoaleman
fernandoaleman / install-rabbitmq-centos-7.md
Last active April 22, 2024 19:00
Install RabbitMQ on CentOS 7

Install RabbitMQ on CentOS 7

sudo yum -y install epel-release
sudo yum -y update

Install Erlang

Download repository

@fernandoaleman
fernandoaleman / how-to-clean-up-ubuntu.md
Last active April 22, 2024 07:57
How to clean up Ubuntu

How To Clean Up Ubuntu

Some simple ways to free up space on Ubuntu

Remove Unnecessary Packages and Dependencies

apt-get autoremove
@fernandoaleman
fernandoaleman / how-to-manually-update-chef-server-ssl-certificates.md
Last active April 19, 2024 21:16
How To Manually Update Chef Server SSL Certificates

How To Manually Update Chef Server SSL Certificates

Replace the contents of /var/opt/opscode/nginx/ca/www.yourdomain.com.crt with your ssl combined certificate.

Make sure SSL certificate includes DigiCert ca root certificate

Replace the contents of /var/opt/opscode/nginx/ca/www.yourdomain.com.key with your ssl key.

Reconfigure chef server

@fernandoaleman
fernandoaleman / mysql-8.0-gpg-fix.md
Last active April 19, 2024 09:27
The GPG keys listed for the "MySQL 8.0 Community Server" repository are already installed but they are not correct for this package.

Problem

The GPG keys listed for the "MySQL 8.0 Community Server" repository are already installed but they are not correct for this package.

Solution

rpm --import https://repo.mysql.com/RPM-GPG-KEY-mysql-2023
@fernandoaleman
fernandoaleman / mysql2-apple-silicon-macos-sonoma.md
Created November 2, 2023 16:32
How to install mysql2 gem on apple silicon M1, M2 or M3 macOS Sonoma

Problem

Installing mysql2 gem errors on Apple silicon M1, M2 or M3 Mac running macOS Sonoma.

Solution

Make sure mysql-client, openssl and zstd are installed on Mac via Homebrew.

Replace mysql-client with whichever mysql package you are using

@fernandoaleman
fernandoaleman / how-to-install-and-run-clamav-on-centos7.md
Last active April 10, 2024 09:55
How to install and run ClamAV on CentOS 7

How To Install and Run ClamAV on CentOS 7

ClamAV is an open-source antivirus. It is used to detect viruses, trojans, and malware.

Install ClamAV

Install EPEL repository

yum install -y epel-release
@fernandoaleman
fernandoaleman / reduce-lvm-partition-centos-7.md
Last active April 1, 2024 13:19
Reduce an LVM partition on CentOS 7

Reduce LVM Partition on CentOS 7

Sometimes when creating a new CentOS 7 server, the drive is partioned with the root, boot and swap, and then all the rest of the space is given to the home directory.

Here, we are going to reduce the size of the /home partition and allocate the remaining space back to the root partition.

List Block Devices

List the current block devices

@fernandoaleman
fernandoaleman / how-to-disable-ubuntu-22.04-pop-up-daemons.md
Created November 14, 2023 21:25
How to disable Ubuntu 22.04 "Daemons using outdated libraries" popup

Problem

When using apt to install or update packaged, Ubuntu 22.04 now pops up a Daemons using outdated libraries box.

lAFlE

Solution

To disable this pop up box, edit

@fernandoaleman
fernandoaleman / my.cnf
Last active February 29, 2024 20:01 — forked from fevangelou/my.cnf
Optimized my.cnf configuration for MySQL/MariaSQL (on Ubuntu, CentOS etc. servers)
# Optimized my.cnf configuration for MySQL/MariaSQL
#
# by Fotis Evangelou, developer of Engintron (engintron.com)
#
# ~ Updated January 2020 ~
#
#
# The settings provided below are a starting point for a 2GB - 4GB RAM server with 2-4 CPU cores.
# If you have different resources available you should adjust accordingly to save CPU, RAM & disk I/O usage.
#