AMSTERDAM (Reuters) - Eberhard van der Laan, Amsterdam’s popular mayor, has died of lung cancer, the city said on Friday.

Van der Laan informed city residents of his illness in January, saying the prognosis left “little reason for optimism”. When he retreated from public life three weeks ago, thousands gathered in front of his canal-side house to applaud for several minutes in a display of support.

Van der Laan, 62, was known as an effective, pragmatic and sometimes combative mayor with a sense of humor.

When an “Occupy” tent camp arose in front of the stock market in October 2011, Van der Laan was a frequent visitor, engaging protesters in discussion. He allowed the tents to remain until a court ordered them cleared months later.

One of his most remarkable moments on an international stage was in 2013 when Van der Laan said he was too busy to meet Vladimir Putin during the Russian president’s visit to Amsterdam, and ordered a rainbow flag flown from city hall in protest at Russian policies against homosexuals.

The former lawyer served briefly as housing minister and shortly after becoming mayor in 2010 enforced a law banning squatting, sparking minor riots and banishing a long Amsterdam tradition to the fringes.

Van der Laan is survived by his wife and five children from two marriages.