Re: running backup



On Wed, May 31, 2006 at 13:56:39 +0800, Jon Miller wrote:
I have a file that I want to run daily to backup data. This tgz file then needs to be copied to a Windows 2003 server. I'm using smbclient, but it does not seem to work thru the script. Can someone point out where the problem lies. I run this as a cron job as follows:
30 19 * * 1,2,3,4,5 root /root/rubybackup.sh

The script is as follows:
#!/bin/sh
# script to automate the backup of the Ruby server to the W2K3 server
#
DAY=`date +'%a-%d-%m-%y'`
BACKUPDIR=/backup
RUBYLIVE=/var/lib/mysql/

cd $RUBYLIVE
tar -czvf /backup/rubylive${DAY}.tgz ./rubylive

cd $BACKUPDIR
smbclient //server/backup tfc651800 -U administrator
put rubylive${DAY}.tgz

The recommended procedure for smbclient in scripts is to use the -c
option for the command string. In your case that would probably be
something like

smbclient //server/backup tfc651800 -U administrator -c "put rubylive${DAY}.tgz; exit"

Is it really necessary to use the administrator account for pushing a
backup file to the server?

--
Regards,
Florian


--
To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx
with a subject of "unsubscribe". Trouble? Contact listmaster@xxxxxxxxxxxxxxxx



Relevant Pages

  • Re: SBS 2003 Backup Failures
    ... I have used a recovery storage group on the server but that was last year ... I have loaded the "Small Business Backup Script.bks" file but there is no ... The RSG will be added to the script. ...
    (microsoft.public.windows.server.sbs)
  • Re: Automatic shutdown
    ... backup server via xinetd. ... So the client has to wait until the server ... autofs script has no capability to wake up machines on request). ... The advantage of a little bit of scripting is that adding extra machines ...
    (alt.os.linux.suse)
  • Re: SBS 2003 Backup Failures
    ... If they are not in use, can you please remove it and retry the backup for a test? ... The RSG will be added to the script. ... NTbackup is not able to back it up either via the script or directly via the NTbackup GUI. ... run the Windows Small Business Server Backup Configuration Wizard from the Backup taskpad in Server Management and see if the issue still occurs. ...
    (microsoft.public.windows.server.sbs)
  • Re: Scripting removal of app mappings.
    ... >> I would like to script out removing certain application mappings from IIS. ... You cannot restore a metabase backup from one server to another. ...
    (microsoft.public.inetserver.iis.security)
  • Re: SMS 2003 - afterbackup.bat
    ... You could add some error handling to your vbscript and catch the error. ... from the other server. ... computer account of the server running the script to the share privileges on ... the server receiving the backup. ...
    (microsoft.public.sms.admin)