Page 1 of 2 12>
Topic Options
#23795 - 2002-06-25 03:00 AM Global Groups
Troy Edwards Offline
Fresh Scripter

Registered: 2002-06-12
Posts: 23
Loc: Dallas, TX
I had figured out how to do this, and stupid me, accidentaly erased the scripts. I am looking for a way to use global groups (domain), with using the IF INGROUP command. Please help!
_________________________
Troy Edwards IS Manager Brandt Engineering Co.

Top
#23796 - 2002-06-25 03:07 AM Re: Global Groups
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
code:
IF INGROUP("Domain Users")
DISPLAY "z:\users.txt"
ENDIF

_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#23797 - 2002-06-25 03:10 AM Re: Global Groups
Troy Edwards Offline
Fresh Scripter

Registered: 2002-06-12
Posts: 23
Loc: Dallas, TX
That doesn't work, for some reason on the Win9X clients. Here's what I got, and yes I have KXRPC installed on all DC.

? "Logon Server: " @lserver
? "KIXRPC Server: " @rserver
? "Date: " @date
? "Domain: " @domain

; --Set Workstation Time
SetTime "*"
? "Time syncronized with the server"

Use * /Delete /Persistent

$user= @userid + "$"
use u: "\\brandtpdc\$user"

IF INGROUP("Everyone", 1) = 1 use t: "\\cluster1\forms" endif
IF INGROUP("Safety", 1) = 1 use f: "\\cluster1\safety" endif
IF INGROUP("Controls", 1) = 1 use g: "\\cluster1\controls" endif
IF INGROUP("Estimating", 1) = 1 use h: "\\cluster1\estimating" endif
IF INGROUP("Sales", 1) = 1 use i: "\\cluster1\sales" endif
IF INGROUP("Engineering", 1) = 1 use j: "\\cluster1\engineering" endif
IF INGROUP("McCormick", 1) = 1 use k: "\\cluster1\mccormick" endif
IF INGROUP("Billing", 1) = 1 use l: "\\cluster1\billing" endif
IF INGROUP("Maxwell", 1) = 1 use m: "\\ntmaxwell\maxwell" endif
IF INGROUP("Drafting", 1) = 1 use n: "\\cluster1\drafting" endif
IF INGROUP("DP", 1) = 1 use o: "\\cluster1\dp" endif
IF INGROUP("Project Management", 1) = 1 use p: "\\cluster1\projmgmt" endif
IF INGROUP("Quickpen", 1) = 1 use q: "\\cluster1\quickpen" endif
IF INGROUP("Payroll", 1) = 1 use r: "\\cluster1\payroll" endif
IF INGROUP("Service", 1) = 1 use s: "\\cluster1\service" endif
IF INGROUP("Constructware", 1) = 1 use v: "\\cluster1\constructware" endif
IF INGROUP("Electrical", 1) = 1 use w: "\\cluster1\electrical" endif
IF INGROUP("Domain Admins", 1) = 1 use x: "\\cluster1\mis" endif
IF INGROUP("Purchasing", 1) = 1 use y: "\\cluster1\purchase" endif
IF INGROUP("Accounting", 1) = 1 use z: "\\cluster1\accounting" endif
_________________________
Troy Edwards IS Manager Brandt Engineering Co.

Top
#23798 - 2002-06-25 03:13 AM Re: Global Groups
Troy Edwards Offline
Fresh Scripter

Registered: 2002-06-12
Posts: 23
Loc: Dallas, TX
Nevermind got the Win9X clients to map everything except user drives. Any ideas why? Worked before.
_________________________
Troy Edwards IS Manager Brandt Engineering Co.

Top
#23799 - 2002-06-25 03:17 AM Re: Global Groups
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Pause the script and check the value of $User. On some Wintendos, @UserID does not return anything during logon.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#23800 - 2002-06-25 03:17 AM Re: Global Groups
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Also, with Wintendos, you must leave the Z: drive alone during logon.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#23801 - 2002-06-25 03:18 AM Re: Global Groups
Troy Edwards Offline
Fresh Scripter

Registered: 2002-06-12
Posts: 23
Loc: Dallas, TX
Is there a different way?
_________________________
Troy Edwards IS Manager Brandt Engineering Co.

Top
#23802 - 2002-06-25 03:31 AM Re: Global Groups
Troy Edwards Offline
Fresh Scripter

Registered: 2002-06-12
Posts: 23
Loc: Dallas, TX
Figured it out. Next problem is:

I have a network w/ a VPN to two other locations. They have their own login server, but replicate to all the other DC's (Windows 2000 Native AD). How do you make a seperate login script file that will map what they need to their specific server (i.e. file shares and printers)? I tried doing this and that's how I screwed it all up. Not a programmer, but starting to feel like one. I'm pretty impressed with the program and once you figure out the specifics, it works. I just need to know how this would work. Any ideas would be great!
_________________________
Troy Edwards IS Manager Brandt Engineering Co.

Top
#23803 - 2002-06-25 04:27 AM Re: Global Groups
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
You can call specific code based on the clients subnet or IP address. Search the UDF library for "Subnet" to get some ideas.
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#23804 - 2002-06-25 04:12 PM Re: Global Groups
Troy Edwards Offline
Fresh Scripter

Registered: 2002-06-12
Posts: 23
Loc: Dallas, TX
I am using this to delete all drives and any persistent drives. Win 2K is not doing this. Any ideas? Use * /Delete /Persistent

It is mapping the other's, just not getting rid of the old mapped drives, nor overwriting any letters.
_________________________
Troy Edwards IS Manager Brandt Engineering Co.

Top
#23805 - 2002-06-25 04:27 PM Re: Global Groups
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
Are you saying that that the "Use * /Delete /Persistent" is not removing old drive on W2K only?

Have you tried to "Use X: /Delete /Persistent" where "X" is a drive that does not unmap?

Did I understand your problem?
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#23806 - 2002-06-25 04:32 PM Re: Global Groups
Troy Edwards Offline
Fresh Scripter

Registered: 2002-06-12
Posts: 23
Loc: Dallas, TX
I take that back it is not working on either (2K nor 9X). I need it to delete all drives first, then remap to what their group is. It maps the groups, but won't overwrite, nor delete any previous mappings. [Razz]
_________________________
Troy Edwards IS Manager Brandt Engineering Co.

Top
#23807 - 2002-06-25 05:31 PM Re: Global Groups
BrianTX Offline
Korg Regular

Registered: 2002-04-01
Posts: 895
Hmm. not sure you need /persistent

Try just:
code:
USE "*" /DELETE

Also, your $ needs to be doubled in a string
$user = "@USERID$$"

Brian

[ 25 June 2002, 17:34: Message edited by: BrianTX ]

Top
#23808 - 2002-06-25 05:32 PM Re: Global Groups
Troy Edwards Offline
Fresh Scripter

Registered: 2002-06-12
Posts: 23
Loc: Dallas, TX
Will give it a whirl. Thanks.
_________________________
Troy Edwards IS Manager Brandt Engineering Co.

Top
#23809 - 2002-06-25 05:36 PM Re: Global Groups
BrianTX Offline
Korg Regular

Registered: 2002-04-01
Posts: 895
See previous message I edited again.. another thing:

Why are your ingroups like this:

IF INGROUP("groupname",1) ?

They should just be

IF INGROUP("groupname")

correct?

Top
#23810 - 2002-06-25 06:11 PM Re: Global Groups
evf Offline
Fresh Scripter

Registered: 2002-06-24
Posts: 16
About this:
"I have a network w/ a VPN to two other locations. They have their own login server, but replicate to all the other DC's (Windows 2000 Native AD). How do you make a seperate login script file that will map what they need to their specific server (i.e. file shares and printers)? I tried doing this and that's how I screwed it all up. Not a programmer, but starting to feel like one. I'm pretty impressed with the program and once you figure out the specifics, it works. I just need to know how this would work. Any ideas would be great!"

You can separate the users by their homedir, i.e. $h=@homedir.

Then, using the substr command you can get the server name that the user belongs to. i.e. user: user1 / server: server1 / homedir: \\server1\user1 ==> $s=substr($h,1,9). This way you do $s="\\server1" <=== Server name.

After that, you can use $s in your script:
use e: $s+"\dep"
use f: $s+"\sof"
use i: $s+"\des"
use j: $s+"\pro"
use y: $s+"\cd_rom"
so on....

If you give me more details, I can help you to finish you script.

Top
#23811 - 2002-06-25 09:18 PM Re: Global Groups
MightyR1 Offline
MM club member
*****

Registered: 1999-09-09
Posts: 1264
Loc: The Netherlands
Troy,

Why not put all users from Location A in a global group called "Location_A" and all users from Location B in "Location_B"

Then you can use:
code:
select
case ingroup("Location_A") = 1
call "Location_A.kix"
case ingroup("Location_B") = 1
call "Location_B.kix"
case 1
? "Not in A or B...."
endselect

_________________________
Greetz,
Patrick Rutten

- We'll either find a way or make one...
- Knowledge is power; knowing how to find it is more powerful...
- Problems don't exist; they are challenges...

Top
#23812 - 2002-06-25 09:40 PM Re: Global Groups
Troy Edwards Offline
Fresh Scripter

Registered: 2002-06-12
Posts: 23
Loc: Dallas, TX
Brian,

In the manual, it states using the ,1 lets it acknowledge they could be in more than one group. Is this not correct?
_________________________
Troy Edwards IS Manager Brandt Engineering Co.

Top
#23813 - 2002-06-25 09:45 PM Re: Global Groups
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Troy,
Don't know what manual you're reading... can find no such in Ruud's manual.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#23814 - 2002-06-25 09:46 PM Re: Global Groups
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
Not my 4.02 manual. what version are you using?
_________________________
Home page: http://www.kixhelp.com/hb/

Top
Page 1 of 2 12>


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 2419 anonymous users online.
Newest Members
batdk82, StuTheCoder, M_Moore, BeeEm, min_seow
17885 Registered Users

Generated in 0.187 seconds in which 0.15 seconds were spent on a total of 13 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org