[plug] what would this command do if typed as root?

Christian christian at amnet.net.au
Mon Feb 26 08:39:23 WST 2001


On Fri, Feb 23, 2001 at 11:44:00AM +1600, Ari Finander wrote:
> What would 'chmod 777 *.bin' do if I typed it as root from a command
> prompt?  I haven't gotten to the chapter on groups, owners, and
> permissions yet in my linux text.  It was recommended to do as root
> before the star office install on the installation instructions page.
> I wasn't sure what it would do, so I replaced the * with the filename
> for the star office download and then executed it.

Short answer: probably not what you intend.

Long answer: It would make all files that end in '.bin' completely
accessible by everyone on the system.  You'd probably get a "file not
found" error since there aren't that many files ending in .bin on the
average Linux system.  As for the '777' bit... the best advice I can
give is that it is a really, really good idea to avoid this permissions
set.  If you find yourself about to run 'chmod 777 anything' then you're
probably making a mistake.  It's very, very rarely necessary. '755' is a
much better set of permissions, even for a system with all "friendly"
users.



More information about the plug mailing list