Koozali.org: home of the SME Server

SME server kills my local windows nework?

Offline svetlo56

  • **
  • 39
  • +0/-0
SME server kills my local windows nework?
« Reply #15 on: February 17, 2007, 03:27:30 PM »
Quote from: "RayMitchell"
svetlo56


> WHAT MAY BE USEFUL IS SOMETHING GO THERE CHANGE THIS END

The more explicit steps are (which you should learn to work out for yourself)

cp /etc/e-smith/templates/etc/smb.conf/11osLevel /etc/e-smith/templates-custom/etc/smb.conf/11osLevel

pico /etc/e-smith/templates-custom/etc/smb.conf/11osLevel

make changes to the line that says
 my $os_level = $smb{OsLevel} || "65";
eg set to 30 if you want windows servers to be browsemasters or set to 95 if you want sme to be browsemaster

Ctrl o to save Ctrl x to exit

expand-template /etc/smb.conf

/etc/init.d/smb restart

note this wil restart smb & nmb services

Read the devinfo guide and search forums and how tos for many many examples of the approach to doing this for any custom template & service.


Why not change directly the file
/etc/e-smith/templates/etc/smb.conf/11osLevel

as above? I tried searching under devinfo and custom templates and got nowhere. I really want to learn but the search was unwieldy.

Offline raem

  • *
  • 3,972
  • +4/-0
SME server kills my local windows nework?
« Reply #16 on: February 17, 2007, 03:56:15 PM »
svetlo56

> Why not change directly the file /etc/e-smith/templates/etc/smb.conf/11osLevel

You asked for a GO THERE, CHANGE THIS, END approach, and now you are even questioning that.
I suggest you need to listen to what people are telling you, learn a lot more about sme, and improve your search skills.

Changing templates directly is NOT the recommended approach. Creating custom templates IS the recommended approach, as you can easily return your server to default settings in the event the you wish to undo your changes or have made errors when doing your changes. Any upgrades will overwrite the templates and replace your customisation, whereas custom templates will not be overwritten during upgrades.
Note that the custom template contents take precedence over the templates contents when an expand-template event is done.
That's the whole point of the templating system.

Your approach is essentially why have templates at all, why not just edit config files directly eg edit /etc/samba/smb.conf
Well that's how it is done in most other Linux OS's, and can lead to a lot of problems, whereas using the sme templates and custom templates method allows for easy manipulation of settings and easy troubleshooting if incorrect changes are made and allows your customisations to be retained during upgrades of packages & template settings etc.

To undo a change you would do
rm /etc/e-smith/templates-custom/etc/smb.conf/11osLevel
expand-template /etc/smb.conf
/etc/init.d/smb restart

> I tried searching under devinfo

The mail list archive us here
http://lists.contribs.org/mailman/public/devinfo/

>....custom templates and got nowhere.

See Chapter 8 of the dev guide
http://mirror.contribs.org/smeserver/contribs//gordonr/devguide/devguide.pdf


> I really want to learn but the search was unwieldy.

If you want to use Linux I can guarantee that you will have to read a lot and learn a lot, and that will involve wading through many forums threads & posts, as unweildly as it may seem to you. Linux is really a self help community.
...

Offline JohnG

  • ****
  • 89
  • +0/-0
Re: SME server kills my local windows nework?
« Reply #17 on: February 17, 2007, 04:56:54 PM »
Quote from: "svetlo56"
The problem is that my Windows network does not work, after a period of working fine. I tried disconnecting the SME server (which has assigned a static address 192.168.2.225), and then connecting any combination of computers (cca. 7 or more) in any order with Windows networking working. Conversely, whenever the SME server is connected the Windows network does not work (cannot be accessed), regardless of other computers. The bottom line is that only time the Windows network works is when I disconnect ie unplug the wire from the SME server.


As per the original post (unless it's a silly typo), I'm still thinking the SME machine had an incorrect .2.x IP on the same switch as a .1.x IP which confused the switch.

Offline CharlieBrady

  • *
  • 6,918
  • +3/-0
SME server kills my local windows nework?
« Reply #18 on: February 17, 2007, 05:49:47 PM »
Quote from: "RayMitchell"

make changes to the line that says
 my $os_level = $smb{OsLevel} || "65";
eg set to 30 if you want windows servers to be browsemasters or set to 95 if you want sme to be browsemaster


There is no need to change any template.

config setprop smb OsLevel xxx
signal-event workgroup-update

Voila!

Offline raem

  • *
  • 3,972
  • +4/-0
SME server kills my local windows nework?
« Reply #19 on: February 18, 2007, 02:41:40 AM »
Charlie

Thank you Charlie, I didn't realise that was a db entry now.
There are lot's of improvements in sme7.x

Regards
...

Offline gordonr

  • *
  • 646
  • +0/-0
    • http://www.smeserver.com.au/
SME server kills my local windows nework?
« Reply #20 on: February 18, 2007, 09:09:23 AM »
Quote from: "RayMitchell"

Thank you Charlie, I didn't realise that was a db entry now.
There are lot's of improvements in sme7.x


There certainly are, but the line you showed already referred to a db entry, but not one which is configured by default. This:

Code: [Select]
my $os_level = $smb{OsLevel} || 65;

says "Use the value of the OsLevel property of the smb service. If that value isn't configured, use the value 65". The 65 shouldn't be quoted - it's a number, not a string (though Perl will work it out correctly in most cases).

Gordon

P.S. I lied a little above. A value of 0 will be treated as the same as not configured. You need to be a bit more careful if 0 is a useful value.
............

Offline raem

  • *
  • 3,972
  • +4/-0
SME server kills my local windows nework?
« Reply #21 on: February 18, 2007, 02:53:30 PM »
gordon

Thank you for that primer, I'm sure it will be very useful for other code analysis. Others should benefit from it too.

Have a safe & successful trip to USA.
Regards
Ray
...

Offline svetlo56

  • **
  • 39
  • +0/-0
SME server kills my local windows nework?
« Reply #22 on: February 18, 2007, 04:31:11 PM »
Quote from: CharlieBrady
Quote from: "RayMitchell"


There is no need to change any template.

config setprop smb OsLevel xxx
signal-event workgroup-update

Voila!


Thanks a ton! Thanks to Ray to pointing things to me and making me learn something.

Now, shouldn't this be made an option during installation? I am sure many people have the same problem? The option would be "Is this server going to be a member of Windows workgoup?" Yes or No and then some brief explanation in a small print?

Offline gordonr

  • *
  • 646
  • +0/-0
    • http://www.smeserver.com.au/
SME server kills my local windows nework?
« Reply #23 on: February 18, 2007, 06:42:24 PM »
Quote from: "svetlo56"
[
Thanks a ton! Thanks to Ray to pointing things to me and making me learn something.

Now, shouldn't this be made an option during installation? I am sure many people have the same problem? The option would be "Is this server going to be a member of Windows workgoup?" Yes or No and then some brief explanation in a small print?


Historically we have started with Samba enabled, but not as a domain controller/browse master. This configuration should not affect most Windows networks, however it appears that it does for some.

I ve thought for a while that we should change this so that Samba (and AppleTalk for that matter) does not start until you visit the Workgroup panel and set your Workgroup name and possibly server name.

Could you raise this as a bug please? I can do it, but I have plenty of bugs in my name, and I tend to look at other people's bugs before my own :-)
............