File:
[LON-CAPA] /
doc /
build /
Attic /
loncapasamba.html
Revision
1.1:
download - view:
text,
annotated -
select for diffs
Fri Oct 27 02:28:11 2000 UTC (23 years, 10 months ago) by
harris41
Branches:
MAIN
CVS tags:
version_1_0_3,
version_1_0_2,
version_1_0_1,
version_1_0_0,
version_0_99_5,
version_0_99_4,
version_0_99_3,
version_0_99_2,
version_0_99_1,
version_0_99_0,
version_0_6_2,
version_0_6,
version_0_5_1,
version_0_5,
version_0_4,
stable_2002_spring,
stable_2002_july,
stable_2002_april,
stable_2001_fall,
conference_2003,
STABLE,
HEAD
howto's and descriptions of system services associated with LON-CAPA -Scott
1: <HTML>
2: <HEAD>
3: <TITLE>LON-CAPA Samba-Windows Connectivity Documentation</TITLE>
4: </HEAD>
5: <BODY>
6: <H1>LON-CAPA Samba-Windows Connectivity Documentation</H1>
7: <P>
8: Scott Harrison
9: </P>
10: <P>
11: Last updated: 10/26/2000
12: </P>
13: <H3>Introduction</H3>
14: <P>
15: This file describes issues associated with accessing a LON-CAPA machine through
16: Samba. This allows Microsoft machines to mount portions of the LON-CAPA machine
17: as file space (useful for an instructor).
18: </P>
19: <P>
20: <H3>Password Synchronization</H3>
21: <PRE>
22: Can we sync samba password file space mounting with a kerberos v4 system?
23: The answer is yes-no-maybe so. It is doable via kerberos v5
24: only with Microsoft Windows 2000. Samba supports kerberos v4 but requires
25: instructors et al to change their windows settings to send plaintext
26: passwords over the net as opposed to encrypted passwords.
27: Can we even sync samba password file space with unix password file space?
28: ONLY if we script something that crypts both (assume a user has
29: already been added, this script invokes both usermod and smbpasswd...
30: similar to http://adis.on.ca/School-doc/Highschool-HOWTO-1-4.html)
31: so I guess, if instructors want to have samba access be the same
32: as pilot access, they must actually "sign-up" somehow everytime they
33: change their pilot password :(
34:
35: #! /bin/bash
36:
37: # /sbin/newpasswd
38: #
39: # Change the password of an existing user:
40: # newpasswd [name] [password]
41:
42: PATH=/bin:/sbin:/usr/bin:/usr/sbin
43:
44: NAME=$1
45: PASSWD=$2
46:
47: # Define error message
48: usage ()
49: {
50: echo " "
51: echo "Usage: newpasswd [name] [password]"
52: echo " "
53: }
54:
55: # Test for username
56: if [ -z "$NAME" ]; then
57: usage
58: exit 1
59: fi
60:
61: # Test for existing user name
62: if ! id $NAME > /dev/null 2>&1; then
63: echo "No such user exists!"
64: exit 1
65: fi
66:
67: # Test for password
68: if [ -z "$PASSWD" ]; then
69: usage
70: exit 1
71: fi
72:
73: # Run the usermod command
74: if usermod -p `echo "print crypt('$PASSWD', 'RH');" | perl` $NAME; then
75: # Change password with /etc/smbpasswd
76: echo "$PASSWD" > /etc/smbpwd
77: echo "$PASSWD" >> /etc/smbpwd
78: smbpasswd -s $NAME < /etc/smbpwd
79: rm -f /etc/smbpwd
80: echo " "
81: echo "Success!"
82: echo "Changed the user: $NAME"
83: echo "To password: $PASSWD"
84: echo " "
85: else
86: echo " "
87: echo "Oops, something went wrong!"
88: echo " "
89: fi
90:
91: </PRE>
92: <H3>RPM packages</H3>
93: <PRE>
94: Get these packages and install all three
95: samba-2.0.7-4.i386.rpm
96: samba-client-2.0.7-4.i386.rpm
97: samba-common-2.0.7-4.i386.rpm
98: (probably don't need samba-client though..except for development)
99: </PRE>
100: <H3>Configuration</H3>
101: <PRE>
102: Generate a config file. (/etc/smb.conf)
103:
104: # Samba config file created using LON-CAPA system
105: # Date: 2000/09/16 20:15:55
106:
107: # Global parameters
108: [global]
109: workgroup = LONCAPA_{{{{[lonDefDomain]}}}}
110: netbios name = {{{{[lonHostID]}}}}
111: server string = Samba Server
112: encrypt passwords = Yes
113: log file = /var/log/samba/log.%m
114: max log size = 0
115: socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
116: dns proxy = No
117:
118: [homes]
119: comment = Home Directories
120: writeable = Yes
121: browseable = No
122: </PRE>
123:
124: <H3>Synchronizing passwords, quick fix</H3>
125: <PRE>
126: Run these commands to sync the passwords.
127: cat /etc/passwd | mksmbpasswd.sh > /etc/smbpasswd
128: and run, per-user this command (for the users you want active)
129: smbpasswd johndoe88 (but then you have to type in the passwords)
130: (this refers to Step #0, the whole password issue)
131: </PRE>
132:
133: <H3>Process control</H3>
134: <PRE>
135: Run /etc/rc.d/init.d/smb restart
136: Run /etc/rc.d/init.d/inet restart
137: </PRE>
138:
139: <H3>Notes</H3>
140: <PRE>
141: Be patient. In 10 minutes or so, Network Neighborhood
142: will do its poorly designed Bill-Gates rhumba and realize your
143: computer is indeed samba-ing on the network.
144: </PRE>
145: </P>
146: </BODY>
147: </HTML>
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>