open an rm file for writing from mf

I have a mf cobol program that reads items from an indexed rm file. The filetype is set to 21. trying to open a file for output gives a file status error of 93. 

Reading the file works find but opening for output gives a 21.