Database is mounted read only and I can't change it

I have a couple of new namespaaces/databases that are read-only.  I don't remember changing them to read-only, and although my username has %all (I installed the system), I am unable to change the "Always mount as read-only" property.

What am I missing?

 

Thanks,

Laura

  • 0
  • 261
  • 2
  • 4

Answers

Hi Laura,

 

Can you check in the cconsole.log for any error messages ? If your cache.dat is not RW accessible by Caché, you get an error like :

11/14/17-16:55:39:138 (16952) 0 DKMOUNT: Mounted SFN 6 DB 'c:\intersystems\cache\mgr\user\' as Read Only DB. File or filesystem allows read-only access. 

 

Hi Laura,

 

Can you look at the directory where your cache.dat is located.

If a database is mounted, there should be a cache.lck file with the root directory  and name of the Caché that mounted it.

If the root/name is not the same as your Caché system, it will not mount it as RW.

 

Best is to stop Caché (or dismount the database), remove the cache.lck, and mount/start Caché again.

(If you are sure that this DB is not used by another Caché).

 

 

Hi Danny,

That seemed promising, but when I stop Caché, the cache.lck file is removed, and appears again when I restart the instance. 

Yes, the root database name is not the same as my caché system.  Caché is installed in the typical c:\intersystems\instance while these namespaces' databases are on another drive - e:\datasets.  Also, we changed the underlying Windows security recently for our 2016 upgrade, so I'll have to make sure the instance's service user has access to the e:\ drive.

 

This is what appears in the cache.lck file:

c:\intersystems\rhs01p\mgr\

SERVER01

where rhs01p is the instance name, and SERVER01 is the server name.

 

I'll check the Windows security and let you know.

Thanks,

Laura

Great idea! Yes indeed! this is what it says:

 DKMOUNT: Mounted SFN 5 DB 'e:\datasets\demo\' as Read Only DB. File or filesystem allows read-only access. 

Looks like it's related to our new windows security setup, which, by the way, was implemented as part of the 2016 upgrade.  The 2016 version wants a windows group called Cache_Instance_instancename and the username that runs the instance is moved to this group.  We had to run something to change this windows security after we installed this instance as 2016.  Origainlly, the instance was installed to run as SYSTEM.

 

I wonder - should I uninstall the instance and reinstall so that it's run as the user?  It's still early enough in the game that I could do that.  Would that automatically give my user access to the e:\datasets\ folder since I'm creating namespaces in the Installer manifest?  not sure.

 

Anyway, after I've figured out the windows security for this folder, I'll let you know if that helps.

Thanks! 

From http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=GCI_windows_nonadminperm

To ensure Caché the needed access to all instance database, journal and log files that are outside the Caché installation tree, grant the Cache_Instance_instancename group full access to these files and the directories containing them.

(my highlighting)

Also, remember that in DC you can comment on an answer (like I am doing here) rather than posting your response as though it's another answer.

John, thanks for the info.  It was indeed a windows security problem, related to the new Cache_Instance_instancename group.  I had created 3 namespaces before we ran the cinstall (windows-level caché command to set up the windows security needed), and then because they were located outside of the cache tree, lost access to them.

Note: this was a very special case where I installed the new instance to run as the local system, and then needed to run the cinstall command to change it to use another windows domain user.  We also ran into a few windows security issues after the upgrade that we're still working out.

 

We rectified it by added the appropriate security to the e:\ drive where the dataset are located.

 

Also note: I created a test namespace AFTER we ran the command to set up the windows security (i.e. today, I created it), and the caché service user DOES automatically get access to the folder with the new dataset.

 

Thanks for all the speedy help!

Laura