Solved

Simple Backup of a Linux folder to remote Windows File Server

Posted on 2007-03-27
3
649 Views
Last Modified: 2012-08-13
Hi,
I'm trying to backup a specific folder in Linux (Red Hat) and been trying to come up with very simple script to do so.  I'm mkdir a directory call 'backup'.  Then I tar the folder I want and have it dump to the folder call 'backup'.  After that, I cp the file to a Windows Network Share.  The problem is every time I run these command in a script format in bash, it chokes.  Just wondering what I'm doing wrong?
0
Comment
Question by:yackko
3 Comments
 
LVL 1

Expert Comment

by:midrisi
ID: 18799876
Can you send me the script? then I can check off.
0
 
LVL 4

Accepted Solution

by:
freaky_NL earned 125 total points
ID: 18807311
Would like to the script as well.

Why don't you write the tar straight to the fileserver btw?

Sort of like

tar -jcvpf /path/to/windows/share/backup.tbz2 /dir/to/backup

options:
j = bzip2 (either compress or uncompress)
c = compress
v = verbose (you should remove this in scripts i guess)
p = permissions (stores the file permissions)
f = to specify filename
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Many time we need to work with multiple files all together. If its windows system then we can use some GUI based editor to accomplish our task. But what if you are on putty or have only CLI(Command Line Interface) as an option to  edit your files. I…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now