Koozali.org: home of the SME Server

smb.conf

tim heinzen

smb.conf
« on: January 17, 2003, 10:28:38 PM »
I needed to share a directory within one of my ibays so an old app would work.  I solved the problem by renaming the /etc/e-smith/templates/etc/smb.conf directory to /etc/e-smith/templates/etc/smb.old.conf.  I then edited the /etc/smb.conf file and added the share using the same paramaters as was used by the ibays that I had created using the SME web interface.  I know that any further changes will have to be made directly in the /etc/smb.conf file but I couldn't find another way to accomplish a share within a share.  I couldn't find a "fragment" in the /etc/e-smith/templates/etc/smb.conf folder that contained the ibays.  If anyone has a better way to do this please let me know.  For anyone looking for a quick fix I hope this helps.


Tim

Greg Zartman

Re: smb.conf
« Reply #1 on: January 17, 2003, 10:51:40 PM »
You are just asking for trouble by editting the smb.conf.  Next time you edit, add, or delete an Ibay, that editted smb.conf file is toast.

Why not just make up your own fragment?   Say 95mysharefragment, with the following:

[mystaticshare]
comment = Stuff
path = path to share info
read only = no
writable = yes
printable = no
inherit permissions = yes
create mode = 0660

Place this fragment in /etc/e-smith/templates-custom/etc/smb.conf, expand the /etc/smb.conf fragment, and restart samba.  Will save you many headaches...  :o)

Greg Zartman

Ed Form

Re: smb.conf
« Reply #2 on: January 18, 2003, 01:05:48 AM »
tim heinzen wrote:

> I needed to share a directory within one of my ibays so an
> old app would work.  I solved the problem by renaming the
> /etc/e-smith/templates/etc/smb.conf directory to
> /etc/e-smith/templates/etc/smb.old.conf.  I then edited the
> /etc/smb.conf file and added the share using the same
> paramaters as was used by the ibays that I had created using
> the SME web interface.  I know that any further changes will
> have to be made directly in the /etc/smb.conf file but I
> couldn't find another way to accomplish a share within a
> share.  I couldn't find a "fragment" in the
> /etc/e-smith/templates/etc/smb.conf folder that contained the
> ibays.  If anyone has a better way to do this please let me
> know.  For anyone looking for a quick fix I hope this helps.

Am I being dumb here or did you miss the obvious trick? If your workstations are Winblows you can map a drive letter to a subdirectory of an already mapped ibay.

Ed Form

Boris

Re: smb.conf
« Reply #3 on: January 18, 2003, 08:22:27 AM »
It is not that obvious since by using "right-click" you can map only share.
Try something like "net use f: \server-name\share-name\folder-name" from the command line. If you've enabled PDC support you can put this command in you login.bat file to restore mapping on restart.
You shouldn't modify smb.conf directly. Your changes will be lost the next time this file rebuild from templates. Keep it standard or use custom-templates if you know what you are doing.
Good luck.
Boris.

Ed Form

Re: smb.conf
« Reply #4 on: January 18, 2003, 03:10:18 PM »
Boris wrote:
>
> It is not that obvious since by using "right-click" you can
> map only share. Try something like "net use f:
> \server-name\share-name\folder-name" from the command line.
> If you've enabled PDC support you can put this command in you
> login.bat file to restore mapping on restart...

In Windows 2000 or XP open any folder and choose TOOLS - MAP NETWORK DRIVE from the menu. Then choose the drive letter you want and navigate to the required folder in the shared ibay and click FINISH.

In Windows 98 there is a button bar menu that can be made visible by right-clicking on the menu bar and then clicking on the item STANDARD BUTTONS that appears. One of the standard buttons is a MAP NETWORK DRIVE tool.

Ed Form

Tim Heinzen

Re: smb.conf
« Reply #5 on: January 20, 2003, 11:39:17 PM »
Thanks, I'll try that.  I was looking for the fragment that listed the ibays.  I didn't know I could just add a fragment (I'm a newbie)

Tim Heinzen

Re: smb.conf
« Reply #6 on: January 20, 2003, 11:41:57 PM »
While I can map a folder within a share using the net use command on a Windows 2000 or Windows XP machine, I can't do it using Windows 98 (which is what the machine that needs to map the drive is running).  If you know of any way to do this on a Win98 or older machine I'd love to know how.


Thanks
Tim

steve

Re: smb.conf
« Reply #7 on: January 21, 2003, 02:49:27 AM »
afaik, the functionality of mapping to dirs under a share is only available in Win2k and XP.
It will not work in NT4, 9X.

hth

steve

Tom Keiser

Re: smb.conf
« Reply #8 on: January 21, 2003, 06:43:36 AM »
Steve wrote:

"afaik, the functionality of mapping to dirs under a share is only available in Win2k and XP. It will not work in NT4, 9X."

Wrong! Go back and read Ed Form's post. He's right, and it works in 98.

T.

Greg Zartman

Re: smb.conf
« Reply #9 on: January 21, 2003, 07:47:37 PM »
> Wrong! Go back and read Ed Form's post. He's right, and it
> works in 98.

Yes, Ed did point out a valid Windows mapping mechanism, but this does not go to the underlying issue presented by the original poster: manually editing the smb.conf file.  Regardless of what he does on the client end, editing smb.conf on an SME box is always bad practice.

Regards,

Greg Zartman

Ed Form

Re: smb.conf
« Reply #10 on: January 22, 2003, 01:01:33 AM »
Greg Zartman wrote:

> Yes, Ed did point out a valid Windows mapping mechanism, but
> this does not go to the underlying issue presented by the
> original poster: manually editing the smb.conf file.
> Regardless of what he does on the client end, editing
> smb.conf on an SME box is always bad practice.

On the contrary, my info did go to the underlying issue. it pointed out that editting the smb.conf file is totally unnecessary in the first place.

Ed Form