1 <?xml version="1.0" encoding="iso-8859-1"?>
2 <!DOCTYPE refentry PUBLIC "-//Samba-Team//DTD DocBook V4.2-Based Variant V1.0//EN" "http://www.samba.org/samba/DTD/samba-doc">
3 <refentry id="smbsh.1">
6 <refentrytitle>smbsh</refentrytitle>
7 <manvolnum>1</manvolnum>
8 <refmiscinfo class="source">Samba</refmiscinfo>
9 <refmiscinfo class="manual">User Commands</refmiscinfo>
10 <refmiscinfo class="version">3.2</refmiscinfo>
15 <refname>smbsh</refname>
16 <refpurpose>Allows access to remote SMB shares
17 using UNIX commands</refpurpose>
22 <command>smbsh</command>
23 <arg choice="opt">-W workgroup</arg>
24 <arg choice="opt">-U username</arg>
25 <arg choice="opt">-P prefix</arg>
26 <arg choice="opt">-R <name resolve order></arg>
27 <arg choice="opt">-d <debug level></arg>
28 <arg choice="opt">-l logdir</arg>
29 <arg choice="opt">-L libdir</arg>
34 <title>DESCRIPTION</title>
36 <para>This tool is part of the <citerefentry><refentrytitle>samba</refentrytitle>
37 <manvolnum>7</manvolnum></citerefentry> suite.</para>
39 <para><command>smbsh</command> allows you to access an NT filesystem
40 using UNIX commands such as <command>ls</command>, <command>
41 egrep</command>, and <command>rcp</command>. You must use a
42 shell that is dynamically linked in order for <command>smbsh</command>
43 to work correctly.</para>
47 <title>OPTIONS</title>
51 <term>-W WORKGROUP</term>
52 <listitem><para>Override the default workgroup specified in the
53 workgroup parameter of the <citerefentry><refentrytitle>smb.conf</refentrytitle>
54 <manvolnum>5</manvolnum></citerefentry> file
55 for this session. This may be needed to connect to some
56 servers. </para></listitem>
60 <term>-U username[%pass]</term>
61 <listitem><para>Sets the SMB username or username and password.
62 If this option is not specified, the user will be prompted for
63 both the username and the password. If %pass is not specified,
64 the user will be prompted for the password.
69 <term>-P prefix</term>
70 <listitem><para>This option allows
71 the user to set the directory prefix for SMB access. The
72 default value if this option is not specified is
73 <emphasis>smb</emphasis>.
79 &stdarg.resolve.order;
82 <term>-L libdir</term>
83 <listitem><para>This parameter specifies the location of the
84 shared libraries used by <command>smbsh</command>. The default
85 value is specified at compile time.
93 <title>EXAMPLES</title>
95 <para>To use the <command>smbsh</command> command, execute <command>
96 smbsh</command> from the prompt and enter the username and password
97 that authenticates you to the machine running the Windows NT
100 <prompt>system% </prompt><userinput>smbsh</userinput>
101 <prompt>Username: </prompt><userinput>user</userinput>
102 <prompt>Password: </prompt><userinput>XXXXXXX</userinput>
103 </programlisting></para>
106 <para>Any dynamically linked command you execute from
107 this shell will access the <filename>/smb</filename> directory
108 using the smb protocol. For example, the command <command>ls /smb
109 </command> will show a list of workgroups. The command
110 <command>ls /smb/MYGROUP </command> will show all the machines in
111 the workgroup MYGROUP. The command
112 <command>ls /smb/MYGROUP/<machine-name></command> will show the share
113 names for that machine. You could then, for example, use the <command>
114 cd</command> command to change directories, <command>vi</command> to
115 edit files, and <command>rcp</command> to copy files.</para>
119 <title>VERSION</title>
121 <para>This man page is correct for version 3 of the Samba suite.</para>
127 <para><command>smbsh</command> works by intercepting the standard
128 libc calls with the dynamically loaded versions in <filename>
129 smbwrapper.o</filename>. Not all calls have been "wrapped", so
130 some programs may not function correctly under <command>smbsh
133 <para>Programs which are not dynamically linked cannot make
134 use of <command>smbsh</command>'s functionality. Most versions
135 of UNIX have a <command>file</command> command that will
136 describe how a program was linked.</para>
141 <title>SEE ALSO</title>
142 <para><citerefentry><refentrytitle>smbd</refentrytitle>
143 <manvolnum>8</manvolnum></citerefentry>, <citerefentry><refentrytitle>smb.conf</refentrytitle>
144 <manvolnum>5</manvolnum></citerefentry></para>
148 <title>AUTHOR</title>
150 <para>The original Samba software and related utilities
151 were created by Andrew Tridgell. Samba is now developed
152 by the Samba Team as an Open Source project similar
153 to the way the Linux kernel is developed.</para>
155 <para>The original Samba man pages were written by Karl Auer.
156 The man page sources were converted to YODL format (another
157 excellent piece of Open Source software, available at <ulink url="ftp://ftp.icce.rug.nl/pub/unix/">
158 ftp://ftp.icce.rug.nl/pub/unix/</ulink>) and updated for the Samba 2.0
159 release by Jeremy Allison. The conversion to DocBook for
160 Samba 2.2 was done by Gerald Carter. The conversion to DocBook XML 4.2
161 for Samba 3.0 was done by Alexander Bokovoy.</para>