fifos on samba / 2.6.0 cifs

Florian Lohoff flo at rfc822.org
Tue Dec 30 16:07:11 GMT 2003


Hi,
i am trying to get fifos running (Which is the major showstopper on
putting roaming linux users homedir on an SMB share)

I found that using Linux 2.6.0 cifs filesystem i can see fifos and
symlinks correctly mounting a samba share. I can also create symlinks
but not fifos.

By digging through the source i found that this is the default behaviour
in the samba code as it does not compile in that code 

#if !defined(HAVE_MAKEDEV_FN)

As this looks like someone is testing for some function in configure i
looked there to no success.

So i guess this is either knowingly disabled or someone stepped on the
wrong define.

As the sys_mknod wrapper in source/lib/system.c already checks for the
availability of any type of mknod and returns ENOSYS in case it doesnt i
would propose to drop all ifdef's in source/smbd/trans2.c

This will not drop out early in case of unavailability of mknod 
but mknod is not really a hot path i guess.

e.g:

Index: source/smbd/trans2.c
===================================================================
RCS file: /cvsroot/samba/source/smbd/trans2.c,v
retrieving revision 1.258
diff -u -r1.258 trans2.c
--- source/smbd/trans2.c	1 Dec 2003 06:53:21 -0000	1.258
+++ source/smbd/trans2.c	30 Dec 2003 16:04:26 -0000
@@ -2848,9 +2848,6 @@
 				 * a new info level should be used for mknod. JRA.
 				 */
 
-#if !defined(HAVE_MAKEDEV_FN)
-				return(ERROR_DOS(ERRDOS,ERRnoaccess));
-#else /* HAVE_MAKEDEV_FN */
 				uint32 file_type = IVAL(pdata,0);
 				uint32 dev_major = IVAL(pdata,4);
 				uint32 dev_minor = IVAL(pdata,12);
@@ -2890,8 +2887,6 @@
 				SSVAL(params,0,0);
 				send_trans2_replies(outbuf, bufsize, params, 2, *ppdata, 0);
 				return(-1);
-#endif /* HAVE_MAKEDEV_FN */
-
 			}
 
 			/*

Flo
-- 
Florian Lohoff                  flo at rfc822.org             +49-171-2280134
                        Heisenberg may have been here.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.samba.org/archive/samba-technical/attachments/20031230/5eb8629e/attachment.bin


More information about the samba-technical mailing list