Odd preexec/root preexec behavior

Jeremy Allison jra at samba.org
Mon Dec 10 17:06:51 GMT 2001


On Thu, Nov 29, 2001 at 01:03:42AM -0800, Kris Jordan wrote:
> Running Samba 2.2.2, having troubles with preexec when it involves the 
> path parameter:
> 
> Log on to the samba server as kris, user "users".
> %U expands to kris, %G expands to users.
> 
> [profile]
>     path = /data/profile/%U
>     preexec = /bin/mkdir -m 700 /data/profile/%U
>     writable = yes
>     create mode = 0600
>     directory mode = 0700
> 
> This fails to work, Samba reports that it could not open 
> /data/profile/kris. Replacing preexec with "root preexec = /bin/mkdir -m 
> 700 /data/profile/%U; chown %U:%G /data/profile/%U" fixes the problem, 
> but it does not explain what the problem with preexec is. If I remove %U 
> from the path parameter, preexec works, the directory does shows up, but 
> I don't it set-up this way of course.
> 
> I found a bug report about preexec not working, but supposedly it has 
> been fixed in 2.2.1.

I just fixed this in the SAMBA_2_2 CVS tree. If you could check
out the new code and test this I'd appreciate it.

Thanks,

	Jeremy.




More information about the samba mailing list