BERLIN — While Germans are stocking up on firecrackers and Champagne to welcome the New Year, officials are setting up roadblocks and safety zones for women to ensure that festivities in cities across the country remain peaceful and safe.

For the first time this year, organizers in Berlin have designated a “women’s safety area” where girls and women who feel threatened or have been assaulted can turn for help. But it is in and around Cologne where security has been especially fortified.

There, two years ago, groups of mostly young men, including asylum seekers and other newly arrived immigrants, assaulted and robbed hundreds of women as 2016 arrived. This year, there will be 10 times as many police officers on the streets, as well as video surveillance cameras and special services for women and girls who feel threatened.

More than any terrorists attacks that plagued Germany in the months that followed the arrival of about one million asylum seekers in 2015, that chaotic New Year’s Eve in Cologne set off fears among Germans that the new arrivals threatened their way of life.