[#873] Use a g.ofs_impl to check filestore status

* Remove the helper function check_datastore
* Create a global varibale called ofs_impl that stores
  the value of the config option