Hi,

I have checked your patch and it solves the number conversion (octal<->  
decimal) issues. Thank you for that.
However, the file permission issues are still valid. Please find the test 
execution log with this mail.

>But then 001 is right to exec by other which should work.
>         010 is right to exec for group, which is the same on that line
>         100 is right to exec for owner, which is the same again

In this case, I partially agree with you. It is true in the case of binary 
files. However, We need 'read' and 'exec'
for script files and these testcases deals with script files too.

______________________________________________________________
$ pwd
/tmp

$ cat script.sh
#!/bin/sh
echo "hi"

$ chmod 001 script.sh
$ ls -la script.sh
---------x 1 maxin maxin 20 2011-02-14 17:00 script.sh

$ su test
Password:

$ pwd
/tmp

$ ./script.sh
/bin/sh: Can't open ./script.sh

$ strace ./script.sh
....
open("./script.sh", O_RDONLY)           = -1 EACCES (Permission denied)
write(2, "/bin/sh: ", 9/bin/sh: )                = 9
write(2, "Can't open ./script.sh", 22Can't open ./script.sh)  = 22
write(2, "\n", 1
..

With 005 permission:

$ chmod 005 script.sh
$ ls -la script.sh
-------r-x 1 maxin maxin 20 2011-02-14 17:00 script.sh
$ su test
Password:
$ ./script.sh
hi
______________________________________________________________


Please let me know your comments.

Best Regards,
Maxin B. John

----------------------------------------
COMMAND:    /opt/ltp/bin/ltp-pan  -e -S   -a 26493     -n 26493  -p
-f /tmp/ltp-tLpaJ3aD9r/alltests -l
/opt/ltp/results/LTP_RUN_ON-2011_Feb_14-16h_35m_19s.log  -C
/opt/ltp/output/LTP_RUN_ON-2011_Feb_14-16h_35m_19s.failed
-e LOG File: /opt/ltp/results/LTP_RUN_ON-2011_Feb_14-16h_35m_19s.log
-e FAILED COMMAND File:
/opt/ltp/output/LTP_RUN_ON-2011_Feb_14-16h_35m_19s.failed
Running tests.......
<<<test_start>>>
tag=fs_perms01 stime=1297694119
cmdline="fs_perms 001 99 99 12 100 x 0"
contacts=""
analysis=exit
<<<test_output>>>
/bin/sh: Can't open ./test.file2
/bin/sh: Can't open ./test.file1
fs_perms    1  TFAIL  :  x a 001 file owned by (99/99) as user/group (12/100)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=1 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms02 stime=1297694119
cmdline="fs_perms 010 99 99 200 99 x 0"
contacts=""
analysis=exit
<<<test_output>>>
/bin/sh: Can't open ./test.file2
/bin/sh: Can't open ./test.file1
fs_perms    1  TFAIL  :  x a 010 file owned by (99/99) as user/group (200/99)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=1 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms03 stime=1297694119
cmdline="fs_perms 100 99 99 99 500 x 0"
contacts=""
analysis=exit
<<<test_output>>>
/bin/sh: Can't open ./test.file2
/bin/sh: Can't open ./test.file1
fs_perms    1  TFAIL  :  x a 100 file owned by (99/99) as user/group (99/500)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=1 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms04 stime=1297694119
cmdline="fs_perms 002 99 99 12 100 w 0"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  w a 002 file owned by (99/99) as user/group (12/100)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms05 stime=1297694119
cmdline="fs_perms 020 99 99 200 99 w 0"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  w a 020 file owned by (99/99) as user/group (200/99)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms06 stime=1297694119
cmdline="fs_perms 200 99 99 99 500 w 0"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  w a 200 file owned by (99/99) as user/group (99/500)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms07 stime=1297694119
cmdline="fs_perms 004 99 99 12 100 r 0"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  r a 004 file owned by (99/99) as user/group (12/100)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms08 stime=1297694119
cmdline="fs_perms 040 99 99 200 99 r 0"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  r a 040 file owned by (99/99) as user/group (200/99)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms09 stime=1297694119
cmdline="fs_perms 400 99 99 99 500 r 0"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  r a 400 file owned by (99/99) as user/group (99/500)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms10 stime=1297694119
cmdline="fs_perms 000 99 99 99 99  r 1"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  r a 000 file owned by (99/99) as user/group (99/99)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms11 stime=1297694119
cmdline="fs_perms 000 99 99 99 99  w 1"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  w a 000 file owned by (99/99) as user/group (99/99)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms12 stime=1297694119
cmdline="fs_perms 000 99 99 99 99  x 1"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  x a 000 file owned by (99/99) as user/group (99/99)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms13 stime=1297694119
cmdline="fs_perms 010 99 99 99 500 x 1"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  x a 010 file owned by (99/99) as user/group (99/500)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms14 stime=1297694119
cmdline="fs_perms 100 99 99 200 99 x 1"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  x a 100 file owned by (99/99) as user/group (200/99)
<<<execution_status>>>
initiation_status="ok"
duration=1 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms15 stime=1297694120
cmdline="fs_perms 020 99 99 99 500 w 1"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  w a 020 file owned by (99/99) as user/group (99/500)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms16 stime=1297694120
cmdline="fs_perms 200 99 99 200 99 w 1"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  w a 200 file owned by (99/99) as user/group (200/99)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms17 stime=1297694120
cmdline="fs_perms 040 99 99 99 500 r 1"
contacts=""
analysis=exit
<<<test_output>>>
fs_perms    1  TPASS  :  r a 040 file owned by (99/99) as user/group (99/500)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
<<<test_start>>>
tag=fs_perms18 stime=1297694120
cmdline="fs_perms 400 99 99 200 99 r 1"
contacts=""
analysis=exit
<<<test_output>>>
incrementing stop
fs_perms    1  TPASS  :  r a 400 file owned by (99/99) as user/group (200/99)
<<<execution_status>>>
initiation_status="ok"
duration=0 termination_type=exited termination_id=0 corefile=no
cutime=0 cstime=0
<<<test_end>>>
INFO: ltp-pan reported some tests FAIL
LTP Version: LTP-20100831

        ###############################################################"

             Done executing testcases."
             LTP Version:  LTP-20100831
        ###############################################################"


----------------------------------------

On Mon, Feb 14, 2011 at 4:23 PM, Cyril Hrubis<[email protected]>  wrote:
>  Hi!
>>  >  On the preliminary analysis of  this failure, I came to know that the 
>> reason was due to insufficient file permissions provided in the
>>  >  "runtests/fs_perms_simple" . To execute a script file, 'user', 'group', 
>> or 'others' should have 'read' and 'execute' permissions.
>>  >  Based on that, I have modified the "s_perms_simple"  file as follows:
>>  >
>>  >  -fs_perms01 fs_perms 001 99 99 12 100 x 0
>>  >  -fs_perms02 fs_perms 010 99 99 200 99 x 0
>>  >  -fs_perms03 fs_perms 100 99 99 99 500 x 0
>>  >  +fs_perms01 fs_perms 005 99 99 12 100 x 0
>>  >  +fs_perms02 fs_perms 050 99 99 200 99 x 0
>>  >  +fs_perms03 fs_perms 500 99 99 99 500 x 0
>>
>>  Actually these are correct, the last number in a row is
>>  'expected result'. So execution of these files must fail in order for
>>  the test to succeed.
>
>  Reading the source again, 0 is success there.
>
>  But then 001 is right to exec by other which should work.
>           010 is right to exec for group, which is the same on that line
>           100 is right to exec for owner, which is the same again
>
>  So this should really work. Let me know if the test works for you with
>  previously posted patch.
>
>  --
>  Cyril Hrubis
>  [email protected]
>
>  
> ------------------------------------------------------------------------------
>  The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
>  Pinpoint memory and threading errors before they happen.
>  Find and fix more than 250 security defects in the development cycle.
>  Locate bottlenecks in serial and parallel code that limit performance.
>  http://p.sf.net/sfu/intel-dev2devfeb
>  _______________________________________________
>  Ltp-list mailing list
>  [email protected]
>  https://lists.sourceforge.net/lists/listinfo/ltp-list
>


------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to