Home > Archive > MySQL ODBC Connector > February 2006 > mysqlhotcopy









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author mysqlhotcopy
Peter

2006-02-25, 9:43 am

Hello,

I read the manual(http://dev.mysql.com/doc/refman/5.0...sqlhotcopy.html)
and especially:

" Back up tables in the given database that match a regular expression:

shell> mysqlhotcopy db_name./regex/

The regular expression for the table name can be negated by prefixing it
with a tilde (‘~’):

shell> mysqlhotcopy db_name./~regex/
"

I want to backup all my tables except two -'rtt' and 'expirations'.

I use
/usr/local/bin/mysqlhotcopy -p mypass --allowold
mydb./~expirations/~rtt/ /var/backups/mysqlbackup/$1


However for some reason mysqlhotcopy do NOT skip tables 'rtt' and
'expirations'.

Please give me an idea what is wrong. Thanks :-))

Kind regards,

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw

Peter

2006-02-25, 9:43 am

solved :)

Thanks :-)

Peter wrote:
> Hello,
>
> I read the manual(http://dev.mysql.com/doc/refman/5.0...sqlhotcopy.html)
> and especially:
>
> " Back up tables in the given database that match a regular expression:
>
> shell> mysqlhotcopy db_name./regex/
>
> The regular expression for the table name can be negated by prefixing it
> with a tilde (‘~’):
>
> shell> mysqlhotcopy db_name./~regex/
> "
>
> I want to backup all my tables except two -'rtt' and 'expirations'.
>
> I use
> /usr/local/bin/mysqlhotcopy -p mypass --allowold
> mydb./~expirations/~rtt/ /var/backups/mysqlbackup/$1
>
>
> However for some reason mysqlhotcopy do NOT skip tables 'rtt' and
> 'expirations'.
>
> Please give me an idea what is wrong. Thanks :-))
>
> Kind regards,
>


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw

Imran Chaudhry

2006-02-25, 9:43 am

Good stuff Peter, can you tell us your solution so folks can benefit
from your efforts?

(I expect the regex has to be POSIX style such as:
mydb./ '~(expirations|rtt)'
/ right?)

Imran Chaudhry

--
http://www.ImranChaudhry.info
MySQL Database Management & Design Services

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw

Peter

2006-02-25, 9:43 am

Hi,

this is the solution I use:

/usr/local/bin/mysqlhotcopy -p mypass --allowold
'mydb./~(expirations|rtt)$/' /var/backups/mysqlbackup/$1

I guess this one is also possible:


/usr/local/bin/mysqlhotcopy -p mypass --allowold
'mydb./ ~^(expirations|rtt)$
/' /var/backups/mysqlbackup/$1

Kind regards,

Peter

Imran Chaudhry wrote:
> Good stuff Peter, can you tell us your solution so folks can benefit
> from your efforts?
>
> (I expect the regex has to be POSIX style such as:
> mydb./ '~(expirations|rtt)'
/ right?)
>
> Imran Chaudhry
>
> --
> http://www.ImranChaudhry.info
> MySQL Database Management & Design Services
>


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw

Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2009 droptable.com