Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > Plugins/Modules/Addons

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #91  
Old 11th February 2011, 10:39
go0ogl3 go0ogl3 is offline
Member
 
Join Date: Jul 2008
Posts: 73
Thanks: 5
Thanked 39 Times in 6 Posts
Default

Quote:
Originally Posted by smurf64 View Post
My output after run scrip is:

Code:
root@terserver:/home/badmin# ./back-res
mysql.general_log
note     : The storage engine for the table doesn't support optimize
mysql.slow_log
note     : The storage engine for the table doesn't support optimize
/bin/tar: /var/log/syslog: file changed as we read it
/bin/tar: /var/log/auth.log: file changed as we read it
/bin/tar: /var/log/messages: file changed as we read it
/bin/tar: /var/lib/apache2/fcgid/sock/32697.0: socket ignored
root@terserver:/home/badmin#
It is O.K.?
Short answer: Yes.
The mysql you have it's using newer type of storage engine wich does not support optimize.
The syslog daemon usually keeps writing if it's not stopped. Don't worry you will have the missing lines in the next daily backup if you need them. Same with apache.

Don't forget to setup a cron job daily...
Reply With Quote
Sponsored Links
  #92  
Old 25th February 2011, 19:51
clttech clttech is offline
Junior Member
 
Join Date: Mar 2009
Posts: 15
Thanks: 1
Thanked 0 Times in 0 Posts
Default Restore Question

I am new to Linux so I have a question about the backup-res restore. I created a dir /bck. This is where I have the backup-res put my backup files. It then creates a folder that is my domain name me.mydomain.tld. Inside that folder it creates the following
2011-02
2011-01
log
full_var_lib_mysql-2011-02-01.tar.bz2
full_var_vmail-2011-02-01.tar.bz2
full_etc-2011-02-01.tar.bz2
full_var_www-2011-02-01.tar.bz2
full_var_lib_mysql-2010-11-03.tar.bz2
when I run the ./backup-res dir all 2011-02-01 / this is what I get
-su: ./backup-res: No such file or directory
What am I missing here. I have the backup-res in the /etc folder
I am running Ununtu 10.04.01 LTS
Reply With Quote
  #93  
Old 27th February 2011, 17:56
go0ogl3 go0ogl3 is offline
Member
 
Join Date: Jul 2008
Posts: 73
Thanks: 5
Thanked 39 Times in 6 Posts
Lightbulb

Quote:
Originally Posted by clttech View Post
I am new to Linux so I have a question about the backup-res restore. I created a dir /bck. This is where I have the backup-res put my backup files. It then creates a folder that is my domain name me.mydomain.tld. Inside that folder it creates the following
2011-02
2011-01
log
full_var_lib_mysql-2011-02-01.tar.bz2
full_var_vmail-2011-02-01.tar.bz2
full_etc-2011-02-01.tar.bz2
full_var_www-2011-02-01.tar.bz2
full_var_lib_mysql-2010-11-03.tar.bz2
when I run the ./backup-res dir all 2011-02-01 / this is what I get
-su: ./backup-res: No such file or directory
What am I missing here. I have the backup-res in the /etc folder
I am running Ununtu 10.04.01 LTS

If you have the script in /etc then it will only work when you'll run it from there. So you'll have to 'cd /etc' first or run '/etc/back-res ...........'
Please read the info from the header of the script. I've tried to explain everything there. Then modify the variables as you like.
Reply With Quote
  #94  
Old 7th March 2011, 21:33
Florisjan Florisjan is offline
Junior Member
 
Join Date: Oct 2009
Posts: 14
Thanks: 5
Thanked 0 Times in 0 Posts
Default Restore backup on different server

Hi

I've managed to copy the backup files to a new server using scp. After processing all the sql dumps I untarred the /var/www and /var/vmail directories. However, the user names are obviously missing on the new server, so the owners of the files are now all set to root (except for a few files, of which the owner does exist.)

Am I missing something, or if not, is there a way to solve this, for instance by copying the entire user 'database' from one server to the other?

I feel I am very close to making a running backup server, but can't figure this out.

Thanks a lot!
Reply With Quote
  #95  
Old 25th March 2011, 09:35
go0ogl3 go0ogl3 is offline
Member
 
Join Date: Jul 2008
Posts: 73
Thanks: 5
Thanked 39 Times in 6 Posts
Lightbulb Restore the users, groups and permissions

Hello, I'm sorry to respond so late, but if you've have the backup of /etc restore that first (so you can have the user and groups from the old server) then restore the rest. This way you can preserve de file owner and permissions.

The other way is to instal the same linux version onto a new drive, then restore the backup on top of the new machine. So you can have a full working state of the backed up machine at your chosen date.

Hope this helps others too.

Quote:
Originally Posted by Florisjan View Post
Hi

I've managed to copy the backup files to a new server using scp. After processing all the sql dumps I untarred the /var/www and /var/vmail directories. However, the user names are obviously missing on the new server, so the owners of the files are now all set to root (except for a few files, of which the owner does exist.)

Am I missing something, or if not, is there a way to solve this, for instance by copying the entire user 'database' from one server to the other?

I feel I am very close to making a running backup server, but can't figure this out.

Thanks a lot!
Reply With Quote
  #96  
Old 4th April 2011, 00:16
neutrino neutrino is offline
Member
 
Join Date: Oct 2008
Posts: 61
Thanks: 13
Thanked 9 Times in 8 Posts
Default

Hey folks,

I'm saving my server for some month with this great script an now I need to backup a folder.


What I launched as command was the following :

Code:
www:~/bin# ./backup.sh dir /var/www/clients/client0/web3/web 2011-04-01 /var/www/clients/client0/web3/web
Then I obtained this :

Code:
You want to restore dir /var/www/clients/client0/web3/web to date 2011-04-01.

Please input "yes" if the above is ok with you and press [ENTER]: yes
touch: cannot touch `/tmp/tmpbck/datestart': No such file or directory
touch: cannot touch `/tmp/tmpbck/dateend': No such file or directory

---------------------=== The back-res script by go0ogl3 ===---------------------

The backup part requires some configuration in the header of the script
and it's supposed to be run from cron.
The restore part it's supposed to be run from command line.
restore part Usage:
         backup.sh [type-of-restore] [dir|db] [YYYY-MM-DD] [path]

         backup.sh dir [dir-to-restore] [to-date] [path]
         backup.sh dir all [to-date] [path]
         backup.sh db [db-to-restore] [to-date]
         backup.sh db all [to-date]

Where 'dir' or 'db' to restore is one of the configured dirs or db's to
backup, or 'all' to restore all dirs or db's.
Date format is full date, year sorted, YYYY-MM-DD, like 2009-01-30.
'path' is for dirs and is the path on which you want to extract the backup.
If the path to extract is not set, then the backup is extracted on /.
For more info read the header of this script!
-===--===--===--===--===--===--===--===--===--===--===--===--===--===--===--===-

                ###     Invalid directory to restore!   ###

./backup.sh: line 574: /tmp/tmpbck/maildata: No such file or directory
And line 574 contains this :

Code:
# Send accumulated maildata an cleanup
mail -s "Daily backup of $COMPUTER `date +'%F'`" "$email" < $tmpdir/maildata
So I think something is wrong with /tmp/tmpbck but since I do not know how this script exacly works I wanted to have some advice before trying some changes.

The script is in /root/bin and the data is in /bck

Thanks

Last edited by neutrino; 4th April 2011 at 00:18.
Reply With Quote
  #97  
Old 7th April 2011, 02:44
kostas1972 kostas1972 is offline
Junior Member
 
Join Date: Jan 2011
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi...

thanks for the script!

any one know what that -> binary operator expected ... means?


================
/etc/back-res: line 347: [: full_bin-2011-03-25.tar.bz2: binary operator expected
/etc/back-res: line 347: [: full_boot-2011-03-25.tar.bz2: binary operator expected
/etc/back-res: line 347: [: full_etc-2011-03-25.tar.bz2: binary operator expected
/etc/back-res: line 347: [: full_home-2011-03-25.tar.bz2: binary operator expected
=====================

is this a kind of problem ?

thanks!
Reply With Quote
  #98  
Old 12th April 2011, 14:16
clttech clttech is offline
Junior Member
 
Join Date: Mar 2009
Posts: 15
Thanks: 1
Thanked 0 Times in 0 Posts
Default

Thanks for such a great script.

I am having a very similar problem.

You want to restore dir all to date 2011-04-01.

Please input "yes" if the above is ok with you and press [ENTER]: yes

Extracting all dir's backup from date 2011-04-01 to /:
touch: cannot touch `/tmp/tmpbck/datestart': No such file or directory
touch: cannot touch `/tmp/tmpbck/dateend': No such file or directory
find: `/tmp/tmpbck/datestart': No such file or directory
find: `/tmp/tmpbck/datestart': No such file or directory
find: `/tmp/tmpbck/dateend': No such file or directory


---------------------=== The back-res script by go0ogl3 ===---------------------

For a clean backup restored at 2011-04-01 we need now to delete the files
created after the backup date.
If exists, a list of files to be deleted follows:


Please input "yes" to delete those files, if they exist, and press [ENTER]:
/bck/c3po.clttechnologies.com/./backup-res: line 572: /tmp/tmpbck/maildata: No such file or directory


Line 572 is
mail -s "Daily backup of $COMPUTER `date +'%F'`" "$email" < $tmpdir/maildata
Reply With Quote
  #99  
Old 13th April 2011, 11:40
go0ogl3 go0ogl3 is offline
Member
 
Join Date: Jul 2008
Posts: 73
Thanks: 5
Thanked 39 Times in 6 Posts
Lightbulb Temp dir for the script...

It seems that you don't have a /tmp directory, or the script does NOT have access to write to /tmp. The script is creating the /tmp/tmpbck dir and keeps there all the files it needs to run.
Please check that you have the /tmp dir and if you do please check that is writable by the script (the user you run the script should be root).

The place where the script is located is not so important...

Hope this helps...

Quote:
Originally Posted by neutrino View Post
Hey folks,

I'm saving my server for some month with this great script an now I need to backup a folder.


What I launched as command was the following :

Code:
www:~/bin# ./backup.sh dir /var/www/clients/client0/web3/web 2011-04-01 /var/www/clients/client0/web3/web
Then I obtained this :

Code:
You want to restore dir /var/www/clients/client0/web3/web to date 2011-04-01.

Please input "yes" if the above is ok with you and press [ENTER]: yes
touch: cannot touch `/tmp/tmpbck/datestart': No such file or directory
touch: cannot touch `/tmp/tmpbck/dateend': No such file or directory

---------------------=== The back-res script by go0ogl3 ===---------------------

The backup part requires some configuration in the header of the script
and it's supposed to be run from cron.
The restore part it's supposed to be run from command line.
restore part Usage:
         backup.sh [type-of-restore] [dir|db] [YYYY-MM-DD] [path]

         backup.sh dir [dir-to-restore] [to-date] [path]
         backup.sh dir all [to-date] [path]
         backup.sh db [db-to-restore] [to-date]
         backup.sh db all [to-date]

Where 'dir' or 'db' to restore is one of the configured dirs or db's to
backup, or 'all' to restore all dirs or db's.
Date format is full date, year sorted, YYYY-MM-DD, like 2009-01-30.
'path' is for dirs and is the path on which you want to extract the backup.
If the path to extract is not set, then the backup is extracted on /.
For more info read the header of this script!
-===--===--===--===--===--===--===--===--===--===--===--===--===--===--===--===-

                ###     Invalid directory to restore!   ###

./backup.sh: line 574: /tmp/tmpbck/maildata: No such file or directory
And line 574 contains this :

Code:
# Send accumulated maildata an cleanup
mail -s "Daily backup of $COMPUTER `date +'%F'`" "$email" < $tmpdir/maildata
So I think something is wrong with /tmp/tmpbck but since I do not know how this script exacly works I wanted to have some advice before trying some changes.

The script is in /root/bin and the data is in /bck

Thanks
Reply With Quote
  #100  
Old 13th April 2011, 11:51
go0ogl3 go0ogl3 is offline
Member
 
Join Date: Jul 2008
Posts: 73
Thanks: 5
Thanked 39 Times in 6 Posts
 
Exclamation Strange error

Hello!

Do you have the latest version of the script? What is the 347 line of your script? What's the BACKUPDIR you set? It's empty?

In the 347 line of the script, as I know it, is not a test in any version of the script and that error is only if you test something...
If the 347 line is
Code:
if [ -z $fb ] ; then
and you have the BACKUPDIR set,
then please check if you have spaces in the backup path... or try to modify the line like:
Code:
if [ -z "$fb" ] ; then

Quote:
Originally Posted by kostas1972 View Post
Hi...

thanks for the script!

any one know what that -> binary operator expected ... means?


================
/etc/back-res: line 347: [: full_bin-2011-03-25.tar.bz2: binary operator expected
/etc/back-res: line 347: [: full_boot-2011-03-25.tar.bz2: binary operator expected
/etc/back-res: line 347: [: full_etc-2011-03-25.tar.bz2: binary operator expected
/etc/back-res: line 347: [: full_home-2011-03-25.tar.bz2: binary operator expected
=====================

is this a kind of problem ?

thanks!
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
freebsd 7, samba 3, domain controller alexdimarco Suggest HOWTO 6 5th November 2010 17:54
how to restore Ispconfig from backup db na0lb Installation/Configuration 4 24th September 2008 09:51
Restore backup ISPConfig leeeonardo General 4 18th April 2007 21:21
Restore ispconfig complete backup statiic General 1 15th January 2007 11:32
Backup restore on ispconfig misterm Installation/Configuration 0 19th December 2005 00:32


All times are GMT +2. The time now is 16:58.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.