2 servers with 2 local memcached: flush both I have servers and 1 memcached server linked by the network. When I add 2 memcached on the 2 servers, locally, it's drastically faste !

So I've configured Drupal to use memcached on 127.0.0.1, except for sessions.
The sessions are the only data hosted on the network server (MC 3).

DRUPAL 1    DRUPAL 2
 MC 1         MC 2
   \            /
    \          /
     \        /
        MC 3
      Sessions


It's fine, except for the cache flush because when I do a drush cc all, Drupal 1 will only flush MC1, and Drupal2 only MC2, but not both.

The idea is to force Drupal to clear all the memcached, but to use only the localhost + MC3.

What is your advice, add a hook to clear both servers?
I suggest you to use Drush aliases.

Here is the quote from the documentation http://drush.org/en/master/usage/#site-aliases


  Drush lets you run commands on a remote server, or even on a set of remote servers. Once defined, aliases can be references with the @ nomenclature


Also from here https://raw.githubusercontent.com/drush-ops/drush/master/examples/example.aliases.drushrc.php


  Alias groups (aliases stored together in files called GROUPNAME.aliases.drushrc.php, as mentioned above) also create an implicit namespace that is named after the group name.


Finally, these are few simple steps to achieve what you want:


Create production.aliases.drushrc.php file
Put in this file aliases for both Drupal 1 and 2
Then you can clear cache on all site at once with drush @production cc all