suppress external diff program when using git diff.
point 2 of slave-serve-stale-data miss '-' between 'stale' and 'data'
Merge pull request #967 from 0x20h/fix-git-diff

suppress external diff program when using git diff.
redis-cli: use keepalive socket option.

This should improve things in two ways:

1) Prevent timeouts caused by the execution of long commands.
2) Improve detection of real connection errors.

This is mostly effective only on Linux because of the bogus default
keepalive settings. In Linux we have OS-specific calls to set the
keepalive interval to reasonable values.
adding check error code

adding check error code
Cluster: REPLICATE subcommand and stub for clusterSetMaster().
SLAVEOF command refactored into a proper API.

We now have replicationSetMaster() and replicationUnsetMaster() that can
be called in other contexts (for instance Redis Cluster).
Cluster: actually setup replication in CLUSTER REPLICATE.
Make sure replicationSetMaster() works when ip argument is not an sds.
Cluster: fix maximum line length when loading config.

There are pathological cases where the line can be even longer a single
node may contain all the slots in importing/migrating state.
Cluster: don't perform startup slots sanity check for slaves.

If we are a cluster node the DB content will not match our configured
slots. Don't do the check at all.
Cluster: set node->slaveof correctly when a node state is updated.
Cluster: send a ping to every node we never contacted in timeout/2 seconds.

Usually we try to send just 1 ping every second, however when we detect
we are going to have unreliable failure detection because we can't ping
some node in time, send an additional ping.

This should only happen with very large clusters or when the the node
timeout is set to a very low value.
Cluster: A comment updated in clusterCron().
Cluster: SLAVEOF command not allowed in cluster mode.
Cluster: slaveof not allowed in redis.conf as well.
Cluster: don't check keys hash slots when the source is our master.

Usually we redirect clients to the right hash slot, however we don't
want to do that with our master, we want just to mirror it.
Cluster: new node field fail_time.

This is the unix time at which we set the FAIL flag for the node.
It is only valid if FAIL is set.

The idea is to use it in order to make the cluster more robust, for
instance in order to revert a FAIL state if it is long-standing but
still slots are assigned to this node, that is, no one is going to fix
these slots apparently.
Cluster: more robust FAIL flag cleaup.

If we have a master in FAIL state that's reachable again, and apparently
no one is going to serve its slots, clear the FAIL flag and let the
cluster continue with its operations again.
Cluster: connect to our master ASAP after startup if we are a slave node.