Keepalived not detect haproxy status on Debian Jessie

Keepalived not detect haproxy status on Debian Jessie

vi /etc/keepalived/keepalived.conf

The reason is keepall command does not installed!

Just install

Then everything works fine.

Increase SNMP ping Timeout Period for Check_MK

If you are monitoring external devices through SNMP like Netapp Storage, it may throw out alert when the Device is busy or the connect time out.

Put this in your main.mk file:

Let check_mk server check 1 more time before it send alert after the first one fail.
The wait time out increase to 30 seconds.
These lines apply changes on all of your SNMP machines having the tag snmp.

To force checm_mk client and ping run second checking if first one fail, add these into ~/etc/check_mk/main.mk:

Then restart OMD/Check_MK to make it works.

How to clone a 2 TB Oracle Database VM at 3:00 AM

I have to clone a 2 TB Oracle Database VM at 3:00 AM.

Don’t want get up at 3:00 AM just for clone.

Create a Scheduled Task to Clone a Virtual Machine

This procedure creates a scheduled task to clone a virtual machine.
Procedure

  1. Start the vSphere client, and log in to the vCenter Server system.
  2. From the Home page, click Scheduled Tasks.
  3. Select File > New > Scheduled Task, or click New. The Select a Task to Schedule dialog box appears.
  4. Select Clone a virtual machine from the drop-down menu, and click OK. The Clone Virtual Machine wizard appears.
  5. Select the virtual machine to clone and click Next.
  6. Follow the wizard through the same steps as those in the previous task in which you cloned a virtual machine.
  7. Enter a name and a task description in the text box.
  8. Select the frequency of the task.
  9. Select Now or Later. If later, enter the time and date when you want the virtual machine to be deployed, and click Next. To see the calendar, click Later, and click the drop-down arrow to select a date from the calendar. A red circle indicates today’s date, and a dark circle indicates the scheduled date.
  10. Review the information on the Ready to Complete New Virtual Machine page, and click Finish.

Optionally, you can select the check box to power on the new virtual machine after it is created.

Logrotate HAproxy every 6 hours

Running the logrotate with -f in a cron job:

My /etc/logrotate.d/haproxy

Oracle Account locked ORA-28000

After Someone type the wrong password in the application, the user been locked in Oracle Database.

To unlock the Account:

Permanent Disable Account lock function.

Nginx and HHVM always return a 404

This because the /etc/nginx/hhvm.conf did not load before the root in vhost.

This is just a quick notice for myself, I will add more example later:

3 fix solutions:

1.move root out of /

OR:

2.move hhvm into /

3.add /var/www replace $doc_root

My /etc/nginx/hhvm.conf file:

Reference:

    http://stackoverflow.com/questions/28308099/nginx-and-hhvm-always-return-a-404

Postfix & Dovecot error The maximum number of concurrent server connections has exceeded a per-source limit

EmailServer : 672 : Error Sending E-mail [Smtp Error : [4.3.2 The maximum number of concurrent server connections has exceeded a per-source limit, closing transmission channel

First I checked the current config:

Which is 10 as default.

This parameter shows up in 3 files:

I uncommon them and changed 10 to 20, restart the service

Double check when the service is back online:

HHVM 3.14 update missing error while loading shared libraries: libdouble-conversion.so.1 and liblz4.so.1

One of my Ubuntu 14.04 LTS server running HHVM for a while.
Recently the 3.14 update just came, after upgrade the HHVM won’t start:

Than I installed the libdouble-conversion library:

But still no luck:

I have to install liblz4 to fix it:

I noticed my Debian 8 Jessie server doesn’t have this issue, only the Ubuntu 14.04 LTS.

Just a heads up for every one test your code and server before you upgrade the production system.

I like (not love anymore, since version 3.10) HHVM, but it got some quality issues since Version 3.10.
Hope it just a temporary thing.

I will keep support HHVM but not suggest it in production system.

Have a nice weekend!

Debian Jessie Keepalived simple Redis Cluster

Even though keepalived under Debian Jessi give samples of check local service with killall in /usr/share/doc/keepalived/samples/keepalived.conf.vrrp.localcheck

But Jessie only have SystemD. [killall] has been remove with SystemV.
You can still use killall5 which is the SystemV killall command.

But killall5 simulates the killall command of SysV UNIX; it sends the given signal to all processes owned by the calling UID. When does it root, it can do very bad things. BE VERY CAREFUL with the killall command on!

# cat /etc/keepalived/keepalived.conf

In my opinion pidof is safer than killall or killall5.

Nginx upgrade to new stable 1.10 switch spdy to http2

nginx just release 1.10 stable.

After upgrade on my Debian server hosting the Milliondollarserver.com, it shows error message:

My old /etc/nginx/sites-enabled/milliondollarserver.com_ssl config file is:

replace spdy by http2, restart the service.

Everything goes normal.

Please let me know if you have any difficult on HTTP2.