Linux

pchero on 7월 25th, 2011

  Ubuntu 11.04 Kernel Version Linux localhost.localdomain 2.6.18-194.32.1.el5 #1 SMP Wed Jan 5 17:53:09 EST 2011 i686 i686 i386 GNU/Linux 환경에서 Virtual Box 를 구동하려고 하니 다음과 같은 에러메시지가 나타났다. “Failed to start the virtual machine WindowsXP. Failed to open/create the internal network ‘HostInterfaceNetworking-eth0′ (you might need to modprobe vboxnetflt to make it accessible) (VERR_SUPDRV_COMPONENT_NOT_FOUND). [...]

Continue reading about Ubuntu Virtual Box Start Error

pchero on 4월 13th, 2011

프로그램 TEST 중 아래와 같은 오류가 발생했다. 결과는 Core dump. jonathan@jonathan-laptop:~/workspace/TEST$ ./TEST *** stack smashing detected ***: ./TEST terminated ======= Backtrace: ========= /lib/tls/i686/cmov/libc.so.6(__fortify_fail+0×50)[0xb775c390] /lib/tls/i686/cmov/libc.so.6(+0xe233a)[0xb775c33a] ./TEST[0x804a2f4] ./TEST[0x8049189] ./TEST[0x8049258] ./TEST[0x8049205] /lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe6)[0xb7690bd6] ./TEST[0x8049081] ======= Memory map: ======== 08048000-0804f000 r-xp 00000000 08:05 7344439    /home/jonathan/workspace/TEST/TEST 0804f000-08050000 r–p 00007000 08:05 7344439    /home/jonathan/workspace/TEST/TEST 08050000-08051000 rw-p 00008000 08:05 7344439    /home/jonathan/workspace/TEST/TEST 08051000-080fd000 rw-p 00000000 [...]

Continue reading about stack smashing detected

pchero on 11월 3rd, 2010

SYBASE 에서 다음의 init 스크립트를 사용중 stop시 locale 에러가 나타나는 것을 확인했다. jonathan@jonathan-laptop:/opt/sybase/ASE-15_0/install$ cat /etc/init.d/sybase #!/bin/sh## Startup script for Sybase ASE# # description: Sybase Adaptive Server Enterprise# is a SQL database server.# processname: dataserver  SYBASE=/opt/sybaseSERVER=JONATHANLAPTOPLANG=ko_KR.euckrexport LANG  # Source environment variables.. $SYBASE/SYBASE.sh  # Find the name of the scriptNAME=`basename $0`  # For SELinux we need to [...]

Continue reading about SYBASE – init Script and locale error

pchero on 10월 4th, 2010

 /usr/include/features.h 파일에는 컴파일 할 때 사용하는 -D 옵션과 긴밀한 관계가 있다.  어떤 Define을 하느냐에 따라 각기 다른 내용의 컴파일과 링크가 이루어 진다.  그 내용을 /usr/include/features.h 파일의 전문을 여기에 싣는다. /* Copyright (C) 1991-1993,1995-2006,2007,2009 Free Software Foundation, Inc.   This file is part of the GNU C Library.    The GNU C Library is free software; you [...]

Continue reading about /usr/include/features.h

pchero on 9월 2nd, 2010

 Linux/Unix 프로그래밍을 하다보면 GCC 버전에 영향을 받는 경우가 있다.  예를 들면 ACE 라이브러리를 컴파일 할 경우, gcc-4.x 대의 버전에는 컴파일 오류가 발생한다.  그래서 부득이 gcc/g++ 을 다시 설치하려고 해도 여의치 않는 경우가 많다. 이럴 경우 다른 배포판을 찾아보게 되는데, 여기에 배포판마다 가지고 있는 gcc의 버전 정보를 싣는다. Distribution Version Compiler version Provided by Date BeOS [...]

Continue reading about 배포판에 설치된 GCC 버전정보

pchero on 8월 31st, 2010

1. 공식 다운로드 페이지에서 ACE-5.5.tar.gz파일을 다운로드 받습니다. 2. 환경 변수를 설정합니다.(~/.bash_profile)  – ACE_ROOT=/home/k2/Apps/ACE_wrappers;export ACE_ROOT  – LD_LIBRARY_PATH=$ACE_ROOT/ace:$ACE_ROOT/lib:$LD_LIBRARY_PATH;     export LD_LIBRARY_PATH 3. $ACE_ROOT/ace에서 심볼릭 링크 추가합니다.  – ln -s config-linux.h config.h 4. $ACE_ROOT/include/makeinclude 에서 심볼릭 링크 추가합니다.  – ln -s platform_linux.GNU platform_macros.GNU 5. $ACE_ROOT/ace에서 make 6. 컴파일 제대로 되었는지 확인합니다.  – $ACE_ROOT/examples/Threads에서 make  – ./task_one 실행하면은 아래 [...]

Continue reading about ACE library 설치법..

 오늘 C++ 책에서 나온 소스코드를 컴파일하다 이상한 에러를 발견했다. 17-2.cpp:84: error: expected unqualified-id before numeric constant17-2.cpp:84: error: expected initializer before numeric constant  다음의 링크에서 해답을 찾을 수 있었다. http://bytes.com/topic/c/answers/752247-what-does-expected-unqualified-id-before-numeric-constant-mean All uppercase names are often used for preprocessor macros, which doesn’t respect namespace scopes. Therefore such names should generally be avoided for everything else.  즉 어디에선가 [...]

Continue reading about error: expected unqualified-id before numeric constant

pchero on 8월 11th, 2010

 KLDP 에서 자료를 검색하던 중 GDB와 관련된 매우 유용한 글타래를 발견하고 여기에 링크를 걸어둔다.  http://kldp.org/node/71806

Continue reading about GDB 사용 관련

 이 글은 http://wiki.kldp.org/KoreanDoc/Ulimit-KLDP (문태준님 작성, 2000년 2월 24일(목))을 토대로 필자가 나름 내용을 추가하여 작성하는 글이다.  최대한 원글의 내용을 그대로 유지하되, 이미 10년이란 세월이 흘렀으므로 많은 변화가 있었다. 워낙 중요하고 좋은 글이라 그냥 그대로 가져다 쓰려고 했으나, 뭔가 아쉬운 느낌이 들어 없는 실력이지만 약간의 보충을 덧붙여보기로 했다.   * 이 글은 실제로 제가 대형서버를 운영하고 있는 [...]

Continue reading about 시스템 최적화 – 동시사용자 늘리기 위한 커널 조정(ulimit)

pchero on 7월 10th, 2010

 * fwsnort 탐지와 psad 동작의 결합  fwsnort는 공격을 탐지하면 iptables 로그 메시지를 생성한다. 이 메시지는 사용자에게 해당 로그 메시지를 촉발한 스노트 규칙 ID, fwsnort 체인내의 규칙 번호, 패킷이 수립된 TCP 세션의 일부인지 여부를 알려주는 로그 접두어를 포함한다.  ** WEB-PHP Setup.php access 공격  스노트 규칙 ID 2281은 미디어위키 소프트웨어(원래는 위키피디아를 보조하기 위해 설계된 소프트웨어다. http://en.wikipedia.org/wiki/Mediawiki 참조)의 [...]

Continue reading about 11.psad와 fwsnort의 결합