Sponsored Content
Top Forums Shell Programming and Scripting [smbtar] Backup more shares in one command Post 68030 by mbarberis on Wednesday 30th of March 2005 09:14:30 AM
Old 03-30-2005
[smbtar] Backup more shares in one command

Hi, is it possible backup more pc share run only one smbtar (like the exclusion)?
This works
Code:
smbtar -v -s pc13 -u usr -p pc13 -x test_share -t - -X test_nobackup | gzip -c > steapc13.tar.gz

also that
Code:
smbtar -v -s pc13 -u usr -p pc13 -x test_share -t - -X test_nobackup test2_nobackup | gzip -c > steapc13.tar.gz

.. This doesn't works
Code:
smbtar -v -s pc13 -u usr -p pc13 -x test_share test2_share -t - -X test_nobackup test2_nobackup | gzip -c > steapc13.tar.gz

In the first section the man says [ -x services ] but in the option description
Quote:
-x service
The share name on the server to connect to. The default
is "backup".
. Thanks Smilie
 

10 More Discussions You Might Find Interesting

1. IP Networking

Mounting shares from a Windows PC

Hi... I can ping my Windows PC using both the IP address and NetBios name and I can ping my Linux box the same, IP address and NetBios name. I can even use smbclient to see the shares on my Windows PC. But I can't map the shares so that Linux sees it as a drive. How do I do that? (5 Replies)
Discussion started by: SeCBerm
5 Replies

2. SCO

Using NFS shares from RMCobol

I have set up a directory on a PC using smb and can access the directory using all normal unix commands. I want to be able to access files in the directory from RMCobol programs but get system error 46 which appears to be "no record locks available". Does anybody know what I need to do to... (3 Replies)
Discussion started by: rongrout
3 Replies

3. UNIX for Advanced & Expert Users

File Server Pc Shares

Hi Everybody, I just want to know if anyone can help me to increase disk space for my users shared folder... it running out of free space... Any command that i can use or any otherway to prevent losing disk space from each folder? Please help... Thank you. (2 Replies)
Discussion started by: bvillante
2 Replies

4. Shell Programming and Scripting

extraction of samba shares with sed

Hi there, My samba configuration file looks like that : ... ... path = /home/samba/profiles/ ... path = /home/samba/shares/family valid users = family path = /home/samba/shares/admins valid users = admins path = /home/samba/shares/publicI want to extract the list of standard... (3 Replies)
Discussion started by: chebarbudo
3 Replies

5. Red Hat

NFS Shares

Hi, Is there any command in linux to check the remote NFS shares from client machine just like we have dfshares in solaris. Thanks, Trimurtulu (1 Reply)
Discussion started by: ktrimu
1 Replies

6. UNIX for Dummies Questions & Answers

Samba - Creating shares

So I have Samba installed on my server and I have to create two shares. Make a backup of your smb.conf - call it smb.conf.orig. Create a share called shared that allows read and write permissions for everyone and points to /media/shared. Create another share called www that points to the... (1 Reply)
Discussion started by: shadowcat
1 Replies

7. UNIX for Dummies Questions & Answers

Help mounting Samba shares

I have these two shares on my Ubuntu Server: path = /media/share read only = no guest ok = yes path = /var/www read only = noI want to mount them to the directories that I created on my Desktop called "shared" and "www" how do I do this? I ran the command: smbclient -L... (1 Reply)
Discussion started by: shadowcat
1 Replies

8. Shell Programming and Scripting

rsync backup mode(--backup) Are there any options to remove backup folders on successful deployment?

Hi Everyone, we are running rsync with --backup mode, Are there any rsync options to remove backup folders on successful deployment? Thanks in adv. (0 Replies)
Discussion started by: MVEERA
0 Replies

9. Red Hat

Help with NFS shares

Hi, I have got nfs shares that were shared from storage (Netapp) to linux servers (RHEL 4) that were on automount. All the share were visible and mounted on the linux serves eventhough they were on auto mount. But recently one of the server was rebooted and mount points were disappeard and... (5 Replies)
Discussion started by: phanidhar6039
5 Replies

10. UNIX for Advanced & Expert Users

File shares in UNIX

a) what are the different ways to share files ? b) How can I get list of file shares on Unix box in my company? c) How can I get list of files and their content present on all the Unix File shares? (1 Reply)
Discussion started by: vipintanwar
1 Replies
SMBTAR(1)																 SMBTAR(1)

NAME
smbtar - shell script for backing up SMB/CIFS shares directly to UNIX tape drives SYNOPSIS
smbtar [-r] [-i] [-a] [-v] {-sserver} [-ppassword] [-xservices] [-X] [-Nfilename] [-bblocksize] [-ddirectory] [-lloglevel] [-uuser] [-ttape] {filenames} DESCRIPTION
This tool is part of the samba(7) suite. smbtar is a very small shell script on top of smbclient(1) which dumps SMB shares directly to tape. OPTIONS
-s server The SMB/CIFS server that the share resides upon. -x service The share name on the server to connect to. The default is "backup". -X Exclude mode. Exclude filenames... from tar create or restore. -d directory Change to initial directory before restoring / backing up files. -v Verbose mode. -p password The password to use to access a share. Default: none -u user The user id to connect as. Default: UNIX login name. -a Reset DOS archive bit mode to indicate file has been archived. -t tape Tape device. May be regular file or tape device. Default: $TAPE environmental variable; if not set, a file called tar.out . -b blocksize Blocking factor. Defaults to 20. See tar(1) for a fuller explanation. -N filename Backup only files newer than filename. Could be used (for example) on a log file to implement incremental backups. -i Incremental mode; tar files are only backed up if they have the archive bit set. The archive bit is reset after each file is read. -r Restore. Files are restored to the share from the tar file. -l log level Log (debug) level. Corresponds to the -d flag of smbclient(1). ENVIRONMENT VARIABLES
The $TAPE variable specifies the default tape device to write to. May be overridden with the -t option. BUGS
The smbtar script has different options from ordinary tar and from smbclient's tar command. CAVEATS
Sites that are more careful about security may not like the way the script handles PC passwords. Backup and restore work on entire shares; should work on file lists. smbtar works best with GNU tar and may not work well with other versions. DIAGNOSTICS
See the DIAGNOSTICS section for the smbclient(1) command. VERSION
This man page is correct for version 3.0 of the Samba suite. SEE ALSO
smbd(8), smbclient(1), smb.conf(5). AUTHOR
The original Samba software and related utilities were created by Andrew Tridgell. Samba is now developed by the Samba Team as an Open Source project similar to the way the Linux kernel is developed. Ricky Poulten wrote the tar extension and this man page. The smbtar script was heavily rewritten and improved by Martin Kraemer. Many thanks to everyone who suggested extensions, improvements, bug fixes, etc. The man page sources were converted to YODL format (another excellent piece of Open Source software, available at ftp://ftp.icce.rug.nl/pub/unix/) and updated for the Samba 2.0 release by Jeremy Allison. The conversion to DocBook for Samba 2.2 was done by Gerald Carter. The conversion to DocBook XML 4.2 for Samba 3.0 was done by Alexander Bokovoy. SMBTAR(1)
All times are GMT -4. The time now is 06:35 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy