BAGHDAD — A woman who veiled her explosives in a black robe struck a column of Shiite pilgrims on the outskirts of Baghdad on Monday in a suicide attack that Iraqi officials had predicted but could not stop.

The attack — coming a week after four enormous bombings in Baghdad using vehicles driven by suicide bombers — killed at least 38 people and wounded scores more along a major roadway in an industrial district on the northern edge of Baghdad, according to officials.

The bombing occurred despite what officials had pledged would be intensified security for the annual pilgrimage to Shiite Islam’s holiest shrine in Iraq, underscoring the ability of insurgents to outmaneuver the country’s security forces, seemingly at will.

Two more attacks — one with a grenade, another with a roadside bomb — later struck still more pilgrims in southern Baghdad, wounding 16.