Re: Re: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
Dera Tech, i m not able to see innodb table on mysql database can you pls help me out Thanks regards Rajeev
Re: Re: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
Hi On Wed, May 09, 2012 at 08:04:11AM +0100, Rajeev tyagi wrote: Dera Tech, i m not able to see innodb table on mysql database can you pls help me out Difficult to help without more details How are you attempting to see the table? (e.g. what SQL statement?) Which error do you get? -- Karl E. Jorgensen IT Operations -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20120509183547.GH8503@hawking
Re: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
mysqlcheck --repair --all-databases Have a look at the man page for mysqlcheck. Thank you for help it works good, only one problem is with InnoDB tables: --- sales.users note : The storage engine for the table doesn't support repair --- Is it possible repair this InnoDB tables in the similar way? -- Regards -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Re: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
On 6/7/07, Jarek Buczyński [EMAIL PROTECTED] wrote: I suposse you will need to do inside the mysql client console: mysql USE database; mysql REPAIR TABLE table; ... and so on... Thanks for replay. I understand if I would have one or two databases, but I have o lot of databases with a lot of tables it is impossible do this in way you show. Anybody have any idea? It's fairly easy to do with some basic shell scripting. The following gets you the list of all your databases in a file called all-databases: mysql -u root -p eof | sed -n '2~1p' all-databases show databases; eof Then edit all-databases to remove any databases you don't want to mess with (information_schema comes to mind). Next use something similar to get lists of all tables in those databases into different files (tables.db1, tables.db2, etc.). Finally, iterate over the tables in these files and generate appropriate repair table statements. These steps left as an exercise for the reader. You may want to brush up your shell-fu. The Advanced Bash Scripting Guide (http://tldp.org/LDP/abs/html/) should help. -- Kushal
Re: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
On Mon, Jun 04, 2007 at 09:21:33PM +0200, Jarek Buczy?ski wrote.. How I can repair all tables at some databases (not all), I don't want do this manually mysqlcheck --repair --all-databases Have a look at the man page for mysqlcheck. -- Kevin Coyner GnuPG key: 1024D/8CE11941 signature.asc Description: Digital signature
Re: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
Jarek Buczyński escribió: Hi I've upgrades sarge to etch. I've got problem with MySQL 5 (previously I had MySQL 4). MySQL server tells me: -- Table upgrade required. Please do REPAIR TABLE `adresy` to fix it! ... Version: '5.0.32-Debian_7etch1-log' socket: '/var/run/mysqld/mysqld.sock' port: 3306 Debian etch distribution /etc/mysql/debian-start[8752]: Upgrading MySQL tables if necessary. /etc/mysql/debian-start[8760]: Checking for crashed MySQL tables. Checking for corrupt, not cleanly closed and upgrade needing tables.. ... -- How I can repair all tables at some databases (not all), I don't want do this manually -- Regards I suposse you will need to do inside the mysql client console: mysql USE database; mysql REPAIR TABLE table; ... and so on... -- .-. | Miguel J. Jiménez | | Programador Senior | | Área de Internet/XSL/PHP| | [EMAIL PROTECTED] | :-: | ISOTROL, S.A. | | Edificio BLUENET, Avda. Isaac Newton nº3, 4ª planta.| | Parque Tecnológico Cartuja '93, 41092 Sevilla (ESP).| | Teléfono: +34 955 036 800 - Fax: +34 955 036 849| | http://www.isotrol.com | :-: | Aquellos que mueran mañana serán los que hayan sobrevivido hoy. | | Dusty Attenborough, La Leyenda de los Heroes de la Galaxia | '-' begin:vcard fn;quoted-printable:Miguel J. Jim=C3=A9nez Jim=C3=A9nez n;quoted-printable:Jim=C3=A9nez Jim=C3=A9nez;Miguel J. org:ISOTROL, S.A.;XSL / PHP adr;quoted-printable;quoted-printable;quoted-printable:Parque Tecnol=C3=B3gico Cartuja 93;;C/ Isaac Newton 3, 4=C2=AA;Sevilla;Sevilla;41092;Espa=C3=B1a email;internet:[EMAIL PROTECTED] title:Programador Senior tel;work:+34 955 036 800 (ext. 1805) tel;fax:+34 955 036 849 tel;cell:+34 607 44 87 64 x-mozilla-html:TRUE url:http://www.isotrol.com version:2.1 end:vcard
RE: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
I suposse you will need to do inside the mysql client console: mysql USE database; mysql REPAIR TABLE table; ... and so on... Thanks for replay. I understand if I would have one or two databases, but I have o lot of databases with a lot of tables it is impossible do this in way you show. Anybody have any idea? -- Regards -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Re: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
Jarek Buczyński wrote this at Thu, Jun 07, 2007 at 12:32:05AM +0200 I suposse you will need to do inside the mysql client console: mysql USE database; mysql REPAIR TABLE table; Thanks for replay. I understand if I would have one or two databases, but I have o lot of databases with a lot of tables it is impossible do this in way you show. Excuse me for being so frank, but what is it with the above scenario that's impossible? Some times, you actually have to do a bit of dirty work yourself. You have to do things manually, you just can't sit on your arse awaiting that things will do itself. So what, you have to do it manually on every table on every database that you have. So what! No one ever said that being a system administrator was an easy job. Get over it! -- Yours sincerely Jostein Elvaker Haande A free society is a place where it is safe to be unpopular - Adlai Stevenson Web: http://tolecnal.net - Mail: tolecnal a tolecnal dot net -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
RE: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
#!/bin/bash PASSWD=TWOJEHASLO for i in `mysql -u root -p$PASSWD -e 'show databases'` do echo $i databases.idx.pre ilosclinii_all=`cat databases.idx.pre | wc -l` ilosc_linii_naglowka=1 ilosclinii_minus_X=`expr $ilosclinii_all - $ilosc_linii_naglowka` tail -$ilosclinii_minus_X databases.idx.pre databases.idx.final echo dodalem baze $i do indeksu baz done for c in `cat databases.idx.final` do for d in `mysql -u root -p$PASSWD -D $c -e 'show tables'` do mysql -u root -p$PASSWD -D $c -e repair table $d done done pewnie tak zadziala aczkolwiek nie mam czasu przetestowac ;) Tak zadziałało, wygląda że przeleciało wszystkie tabele, w drugim for wywala błędy typu: +-++--+- Table 'Sklepy.Tables_in_Sklepy' doesn't exist | +-++--+- Ale tak czy tak przechodzi po innych tabelkach, tylko czy ten REPAIR ta naprawdę coś zmienił, dalej widzę: # /etc/init.d/mysql restart Stopping MySQL database server: mysqld. Starting MySQL database server: mysqld. Checking for corrupt, not cleanly closed and upgrade needing tables.. Syslog: mysqld[2795]: 070605 16:04:20 [Note] /usr/sbin/mysqld: Standardowe zakończenie działania mysqld[2795]: mysqld[2795]: 070605 16:04:22 InnoDB: Starting shutdown... mysqld[2795]: 070605 16:04:24 InnoDB: Shutdown completed; log sequence number 0 82909 mysqld[2795]: 070605 16:04:24 [Note] /usr/sbin/mysqld: Zakończenie działania wykonane mysqld[2795]: mysqld_safe[4469]: ended mysqld_safe[4537]: started mysqld[4540]: 070605 16:04:25 InnoDB: Started; log sequence number 0 82909 mysqld[4540]: 070605 16:04:25 [Note] /usr/sbin/mysqld: ready for connections. mysqld[4540]: Version: '5.0.32-Debian_7etch1-log' socket: '/var/run/mysqld/mysqld.sock' port: 3306 Debian etch distribution /etc/mysql/debian-start[4575]: Upgrading MySQL tables if necessary. /etc/mysql/debian-start[4585]: Checking for crashed MySQL tables. Jak jest u Was po przejściach MySQL'a z 4 na 5, czy w ogóle musze się tym martwić? -- Pozdrawiam
Re: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
2007/6/5, Jarek Buczyński [EMAIL PROTECTED]: +-++--+- Table 'Sklepy.Tables_in_Sklepy' doesn't exist | +-++--+- skrypt chce zrobic wiecej niz powinien, nie ma sie czym martwic. Ale tak czy tak przechodzi po innych tabelkach, tylko czy ten REPAIR ta naprawdę coś zmienił, dalej widzę: najlepiej odpal phpmyadmina i sie przekonaj # /etc/init.d/mysql restart Stopping MySQL database server: mysqld. Starting MySQL database server: mysqld. Checking for corrupt, not cleanly closed and upgrade needing tables.. Syslog: mysqld[2795]: 070605 16:04:20 [Note] /usr/sbin/mysqld: Standardowe zakończenie działania mysqld[2795]: mysqld[2795]: 070605 16:04:22 InnoDB: Starting shutdown... mysqld[2795]: 070605 16:04:24 InnoDB: Shutdown completed; log sequence number 0 82909 mysqld[2795]: 070605 16:04:24 [Note] /usr/sbin/mysqld: Zakończenie działania wykonane mysqld[2795]: mysqld_safe[4469]: ended mysqld_safe[4537]: started mysqld[4540]: 070605 16:04:25 InnoDB: Started; log sequence number 0 82909 mysqld[4540]: 070605 16:04:25 [Note] /usr/sbin/mysqld: ready for connections. mysqld[4540]: Version: '5.0.32-Debian_7etch1-log' socket: '/var/run/mysqld/mysqld.sock' port: 3306 Debian etch distribution /etc/mysql/debian-start[4575]: Upgrading MySQL tables if necessary. /etc/mysql/debian-start[4585]: Checking for crashed MySQL tables. Jak jest u Was po przejściach MySQL'a z 4 na 5, czy w ogóle musze się tym martwić? Nie - ostatni komunikat pojawia sie zawsze. Jesli dostales mejla z listą skraszowanych tabel to jednak cos dalej jest nie w porzadku, jesli nie to - git. -- Wojciech Ziniewicz Unix SEX :{look;gawk;find;sed;talk;grep;touch;finger;find;fl ex;unzip;head;tail; mount;workbone;fsck;yes;gasp;fsck;more;yes;yes;eje ct;umount;makeclean; zip;split;done;exit:xargs!!;)}
Re: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
04-06-07, Jarek Buczyński [EMAIL PROTECTED] napisał(a): Witam, Po aktualizacji MySQl'a z wersji 4 na 5, pojawiają się takie błędy: -- Version: '5.0.32-Debian_7etch1-log' socket: '/var/run/mysqld/mysqld.sock' port: 3306 Debian etch distribution /etc/mysql/debian-start[8752]: Upgrading MySQL tables if necessary. /etc/mysql/debian-start[8760]: Checking for crashed MySQL tables. Checking for corrupt, not cleanly closed and upgrade needing tables.. ... Table upgrade required. Please do REPAIR TABLE `adresy` to fix it! -- Można to jakoś hurtowo naprawić, czy muszę łączyć się z każdą bazą i osobno robić REPAIT TABLE ? - co raczej jest bardzo kłopotliwe bo baz jest bardzo dużo przeciez nie bedziesz tego robił recznie, tak na szybko skrypt ktory prawie na pewno zadziała oprocz kilku bledow ktore nic nie zepsują (zbackupuj pierw /var/lib/mysql) #!/bin/bash PASSWD=TWOJEHASLO for i in `mysql -u root -p$PASSWD -e 'show databases'` do echo $i databases.idx echo dodalem baze $i do indeksu baz done for c in `cat databases.idx` do for d in `mysql -u root -p$PASSWD -D $c -e 'show tables'` do mysql -u root -p$PASSWD -D $c -e repair table $d done done kilka linijek a naprawi wszystko -- Wojciech Ziniewicz Unix SEX :{look;gawk;find;sed;talk;grep;touch;finger;find;fl ex;unzip;head;tail; mount;workbone;fsck;yes;gasp;fsck;more;yes;yes;eje ct;umount;makeclean; zip;split;done;exit:xargs!!;)}
Re: MySQL 4.0 (sarge) -- MySQL 5.0 (etch) -- Please do REPAIR TABLE
04-06-07, Jarek Buczyński [EMAIL PROTECTED] napisał(a): #!/bin/bash PASSWD=TWOJEHASLO for i in `mysql -u root -p$PASSWD -e 'show databases'` do echo $i databases.idx echo dodalem baze $i do indeksu baz done for c in `cat databases.idx` do for d in `mysql -u root -p$PASSWD -D $c -e 'show tables'` do mysql -u root -p$PASSWD -D $c -e repair table $d done done kilka linijek a naprawi wszystko Dzięki to już prawie działa tylko że listuje zbyt dużo baz, w cudzysłowu bo dodaje też nazwę tabelki z bazami Database i baze information_schema, można się pozbyć jakoś tych dwóch wpisów. W sumie już to rozwiązałem przez edycję pliku i podział skryptu na dwa :), ale może jest na to sposób w jednym skrypcie :) w sumie zaden to blad... ale: najprosciej przefiltrować plik poleceniem... hmm... , najbardziej po chamsku to ztailować ilosc linii minus jeden #!/bin/bash PASSWD=TWOJEHASLO for i in `mysql -u root -p$PASSWD -e 'show databases'` do echo $i databases.idx.pre ilosclinii_all=`cat databases.idx.pre | wc -l` ilosc_linii_naglowka=1 ilosclinii_minus_X=`expr $ilosclinii_all - $ilosc_linii_naglowka` tail -$ilosclinii_minus_X databases.idx.pre databases.idx.final echo dodalem baze $i do indeksu baz done for c in `cat databases.idx.final` do for d in `mysql -u root -p$PASSWD -D $c -e 'show tables'` do mysql -u root -p$PASSWD -D $c -e repair table $d done done pewnie tak zadziala aczkolwiek nie mam czasu przetestowac ;) Pojawia się jeszcze problem z tabelami InnoDB: The storage engine for the table doesn't support repair Czy ten problem nie dotyczy InnoDB czy trzeba coś innego zrobić? google pzdr. -- Wojciech Ziniewicz Unix SEX :{look;gawk;find;sed;talk;grep;touch;finger;find;fl ex;unzip;head;tail; mount;workbone;fsck;yes;gasp;fsck;more;yes;yes;eje ct;umount;makeclean; zip;split;done;exit:xargs!!;)}