Locate command and shares
-
- Posts: 49
- Joined: Fri Oct 12, 2012 7:32 pm
Locate command and shares
So in the process of trying to automate some file management stuff I've found that the locate command doesn't seem to have any index of locally mounted shares (everything does show up in both the LZs and in the gh directories, just not the shares). This is probably more a question of how samba mounts works in relation to the locate database updates than a greyhole thing per se, but does anyone have ideas as to options (other than just using find) or alternatives? Ideally I'd just like to get the shares indexed, but I don't know much about the workings of locate or how different from a normal directory a samba mount actually is for these purposes.
Re: Locate command and shares
That would make sense that it finds files in both. If you only want to search files in the shares, then restrict your search to /var/hda/files and exclude the drives folder.
ßîgƒσστ65
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
-
- Posts: 49
- Joined: Fri Oct 12, 2012 7:32 pm
Re: Locate command and shares
I would expect it to find files in both, but it doesn't . Only /var/hda/files is indexed at all. Locate seems to think /mnt/samba is empty. My guess is that because of samba being used the indexing daemon thinks they are network mounts and skips them.
[ Post made via iPhone ]
[ Post made via iPhone ]
Re: Locate command and shares
Ah, that could be. I am sure this is one that will require more research.
ßîgƒσστ65
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Re: Locate command and shares
What about using mlocate. According to what I have read, you can run it as a cron job daily to keep the file index updated.
It's supposed to be an advanced version of locate.
http://www.thegeekstuff.com/2012/03/loc ... -examples/
EDIT: Been testing and this does not seem to help.
It's supposed to be an advanced version of locate.
http://www.thegeekstuff.com/2012/03/loc ... -examples/
EDIT: Been testing and this does not seem to help.
ßîgƒσστ65
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Applications Manager
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2
Who is online
Users browsing this forum: No registered users and 54 guests