Creating an Extra MySQL Slave from Another MySQL Slave

August 25, 2016 Jordansphere FreeBSD

I was tasked with creating a new MySQL slave in a Brighton datacenter to replicate with the master in London. There was already a replication in place from London to Manchester.  Here are the steps to copy the information from Manchester Slave (MySQL2) to the Brighton Slave (MySQL3) . This method allows the master MySQL to be completely untouched  In […]


Nagios: DNS CRITICAL – ‘/usr/bin/nslookup -sil’ msg parsing exited with no address

November 19, 2014 Jordansphere FreeBSD

Scenario: We changed from BIND to Unbound on a smarthost email server. As soon as this was changed Nagios started throwing up a "DNS CRITICAL – '/usr/bin/nslookup -sil' msg parsing exited with no address" . In the following example i've substituted for the actual host. Troubleshooting steps:  From the Nagios server i checked the config file: […]


bind unbound nagios,

Setting up vsFTPd to use SSL on FreeBSD

December 12, 2013 Jordansphere FreeBSD

Notes: FreeBSD 9.1 / vsFTPD 3.0.2  / using a CA certificate 1) Ensure both private key and certificate are located in .pem. I named this vsftpd.pem   2) Edit the the vsftpd.conf file # vi /usr/local/etc/vsftpd.conf ### PASV FTP pasv_enable=YES pasv_min_port=49152 pasv_max_port=65535 port_enable=YES ssl_enable=YES ### SSL STUFF allow_anon_ssl=NO force_local_data_ssl=NO force_local_logins_ssl=NO ssl_tlsv1=YES ssl_sslv2=NO ssl_sslv3=NO rsa_cert_file=/usr/local/etc/vsftpd.pem   3) […]


vsftpd ssl freebsd,

Enable SNMP FreeBSD

August 20, 2013 Jordansphere FreeBSD

1) Install Net-SNMP # cd /usr/ports/net-mgmt/net-snmp # make install clean   2) Create SNMP conf file # vi /usr/local/share/snmp/snmpd.conf syscontact [email protected] rocommunity public syscontact Jordansphere syslocation London   3) Start SNMP service # /usr/local/etc/rc.d/snmpd start   4) Input line in rc.conf so it starts on a reboot # vi /etc/rc.conf snmpd_enable="YES"      


Configuring MySQL Replication 5.5 in 6 steps

August 16, 2013 Jordansphere FreeBSD

Scenario: You want to create a MySQL replication between an exisiting master and a brand new slave. Both machines running FreeBSD 8.x with MySQL 5.5. The master server currently has a mixture of InnoDB and MyISAM engines. A small amount of downtime is available. Master server: Slave server:     (1) ON […]


mysql replication master slave,

Using Logrotate with MySQL Database Backups

August 1, 2013 Jordansphere FreeBSD

Scenario: I wanted to backup all the databases individually from a MySQL server and keep for x days. I set about achieving this using a custom script combined with logrotate. The server is running FreeBSD 8.x.   1) Firstly, the script ( #!/usr/local/bin/bash # # backup each mysql db into a different file, rather […]


logrotate mysql script daily, mysqldump,

Add an IP alias to NIC on FreeBSD

July 5, 2013 Jordansphere FreeBSD

Here are the steps for adding and removing an alias to a NIC on a FreeBSD 8.x machine.   Find out the name of the NIC : # ifconfig   As you’ll see from the above screenshot the NIC is called em0 Now to add the alias: # ifconfig em0 netmask alias   […]


MySQL Corruption: Error 1034 (HY000) : Incorrect key file for table ‘xyz’ ; try to repair it

April 12, 2013 Jordansphere FreeBSD

Scenario: We upgraded from MySQL 5.1 to 5.5 (It was 4.1 in the past and possibly even 3.x before my time!). There seems to be some sort of corruption in a particular DB. The normal myisamchk and REPAIR TABLE functions didnt cut the mustard. Below are my steps to fix the issue. It appears that the […]


Error 1034 MySQL corruption Incorrect key file size,

Installing and Enabling NRPE on Remote FreeBSD Server

April 4, 2013 Jordansphere FreeBSD

Here are some instructions I had (from a couple of years ago may I add) to assist in setting up NRPE for remote monitoring from (eg) Nagios   1) Add nagios user. nologin 2) install nagios-plugins from ports (nagios-plugins-1.4.11,1 )  -> cd / /usr/ports/net-mgmt/nagios-plugins/ -> make -> make install   3) Set permissions -> chown […]


nrpe remote host enable install freebsd linux,

Login Incorrect when connecting from FreeBSD to SQL Server 2008 via FreeTDS

February 6, 2013 Jordansphere FreeBSD

Scenario: I wanted to connect to an SQL server 2008 from a FreeBSD 8.2 machine using PHP5.3 and FreeTDS. We have a similar set up on another server running FreeBSD 7.2 with PHP 5.2 . This is still running in production and connecting to the same DB server successfully. The logical thing to do was […]


freebsd freedts php pdo pdo_dblib sql 2008,

« Previous Posts

Powered by WordPress. Designed by elogi.