Mr Osler was addressing a two-day conference on Scottish history, organised by the Scottish Consultative Council on the Curriculum in St Andrews. The council is currently reviewing the Scottish history curriculum, a development welcomed by Mr Osler.
He accepted that pupils did not have a grasp of their past and place in the contemporary world. It was not good enough to have ample "opportunities" to learn about the country's past, a situation common in primaries and the early secondary years.
Mr Osler said: "We need to turn that idea round and have an 'expectation' that all will study Scottish history and culture as well as an opportunity to study the history and cultures of other countries. This does not require extracurricular time and I am not arguing for that. It is a matter of adjusting the choice of content."
Mr Osler advocated "a coherent programme of Scottish history across 5-14", the key curriculum area as two-thirds of pupils drop history after S2. Only 8 per cent of pupils go on to Higher.
He avoided detailed prescription but it is believed history may be reviewed in the near future as part of a wider reassessment of 5-14 environmental studies, an acknowledged problem area.
Scottish history, he said, should be the core of 5-14 history teaching and courses should "ensure a coherent, progressive and systematic understanding of Scotland's past", combined with a wider view of the world. "What I am envisaging is certainly not a route to xenophobia or racism. It is a step towards international understanding. It is about learning to respect the feeling of others," he said.
Mr Osler commented: "In many other countries, it would be unthinkable to give so little place to a study of their own history and culture. There are signs that many people in Scotland are beginning to think that as well and I welcome that in the same way as I welcome the initiative of the SCCC in taking this matter forward so actively and purposefully."
But responsibility for the content of the curriculum lay with councils which took advice from the Secretary of State, he said.