Forum OpenACS Q&A: Response to How to set permissions for reading files

Collapse
Posted by Bob OConnor on

I still havn't solved this one.

I've made the file -rw-rw-r-- and I've added nsadmin to the mail group and when I telnet in as the nsadmin user I can (even) edit the file. If I remove nsadmin from the mail group, I can't edit or read...correct as expected.

But, through aolserver which I assume is an NSADMIN user from ps:
...nsd76 -it .../nsd.tcl -u nsadmin -g nsadmin
I killed nsd76 so it would restart yet I get the same result in this tcl file:

if ** file owned /var/lib/majordomo/lists/teamlist **...
ns_log Notice "File IS NOT owned  (EXPECTED)

if **file readable /var/lib/majordomo/lists/teamlist **...
  ns_log Notice "File IS NOT readable (NOT EXPECTED)

set member_file **(open /var/lib/majordomo/lists/members RDONLY )**
  RESULT from Log:
Error: nsd.tcl: couldn't open "/var/lib/majordomo/lists/teamlist": permission denied
couldn't open "/var/lib/majordomo/lists/teamlist": permission denied
while executing
"open /var/lib/majordomo/lists/members RDONLY"

I even put nsadmin in the root group because the var & lib directories are root root and perhaps they couldn't be accessed. Yes I know this isn't safe but temporarily for testing....

So WHY the permission denied?

TIA -Bob

** square & curlies removed for this message