본문 바로가기

log

analyseplugin - log 분석을 위한 notepad++ 의 유용한 plugin analyseplugin 플러그인은, log와 같은 text 문서에서 내가 입력한 string들을 포함하고 있는 모든 line을 특정 color로 extrect해서 순서대로 정렬해 준다. 따라서, 의미있는 로그 문구(panic, error, abort 등)들을 미리 입력해서 xml 형태로 저장해 두면, 매우 빠르게 log file에서 해당 문구가 있는지 확인할 수 있다. 한동안 notepad++에서 잘 사용하던 analyseplugin이 notepad++ update이후 더이상 plugin list에서 보이지 않아 매우 아쉬워하고 있었는데, 여전히 sourceforge에 project가 살아있고 최근(2020.06)까지 update가 된것을 발견하였다. https://sourceforge.net/proj.. 더보기
logging "linux platform log" without usb connection logging "linux platform log" without usb connectionusb 연결없이 platform log 계속해서 받기 1. connecting adb shell2. type thislogcat > /sdcard/log/name.log &3. adb shell stop adbd4. test start to get log5. adb pull /sdcard/log/ 더보기
stdout 출력을 file 로 돌리기 static const char *TEMPORARY_LOG_FILE = "/tmp/recovery.log"; intmain(int argc, char **argv) { time_t start = time(NULL); redirect_stdio(TEMPORARY_LOG_FILE); 더보기
linux stand out 을 file 에 logging 하기 static const char *TEMPORARY_LOG_FILE = "/tmp/recovery.log"; redirect_stdio(TEMPORARY_LOG_FILE); static void redirect_stdio(const char* filename) { // If these fail, there's not really anywhere to complain... freopen(filename, "a", stdout); setbuf(stdout, NULL); freopen(filename, "a", stderr); setbuf(stderr, NULL);} 더보기
Android log command, logwrapper 출처 : http://elinux.org/Android_Logging_System Android log message 를 만든다. log -p e -t onegun test message25402 01-08 09:27:26.210 15852 15852 E onegun : test message Process 가 출력하는 stdout 이나 stderr 즉, terminal 로 출력될 내용들을 android log 로 보내서 로깅되도록 한다. logwrapper -x ./test_program_name -testprogram_argstag : binarypriority : LOG_INFO 더보기
kernel log back ground 로 저장하기 cat proc/kmsg > /data/log.txt & 더보기