System.IO.IOException: The Device Is Not Ready RRS feed

  • Question

  • User1122355199 posted

    Hello Everyone and thanks for your help in advance.  I am developing an application that reads from a network shared folder on a separate Windows Server.  When the application attempts to read, I am receiving the error message "System.IO.IOException: The Device Is Not Ready".  I have tried running the application as an Administrator, however I still receive the same error.  The files in question do not appear to be in use by any other application.  Any help would be greatly appreciated.  Thanks.

    Wednesday, October 12, 2011 1:10 PM

All replies

  • User-1528094326 posted

    Sounds like you have insufficient permissions, make sure the user account you are using to access them has sufficient permissions.

    Wednesday, October 12, 2011 1:39 PM
  • User1122355199 posted

    I agree, but I am not exactly sure what additional permissions would be need.  I granted the dll full privileges, but obviously that is not enough.

    Wednesday, October 12, 2011 2:17 PM
  • User-1528094326 posted

    it has nothing to do with the DLL. The Asp.net website is being compiled under IIS and then IIS uses whatever permissions it has assigned for that website to access the files. By default you are using the IUSR_<server name> guest account, which has virtually no privileges. You will need to either grant that account privileges to the file folders in question or in your web.config set Impersonate="true" and give it a username and password on the domain.

    Wednesday, October 12, 2011 2:20 PM
  • User1122355199 posted

    Thanks for the response.  I tried this but stil no luck.  I also tried calling it from a windows form application with similar problem.  Obviously, I'm missing something.

    Wednesday, October 12, 2011 2:38 PM