|
|
Locking files and folders to prevent changes
Great Hint! I really like this:
chflags -R uappnd * It's a great way to protect files & folders that are not supposed to change, but do need to be opened, looked at, and copied (but NOT deleted, moved, edited, nor accidentally overwritten!). The * gets all files & folders at this level, plus the -R gets all folders & files recursively. Even the mighty Root can't change files after this command has been applied, and that goes for admins doing sudo as well. Nicely protected. Use ls -lo to see the flags. If you want to change the files, use chflags -R nouappnd * to turn it off again. Nifty. Ok, so my goal is to protect the files that are on a server: ssh root@servername cd /volumes/hdName/TopFolder2Protect/ then chflags -R uappnd * I planned to use this command to protect files on a ReadyNAS which I believe is using some Linux variation, but serves up AFP over TCP. I would apply the command either SSH-ed into the ReadyNAS, or mount the NAS as a AFP volume, then apply the command as if it were a local volume. Problem: this seems to work differently on a network volume, even if I ssh into that server. When on a network volume (in this case OSX (non-server) 10.3.4) The files are protected against name edits, file edits, etc, but in some cases they are not openable, either. I'm using a bunch of GIFs & PNGs in folders as a test, and They can double-click open into Preview, but Graphic Converter can't open them as they are locked. ("System Error software lock on file, not a subscriber") Adobe Illustrator X says it can't open the GIF files because "the server has denied access to the file". That's sort of disappointing, as I expected it would work the same on the servers as it does on my Mac. I want the files to not only be protected, but also easily opened in place. How could this be improved to work better? Thanks! Dave N |
SearchFrom our Sponsor...Latest Mountain Lion HintsWhat's New:HintsNo new hintsComments last 2 daysLinks last 2 weeksNo recent new linksWhat's New in the Forums?
Hints by TopicNews from Macworld
From Our Sponsors |
|
Copyright © 2014 IDG Consumer & SMB (Privacy Policy) Contact Us All trademarks and copyrights on this page are owned by their respective owners. |
Visit other IDG sites: |
|
|
|
Created this page in 0.08 seconds |
|