Two gunmen have also been killed and at least five others, including three civilians were injured, police say.
The region has seen an insurgency against Indian rule since 1989, but violence has declined in recent years.
No group has said it carried out the attack.
This is the first major attack in three years in Indian-administered Kashmir which is claimed by both India and Pakistan.
The school was closed and no children were hurt in the attack, officials said. Security forces have cordoned off the area.
The gunmen attacked a security camp manned by the Central Reserve Police Force (CRPF) near a school run by the police in the Bemina district.
A senior police official said the attackers had “mixed” with children playing cricket on a nearby field and were carrying arms in sports kits.
“They threw a grenade at the security forces, killing five of them. They also opened fire,” the official said.
Indian-administered Kashmir has been tense since the execution in February of Afzal Guru, a Kashmiri man convicted for plotting to attack India’s parliament in 2001.
Attacks in Srinagar have become rare – last October one person was killed by gunmen who opened fire in a hotel on the outskirts of Srinagar.
And in May last year seven paramilitary soldiers were injured after two men on a motorcycle fired at them in the city.
DUyITVrQh1IQuincy Jones, the celebrated musician and producer who worked with Michael Jackson, Frank Sinatra, Ray…
Misleading allegations, rumours and outright lies about voting and fraud are flooding online spaces in…
At least 158 people have died in Spain's worst flooding disaster in generations. On October…
Google has been fined two undecillion (a two followed by 36 zeroes) roubles by a…
Embarking on a home remodel is an exciting journey, promising enhanced comfort, increased property value,…
The US presidential candidates continued to campaign across key swing states on October 20. Footage…