Author Topic: Samba domain controller, logon script doesn't run  (Read 712 times)

ims27_8

  • Member
  • **
  • Posts: 45
  • Kudos: 0
Samba domain controller, logon script doesn't run
« on: 11 January 2003, 15:48 »
as the topic says, i've got a (working) samba domain controller, but my logon script isn't being executed when i log on. The logon script:

Code: [Select]

smb.conf

if i create a duplicate logon.cmd on the windows machine and run it, it works, so the script itself works. The script is located in /home/netlogon on the samba server. I don't know why it isn't working. Does anyone have any ideas? thanks

voidmain

  • VIP
  • Member
  • ***
  • Posts: 5,605
  • Kudos: 184
    • http://voidmain.is-a-geek.net/
Samba domain controller, logon script doesn't run
« Reply #1 on: 11 January 2003, 16:08 »
The first thing I see is you have your netlogon share commented out. You need to uncomment the "[netlogon]". Once you do that and restart Samba you should be able to type "\\Ian\netlogon" in a run box and see your logon script. I'm testing the rest now to see if there is anything else wrong. I don't believe you want to use a full path on the logon script definition. That is I believe if you want everyone to run the same logon script it should be:

logon script = logon.cmd

[edit]
Yep, it works for me.. I'll post my config (which will not be exactly like yours obviously):

http://voidmain.kicks-ass.net/files/smb.conf
[/edit]

[edit2]
I see you are using a very long domain name and I am not sure that a "." is allowed in an NT domain name. But if that's what you want...
[/edit2]

[edit3]
One last thing. You probably already know this but if you have any Win9x machines you should use a *.bat extension. Only NT/2k and above can execute *.cmd scripts.
[/edit3]

[ January 11, 2003: Message edited by: void main ]

Someone please remove this account. Thanks...

ims27_8

  • Member
  • **
  • Posts: 45
  • Kudos: 0
Samba domain controller, logon script doesn't run
« Reply #2 on: 11 January 2003, 16:44 »
I can't believe i did that... well, actually i can, i did the same thing with the profiles share... It's been a long week (at least that's the excuse i'm going to use  :D ). It's working now. However, how can i make the logon script mount the user's home folder aswell? I've seen
net use h: /Home on a few how-to's, but that doesn't work. if i run that in a command prompt i get "the network path was not found". I could just use different logon scripts for each user, but I would like to be able to do it with just one.

Thanks for your help

voidmain

  • VIP
  • Member
  • ***
  • Posts: 5,605
  • Kudos: 184
    • http://voidmain.is-a-geek.net/
Samba domain controller, logon script doesn't run
« Reply #3 on: 11 January 2003, 16:53 »
Well, on Win2k+ you could do:

net use U: %HOMESHARE%

or NT+:

net use U: \\Ian\%USERNAME%

Good luck on 9x, you might have to use individual logon scripts for that one (%U.bat in smb.conf) and have a separate logon script for each user.

[ January 11, 2003: Message edited by: void main ]

Someone please remove this account. Thanks...

ims27_8

  • Member
  • **
  • Posts: 45
  • Kudos: 0
Samba domain controller, logon script doesn't run
« Reply #4 on: 11 January 2003, 17:01 »
Well, since my network has 2k & 9x machines, i'll just go with the seperate login scripts. Thanks for all your help.