No Image

tcp-wrapper on proftpd (using mod_wrap2, mod_wrap2_file)

2016-04-18 KENNETH 0

tcp-wrapper on proftpd (using mod_wrap2, mod_wrap2_file) 개요 proftpd 를 컴파일 해서 사용 중 iptables 말고 tcp-wrapper 를 이용해서 접근제어를 하고 싶음 그러면서 ftp접근을 모두 막되… 내가 열어주고 싶은 아이피 주소에 대해서만 허용을 하고 싶음 centos, ubuntu 등에서 사용가능한(할지도모르는) proftpd 패키지는 테스트를 안함… 갸들은 아마 되겠지… 설마… 컴파일 하는 환경에서 쓸모 있는 정보… 허용하고 싶은 아이피 주소 : 192.168.100.200     설치 require : proftpd-1.3.3 or higher 였던가.. ??;;;; configure –with-shared=mod_wrap2:mod_wrap2_file –enable-wrapper-options 당신이 만약 다른 옵션들을 사용하고 있다 하더라도 컴파일시  ”–with-shared=mod_wrap2:mod_wrap2_file –enable-wrapper-options” 옵션만 들어가 있으면 됨 mod_wrap2, mod_wrap2_file 이라는 모듈이 추가로 필요하기 때문   설정 proftpd 설정 파일명 : proftpd.conf LoadModule mod_wrap2.c LoadModule mod_wrap2_file.c WrapEngine on WrapServiceName proftpd WrapTables file:/etc/hosts.allow file:/etc/hosts.deny   접근제어 설정 우선 차단.. 파일명 : /etc/hosts.deny ALL:ALL 로 쿨하게 막아버리자…   그다음 허용.. 파일명 : /etc/hosts.allow proftpd:192.168.100.200   끝… 그 외에.. 차단메세지 설정등의 옵션도 있으나.. 난 그런건 안좋아함.. [ more… ]

No Image

Appendix D: Java Programming Cheatsheet

2016-04-14 KENNETH 0

  출처 : http://introcs.cs.princeton.edu/java/11cheatsheet/ Appendix D:   Java Programming Cheatsheet This appendix summarizes the most commonly-used Java language features in the textbook. Here are the APIs of the most common libraries. Hello, World. Editing, compiling, and executing. Built-in data types. Declaration and assignment statements. Integers. Floating-point numbers. Booleans. Comparison operators. Printing. Parsing command-line arguments. Math library. The full java.lang.Math API. Java library calls. Type conversion. If and if-else statements. Nested if-else statement. While loops. For loops. Loops. Break statement. Do-while loop. Switch statement. Arrays. Inline array initialization. Typical array-processing code. Two-dimensional arrays. Inline initialization. Our standard output library. The full StdOut API. Our standard input library. The full StdIn API. Our standard drawing library. The full StdDraw API. Our standard audio library. The full StdAudio API. Redirection and piping.                Functions. Libraries of functions. Our standard random library. Our [ more… ]

No Image

USE Method: Linux Performance Checklist

2016-04-05 KENNETH 0

출처 : http://www.brendangregg.com/USEmethod/use-linux.html   USE Method: Linux Performance Checklist The USE Method provides a strategy for performing a complete check of system health, identifying common bottlenecks and errors. For each system resource, metrics for utilization, saturation and errors are identified and checked. Any issues discovered are then investigated using further strategies. This is an example USE-based metric list for Linux operating systems (eg, Ubuntu, CentOS, Fedora). This is primarily intended for system administrators of the physical systems, who are using command line tools. Some of these metrics can be found in remote monitoring tools. Physical Resources component type metric CPU utilization system-wide: vmstat 1, ”us” + ”sy” + ”st”; sar -u, sum fields except ”%idle” and ”%iowait”; dstat -c, sum fields except ”idl” and ”wai”; per-cpu: mpstat -P ALL 1, sum fields except ”%idle” and ”%iowait”; sar -P ALL, same as [ more… ]

No Image

mysql error : No data – zero rows fetched, selected, or processed

2016-04-05 KENNETH 0

프로시저를 생성해놓고 호출시에.. No data – zero rows fetched, selected, or processed 에러가 발생하는 경우가 있음. DECLARE CONTINUE HANDLER FOR NOT FOUND SET done = 1; 구문을 프로시저에 추가해주면 된다고함… (이것은 내가 테스트 해본것은 아님.. 귀찮기도 하고.. ) 실사용은 아래 내용을 참고할 것 PS. mysql-5.6 으로 업데이트 하는 방법도 있다고함 (역시 내가 테스트 해본것은 아님.. 귀찮기도 했고.. ) 참고 : https://jirak.net/wp/mysql-fetch-cursor-%eb%ac%b8-%ec%82%ac%ec%9a%a9%eb%b0%a9%eb%b2%95/

No Image

MySQL Fetch Cursor 문 사용방법

2016-04-05 KENNETH 1

출처 : http://bizadmin.tistory.com/entry/MySQL-Fetch-Cursor-%EB%AC%B8-%EC%82%AC%EC%9A%A9%EB%B0%A9%EB%B2%95 작성자 : 불가사리 bluemount 아래 내용은 ”http://bizadmin.tistory.com/”에서 발췌한 내용입니다.   Mysql에서 커서(Fetch Cursor)를 사용할 때 아래와 같은 경고메세지를 얻는 경우가 있다. 1329: No data – zero rows fetched, selected, or processed 무슨 이유인지 커서가 다 돌지를 않고 중간에 멈춘거 같은 것을 보고 역시  Mysql 은 믿을 수가 없어 그런 느낌을 갖기도 했지만 역시 믿을 수 없는 건 나의 실력이었다. Mysql 의 커서(Cursor)를 충분히 분석하고 기능을 알아보려 한다. 커서는 기본적으로 커서(Cursor)를 돌면 어떤 데이타를 처리하는 것이 목적이다. 간단한 예제 수준만 알아서 해결이 안되는 경우 아래의 내용을 검토해 보자. 1. Fetch Cursor 기본 구조  : 아주 기초적 구조다. 이해가 안되면 외어라. CREATE PROCEDURE curdemo() BEGIN DECLARE done INT DEFAULT FALSE; DECLARE vRowCount INT DEFAULT 0 ; DECLARE vUserID varchar(20);   — 커서로 만들 데이타 값들 DECLARE cur1 CURSOR FOR SELECT Userid FROM Member;   — 커서가 마지막에 도착할 때의 상태값 DECLARE CONTINUE HANDLER [ more… ]