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="smbtar.1">
6 <refentrytitle>smbtar</refentrytitle>
7 <manvolnum>1</manvolnum>
12 <refname>smbtar</refname>
13 <refpurpose>shell script for backing up SMB/CIFS shares
14 directly to UNIX tape drives</refpurpose>
19 <command>smbtar</command>
20 <arg choice="opt">-r</arg>
21 <arg choice="opt">-i</arg>
22 <arg choice="opt">-a</arg>
23 <arg choice="opt">-v</arg>
24 <arg choice="req">-s server</arg>
25 <arg choice="opt">-p password</arg>
26 <arg choice="opt">-x services</arg>
27 <arg choice="opt">-X</arg>
28 <arg choice="opt">-N filename</arg>
29 <arg choice="opt">-b blocksize</arg>
30 <arg choice="opt">-d directory</arg>
31 <arg choice="opt">-l loglevel</arg>
32 <arg choice="opt">-u user</arg>
33 <arg choice="opt">-t tape</arg>
34 <arg choice="req">filenames</arg>
39 <title>DESCRIPTION</title>
41 <para>This tool is part of the <citerefentry><refentrytitle>samba</refentrytitle>
42 <manvolnum>7</manvolnum></citerefentry> suite.</para>
44 <para><command>smbtar</command> is a very small shell script on top
45 of <citerefentry><refentrytitle>smbclient</refentrytitle><manvolnum>1</manvolnum>
46 </citerefentry> which dumps SMB shares directly to tape.</para>
50 <title>OPTIONS</title>
54 <term>-s server</term>
55 <listitem><para>The SMB/CIFS server that the share resides
56 upon.</para></listitem>
61 <term>-x service</term>
62 <listitem><para>The share name on the server to connect to.
63 The default is "backup".</para></listitem>
69 <listitem><para>Exclude mode. Exclude filenames... from tar
70 create or restore. </para></listitem>
76 <term>-d directory</term>
77 <listitem><para>Change to initial <parameter>directory
78 </parameter> before restoring / backing up files. </para></listitem>
85 <listitem><para>Verbose mode.</para></listitem>
91 <term>-p password</term>
92 <listitem><para>The password to use to access a share.
93 Default: none </para></listitem>
99 <listitem><para>The user id to connect as. Default:
100 UNIX login name. </para></listitem>
106 <listitem><para>Reset DOS archive bit mode to
107 indicate file has been archived. </para></listitem>
112 <listitem><para>Tape device. May be regular file or tape
113 device. Default: <parameter>$TAPE</parameter> environmental
114 variable; if not set, a file called <filename>tar.out
115 </filename>. </para></listitem>
120 <term>-b blocksize</term>
121 <listitem><para>Blocking factor. Defaults to 20. See
122 <command>tar(1)</command> for a fuller explanation. </para></listitem>
127 <term>-N filename</term>
128 <listitem><para>Backup only files newer than filename. Could
129 be used (for example) on a log file to implement incremental
130 backups. </para></listitem>
136 <listitem><para>Incremental mode; tar files are only backed
137 up if they have the archive bit set. The archive bit is reset
138 after each file is read. </para></listitem>
144 <listitem><para>Restore. Files are restored to the share
145 from the tar file. </para></listitem>
151 <term>-l log level</term>
152 <listitem><para>Log (debug) level. Corresponds to the
153 <parameter>-d</parameter> flag of <citerefentry>
154 <refentrytitle>smbclient</refentrytitle><manvolnum>1</manvolnum>
155 </citerefentry>.</para></listitem>
162 <title>ENVIRONMENT VARIABLES</title>
164 <para>The <parameter>$TAPE</parameter> variable specifies the
165 default tape device to write to. May be overridden
166 with the -t option. </para>
173 <para>The <command>smbtar</command> script has different
174 options from ordinary tar and from smbclient's tar command. </para>
179 <title>CAVEATS</title>
181 <para>Sites that are more careful about security may not like
182 the way the script handles PC passwords. Backup and restore work
183 on entire shares; should work on file lists. smbtar works best
184 with GNU tar and may not work well with other versions. </para>
189 <title>DIAGNOSTICS</title>
191 <para>See the <emphasis>DIAGNOSTICS</emphasis> section for the <citerefentry>
192 <refentrytitle>smbclient</refentrytitle><manvolnum>1</manvolnum>
193 </citerefentry> command.</para>
198 <title>VERSION</title>
200 <para>This man page is correct for version 3.0 of
201 the Samba suite.</para>
205 <title>SEE ALSO</title>
206 <para><citerefentry><refentrytitle>smbd</refentrytitle>
207 <manvolnum>8</manvolnum></citerefentry>, <citerefentry>
208 <refentrytitle>smbclient</refentrytitle><manvolnum>1</manvolnum>
209 </citerefentry>, <citerefentry><refentrytitle>smb.conf</refentrytitle>
210 <manvolnum>5</manvolnum></citerefentry>.</para>
214 <title>AUTHOR</title>
216 <para>The original Samba software and related utilities
217 were created by Andrew Tridgell. Samba is now developed
218 by the Samba Team as an Open Source project similar
219 to the way the Linux kernel is developed.</para>
221 <para><ulink noescape="1" url="mailto:poultenr@logica.co.uk">Ricky Poulten</ulink>
222 wrote the tar extension and this man page. The <command>smbtar</command>
223 script was heavily rewritten and improved by <ulink noescape="1"
224 url="mailto:Martin.Kraemer@mch.sni.de">Martin Kraemer</ulink>. Many
225 thanks to everyone who suggested extensions, improvements, bug
226 fixes, etc. The man page sources were converted to YODL format (another
227 excellent piece of Open Source software, available at <ulink noescape="1" url="ftp://ftp.icce.rug.nl/pub/unix/">
228 ftp://ftp.icce.rug.nl/pub/unix/</ulink>) and updated for the Samba 2.0
229 release by Jeremy Allison. The conversion to DocBook for
230 Samba 2.2 was done by Gerald Carter. The conversion to DocBook XML 4.2 for
231 Samba 3.0 was done by Alexander Bokovoy.</para>