Open Source RDBMS - Seamless, Scalable, Stable and Free

한국어 | Login |Register

(click on this box to dismiss)

sql_log 관련

큐브리드의 SQL 질의 로그는 sql_log 폴더의 broker*.sql.log, broker*.slow.log, query_editor*.sql.log, query_editor*.slow.log에
저장되는 걸로 알고 있습니다. 최대 100M까지 저장되고 만약 사이즈가 넘어가면 이전 로그가 지워지면서 최근 내용이 기록되는 형태로요.

그런데 저희가 사용하는 테이블 중에서 특정 데이터만 삭제되는 현상이 발생했습니다.
물론 이 특정 데이터는 delete from temp where pid = 0 과 같은 특정 질의를 통해서만 가능합니다.
그래서 위 sql_log 폴더를 확인해봤지만 특정 데이터만을 삭제하는 질의를 찾을 수가 없었습니다.

이처럼 sql_log 폴더의 로그에 남지않고 큐브리드 데이터 삭제가 가능한지 알고 싶습니다.

link comment (0)
asked 4 years ago
1 Answer

He posted the same question on (Korean Q&A board ) and the issue was resolved.

To archive for the other users, I will leave how he handled:


1) If you cannot find the executed query in your SQL_LOG file, it may be deleted already because the previous SQL logs can be overwritten by new SQL logs. However CUBRID Engine creates a backup file of SQL_LOG when your SQL_LOG file exceeds 100M size(by setting in cubrid_broker.conf), so please find your query in .bak files too.

2) If you understand CUBRID Broker's architecture, you will see many of SQL_LOG files generated. Each of SQL_LOG file comes from each of CAS process and you can recognize where it comes from by a file name [Brokername_CASnumbername.sql.log]. Although Broker10_CAS10.sql.log contains SQLs executed in 2012-12, it doesn't gurantee that SQLs executed in 2012-12 still exists in your Broker1_CAS1.sql.log.

3) Broker handles SQL_LOG files, which means it only logs SQLs thru Broker. If you execute queries by CSQL, which directly communicate with DB engine without Broker, the query cannot be found in your SQL_LOG files. Therefore CSQL utility  should be allowed to DBA only.

link comment (0)
answered 4 years ago

You are either using a very old browser or a browser that is not supported.
In order to browse you need to have one of the following browsers:

Internet Explorer: Mozilla Firefox: Google Chrome: