Re: Recover dropped database

2012-10-29 Thread Lorenzo Milesi
 That's rough. The only thing I could suggest is try out Percona's
 data recovery tool 

My collegue did some recovery using Percona tools and (suspance...) recovered 
95% of the data!

Lovely!

Ciao.
maxxer
-- 
Lorenzo Milesi - lorenzo.mil...@yetopen.it

GPG/PGP Key-Id: 0xE704E230 - http://keyserver.linux.it



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



Re: Recover dropped database

2012-10-29 Thread Sharl Jimh Tsin
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

于 2012年10月29日 17:18, Lorenzo Milesi 写道:
 That's rough. The only thing I could suggest is try out
 Percona's data recovery tool
 
 My collegue did some recovery using Percona tools and (suspance...)
 recovered 95% of the data!
 
 Lovely!
 
 Ciao. maxxer
 

back it up daily,you will keep this case away forever.

- -- 
Best regards,
Sharl.Jimh.Tsin (From China *Obviously Taiwan INCLUDED*)

Using Gmail? Please read this important notice:
http://www.fsf.org/campaigns/jstrap/gmail?10073.
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iQEcBAEBAgAGBQJQjkppAAoJEEYmNy4jisTjI0wH/3PVVKmR0BXGCgockiE4TzOJ
PEd1UhrEfmVdVUsJnzTb19wd6U5i8u7MyHDClJlqn5HDydUsP/J73Jb6ogufY5GF
aGeJmLlDnyoCFi4AJgU/IPJDdkpiykdNO9ZlJAB6+u8NJu2j/1GJAf+XOsjrmfSX
BHnSo398muY/ENgyr+rgEs1zwNnBUuEqTEP3h3xvRQ1Khen7KYdJuD4CPTaq54cy
SxD283inX6Ra18/g83Zrb8ZsTcqF/JVQO7PSu+JosnmPp86qfsbibEUg+RCMkKyz
I8O7luDPkE5EcqLUDja+3qzhODwJJksQkP5WQryddCrPdbfsDmb86UOorv9RaXw=
=tWBm
-END PGP SIGNATURE-

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



Re: Recover dropped database

2012-10-29 Thread spameden
Hi,
could your collegue please share steps he taken to recover data?

I'd be interested most definetely!

Thanks

2012/10/29 Lorenzo Milesi max...@ufficyo.com

  That's rough. The only thing I could suggest is try out Percona's
  data recovery tool

 My collegue did some recovery using Percona tools and (suspance...)
 recovered 95% of the data!

 Lovely!

 Ciao.
 maxxer
 --
 Lorenzo Milesi - lorenzo.mil...@yetopen.it

 GPG/PGP Key-Id: 0xE704E230 - http://keyserver.linux.it



 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:http://lists.mysql.com/mysql




Unknown database error

2012-10-29 Thread javad bakhshi
Hi,

I get an Unknown database error when I am trying to connect to mysql using C 
API.

I have created the database in mysql prompt as root:

CREATE DATABASE Lr0;

I am pretty sure that the problem is a ownership issue, because when I do
ls -l in my datadir I get:

[javad64@udbl64 data]$ ls -l
total 20532
-rw-rw 1 javad64 mysql   10485760 Oct 26 14:10 ibdata1
-rw-rw 1 javad64 mysql    5242880 Oct 26 14:10 ib_logfile0
-rw-rw 1 javad64 mysql    5242880 Oct 19 15:28 ib_logfile1
drwx-- 2 javad64 javad64 4096 Oct 26 14:35 Lr0
drwx-- 2 javad64 mysql   4096 Oct 22 11:04 mysql
drwx-- 2 javad64 mysql   4096 Oct 22 11:04 test

which shows Lr0 doesn't have mysql ownership.

my question is:
1- Why does this happen? While I am creating the 
database in mysql prompt as root.

2- How can I fix it? I don't have root access in the system I am using
so the chown solution is off table.


 
Best regards,
Javad Bakhshi,
Computer Science M.Sc
Department of IT, Uppsala University


optimize and tmpfiles

2012-10-29 Thread walter harms
hi list,
does someone know under what circumstances ''optimize tables'' will
create a tmpfile ?

we had a strange case of out of space that seems related to an optimize 
table
but i was unable to replicate that case exactly as that no tmpfile appeared.
(The table has a lot of partitions if that matters.)

re,
 wh


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



Re: optimize and tmpfiles

2012-10-29 Thread Reindl Harald


Am 29.10.2012 12:48, schrieb walter harms:
 hi list,
 does someone know under what circumstances ''optimize tables'' will
 create a tmpfile?

under all if it is MyISAM and for select id from table order by rand(); too



signature.asc
Description: OpenPGP digital signature


Re: optimize and tmpfiles

2012-10-29 Thread walter harms


Am 29.10.2012 13:17, schrieb Reindl Harald:
 
 
 Am 29.10.2012 12:48, schrieb walter harms:
 hi list,
 does someone know under what circumstances ''optimize tables'' will
 create a tmpfile?
 
 under all if it is MyISAM and for select id from table order by rand(); too
 

interessting, i was trying to force it (with optimize) but it did not work.

Is there a way to restrict the maximum size of those tmpfiles ?

re,
 wh

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



Re: optimize and tmpfiles

2012-10-29 Thread Reindl Harald


Am 29.10.2012 14:54, schrieb walter harms:
 
 
 Am 29.10.2012 13:17, schrieb Reindl Harald:


 Am 29.10.2012 12:48, schrieb walter harms:
 hi list,
 does someone know under what circumstances ''optimize tables'' will
 create a tmpfile?

 under all if it is MyISAM and for select id from table order by rand(); too

 
 interessting, i was trying to force it (with optimize) but it did not work.
 
 Is there a way to restrict the maximum size of those tmpfiles?

you do you imagine restrict them?
they are as big as the table



signature.asc
Description: OpenPGP digital signature


Re: Unknown database error

2012-10-29 Thread Michael Dykman
The contents of datadir is typically owned by the mysql user and group.
Certain attributes on the datadir itself (ls -ld $datadir) can affect the
permissions of newly-created files and directories.  You need to talk to
you sysadmin,  with a eye towards doing something like

chown -R mysql:mysql $datadir

I honestly cannot think of a scenario where the datadir should be
permissioned any other way.

On 2012-10-29 6:26 AM, javad bakhshi javadbakh...@yahoo.com wrote:

Hi,

I get an Unknown database error when I am trying to connect to mysql using
C API.

I have created the database in mysql prompt as root:

CREATE DATABASE Lr0;

I am pretty sure that the problem is a ownership issue, because when I do
ls -l in my datadir I get:

[javad64@udbl64 data]$ ls -l
total 20532
-rw-rw 1 javad64 mysql   10485760 Oct 26 14:10 ibdata1
-rw-rw 1 javad64 mysql5242880 Oct 26 14:10 ib_logfile0
-rw-rw 1 javad64 mysql5242880 Oct 19 15:28 ib_logfile1
drwx-- 2 javad64 javad64 4096 Oct 26 14:35 Lr0
drwx-- 2 javad64 mysql   4096 Oct 22 11:04 mysql
drwx-- 2 javad64 mysql   4096 Oct 22 11:04 test

which shows Lr0 doesn't have mysql ownership.

my question is:
1- Why does this happen? While I am creating the
database in mysql prompt as root.

2- How can I fix it? I don't have root access in the system I am using
so the chown solution is off table.



Best regards,
Javad Bakhshi,
Computer Science M.Sc
Department of IT, Uppsala University


Re: optimize and tmpfiles

2012-10-29 Thread walter harms


Am 29.10.2012 14:55, schrieb Reindl Harald:
 
 
 Am 29.10.2012 14:54, schrieb walter harms:


 Am 29.10.2012 13:17, schrieb Reindl Harald:


 Am 29.10.2012 12:48, schrieb walter harms:
 hi list,
 does someone know under what circumstances ''optimize tables'' will
 create a tmpfile?

 under all if it is MyISAM and for select id from table order by rand(); 
 too


 interessting, i was trying to force it (with optimize) but it did not work.

 Is there a way to restrict the maximum size of those tmpfiles?
 
 you do you imagine restrict them?

actually i espected a no, but sometimes i have to think positv.



 they are as big as the table
 
that is a problem with a large table


re,
 wh



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



Re: optimize and tmpfiles

2012-10-29 Thread Reindl Harald


Am 29.10.2012 18:11, schrieb walter harms:
 Is there a way to restrict the maximum size of those tmpfiles?

 you do you imagine restrict them?
 
 actually i espected a no, but sometimes i have to think positv.

think negative and get positive suprprised :-)

 they are as big as the table
 that is a problem with a large table

that is why you should always have as minimum space left
as the largets table grows because you need 'optimize table'
and in the worst case the full size to free disk-space after
deleting many data or for whatever repair



signature.asc
Description: OpenPGP digital signature


name of a database in mysql....

2012-10-29 Thread FHDATA



mysql server 5.1.41

hello

Is there a way mysql server can be told to disallow
any attempt of creating a database whose name contains
certain characters?

thanks,

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



Re: name of a database in mysql....

2012-10-29 Thread Pintér Tibor

2012.10.29. 20:59 keltezéssel, FHDATA írta:



mysql server 5.1.41

hello

Is there a way mysql server can be told to disallow
any attempt of creating a database whose name contains
certain characters?

thanks,



make an empty dir in /var/lib/mysql with that name + chmod 000, owner 
!mysql :)


t

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



Re: optimize and tmpfiles

2012-10-29 Thread Mogens Melander

On Mon, October 29, 2012 18:11, walter harms wrote:


 Am 29.10.2012 14:55, schrieb Reindl Harald:


 Am 29.10.2012 14:54, schrieb walter harms:


 Am 29.10.2012 13:17, schrieb Reindl Harald:


 Am 29.10.2012 12:48, schrieb walter harms:
 hi list,
 does someone know under what circumstances ''optimize tables'' will
 create a tmpfile?

 under all if it is MyISAM and for select id from table order by
 rand(); too


 interessting, i was trying to force it (with optimize) but it did not
 work.

 Is there a way to restrict the maximum size of those tmpfiles?

 you do you imagine restrict them?

 actually i espected a no, but sometimes i have to think positv.



 they are as big as the table

 that is a problem with a large table


Well, my friend. That's a hardware problem ;^)


 re,
  wh



-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



Dumping drupal databases

2012-10-29 Thread Tim Johnson
I've recently unstalled drupal 7.15 on Mac OS X 10.7.

I want to back up the mysql data for drupal.
However, I can't locate those databases and tables using MySQL
server or PHPMyAdmin, even if I start mysql on port 3307.

The drupal mysql datafiles are located at
/Applications/drupal-7.15-0/mysql/data

as opposed to /opt/local/var/db/mysql5 for
'customary' mysql.

How can I accomplish this?
thanks
-- 
Tim 
tim at tee jay forty nine dot com or akwebsoft dot com
http://www.akwebsoft.com

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



Re:Dumping drupal databases

2012-10-29 Thread 小刀
You can the the /etc/my.cnf and file the parameter about the data_dir
At 2012-10-30 08:24:14,Tim Johnson t...@akwebsoft.com wrote:
I've recently unstalled drupal 7.15 on Mac OS X 10.7.

I want to back up the mysql data for drupal.
However, I can't locate those databases and tables using MySQL
server or PHPMyAdmin, even if I start mysql on port 3307.

The drupal mysql datafiles are located at
/Applications/drupal-7.15-0/mysql/data

as opposed to /opt/local/var/db/mysql5 for
'customary' mysql.

How can I accomplish this?
thanks
-- 
Tim 
tim at tee jay forty nine dot com or akwebsoft dot com
http://www.akwebsoft.com

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



ndb_restore is not restoring users and grants

2012-10-29 Thread Bheemsen Aitha
Hi,

I was able to backup my cluster using ndb_mgm and also restore using
ndb_restore. However, when everything looks fine after restore, I see that
users and grants are not restored. So, does ndb_restore restore all
databases including information_schema and mysql databases, plus users and
grants? Am I missing something? Do I need to do anything after restore step?

here are the commands I used for restore.

ndb_restore -c hostname -s -n 1 -m -b 3 -r --restore-privilege-tables=true
--backup_path=/opt/app/mysql_data01/ndb_backup/BACKUP/BACKUP-3/
ndb_restore -c hostname -s -n 2 -b 3 -r --restore-privilege-tables=true
--backup_path=/opt/app/mysql_data02/ndb_backup/BACKUP/BACKUP-3/

I really appreciate any help on this.

Thanks
-bheem