Hello, I'm trying to get a perl script to execute when users connect to their home drive. I have SAMBA 2.0.7 running on RH6.2. This is how my homes section looks: [homes] comment = Home Directories preexec = /var/log/samba/pre-connect.engr.commands %u %m & browseable = no read only = no create mode = 0740 security mask = 0777 force security mode = 0 directory security mask = 0777 force directory security mode = 0 The perl scripts works fine form the command line. It its doing is opening a file in /tmp and writing junk to it. But when users login and there home drive is mapped no file is being created. Its looking like the preexec isn't attempting to run the perl script. The perl script permissions are 755, the temp file is 666. Any ideas on this? Thanks... C. J. Keist Email: cjay@engr.colostate.edu UNIX/Network Manager Phone: 970-491-0630 Engineering Network Services Fax: 970-491-2465 College of Engineering, CSU Ft. Collins, CO 80523-1301
Hello, I figured it out. There was one directory in the path to my script that did not have read access for the world. Got that corrected and now its working fine. C. J. Keist Email: cjay@engr.colostate.edu UNIX/Network Manager Phone: 970-491-0630 Engineering Network Services Fax: 970-491-5569 College of Engineering, CSU Ft. Collins, CO 80523-1301
hi all! is it possible to forbid samba to open a share from within a preexec script? and how could this be done? one idea would be to kill the request, but im sure there is a much nicer solution?! ceys y
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 15 Aug 2003, Yannick Koechlin wrote:> hi all! > is it possible to forbid samba to open a share from within a preexec script? > and how could this be done? > > one idea would be to kill the request, but im sure there is a much nicer > solution?!see "preexec close" in the smb.conf(5) man page. cheers, jerry ---------------------------------------------------------------------- Hewlett-Packard ------------------------- http://www.hp.com SAMBA Team ---------------------- http://www.samba.org GnuPG Key ---- http://www.plainjoe.org/gpg_public.asc "You can never go home again, Oatman, but I guess you can shop there." --John Cusack - "Grosse Point Blank" (1997) -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (GNU/Linux) Comment: For info see http://quantumlab.net/pine_privacy_guard/ iD8DBQE/QkOWIR7qMdg1EfYRAjsSAJ9H6QYbMmjdzOqqQAHqNT9ofcsYuwCg2L4D nru5i1T8TC9R8l9uJP8f3/A=xwMz -----END PGP SIGNATURE-----