how many us can you find in:
q: how to fix corrupt, not cleanly closed and upgrade needing tables in mysql when i restart mysql server in debian, i always have the below messages. how to make the messages disappear or fix the problem/corrupted tables? 
debian:~# /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..

the linux /var/log/syslog shows
jul 18 12:27:57 localhost mysqld: 140718 12:27:57 [note] /usr/sbin/mysqld: normal shutdown
jul 18 12:27:57 localhost mysqld:
jul 18 12:27:57 localhost mysqld: 140718 12:27:57 [note] event scheduler: purging the queue. 0 events
jul 18 12:27:57 localhost mysqld: 140718 12:27:57  innodb: starting shutdown...
jul 18 12:27:58 localhost mysqld: 140718 12:27:58  innodb: shutdown completed; log sequence number 0 44233
jul 18 12:27:58 localhost mysqld: 140718 12:27:58 [note] /usr/sbin/mysqld: shutdown complete
jul 18 12:27:58 localhost mysqld:
jul 18 12:27:58 localhost mysqld_safe: mysqld from pid file /var/run/mysqld/mysqld.pid ended
jul 18 12:28:00 localhost mysqld_safe: starting mysqld daemon with databases from /mnt/user/mysql
jul 18 12:28:00 localhost mysqld: 140718 12:28:00 [note] plugin federated is disabled.
jul 18 12:28:00 localhost mysqld: 140718 12:28:00  innodb: started; log sequence number 0 44233
jul 18 12:28:00 localhost mysqld: 140718 12:28:00 [note] event scheduler: loaded 0 events
jul 18 12:28:00 localhost mysqld: 140718 12:28:00 [note] /usr/sbin/mysqld: ready for connections.
jul 18 12:28:00 localhost mysqld: version: 5.1.49-3~bpo50+1  socket: /var/run/mysqld/mysqld.sock  port: 3306  (debian)
jul 18 12:28:01 localhost /etc/mysql/debian-start[11601]: upgrading mysql tables if necessary.
jul 18 12:28:01 localhost /etc/mysql/debian-start[11605]: /usr/bin/mysql_upgrade: the --basedir option is always ignored
jul 18 12:28:01 localhost /etc/mysql/debian-start[11605]: looking for mysql as: /usr/bin/mysql
jul 18 12:28:01 localhost /etc/mysql/debian-start[11605]: looking for mysqlcheck as: /usr/bin/mysqlcheck
jul 18 12:28:01 localhost /etc/mysql/debian-start[11605]: this installation of mysql is already upgraded to 5.1.49, use --force if you still need to run mysql_upgrade
jul 18 12:28:01 localhost /etc/mysql/debian-start[11611]: checking for insecure root accounts.
jul 18 12:28:01 localhost /etc/mysql/debian-start[11615]: triggering myisam-recover for all myisam tables


a: do not follow the 1st answer its a very bad issue.
if you read the line correctly you will see there is no problem cause not corrupt table or anything else can be found
checking for corrupt, not cleanly closed and upgrade needing tables so everything is ok.

a: couple options which works for me.
1) find the all mysql processes running on your debian:
ps -a | grep mysql

and if is any running, kill it:
kill -9 <ps_number which is second column number>

2) other option is to start mysql with local host and typical port number for it
sudo mysql -h 127.0.0.1 -p 3306 -u root -p <database>

https://stackoverflow.com/a/11658142/2523431
3)the most savage one; uninstall mysql and reinstall (the solution found on some other post, however at the moment cant recall link to give credit):
with the command:
sudo apt-get remove --purge mysql\*

you can delete anything related to packages named mysql. those commands is only valid on debian / debian based linux distributions (for eg. ubuntu).
you can list all mysql packages installed with:
sudo dpkg -l | grep -i mysql

for more cleanup for package cache you can:
sudo apt-get clean

remember to:
sudo updatedb

otherwise the locate command will display old data.
to install mysql again, use the following command:
sudo apt-get install libmysqlclient-dev mysql-client

this will install mysql client, libmysql and its headers files.
to install the server, run this one:
sudo apt-get install mysql-server

there are other options advised by other guys, like overwriting config file, but in my case (im running mysql on kali linux which is debian based) didnt help. 
btw dont forget to shut system with command:
shutdown -h now

it should prevent you for further inconvenience in the future.

user
There are one hundred and ten "u"s in the text you provided.
assistant