Initial version imported to CVS
[samba.git] / docs / manpages / smbclient.1
1 .TH SMBCLIENT 1 17/1/1995 smbclient smbclient
2 .SH NAME
3 smbclient \- ftp-like Lan Manager client program
4 .SH SYNOPSIS
5 .B smbclient
6 .B servicename
7 [
8 .B password
9 ] [
10 .B -A
11 ] [
12 .B -E
13 ] [
14 .B -L
15 .I host
16 ] [
17 .B -M
18 .I host
19 ] [
20 .B -I
21 .I IP number
22 ] [
23 .B -N
24 ] [
25 .B -P
26 ] [
27 .B -U
28 .I username
29 ] [
30 .B -d
31 .I debuglevel
32 ] [
33 .B -l
34 .I log basename
35 ] [
36 .B -n
37 .I netbios name
38 ] [
39 .B -O
40 .I socket options
41 ] [
42 .B -p
43 .I port number
44 .B -T
45 .I tar options
46 .B -D
47 .I initial directory
48 ]
49 .SH DESCRIPTION
50 This program is part of the Samba suite.
51
52 .B smbclient
53 is a client that can 'talk' to a Lan Manager server. It offers
54 an interface similar to that of the 
55 .B ftp
56 program (see
57 .B ftp(1)). Operations include things like getting files from the
58 server to the local machine, putting files from the local machine to
59 the server, retrieving directory information from the server and so on.
60
61 .SH OPTIONS
62 .B servicename
63 .RS 3
64 .B servicename
65 is the name of the service you want to use on the server. A service
66 name takes the form
67 .B "\\\\\\\\server\\\\service"
68 where
69 .B server
70 is the netbios name of the Lan Manager server offering the desired service and
71 .B service
72 is the name of the service offered. Thus to connect to the service "printer" 
73 on the Lan Manager server "lanman", you would use the servicename
74
75 .RS 10
76 .B "\\\\\\\\lanman\\\\printer"
77 .RE
78
79 Note that the server name required is NOT necessarily the host name of the
80 server! The name required is a Lan Manager server name, which may or may not
81 be the same as the hostname of the machine running the server.
82 .RE
83
84 .B password
85 .RS 3
86 .B
87 password
88 is the password required to access the specified service on the
89 specified server. If supplied, the
90 .B -N
91 option (suppress password prompt) is assumed.
92
93 There is no default password. If no password is supplied on the command line
94 (either here or using the 
95 .B -U
96 option (see below)) and 
97 .B -N
98 is not specified, the client will prompt for a password, even if the desired 
99 service does not require one. (If prompted for a password and none is 
100 required, simply press ENTER to provide a null password.)
101
102 Note: Some servers (including OS/2 and Windows for Workgroups) insist
103 on an uppercase password. Lowercase or mixed case passwords may be
104 rejected by these servers.
105
106 Be cautious about including passwords in scripts.
107 .RE
108
109 .B -A
110
111 .RS 3
112 This parameter, if specified, causes the maximum debug level to be selected.
113 Be warned that this generates prodigious amounts of debug data. There is also
114 a security issue involved, as at the maximum debug level cleartext passwords
115 may be written to some log files.
116 .RE
117
118 .B -L
119
120 .RS 3
121 This option allows you to look at what services are available on a
122 server. You use it as "smbclient -L host" and a list should appear.
123 The -I option may be useful if your netbios names don't match your 
124 tcp/ip host names or if you are trying to reach a host on another
125 network. For example:
126
127 smbclient -L ftp -I ftp.microsoft.com
128
129 will list the shares available on microsofts public server.
130 .RE
131
132 .B -M
133
134 .RS 3
135 This options allows you to send messages, using the "WinPopup"
136 protocol, to another computer. Once a connection is established you
137 then type your message, pressing ^D (control-D) to end.
138
139 If the receiving computer is running WinPopup the user will receive
140 the message and probably a beep. If they are not running WinPopup the
141 message will be lost, and no error message will occur.
142
143 The message is also automatically truncated if the message is over
144 1600 bytes, as this is the limit of the protocol.
145
146 One useful trick is to cat the message through smbclient. For example:
147
148 cat mymessage.txt | smbclient -M FRED
149
150 will send the message in the file "mymessage.txt" to the machine FRED.
151
152 You may also find the -U and -I options useful, as they allow you to
153 control the FROM and TO parts of the message. 
154
155 Samba currently has no way of receiving WinPopup messages.
156
157 Note: Copy WinPopup into the startup group on your WfWg PCs if you
158 want them to always be able to receive messages.
159 .RE
160
161 .B -E
162
163 .RS 3
164 This parameter, if specified, causes the client to write messages to the
165 standard error stream (stderr) rather than to the standard output stream.
166
167 By default, the client writes messages to standard output - typically the
168 user's tty.
169 .RE
170
171 .B -I
172 .I IP number
173
174 .RS 3
175 .I IP number
176 represents the IP number of the server to connect to. It should
177 be specified in standard "a.b.c.d" notation.
178
179 Normally the client will attempt to locate the specified Lan Manager server
180 by looking it up - that is, broadcasting a request for the given server to
181 identify itself. Using this parameter will force the client to assume that
182 the server is on the machine with the specified IP number.
183
184 There is no default for this parameter. If not supplied, it will be determined
185 automatically by the client as described above.
186 .RE
187
188 .B -N
189
190 .RS 3
191 If specified, this parameter suppresses the normal password prompt from the
192 client to the user. This is useful when accessing a service that does not
193 require a password.
194
195 Unless a password is specified on the command line or this parameter is
196 specified, the client will request a password.
197 .RE
198
199 .B -O
200 .I socket options
201 .RS 3
202
203 See the socket options section of smb.conf(5) for details
204
205 .RE
206 .B -P
207
208 .RS 3
209 If specified, the service requested will be connected to as a printer service
210 rather than as a normal filespace service. Operations such as put and get
211 will not be applicable for such a connection.
212
213 By default, services will be connected to as NON-printer services.
214 .RE
215
216 .B -U
217 .I username
218
219 .RS 3
220 .I username
221 is the user name that will be used by the client to make a connection,
222 assuming your server is running a protocol that allows for usernames.
223
224 Some servers are fussy about the case of this name, and some insist
225 that it must be a valid netbios name.
226
227 If no 
228 .I username
229 is supplied, it will default to an uppercase version of the 
230 environment variable 
231 .B USER
232 or
233 .B LOGNAME
234 in that order.
235 If no 
236 .I username
237 is supplied and neither environment variable exists the user name will
238 be empty.
239
240 If the service you are connecting to requires a password, it can be supplied
241 using the
242 .B -U
243 option, by appending a percent symbol ("%") then the password to 
244 .I username.
245 For example, to attach to a service as user "fred" with password "secret", you
246 would specify
247 .B -U
248 .I fred%secret
249 on the command line. Note that there are no spaces around the percent symbol.
250
251 If you specify the password as part of
252 .I username
253 then the 
254 .B -N
255 option (suppress password prompt) is assumed.
256
257 If you specify the password as a parameter AND as part of
258 .I username
259 then the password as part of
260 .I username
261 will take precedence. Putting nothing before or nothing after the percent 
262 symbol will cause an empty username or an empty password to be used,
263 respectively.
264
265 Note: Some servers (including OS/2 and Windows for Workgroups) insist
266 on an uppercase password. Lowercase or mixed case passwords may be
267 rejected by these servers.
268
269 Be cautious about including passwords in scripts.
270 .RE
271
272 .B -d
273 .I debuglevel
274 .RS 3
275
276 debuglevel is an integer from 0 to 5.
277
278 The default value if this parameter is not specified is zero.
279
280 The higher this value, the more detail will be logged to the log files about
281 the activities of the client. At level 0, only critical errors and serious 
282 warnings will be logged. Level 1 is a reasonable level for day to day running
283 - it generates a small amount of information about operations carried out.
284
285 Levels above 1 will generate considerable amounts of log data, and should 
286 only be used when investigating a problem. Levels above 3 are designed for 
287 use only by developers and generate HUGE amounts of log data, most of which 
288 is extremely cryptic.
289 .RE
290
291 .B -l
292 .I log basename
293
294 .RS 3
295 If specified,
296 .I log basename
297 specifies a base filename into which operational data from the running client
298 will be logged.
299
300 The default base name is specified at compile time.
301
302 The base name is used to generate actual log file names. For example, if the
303 name specified was "log", the following files would be used for log data:
304
305 .RS 3
306 log.client.debug (containing debugging information)
307
308 log.client.in (containing inbound transaction data)
309
310 log.client.out (containing outbound transaction data)
311 .RE
312
313 The log files generated are never removed by the client.
314 .RE
315 .RE
316
317 .B -n
318 .I netbios name
319
320 .RS 3
321 By default, the client will use the local machine's hostname (in
322 uppercase) as its netbios name. This parameter allows you to override
323 the host name and use whatever netbios name you wish.
324 .RE
325
326 .B -p
327 .I port number
328 .RS 3
329
330 port number is a positive integer value.
331
332 The default value if this parameter is not specified is 139.
333
334 This number is the port number that will be used when making connections to
335 the server. The standard (well-known) port number for the server is 139, 
336 hence the default.
337
338 This parameter is not normally specified.
339
340 .B -T
341 .I tar options
342 .RS3 
343
344 where tar options are one or more of c,x,I,X,b,g,N or a; used as:
345 .LP
346 smbclient 
347 .B "\\\\\\\\server\\\\share"
348 \-TcxIXbgNa
349 [
350 .IR blocksize
351 ]
352 [
353 .IR newer-file
354 ]
355 .IR tarfile
356 [
357 .IR filenames....
358 ]
359
360 .RS3
361 .B c
362 Create a tar file on UNIX. Must be followed by the name of a tar file,
363 tape device or "-" for standard output. (May be useful to set debugging
364 low (-d0)) to avoid corrupting your tar file if using "-"). Mutually
365 exclusive with the x flag.
366
367 .B x
368 Extract (restore) a local tar file back to a share. Unless the -D
369 option is given, the tar files will be restored from the top level of
370 the share. Must be followed by the name of the tar file, device or "-"
371 for standard input. Mutually exclusive with the c flag.
372
373 .B I
374 Include files and directories. Is the default behaviour when
375 .IR filenames
376 are specified above. Causes tar files to be included in an extract or create
377 (and therefore everything else to be excluded). See example below.
378 Filename globbing does not work for included files for extractions (yet).
379
380 .B X
381 Exclude files and directories. Causes tar files to be excluded from
382 an extract or create. See example below.
383 Filename globbing does not work for excluded files (yet).
384
385 .B b
386 Blocksize. Must be followed by a valid (greater than zero) blocksize.
387 Causes tar file to be written out in blocksize*TBLOCK (usually 512 byte)
388 blocks.
389
390 .B g
391 Incremental. Only back up files that have the archive bit set. Useful
392 only with the c flag.
393
394 .B N
395 Newer than. Must be followed by the name of a file whose date is
396 compared against files found on the share during a create. Only files
397 newer than the file specified are backed up to the tar file. Useful
398 only with the c flag.
399
400 .B a
401 Set archive bit. Causes the archive bit to be reset when a file is backed
402 up. Useful with the g (and c) flags.
403 .LP
404
405 .B Examples
406
407 smbclient \\\\mypc\\myshare "" -N -Tx backup.tar
408
409 Restore from tar file backup.tar into myshare on mypc (no password on share).
410
411 smbclient \\\\mypc\\myshare "" -N -TXx backup.tar users/docs
412
413 Restore everything except users/docs
414
415 smbclient \\\\mypc\\myshare "" -N -Tc backup.tar users/docs
416
417 Create a tar file of the files beneath users/docs.
418
419 .RE
420
421 .B -D
422 .I initial directory
423
424 .RS3 
425
426 Change to initial directory before starting. Probably only of any use
427 with the tar (\-T) option.
428
429
430 .RE
431
432 .SH OPERATIONS
433 Once the client is running, the user is presented with a prompt, "smb: \\>".
434 The backslash ("\\") indicates the current working directory on the server,
435 and will change if the current working directory is changed.
436
437 The prompt indicates that the client is ready and waiting to carry out a user
438 command. Each command is a single word, optionally followed by parameters
439 specific to that command. Command and parameters are space-delimited unless
440 these notes specifically state otherwise. All commands are case-insensitive.
441 Parameters to commands may or may not be case sensitive, depending on the
442 command.
443
444 You can specify file names which have spaces in them by quoting the
445 name with double quotes, for example "a long file name".
446
447 Parameters shown in square brackets (eg., "[parameter]") are optional. If not
448 given, the command will use suitable defaults. Parameters shown in angle
449 brackets (eg., "<parameter>") are required.
450
451 Note that all commands operating on the server are actually performed by
452 issuing a request to the server. Thus the behaviour may vary from server to
453 server, depending on how the server was implemented.
454
455 The commands available are given here in alphabetical order.
456
457 .B ?
458 .RS 3
459 .B Parameters:
460 .RS 3
461 .I [command]
462
463 .RE
464 .B Description:
465 .RS 3
466 If
467 .I command
468 is specified, the
469 .B ?
470 command will display a brief informative message about the specified command.
471
472 If no command is specified, a list of available commands will be displayed.
473 .RE
474 .RE
475
476 .B !
477 .RS 3
478 .B Parameters:
479 .RS 3
480 .I [shell command]
481
482 .RE
483 .B Description:
484 .RS 3
485 If
486 .I shell command
487 is specified, the
488 .B !
489 command will execute a shell locally and run the specified shell command. If
490 no command is specified, a shell will be run.
491 .RE
492 .RE
493
494 .B cd
495 .RS 3
496 .B Parameters:
497 .RS 3
498 .I [directory name]
499
500 .RE
501 .B Description:
502 .RS 3
503 If
504 .I directory name
505 is specified, the current working directory
506 .B on the server
507 will be changed to the directory specified. This operation will fail if for
508 any reason the specified directory is inaccessible.
509
510 If no directory name is specified, the current working directory
511 .B on the server
512 will be reported.
513 .RE
514 .RE
515
516 .B del
517 .RS 3
518 .B Parameters:
519 .RS 3
520 .I <mask>
521
522 .RE
523 .B Description:
524 .RS 3
525 The client will request that the server attempt to delete all files matching
526 .I mask
527 from the current working directory
528 .B on the server.
529 .RE
530 .RE
531
532 .B dir
533 .RS 3
534 .B Parameters:
535 .RS 3
536 .I <mask>
537
538 .RE
539 .B Description:
540 .RS 3
541 A list of the files matching
542 .I mask
543 in the current working directory
544 .B on the server
545 will be retrieved from the server and displayed.
546 .RE
547 .RE
548
549 .B exit
550 .RS 3
551 .B Parameters:
552 .RS 3
553 None.
554
555 .RE
556 .B Description:
557 .RS 3
558 Terminate the connection with the server and exit from the program.
559 .RE
560 .RE
561
562 .B get
563 .RS 3
564 .B Parameters:
565 .RS 3
566 .I <remote file name> [local file name]
567
568 .RE
569 .B Description:
570 .RS 3
571 Copy the file called
572 .I remote file name
573 from the server to the machine running the client. If specified, name the
574 local copy
575 .I local file name.
576 Note that all transfers in smbclient are binary. See also the
577 .B lowercase
578 command.
579 .RE
580 .RE
581
582 .B help
583 .RS 3
584 .B Parameters:
585 .RS 3
586 .I [command]
587
588 .RE
589 .B Description:
590 .RS 3
591 See the
592 .B ?
593 command above.
594 .RE
595 .RE
596
597 .B lcd
598 .RS 3
599 .B Parameters:
600 .RS 3
601 .I [directory name]
602
603 .RE
604 .B Description:
605 .RS 3
606 If
607 .I directory name
608 is specified, the current working directory
609 .B on the local machine
610 will be changed to the directory specified. This operation will fail if for
611 any reason the specified directory is inaccessible.
612
613 If no directory name is specified, the name of the current working directory
614 .B on the local machine
615 will be reported.
616 .RE
617 .RE
618
619 .B lowercase
620 .RS 3
621 .B Parameters:
622 .RS 3
623 None.
624
625 .RE
626 .B Description:
627 .RS 3
628 Toggle lowercasing of filenames for the
629 .B get
630 and
631 .B mget
632 commands.
633
634 When lowercasing is toggled ON, local filenames are converted to lowercase
635 when using the
636 .B get
637 and
638 .B mget
639 commands. This is often useful when copying (say) MSDOS files from a server,
640 because lowercase filenames are the norm on Unix systems.
641 .RE
642 .RE
643
644 .B ls
645 .RS 3
646 .B Parameters:
647 .RS 3
648 .I <mask>
649
650 .RE
651 .B Description:
652 .RS 3
653 See the
654 .B dir
655 command above.
656 .RE
657 .RE
658
659 .B mask
660 .RS 3
661 .B Parameters:
662 .RS 3
663 .I <mask>
664
665 .RE
666 .B Description:
667 .RS 3
668 This command allows the user to set up a mask which will be used during
669 recursive operation of the
670 .B mget
671 and
672 .B mput
673 commands.
674
675 The masks specified to the
676 .B mget
677 and
678 .B mput
679 commands act as filters for directories
680 rather than files when recursion is toggled ON.
681
682 The mask specified with the
683 .B mask
684 command is necessary to filter files within those directories. For example,
685 if the mask specified in an
686 .B mget
687 command is "source*"
688 .I and
689 the mask specified with the
690 .B mask
691 command is "*.c"
692 .I and
693 recursion is toggled ON, the
694 .B mget
695 command will retrieve all files matching "*.c" in all directories below
696 and including all directories matching "source*" in the current working 
697 directory.
698
699 Note that the value for
700 .I mask
701 defaults to blank (equivalent to "*") and remains so until the
702 .B mask
703 command is used to change it. It retains the most recently specified value
704 indefinitely. To avoid unexpected results it would be wise to change the
705 value of
706 .I mask
707 back to "*" after using the
708 .B mget
709 or
710 .B mput
711 commands.
712 .RE
713 .RE
714
715 .B md
716 .RS 3
717 .B Parameters:
718 .RS 3
719 .I <directory name>
720
721 .RE
722 .B Description:
723 .RS 3
724 See the
725 .B mkdir
726 command.
727 .RE
728 .RE
729
730 .B mget
731 .RS 3
732 .B Parameters:
733 .RS 3
734 .I <mask>
735
736 .RE
737 .B Description:
738 .RS 3
739 Copy all files matching
740 .I mask
741 from the server to the machine running the client.
742
743 Note that
744 .I mask
745 is interpreted differently during recursive operation and non-recursive
746 operation - refer to the
747 .B recurse
748 and
749 .B mask
750 commands for more information. Note that all transfers in smbclient are 
751 binary. See also the
752 .B lowercase
753 command.
754 .RE
755 .RE
756
757 .B mkdir
758 .RS 3
759 .B Parameters:
760 .RS 3
761 .I <directory name>
762
763 .RE
764 .B Description:
765 .RS 3
766 Create a new directory 
767 .B on the server
768 (user access privileges permitting) with the specified name.
769 .RE
770 .RE
771
772 .B mput
773 .RS 3
774 .B Parameters:
775 .RS 3
776 .I <mask>
777
778 .RE
779 .B Description:
780 .RS 3
781 Copy all files matching
782 .I mask
783 in the current working directory
784 .B on the local machine
785 to the current working directory on the server.
786
787 Note that
788 .I mask
789 is interpreted differently during recursive operation and non-recursive
790 operation - refer to the
791 .B recurse
792 and
793 .B mask
794 commands for more information. Note that all transfers in smbclient are 
795 binary.
796 .RE
797 .RE
798
799 .B print
800 .RS 3
801 .B Parameters:
802 .RS 3
803 .I <file name>
804
805 .RE
806 .B Description:
807 .RS 3
808 Print the specified file
809 .B from the local machine
810 through a printable service on the server.
811
812 See also the
813 .B printmode
814 command.
815 .RE
816 .RE
817
818 .B printmode
819 .RS 3
820 .B Parameters:
821 .RS 3
822 .I <graphics or text>
823
824 .RE
825 .B Description:
826 .RS 3
827 Set the print mode to suit either binary data (such as graphical information)
828 or text. Subsequent
829 .B print
830 commands will use the currently set print mode.
831 .RE
832 .RE
833
834 .B prompt
835 .RS 3
836 .B Parameters:
837 .RS 3
838 None.
839
840 .RE
841 .B Description:
842 .RS 3
843 Toggle prompting for filenames during operation of the
844 .B mget
845 and
846 .B mput
847 commands.
848
849 When toggled ON, the user will be prompted to confirm the transfer of each
850 file during these commands. When toggled OFF, all specified files will be
851 transferred without prompting.
852 .RE
853 .RE
854
855 .B put
856 .RS 3
857 .B Parameters:
858 .RS 3
859 .I <local file name> [remote file name]
860
861 .RE
862 .B Description:
863 .RS 3
864 Copy the file called
865 .I local file name
866 from the machine running the client to the server. If specified, name the
867 remote copy
868 .I remote file name.
869 Note that all transfers in smbclient are binary. See also the
870 .B lowercase
871 command.
872 .RE
873 .RE
874
875 .B queue
876 .RS 3
877 .B Parameters:
878 .RS 3
879 None.
880
881 .RE
882 .B Description:
883 .RS 3
884 Displays the print queue, showing the job id, name, size and current status.
885 .RE
886 .RE
887
888 .B quit
889 .RS 3
890 .B Parameters:
891 .RS 3
892 None.
893
894 .RE
895 .B Description:
896 .RS 3
897 See the
898 .B exit
899 command.
900 .RE
901 .RE
902
903 .B rd
904 .RS 3
905 .B Parameters:
906 .RS 3
907 .I <directory name>
908
909 .RE
910 .B Description:
911 .RS 3
912 See the
913 .B rmdir
914 command.
915 .RE
916 .RE
917
918 .B recurse
919 .RS 3
920 .B Parameters:
921 .RS 3
922 None.
923
924 .RE
925 .B Description:
926 .RS 3
927 Toggle directory recursion for the commands
928 .B mget
929 and
930 .B mput
931 .
932
933 When toggled ON, these commands will process all directories in the source
934 directory (ie., the directory they are copying
935 .I from
936 ) and will recurse into any that match the mask specified to the command. Only
937 files that match the mask specified using the
938 .B mask
939 command will be retrieved. See also the
940 .mask
941 command.
942
943 When recursion is toggled OFF, only files from the current working
944 directory on the source machine that match the mask specified to the
945 .B mget
946 or
947 .B mput
948 commands will be copied, and any mask specified using the
949 .B mask
950 command will be ignored.
951 .RE
952 .RE
953
954 .B rm
955 .RS 3
956 .B Parameters:
957 .RS 3
958 .I <mask>
959
960 .RE
961 .B Description:
962 .RS 3
963 Remove all files matching
964 .I mask
965 from the current working directory
966 .B on the server.
967 .RE
968 .RE
969
970 .B rmdir
971 .RS 3
972 .B Parameters:
973 .RS 3
974 .I <directory name>
975
976 .RE
977 .B Description:
978 .RS 3
979 Remove the specified directory (user access privileges permitting)
980 .B from the server.
981 .RE
982 .RE
983
984 .B tar
985 .RS 3
986 .B Parameters:
987 .RS 3
988 .I <c|x>[IXbgNa]
989
990 .RE
991 .B Description:
992 .RS 3
993 Performs a tar operation - see -T command line option above. Behaviour
994 may be affected by the
995 .B tarmode
996 command (see below). Using the g (incremental) and N (newer) will affect
997 tarmode settings. Note that using the "-" option with tar x may not
998 work - use the command line option instead.
999 .RE
1000 .RE
1001
1002 .B blocksize
1003 .RS 3
1004 .B Parameters
1005 .RS 3
1006 .I <blocksize>
1007
1008 .RE
1009 .B Description
1010 .RS 3
1011 Blocksize. Must be followed by a valid (greater than zero) blocksize.
1012 Causes tar file to be written out in blocksize*TBLOCK (usually 512 byte)
1013 blocks.
1014 .RE
1015 .RE
1016
1017 .B tarmode
1018 .RS 3
1019 .B Parameters
1020 .RS 3
1021 .I <full|inc|reset|noreset>
1022
1023 .RE
1024 .B Description
1025 .RS 3
1026 Changes tar's behaviour with regard to archive bits. In full mode,
1027 tar will back up everything regardless of the archive bit setting (this
1028 is the default mode). In incremental mode, tar will only back up files
1029 with the archive bit set. In reset mode, tar will reset the archive bit
1030 on all files it backs up (implies read/write share).
1031 .RE
1032 .RE
1033
1034 .B setmode
1035 .RS 3
1036 .B Parameters
1037 .RS 3
1038 .I <filename> <perm=[+|-]rsha>
1039
1040 .RE
1041 .B Description
1042 .RS 3
1043 A version of the DOS attrib command to set file permissions. For example,
1044
1045 setmode myfile +r
1046
1047 would make myfile read only.
1048 .RE
1049 .RE
1050
1051 .SH NOTES
1052 Some servers are fussy about the case of supplied usernames, passwords, share
1053 names (aka service names) and machine names. If you fail to connect try
1054 giving all parameters in uppercase.
1055
1056 It is often necessary to use the
1057 .B -n
1058 option when connecting to some types
1059 of servers. For example OS/2 LanManager insists on a valid netbios name
1060 being used, so you need to supply a valid name that would be known to
1061 the server.
1062
1063 .B smbclient
1064 supports long file names where the server supports the LANMAN2
1065 protocol.
1066
1067 .SH FILES
1068 Not applicable.
1069
1070 .SH ENVIRONMENT VARIABLES
1071 .B USER
1072 .RS 3
1073 The variable USER may contain the username of the person using the client.
1074 This information is used only if the protocol level is high enough to support
1075 session-level passwords.
1076 .RE
1077
1078 .SH INSTALLATION
1079 The location of the client program is a matter for individual system 
1080 administrators. The following are thus suggestions only.
1081
1082 It is recommended that the client software be installed under the /usr/local
1083 hierarchy, in a directory readable by all, writeable only by root. The client
1084 program itself should be executable by all. The client should NOT be setuid 
1085 or setgid!
1086
1087 The client log files should be put in a directory readable and writable only
1088 by the user.
1089
1090 To test the client, you will need to know the name of a running Lan manager
1091 server. It is possible to run the smbd (see
1092 .B smbd(8)) as an ordinary user - running that server as a daemon on a
1093 user-accessible port (typically any port number over 1024) would
1094 provide a suitable test server.
1095 .SH VERSION
1096 This man page is (mostly) correct for version 1.9.00 of the Samba suite, plus some
1097 of the recent patches to it. These notes will necessarily lag behind 
1098 development of the client software, so it is possible that your version of 
1099 the client has extensions or parameter semantics that differ from or are not 
1100 covered by this man page. Please notify these to the address below for 
1101 rectification.
1102 .SH SEE ALSO
1103 .B smbd(8)
1104
1105 .SH DIAGNOSTICS
1106 [This section under construction]
1107
1108 Most diagnostics issued by the client are logged in a specified log file. The
1109 log file name is specified at compile time, but may be overridden on the
1110 command line.
1111
1112 The number and nature of diagnostics available depends on the debug level used
1113 by the client. If you have problems, set the debug level to 3 and peruse the
1114 log files.
1115
1116 Most messages are reasonably self-explanatory. Unfortunately, at time of
1117 creation of this man page the source code is still too fluid to warrant
1118 describing each and every diagnostic. At this stage your best bet is still
1119 to grep the source code and inspect the conditions that gave rise to the 
1120 diagnostics you are seeing.
1121
1122 .SH BUGS
1123 None known.
1124 .SH CREDITS
1125 The original Samba software and related utilities were created by 
1126 Andrew Tridgell (samba-bugs@anu.edu.au). Andrew is also the Keeper
1127 of the Source for this project.
1128
1129 This man page written by Karl Auer (Karl.Auer@anu.edu.au)
1130
1131 See
1132 .B smb.conf(5) for a full list of contributors and details on how to 
1133 submit bug reports, comments etc.