RHEL 5 - chmod 777

Camron W. Fox cwfox at us.fujitsu.com
Thu Apr 23 22:32:10 UTC 2009


Lopez, Denise wrote:
> Hi all,
> 
> I have a quick question.  One of my programmers is trying to get his 
> program working by chmod 777 directories.  On my RHEL 4 server the 
> program is working but on the RHEL 5 server when I do a ls -alh of the 
> directory, it is highlighted and the permissions are 777.
> 
> Does anyone know what the highlighting means?
> 
> P.S. I know about the security risk of chmod 777.  Does anyone know of a 
> way to allow a group of users and apache to write to a directory and all 
> directories underneath it.
> 
> I have umask of 002 permission on directory are 2775 and user is apache 
> with group www. 
> 
> Thanks in advance.
> 
> Denise Lopez
Denise,

	By default, ls is aliased to:

[cwfox at hiloii etc]$ alias ls
alias ls='ls --color=tty'
[cwfox at hiloii etc]$

	The colors are defined by LS_COLORS:

[cwfox at hiloii etc]$ echo $LS_COLORS
no=00:fi=00:di=00;34:ln=00;36:pi=40;33:so=00;35:bd=40;33;01:cd=40;33;01:or=01;05;37;41:mi=01;05;37;41:ex=00;32:*.cmd=00;32:*.exe=00;32:*.com=00;32:*.btm=00;32:*.bat=00;32:*.sh=00;32:*.csh=00;32:*.tar=00;31:*.tgz=00;31:*.arj=00;31:*.taz=00;31:*.lzh=00;31:*.zip=00;31:*.z=00;31:*.Z=00;31:*.gz=00;31:*.bz2=00;31:*.bz=00;31:*.tz=00;31:*.rpm=00;31:*.cpio=00;31:*.jpg=00;35:*.gif=00;35:*.bmp=00;35:*.xbm=00;35:*.xpm=00;35:*.png=00;35:*.tif=00;35:
[cwfox at hiloii etc]$

	The defaults can be found by using "dircolors --print-database".  The 
default setting between RHEL4/5 are different.

Best Regards,
Camron

Camron W. Fox
Hilo Office
High Performance Computing Group
Fujitsu Management Services of America, Inc.
E-mail:		cwfox at us.fujitsu.com





More information about the redhat-sysadmin-list mailing list