[clue] When is it OK to write to a 555 dir?

Chris Fedde chris at fedde.us
Thu May 3 18:26:09 MDT 2012


NAS are weird.  BlueArc doubly so.  The interaction between NFS
"exports" from windows "shares" with native NTFS permissions mapped to
unix permissions is wierd enough, but adding a NAS vendor to the mix
leads into extra dimensions of weirdness.  There is a wild and
wonderful world of mappings available.  Some are semantically sane
others just arn't.

On Wed, May 2, 2012 at 2:21 PM, David L. Willson <DLWillson at thegeek.nu> wrote:
> Weirdness... a directory is clearly 555, but I can write files into it.
> Files which I subsequently cannot remove...
>
> It should work like this:
>
> $ mkdir test
> dlwillson at dwillson-nb-1:5/~/temp 14:17:17
> $ chmod 555 test
> dlwillson at dwillson-nb-1:5/~/temp 14:17:23
> $ cd test
> dlwillson at dwillson-nb-1:5/~/temp/test 14:17:25
> $ ll
> total 8
> dr-xr-xr-x 2 dlwillson dlwillson 4096 May  2 14:17 ./
> drwxrwxr-x 3 dlwillson dlwillson 4096 May  2 14:17 ../
> dlwillson at dwillson-nb-1:5/~/temp/test 14:17:28
> $ > bingo
> bash: bingo: Permission denied
> dlwillson at dwillson-nb-1:5/~/temp/test 14:17:35
> $
>
> But instead it works like this:
>
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA
> 14:07:12
> $ cd COG/
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:07:18
> $ ll -d .
> dr-xr-xr-x 2 root bluearc 2048 May  2 13:53 .
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:09:41
> $ > test
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:10:03
> $ ll
> total 210112
> ...
> -rwxrwxrwx 1 dlsa     bluearc         43000 May  2 13:51 jeff.txt
> -rw-r--r-- 1 sudavidw linux_users         0 May  2 14:10 test
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:10:04
> $ ls -al
> total 210176
> dr-xr-xr-x 2 root     bluearc          2048 May  2 14:10 .
> dr-xr-xr-x 4 root     bluearc          2048 May  2 13:05 ..
> ...
> -rwxrwxrwx 1 dlsa     bluearc         43000 May  2 13:51 jeff.txt
> -rw-r--r-- 1 sudavidw linux_users         0 May  2 14:10 test
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:10:15
> $ rm test
> rm: cannot remove `test': Permission denied
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:10:30
> $ ll -Z
> -rwxrwxrwx  root     bluearc
> AUTO_SFJDL505ID_JDLNIDDID_20111118F001ID2011_5000000.out.DAT
> -rwxrwxrwx  root     bluearc
> COG_raw_1k_test_data_from_F001.txt
> -rwxrwxrwx  dlsa     bluearc                                      jeff.txt
> -rw-r--r--  sudavidw linux_users                                  test
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:10:55
> $ getfacl .
> # file: .
> # owner: root
> # group: bluearc
> user::r-x
> group::r-x
> other::r-x
>
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:11:20
> $ cp test test2
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:11:45
> $ ll
> total 210112
> -rwxrwxrwx 1 dlsa     bluearc         43000 May  2 13:51 jeff.txt
> -rw-r--r-- 1 sudavidw linux_users         0 May  2 14:10 test
> -rw-r--r-- 1 sudavidw linux_users         0 May  2 14:11 test2
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:11:47
> $ rm test*
> rm: cannot remove `test': Permission denied
> rm: cannot remove `test2': Permission denied
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA
> 14:13:51
> $ rm jeff.txt
> rm: cannot remove `jeff.txt': Permission denied
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA
> 14:14:00
> $ sudo rm jeff.txt
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA
> 14:14:06
> $ cd COG/
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:14:15
> $ ll
> total 210112
> ...
> -rwxrwxrwx 1 dlsa     bluearc         43000 May  2 13:51 jeff.txt
> -rw-r--r-- 1 sudavidw linux_users         0 May  2 14:10 test
> -rw-r--r-- 1 sudavidw linux_users         0 May  2 14:11 test2
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:14:16
> $ sudo rm test* jeff.txt
> sudavidw at dcoscrip01:1//net/nas1/NA/Technology/EDT/Test_data_for_new_COA/COG
> 14:14:22
> $
>
> --
> David L. Willson
> Trainer, Engineer, Enthusiast
> RHCE Network+ A+ Linux+ LPIC-1 Ubuntu
> Mobile 720-333-LANS(5267)
>
> This is a good time for a r3volution.
>
>
> _______________________________________________
> clue mailing list: clue at cluedenver.org
> For information, account preferences, or to unsubscribe see:
> http://cluedenver.org/mailman/listinfo/clue


More information about the clue mailing list