How To Empty the Cache in Prometheus Using Curl

Author: , May 7th, 2020

I wanted to empty the time series data cache from the Prometheus server to start clean. The best practice is to use the administrative HTTP API via curl. For example, to clear all data for job mysqld as defined in the prometheus.yml configuration file:

If you want to delete ALL data from Prometheus, then […]

How To Remove A File From The git Staging Pre-Commit List

Author: , May 31st, 2019

Quickref: How to Remove a file from the staging area

The Story Recently, I accidentally added some files to git’s pre-commit phase, i.e.:

For example, here is how to handle the above situation:

To better understand, here are the phases/states/stages that git uses: Untracked – when a file is first created, git […]

How To Fix “dyld: shared cached file was build against a different libSystem.dylib, ignoring cache”

Author: , July 28th, 2016

MacOSX 10.6.8 Snow Leopard running on a Mac Pro 2009 8-way After a system crash, using the backup drive, this error started to appear: dyld: shared cached file was build against a different libSystem.dylib, ignoring cache To fix it, execute the following in Terminal: sudo update_dyld_shared_cache -force As always, YMMV!

How To Fix a “Corrupted index cache file” Error in Dovecot

Author: , June 17th, 2016

Jun 17 00:02:45 inbound dovecot: IMAP(yourName): Corrupted index cache file /home/yourName/Maildir/dovecot.index.cache: invalid record size

As always, YMMV. Proceed with caution.

How To Cache WordPress Using Amazon S3 & CloudFront CDN

Author: , May 3rd, 2012

I found a fantastic tutorial on using the W3 Total Cache plugin with Amazon’s S3/CDN that I had to share: http://www.makeuseof.com/tag/give-wordpress-blog-lightning-fast-speeds-w3-total-cache/ The basic gist of the article says to do the following: Install and activate the W3 Total Cache plugin Sign up for Amazon Web Services (AWS) Obtain your AWS Access and Secret key pair […]

How To Troubleshoot Varnish

Author: , January 17th, 2011

To monitor Varnish, simply run: # varnishlog http://www.varnish-cache.org/docs/2.1/reference/index.html http://www.varnish-cache.org/docs/2.1/tutorial/increasing_your_hitrate.html Important Note: By default, Varnish will NOT cache pages that have cookies!!! http://www.varnish-cache.org/trac/wiki/VCLExampleCacheCookies sub vcl_recv { unset req.http.cookie; } sub vcl_fetch { unset beresp.http.set-cookie; }