I also had difficulity getting kixstart to generate group drive mappings for windows98 boxes.
What I did was to write a perl script that spooled/created a netlogin.bat, ran it on logon and deleted it afterwards.
The perl script is run via the root preexec. It runs when a connection is made to the share (%U translates to the user name, thus username.bat is created when the connection is run). This creates the batch file and the root postexec deletes the file afterwards.
It requires some maintenance, to account for adding shares, but I have found it to work well.
============= snip from /etc/smb.conf ===========
[netlogon]
comment = Network Logon Service
path = /home/netlogon
guest ok = yes
writable = yes
browseable = no
root preexec = /home/netlogon/genlogon.pl %U %L
root postexec = rm /home/netlogon/%U.bat
===== code of perl script to create the username.bat file ======
#!/usr/bin/perl
#
# genlogon.pl
#
# Perl script to general user logon scripts on the fly, when users connect
# from windows clients. This script should be called from smb.conf with
# the following paramaters:
# %U - User Name
# %L - Server Name
# ie root preexec = genlogon.pl %U %L
#
# The script will perform the following:
# 1. Log the user connection to /val/log/samba/netlogon.log
# 2. Set the client workstation to the Linux server time
# 3. Connect the user's home drive to H
# 4. Connect the common drives (I, S)
# 5. Connect the group specific drives (H, I, X, L, M)
# 6. Connect the network printers
#
#log client connection
($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst) = localtime(time);
open LOG,">>/var/log/samba/netlogon.log";
print LOG "$mday/$mon/$year $hour:$min:$sec - User $ARGV[0] logged into $ARGV[1]\n";
close LOG;
# get the groups a user is a member of
$Groups = groups $ARGV[0];
#start logon script generation
open LOGON, ">/home/netlogon/logon/$ARGV[0].bat";
print LOGON "::\@echo off\r\n";
print LOGON ":: Group membership for $Groups\r\n";
#generate the common drive mappings (incl guest)
print LOGON "net time \$ARGV[1] /set /yes\r\n";
print LOGON "\r\n::Mapping for all logins\r\n";
print LOGON "net use i: \$ARGV[1]\winapps\r\n";
print LOGON "net use s: \$ARGV[1]\documents\r\n";
#generate drive mapping for the Staff group
if ($Groups=~/staff/i)
{
print LOGON "\r\n::Mapping for the Staff group\r\n";
print LOGON "net use h: \$ARGV[1]\$ARGV[0]\r\n";
print LOGON "\r\n::Mapping for the Electrac group\r\n";
print LOGON "net use l: \$ARGV[1]\electrak\r\n";
}
#generate drive mapping for the Admins group
if ($Groups=~/admins/i)
{
print LOGON "\r\n::Mapping for the Admins group\r\n";
print LOGON "net use x: \$ARGV[1]\backups\r\n";
}
#generate the drive mapping for the intranet group
if ($Groups=~/intranet/i)
{
print LOGON "\r\n::Mapping for the Intranet group\r\n";
print LOGON "net use n: \$ARGV[1]\Intranet\r\n";
}
#logon script generation complete, closing the output file
close LOGON;