I haven't used 9.0, I'm using 7.3, but I suspect it should be very similar, as
root, edit the /etc/my.cnf file
and add a couple of lines  to the top section: it should look similar to this

[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
log=/var/log/mysql/mysqllog
log-update=/var/log/mysql/mysqlupdate

the two log etries probably aren't there, add them and save the file

then run these commands:

cd /var/log
mkdir mysql
chown mysql.mysql mysql
chmod 700 mysql

then you should be able to restart the mysql server with this command

service mysql restart

this should restart the server and then the logs should be filling up with all
the queries and most importantly the update log will record all the actual
changes that occur in the database, so you can reconstruct it from a known
point, or revert back from a backup and bring the database back to a point
where something bad happened, human or machine wise.. :)

and then when you have this running, you probably should run  the mysqldump
program from the command line, and use the

mysqldump   --opt  --flush-logs --all-databases > 20030911.mysqldump.sql

and that should give you a good backup from right now and the update log files
will be restarted from this point in time..


Kelley



[EMAIL PROTECTED] wrote:

> Dear Miguel:
>
> Firstly I found the path for mysqld, in my system (Linux RH7.3), it is in
> /usr/libexec/
> Then I write this command:
>
> /usr/libexec/mysqld --log=/var/mysqldquery.log -u root
>
> however the system give me this message:
>
> bash: mysqld: command not found
>
> I don`t understand what is happen. Could you help me with this issue,
> please? I`d like to get the mysql error logs and query logs.
>
> Thank you,
>
> Edwin Limachi N.
> DATACOM - Instalaciones La Paz
> Tel.: 591-2-212-3978
> Cel.: 591-715-29967
> Fax.: 591-2-212-3975
>
> miguel solorzano <[EMAIL PROTECTED]>
> 10/09/2003 20:11
>
> Para
> [EMAIL PROTECTED], [EMAIL PROTECTED]
> cc
>
> Asunto
> Re: How to enable General Query_log?
>
> At 17:07 10/9/2003 -0400, [EMAIL PROTECTED] wrote:
> Hi,
>
> Notice the option syntax --log:
>
> /usr/local/mysql/libexec/mysqld --log=/usr/local/mysql/var/mysqlquery.log
> -uroot
> 030910 20:03:54  InnoDB: Started
> /usr/local/mysql/libexec/mysqld: ready for connections.
> Version: '4.0.15-debug-log'  socket: '/tmp/mysql.sock'  port: 3306
>
>  ># tail /usr/local/mysql/var/mysqlquery.log
> /usr/local/mysql/libexec/mysqld, Version: 4.0.15-debug-log, started with:
> Tcp port: 3306  Unix socket: /tmp/mysql.sock
> Time                 Id Command    Argument
> 030910 20:07:05       1 Connect     [EMAIL PROTECTED] on
> 030910 20:07:17       1 Query       select version()
>
> >Dear list friends:
> >
> >I`d like to get your help about this issue. I have a Linux box RedHat 7.3
> >running the MySQL v3.23.56. In this box I`m running a TACACS server for
> >authenticating my users to access to cisco routers. TACACS is using a
> >Mysql database where i configured the user accounts, however TACACS can
> >not get this info from this data base. I`d like to see the query log for
> >the MySQL.
> >The manual says that for it we have to start mysql with a query log. I
> >typed:
> >         shell#mysqld - - log[=/var/log/mysqlquery.log]
> >
> >but I get this message:
> >
> >bash: myslqd command not found
> >
> >What is the correct syntax and where have I to write it for start mysql
> >with a query log?
> >
> >Thank you for your help,
>
> --
> Regards,
>
> For technical support contracts, visit https://order.mysql.com/
> Are you MySQL certified?, http://www.mysql.com/certification/
>
> Miguel Angel Solórzano <[EMAIL PROTECTED]>
> São Paulo - Brazil


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

Reply via email to