On Sunday 01 July 2018 18:10:12 Mike Bird wrote: > On Sun July 1 2018 17:54:14 Mike Bird wrote: > > > chmod -R 770 /home/~/.trinity | chown -R ~/home/~/.trinity | chgrp -R > > > ~ /home/~/.trinity > > > and/or > > > chmod -R 770 /home/~/.trinity/* | chown -R ~/home/~/.trinity/* | chgrp > > > -R ~ /home/~/.trinity/* > > > > **** DO NOT DO THIS ^^^ **** > > > > This would wreck many permissions that should not be 770. > > I wanted to get that warning out quickly. Now I have time for some > explanation. > > (1) My good ~/.trinity has precisely 0 files with 770 permission. Don't > wreck yours. Another suggestion was made for 700 permission. Well > my ~/.trinity does have 951 files with 700 permission but they're > still the minority. For example I have 2049 files with 600 permission. > > DON'T MASS-BORK YOUR PERMISSIONS. UNLESS YOU CAN RESTORE FROM A > BACKUP, RECOVERY COULD TAKE DAYS OF WORK. > > (2) Commands such as those above should not be linked by pipe "|". They > should be linked by semicolon ";" or in some cases ampersand "&". > > When commands are linked by pipe the output of one is fed as the > input to the next. Even if the next ignores the unwanted input > this can still cause problems. Consider "ls | ls". If the second > ls finishes before the first the pipe breaks and the first ls is > prematurely terminated. If that first ls was instead a command > changing every file in your ~/.trinity it would be killed at an > arbitrary point in the proceedings instead of completing its job. > > So what should you do instead of borking your ~/.trinity? > > find ~/.trinity -not -user U -o -not -group G -exec ls -dl {} \; > > Replace U with your user and G with your group in the above. > > If the resulting files look like they should belong to you then you > can: > > chown -R U:G ~/.trinity > > --Mike > I have not had those problems, but thanks for clarifying my own question: how to change the permissions of files inside a folder to 600 only (rw for user), but 700 for the folder (because rwx is necessary to enter the folder). Bill