1 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
5 <refentrytitle>smbtar</refentrytitle>
6 <manvolnum>1</manvolnum>
11 <refname>smbtar</refname>
12 <refpurpose>shell script for backing up SMB/CIFS shares
13 directly to UNIX tape drives</refpurpose>
18 <command>smbtar</command>
19 <arg choice="req">-s server</arg>
20 <arg choice="opt">-p password</arg>
21 <arg choice="opt">-x services</arg>
22 <arg choice="opt">-X</arg>
23 <arg choice="opt">-d directory</arg>
24 <arg choice="opt">-u user</arg>
25 <arg choice="opt">-t tape</arg>
26 <arg choice="opt">-t tape</arg>
27 <arg choice="opt">-b blocksize</arg>
28 <arg choice="opt">-N filename</arg>
29 <arg choice="opt">-i</arg>
30 <arg choice="opt">-r</arg>
31 <arg choice="opt">-l loglevel</arg>
32 <arg choice="opt">-v</arg>
33 <arg choice="req">filenames</arg>
38 <title>DESCRIPTION</title>
40 <para>This tool is part of the <ulink url="samba.7.html">
41 Samba</ulink> suite.</para>
43 <para><command>smbtar</command> is a very small shell script on top
44 of <ulink url="smbclient.1.html"><command>smbclient(1)</command></ulink>
45 which dumps SMB shares directly to tape. </para>
49 <title>OPTIONS</title>
53 <term>-s server</term>
54 <listitem><para>The SMB/CIFS server that the share resides
55 upon.</para></listitem>
60 <term>-x service</term>
61 <listitem><para>The share name on the server to connect to.
62 The default is "backup".</para></listitem>
68 <listitem><para>Exclude mode. Exclude filenames... from tar
69 create or restore. </para></listitem>
75 <term>-d directory</term>
76 <listitem><para>Change to initial <parameter>directory
77 </parameter> before restoring / backing up files. </para></listitem>
84 <listitem><para>Verbose mode.</para></listitem>
90 <term>-p password</term>
91 <listitem><para>The password to use to access a share.
92 Default: none </para></listitem>
98 <listitem><para>The user id to connect as. Default:
99 UNIX login name. </para></listitem>
106 <listitem><para>Tape device. May be regular file or tape
107 device. Default: <parameter>$TAPE</parameter> environmental
108 variable; if not set, a file called <filename>tar.out
109 </filename>. </para></listitem>
114 <term>-b blocksize</term>
115 <listitem><para>Blocking factor. Defaults to 20. See
116 <command>tar(1)</command> for a fuller explanation. </para></listitem>
121 <term>-N filename</term>
122 <listitem><para>Backup only files newer than filename. Could
123 be used (for example) on a log file to implement incremental
124 backups. </para></listitem>
130 <listitem><para>Incremental mode; tar files are only backed
131 up if they have the archive bit set. The archive bit is reset
132 after each file is read. </para></listitem>
138 <listitem><para>Restore. Files are restored to the share
139 from the tar file. </para></listitem>
145 <term>-l log level</term>
146 <listitem><para>Log (debug) level. Corresponds to the
147 <parameter>-d</parameter> flag of <command>smbclient(1)
148 </command>. </para></listitem>
155 <title>ENVIRONMENT VARIABLES</title>
157 <para>The <parameter>$TAPE</parameter> variable specifies the
158 default tape device to write to. May be overridden
159 with the -t option. </para>
166 <para>The <command>smbtar</command> script has different
167 options from ordinary tar and tar called from smbclient. </para>
172 <title>CAVEATS</title>
174 <para>Sites that are more careful about security may not like
175 the way the script handles PC passwords. Backup and restore work
176 on entire shares, should work on file lists. smbtar works best
177 with GNU tar and may not work well with other versions. </para>
182 <title>DIAGNOSTICS</title>
184 <para>See the <emphasis>DIAGNOSTICS</emphasis> section for the
185 <ulink url="smbclient.1.html"><command>smbclient(1)</command>
186 </ulink> command.</para>
191 <title>VERSION</title>
193 <para>This man page is correct for version 2.2 of
194 the Samba suite.</para>
198 <title>SEE ALSO</title>
199 <para><ulink url="smbd.8.html"><command>smbd(8)</command></ulink>,
200 <ulink url="smbclient.1.html"><command>smbclient(1)</command></ulink>,
201 <ulink url="smb.conf.5.html">smb.conf(5)</ulink>,
206 <title>AUTHOR</title>
208 <para>The original Samba software and related utilities
209 were created by Andrew Tridgell. Samba is now developed
210 by the Samba Team as an Open Source project similar
211 to the way the Linux kernel is developed.</para>
213 <para><ulink url="mailto:poultenr@logica.co.uk">Ricky Poulten</ulink>
214 wrote the tar extension and this man page. The <command>smbtar</command>
215 script was heavily rewritten and improved by <ulink
216 url="mailto:Martin.Kraemer@mch.sni.de">Martin Kraemer</ulink>. Many
217 thanks to everyone who suggested extensions, improvements, bug
218 fixes, etc. The man page sources were converted to YODL format (another
219 excellent piece of Open Source software, available at
220 <ulink url="ftp://ftp.icce.rug.nl/pub/unix/">
221 ftp://ftp.icce.rug.nl/pub/unix/</ulink>) and updated for the Samba 2.0
222 release by Jeremy Allison. The conversion to DocBook for
223 Samba 2.2 was done by Gerald Carter.</para>