Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Answers Viewqa JDBC How to delete content of a log file from linux terminal?
Login         

View Questions and Answers by Category

Advertisements


 
Have Programming Question? Ask it here!
 
 
 


Java Coder
How to delete content of a log file from linux terminal?
1 Answer(s)      8 months ago
Posted in : JDBC


Hi,

My production server is on the linux machine. I am trying to debug and find the slow running queries. But first I want to delete the content of the /var/log/slow-queries.log file.

Can anyone tell me how to do this?

Thanks


Advertisement
View Answers

April 8, 2014 at 8:11 PM


Hi,

Its easy to do this. You can use the following command to delete the content of the mysql log file:

cat /dev/null > /var/log/slow-queries.log

Thanks



Related Tutorials/Questions & Answers:
Advertisements
 

 

 

DMCA.com