How-to obtain cache mode of user share through command line?


Recommended Posts

I like to auto backup all shares that have the cache status "Only" and "Prefer". Is there a method available to get this information by passing a user share name or path?

 

The only idea for a dirty hack I had, is to search for all cache root dirs on all disks and if they do not exist on the disks its cache status could be "Only" or "Prefer". But this works only if the status is "Only" or "Prefer" has never filled up the cache (else it creates the dir on the disk array).

Edited by mgutt
Link to comment

You would have to parse the applicable .cfg file within /config/shares on the flash drive

 

Without doing that you could determine if a share is cache only AND no files exist on the array by seeing if the share exists within /mnt/cache and DOES NOT exist within /mnt/user0

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.