We investigate the behavior of the solution of a mixed problem for the Poisson equation in a domain with two moderately close holes. If ϱ1 and ϱ2 are two positive parameters, we define a perforated domain Ω(ϱ1,ϱ2) by making two small perforations in an open set: the size of the perforations is ϱ1ϱ2, while the distance of the cavities is proportional to ϱ1. Then, if r∗ is small enough, we analyze the behavior of the solution for (ϱ1,ϱ2) close to the degenerate pair (0,r∗). Copyright © 2016 John Wiley & Sons, Ltd.