« Previous : 1 : 2 : 3 : 4 : 5 : 6 : ... 22 : Next »
function mychk() {
return /\d/.test(String.fromCharCode(window.event.keyCode));
}


에서 window.event.keyCode라는것은 키가 눌렸을때 키값을 얻는거구요,
String.fromCharCode() 라는것은 키값에 해당하는 아스키값을 얻는겁니다.

예를들어 A키를 누르면 키코드가 65인데, fromCharCode()를 거치면 아스키문자인 A가 검출되는거죠.

그리고 test() 메소드는 매개변수를 정규식의 패턴인지 여부를 확인하여 불린값 true, false를 반환합니다.

\d는 정규식으로 숫자를 나타내구요,
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2006/12/19 14:09 2006/12/19 14:09
Response
No Trackback , No Comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/2161

/etc/passw파일에 정의되어 있는 모든 계정의 최근접속정보를 확인하는 명령어입니다.
주로 서버의 보안점검을 위하여 필수적으로 확인해보아야하는 명령어입니다.
간단히 lastlog라고만 하면 모든 계정의 마지막 접속정보를 출력해줍니다.

사용형식 lastlog [-u login-name] [-t days]

사용예 #1

간단히 lastlog라고만 하면 다음과 같이 서버의 모든 계정에 대한 최근접속정보를 확인할 수 있습니다.

[root@host3 bin]# lastlog
Username Port From Latest
root pts/1 192.168.0.2 금 10월 3 22:08:03 +0900 2003
bin **Never logged in**
daemon **Never logged in**
adm **Never logged in**
mysql **Never logged in**
[root@host3 bin]#

사용예 #2

만약 특정계정만의 최근접속정보를 확인하고자 한다면 다음과 같이 -u 옵션과 함께 사용하시면 됩니다.

[root@host3 bin]# lastlog -u bible
Username Port From Latest
bible pts/2 192.168.0.2 목 9월 18 23:44:18 +0900 2003
[root@host3 bin]#

사용예 #3

astlog는 최근 몇일까지의 마지막접속정보를 확인할 수도 있습니다. 다음은 최근 30일까지의 최근접속정보를 확인한 것입니다.

[root@host3 bin]# lastlog -t 30
Username Port From Latest
root pts/1 192.168.0.2 금 10월 3 22:08:03 +0900 2003
bible pts/2 192.168.0.2 목 9월 18 23:44:18 +0900 2003
bible1 pts/2 192.168.0.202 목 9월 18 23:46:11 +0900 2003
bible2 pts/3 192.168.0.111 목 9월 18 23:46:56 +0900 2003
[root@host3 bin]#
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2006/12/14 11:45 2006/12/14 11:45
Response
No Trackback , No Comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/2154

apache mod_rewrite 설치시 팁

mod_rewrite 설치시 도움 될만한 글입니다...
이것은 처음 설치용이 아닌 사용중 추가하는 방법입니다.

http://www.phpschool.com/gnuboard4/bbs/board.php?bo_table=tipntech&wr_id=18570

cd 아파치설치디렉토리/src/modules/standard
/usr/local/apache/apxs -c -I/usr/include/gdbm mod_rewrite.c
gcc -shared -o mod_rewrite.so mod_rewrite.o -lgdbm
/usr/local/apache/apxs -i mod_rewrite.so

vi /usr/local/apache/conf/httpd.conf
#------- 아래 부분 추가 -------
LoadModule rewrite_module libexec/mod_rewrite.so
Addmodule mod_rewrite.c
#------- 여기까지 ---------
/usr/local/apache/apachectl configtest
/usr/local/apache/apachectl restart
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2006/11/27 17:39 2006/11/27 17:39
Response
No Trackback , a comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/2120

웹서버 설치 및 구현 방법

http://www.phpschool.com/gnuboard4/bbs/board.php?bo_table=tipntech&wr_id=44276

1. 소개 : 웹서버 연동시 Apache, PHP, MySQL 연통설치하는데, 최적화된 서버 운영을 위해 추가로 Zend-Optimizer라 는 프로그램을 설치 할 수 있다.

2. 플렛폼 :OS :REDHAT 9(Linux)

3. 다운로드 사이트 :

MySQL : www.mysql.com
dev.mysql.com/get/Downloads/MySQL 다운로드 하면 된다.
Apache : www.apache.org
http://httpd.apache.org/
PHP : www.php.net
http://www.php.net/downloads.php
Zend-Optimizer : www.zend.com
http://www.zend.com/store/free_download.php
가입하면 자신의 메일로 가입허용이라는 메시지가 올 것이다.
클릭하면 된다.(즉 가입해야 다운 받을 수 있다.)

4. 압축 공통 방식 : tar.gz파일, tar.bz2파일

tar.gz 파일명
예 : tar zxvf mysql-standard-4.0.23-pc-linux-gnu-i686.tar.gz
tar.bz2 파일명
예 : tar jxvf mysql-standard-4.0.23-pc-linux-gnu-i686.tar.bz2

4개의 파일을 모두 압축을 풀어 줘야 한다. 그럼 각각의 디렉토리가 생성 될 것이다.


5. 기존의 인스톨된 apache제거하기 : rpm패키지로 설치되어 있는 아파치 웹서버 프로그램을 삭제 해야 한다. 그렇다고 꼭 해야 하는 것은 아 니지만 공간도 차지하고 서로 충돌이 생길 가능성을 배제하긴 어렵다. 최적화를 위한 작은 성의정도....

- 아파치 데몬을 정지 시킨다.

/etc/rc.d/init.d/httpd stop
설명 : 아파치 1.3버전은 apache라는 이름으로 설치되지만, 2.0버전은
httpd라는 이름으로 설치되므로 두가지 모두 검색해서 나오는 것을 삭제
- rpm으로 아파치 검색 또는 제거

rpm -qi | grep httpd -> 아파치의 정보를 볼때 사용한다.
즉 화면에 정보가 추출되면 설치 되어
있으므로 제거 하면 된다.
rpm -e httpd --nodeps -> 의존성관련된 패키지를 먼저 제거해주고
RPM 패키지를 제거 한다.
- PHP, MySQL도 위와 같은 방식으로 하면 된다.(응용이 될 거라 생각한다.)

6. MySQL 설치 하기

- mysql 소스파일의 압축을 푼 디렉토리로 이동한다.
cd /usr/local/src/cd mysql-standard-4.0.23-pc-linux-gnu-i686
- configure로 환경 설정 한다.
./configure --prefix=/usr/local/mysql --with-charset=euckr

설명 : --prefix는 인스톨한 기본 디렉토리를 지정하는 옵션이다.
--with-charset=ecukr은 한글을 지원한다는 뜻이다.
보통 소스파일에서 환경설정시에 configure를 사용하는데 configure와
관련된 옵션은 ./configure --help 하면 볼 수 있다.
기타 다른 옵션은 불 필요 하므로 사용자에 따라 정의 하면 된다.
- make : 소스이기 때문에 컴파일 과정이 필요하다.
- make install : 컴파일한 것을 실행시켜 설치한다.

7. mysql의 테스트

/usr/local/mysql/bin/mysql_install_db
설명 : 처음 설치시 한번 꼭 실행한다. 이작업은 mysql기본 데이터베이스
인 mysql과 testdb를 설치해준다.

/usr/local/mysql/bin/mysqld_safe --user=root &
설명 : 설치된 디렉토리로 이동하여 데몬을 띄운다.

/usr/local/mysql/bin/mysql
설명 : mysql 실행


8. apache 설치
설치될 디렉토리만 configure 한다.
- 아파치 압축을 푼 디렉토리로 이동한다.
- ./configure --prefix=/usr/local/apache --enable=-mods-shared=most --enable-module=so
설명 : prefix는 아파치가 설치될 디렉토리를 지정 하는 것이고,
--enable=-mods-shared=most --enable-module=so은 DSO 방식으로 PHP 모듈이 사용 될 수 있다.
DSO 동적 모듈로 설정 할 경우 PHP를 업데이트 할때 처음부터 재 설치 하지 않아도 된다.
make
make install

9. 환경 설정 파일 ( httpd.conf ) 설정
- /usr/local/apache/conf/httpd.conf 환경설정파일
설명 : 자신이 설치한 디렉토리 및에 conf폴더가 보일 것이다.
conf폴더 밑에 httpd.conf의 파일을 연다.
- vi httpd.conf
- /ServerName 항목을 찾는다.
설명 : IP 주소나 Domain Name을 적는다.

- php관련 환경 설정 : AddType이라는 항목이 모여있는 곳으로 이동한 뒤
아래와 같이 추가한다.
- AddType application/x-httpd-php .php .htm .html .inc .php5 .php4
- AddType application/x-httpd-php-source .phps
- DirectoryIndex index.html index.php index.htm
설명 : www.mass.com/index.php를 할 필요가 없이 www.mass.com 으로 웹 페이지를 로딩 한다.

10. PHP 설치

- PHP압축을 푼 디렉토리로 이동한다.
- ./configure --prefix=/usr/local/php \
설명 : prefix는 PHP가 설치될 디렉토리를 지정한다.
--with-apxs2=/usr/local/apache/bin/apxs \
설명 : --with-apxs2는 php가 아파치데몬에 DSO 모듈로 로딩 되도록 하기 위한 것이다.
--with-mysql=/usr/local/mysql/ \
설명 : mysql과 연동 하기 위한 설정 부분 이다.
--with-config-file-path=/usr/local/apache/conf \
설명 : php.ini 경로의 위치를 저정 하는 옵션 이다.
--with-exec-dir=/usr/local/apache/bin \
설명 : 아파치 데몬의 실행경로를 지정 한다.
--with-zlib --with-gd --with-ttf --with-png --with-jpeg-dir \
설명 : --with-zlib : zlib 는 zip 나 gzip 에 사용되고 있는 압축 알고리즘을 라이브러리화한 것이다.
--with-gd : GD에 있는 함수를 이용해서 이미지를 편집할 수 있는 라이브러리 이다.
--with-ttf ,--with-png, --with-jpeg-dir : 위와 동일하며 각각의 설정 이다.
--with-freetype-dir --with-gmp --with-xml --with-mod-charset \
--with-iconv \
--with-language=korean --enable-mbstr-enc-trans --enable-mbstring \
--enable-track-vars \
--enable-trans-sid \
설명 : --enable-track-vars는 HTTP_GET_VARS, HTTP_POST_VARS,
--enable-iconv
설명 : iconv라는 함수를 사용 하기 위해 iconv 라이브러리를 설정 한다.

- make
- make install
- cp php.ini-dist /usr/local/lib/php.ini
설명 : PHP의 환경설정파일인 php.ini를 라이브러리 디렉토리에 등록 시킨다.

모든 설치는 완료 된 것이다. 하지만 이렇게 한다고 웹 서버가 구축 된 것은
아니다 왜냐면 환경 설정 부분에서 조금 남아 있기 때문이다.
마무리 작업을 하도록 하겠다.

11. Zend-Optimizer 설치
- Zend-Optimizer 압축을 푼 디렉토리로 이동한다.
- ./install.sh을 실행하여 절차대로 설치한다.

12. 아파치 테스트

- 문서는 /usr/local/apache/htdocs/ 밑에 있다 모두 지우고 다시 만들어도
된다. 그러므로 자신이 원하는 이름으로 만들어 본다.
- index.html 문서에 아래와 같이 만든다.


리눅스 웹 서버 만들기

리눅스에 미치든가 아니면 하지 않는다.



리눅스를 자신의 것으로 만들면 된다.





13. 아파치와 PHP가 제대로 연동되는지 테스트

- test.php에 간단한 PHP문서를 이용하여 phpinfo()라는 PHP정보를 보여주는
함수를 이용해서 작성한 뒤에 웹상에서 불러오도록 한다.
- test.php 문서
php.info();
?>

- 웹상에서 실행 해본다.
예) 192.xxx.xxx.xx/test.php
DNS를 구축 했을 경우 : mass.com/test.php

- 실행 해보면 zend와 각종 관련 정보가 보일 것이다. 그럼 이제 부터 나머지는
각자의 노하우로 하면 된다.


14. 간단한 TIP

- /etc/hosts 네트워크 환경 설정 파일 이용하기
설명 : 많은 사람들은 웹 페이지에서 사이트를 입력 할때 문자로 입력하지
숫자로 입력 하지는 않 숫자로 입력 하지는 않는다. 바로 그 부분을 담당하는 것이라고 생각
하면 된다. 자신의 localhost가 192.33.23.xx이라면 아래와 같이 하면된다.

- vi /etc/hosts
- 192.33.23.xx www.mass.com mass
설명 : 이렇게 하면 telnet 192.123.23.xx 하지 않고
telnet mass 하면 해당 주소로 바인딩 된다.
- /etc/hosts 설명 : DNS 서버를 사용하기 이전에 사용하던 파일로 IP주소와
호스트이름을 매핑시켜 데이터베이스화해서 사용하는 파일이다.
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2006/11/27 17:25 2006/11/27 17:25
Response
No Trackback , No Comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/2119

APM 설치

APM 설치


PHP Version 4.3.3

Configure Command './configure' '--prefix=/usr/local/php' '--with-mysql=/usr/local/mysql' '--with-apxs2=/www/httpd/bin/apxs' '--with-charset=euc_kr' '--with-language=korean' '--enable-track-vars' '--with-gd' '--with-zlib' '--with-freetype2'

Configuration File (php.ini) Path /usr/local/php/lib/php.ini

Mysql

Client API version 4.0.16

MYSQL_INCLUDE -I/usr/local/mysql/include/mysql

Mysql -> ./configure --prefix=/usr/local/mysql --localstatedir=/usr/local/mysql/data --with-charset=euc_kr

Apache

Version Apache/2.0.47 (Unix) PHP/4.3.3

Server Root /www/httpd


PHP -> ./configure --with-apxs2=/www/httpd/bin/apxs --with-mysql=/usr/local/mysql --with-config-file-path=/www/httpd/conf --with-exec-dir=/www/httpd/bin --enable-track-vars --enable-trand-sid --with-gd=/usr/local/gd --with-freetype=/usr/local/freetype --with-xml --with-zlib --with-gmp --with-charset=euc_kr --with-iconv --enable-exif --with-tiff-dir=/usr/local/lib



sendmail

sendmail-8.12.5-7.i386.rpm
sendmail-cf-8.12.5-7.i386.rpm
sendmail-devel-8.12.5-7.i386.rpm
sendmail-doc-8.12.5-7.i386.rpm

DNS - Bind

bindconf-1.4-1
bind-utils-9.2.2-4kr
bind-devel-9.2.2-4kr
ypbind-1.7-6
bind-doc-9.2.2-4kr
bind-9.2.2-4kr
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2006/11/27 15:02 2006/11/27 15:02
Response
No Trackback , No Comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/2117

iconv

받기 경로 : http://ftp.gnu.org/pub/gnu/libiconv


#tar xzf liiconv-1.9.1.tar.gz
#cd libiconv-1.9.1
#./configure --prefix=/usr/lib //설치하고자 하는 디렉토리
#make
#make install
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2006/11/23 16:14 2006/11/23 16:14
Response
No Trackback , No Comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/2102

AWStats 웹상태 분석기

http://awstats.sourceforge.net




웹로그분석기 설치기 - Awstats


글쓴이 : 문용우 (2004년 03월 03일 오전 10:56)

수정이 : 김정언(2005년 8월 18일 오후 2:23)


####################################
# HowTo - Awstats 웹로그 분석 설치 #
# #
# 2004.03.03 linuxxer #
# 2005.08.21 jkim #

####################################

* Webalizer 를 많이 사용하시지만 awstats는 좀더 화려한(?) 인터페이스와다양한 정보를 제공해줍니다.


[목차]

1. 준비사항
2. Setup / Configure
3. Complete

4. 기타

5. 질의응답



1. 준비사항

프로젝트 싸이트 : http://awstats.sourceforge.net
다운로드 : awstats-6.4.tgz (2005년 8월 현재 stable한 버전)

웹로그분석이기 때문에 Web Server는 이미 설치가 되어 있어야 합니다.
( Apache 설치문서는 많이 있기 때문에 별도 설명을 하지 않음을 양해해 주시기 바랍니다. )

2. Setup / Configure

다운로드 받은 압축파일을 푸시면 docs 디렉토리안에 *.html 파일들이
Install 방법과 Plug-in사용법등 다양하게 정보를 같이 제공하고 있읍니다.
(프로젝트 홈페이지에 Install 방법 없읍니다.

꼭 *.html 을 보세요.

FAQ도 꼭 보기를 권합니다. 전부를 읽을 필요는 없지만 궁금해 하는 것에 대한 대다수의 해답을 찾을 수 있을 겁니다.

)



tar xvfz awstats-6.4.tgz
mv -rf awstats-6.4 /usr/local/awstats
chmod -R 755 /usr/local/awstats
mkdir /etc/awstats <- configuration 파일 저장위치
mkdir /var/lib/awstats <- 분석한 데이타 저장 위치

cd /usr/local/awstats/tools


./configure.pl <- awstats를 실행하는데 필요한 환경을 자동으로 만들어주기 위한 스크립트쯤으로 생각하면 됩니다.



(예)

[root@www tools]# ./awstats_configure.pl

----- AWStats awstats_configure 1.0 (build 1.4) (c) Laurent Destailleur -----
This tool will help you to configure AWStats to analyze statistics for
one web server. You can try to use it to let it do all that is possible
in AWStats setup, however following the step by step manual setup
documentation (docs/index.html) is often a better idea. Above all if:
- You are not an administrator user,
- You want to analyze downloaded log files without web server,
- You want to analyze mail or ftp log files instead of web log files,
- You need to analyze load balanced servers log files,
- You want to 'understand' all possible ways to use AWStats...
Read the AWStats documentation (docs/index.html).

-----> Running OS detected: Linux, BSD or Unix

-----> Check for web server install
Found Web server Apache config file '/usr/local/apache/conf/httpd.conf'

-----> Check and complete web server config file '/usr/local/apache/conf/httpd.conf'
Warning: You Apache config file contains directives to write 'common' log files
This means that some features can't work (os, browsers and keywords detection).
Do you want me to setup Apache to write 'combined' log files [y/N] ? y
Add 'Alias /awstatsclasses "/usr/local/awstats/wwwroot/classes/"'
Add 'Alias /awstatscss "/usr/local/awstats/wwwroot/css/"'
Add 'Alias /awstatsicons "/usr/local/awstats/wwwroot/icon/"'
Add 'ScriptAlias /awstats/ "/usr/local/awstats/wwwroot/cgi-bin/"'
Add '' directive
AWStats directives added to Apache config file.

-----> Update model config file '/usr/local/awstats/wwwroot/cgi-bin/awstats.model.conf'
File awstats.model.conf updated.

-----> Need to create a new config file ?
Do you want me to build a new AWStats config/profile
file (required if first install) [y/N] ? y

-----> Define config file name to create
What is the name of your web site or profile analysis ?
Example: www.mysite.com
Example: demo
Your web site, virtual server or profile name:
> www.sample.com

-----> Define config file path
In which directory do you plan to store your config file(s) ?
Default: /etc/awstats
Directory path to store config file(s) (Enter for default):
>

-----> Create config file '/etc/awstats/awstats.www.sample.com.conf'
Config file /etc/awstats/awstats.www.sample.com.conf created.

-----> Restart Web server with '/sbin/service httpd restart'
Stopping httpd: [ OK ]
Starting httpd: [ OK ]

-----> Add update process inside a scheduler
Sorry, configure.pl does not support automatic add to cron yet.
You can do it manually by adding the following command to your cron:
/usr/local/awstats/wwwroot/cgi-bin/awstats.pl -update -config=www.gamebonus.com
Or if you have several config files and prefer having only one command:
/usr/local/awstats/tools/awstats_updateall.pl now
Press ENTER to continue...


A SIMPLE config file has been created: /etc/awstats/awstats.www.gamebonus.com.conf
You should have a look inside to check and change manually main parameters.
You can then manually update your statistics for 'www.gamebonus.com' with command:
> perl awstats.pl -update -config=www.gamebonus.com
You can also read your statistics for 'www.gamebonus.com' with URL:
> http://localhost/awstats/awstats.pl?config=www.gamebonus.com

Press ENTER to finish...

[root@www tools]#



여기까지 잘 따라 하셨다면 에러가 없을겁니다.

configure.pl 을 잘 실행 시키셨다면 자신이 정한 name으로 awstats.[정한 name].conf 파일이 생성되어 있을겁니다.


이 파일을 열어 LogFile= 항목을 자신의 웹로그가 위치한 절대경로를 입력합니다.

(예)

LogFile="/var/log/httpd/mylog.log"

이것을

LogFile="[자신이 사용하는 웹서버의 access 로그]"


제가 사용하는 예를 보여드리면
LogFile="/usr/local/apache/logs/access_log"



/usr/local/awstats/tools/ 아래보시면 httpd_conf 파일이 있읍니다.
이 파일을 vi로 여셔서 내용전체를 웹서버가 설치된 conf/httpd.conf 파일의 맨 하단에
붙여넣으시면 됩니다.

:wq



awstats-6.4 설치시에는 httpd.conf 내에 자동으로 아래부분이 추가 되었습니다.

혹시 추가 되지 않았다면 시스템설정에 맞게 추가해주셔야합니다.

...
#
# Directives to allow use of AWStats as a CGI
#
Alias /awstatsclasses "/usr/local/awstats/wwwroot/classes/"
Alias /awstatscss "/usr/local/awstats/wwwroot/css/"
Alias /awstatsicons "/usr/local/awstats/wwwroot/icon/"
ScriptAlias /awstats/ "/usr/local/awstats/wwwroot/cgi-bin/"

#
# This is to permit URL access to scripts/files in AWStats directory.
#

Options None
AllowOverride None
Order allow,deny
Allow from all





3. Complete

간단하게 다 되었습니다 이제 웹브라우져로 확인을 해보겠습니다.

http://[웹서버]/awstats/awstats.pl?config=[자신이 정한 name]

한글화도 아주 잘 되어 있읍니다.

(설정파일에 language가auto로 되어 있어 사용자의 PC환경에 맞게 출력됩니다.)


자... 웹로그분석이니 Cron 작업도 빼 먹으면 안되겠죠?

vi /etc/crontab 하셔서
0-59/6 * * * * root /usr/local/awstats/wwwroot/cgi-bin/awstats.pl -update -config=[자신이 정한 name]

:wq

로그분석 시간간격은 조정하시면 됩니다.



4. 기타

4.1. config파일에 설정된 기본 로그파일이 아닌 백업받아놓은 임의의 파일을 분석하고자 할 때는 다음과 같이 -LogFile 옵션으로 해결할 수 있다.

/usr/local/awstats/wwwroot/cgi-bin/awstats.pl -update -config=www.sample.com -LogFile=/usr/local/apache/logs/www.sample.com-access_log.1



4.1. DNS REVERSE LOOKUP

awstats 배포할 때 같이 배포되는 logresolvemerge.pl 로 접속하는 ip를 hostname으로 reverse lookup 할 수있다.

/usr/local/awstats/tools/logresolvemerge.pl -dnslookup

하면 간단한 설명을 볼 수 있다.



(예1) 백업되어 있는 로그파일을 pipe를 통해 분석한다.

/usr/local/awstats/wwwroot/cgi-bin/awstats.pl -update -config=www.sample.com -LogFile="/usr/local/awstats/tools/logresolvemerge.pl -dnslookup ./www.sample.com-access_log |"



(예2)백업되어 있는 로그파일을 pipe를 통해 분석한다.
/usr/local/awstats/wwwroot/cgi-bin/awstats.pl -update -config=www.sample.com -LogFile="/usr/local/awstats/tools/logresolvemerge.pl -dnslookup ./www.sample.com-access_log.1 |"
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2006/10/20 18:48 2006/10/20 18:48
Response
No Trackback , No Comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/2041

/etc/initab - 시작할때

/etc/initab - 시작할때
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2006/03/23 17:00 2006/03/23 17:00
Response
No Trackback , No Comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/1663

도메인 네임서버 변경후
도메인이 업데이트 되는 사이 사이트를 확인하고 싶을 경우

C:\WINDOWS\system32\drivers\etc\hosts

해당파일을 메모장등의 편집기를 이용하여서 편집한다.

# Copyright (c) 1993-1999 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host

127.0.0.1 localhost

201.124.107.*** ngio.co.kr
201.124.107.*** www.ngio.co.kr

이것처럼 해당 사이트 도메인과 아이피를 입력해주면
새로 셋팅된 서버 IP로 바로 접근해서 사이트를 볼수 있다.

그리고, 확인이 끝나면
해당 설정 앞에 # 으로 주석처리하면 되시겠다.

ex) #201.124.107.*** ngio.co.kr
#201.124.107.*** www.ngio.co.kr
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2005/11/16 17:58 2005/11/16 17:58
Response
No Trackback , No Comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/1393

방화벽 설정 - /usr/sbin/lokkit

실행 프로그램 : /usr/sbin/lokkit



리눅스 서버의 방화벽 설정에 대한 것이다.

이 설정은 lokkit이라는 프로그램으로 수행이 되며 독립적인 실행또한 가능하다.



방화벽이라고 하면 괜히 어렵게 생각하기 쉬우나, 간단히 개념정리를 하자면, 현재 운용중인 서버의 접근허용에 대한 설정을 한다고 생각하면 된다.

즉, 서버에서 사용중인 여러개의 포트(port) 및 서비스들에 대한 접근허용과 거부에 대한 설정을 하는 것이다.

간단한 예로서 tcpwrapper를 들 수 있다.

이것은 /etc/hosts.allow와 /etc/hosts.deny를 파일을 통해서 각 서비스들(telnet, pop, ftp, ssh등)에 대한 접근설정을 할 수 있는 것으로 원격로그인시에 이 파일을 먼저 읽어서 접근권한을 부여받고서 로그기록(/var/log/secure)을 한 다음 각 서비스들과 세션을 맺도록(연결)한다.

이런 설정을 할 것인지 말 것인지에 대한 설정을 여기서 하게되는 것이다.



또한 setup의 초기 화면에서 Firewall configuration을 통해서도 동일한 실행이 가능하다.



여기서는 보안 레벨을 선택해야하는데, 3가지 보안레벨은 다음과 같다.

High : 모든 접근시도에 대해서 브락킹(blocking)을 하게된다.
Medium : telnet과 printing등에 대한 접근은 블락킹(blocking)을 하고 그외의 접근에 대해서는 허용을 한다.
No firewall : 모든 접근에 대해서 허용하며 이 설정은 권하지 않는다.
위의 3가지 모드중 서버에 보안설정에 자신이 없으신 분은 Medium으로 설정하도록 하자.

High로 설정해 두면 원격접근이 자신조차도 어려울 수가 있으며, No firewall을 선택하면 보안이 위협받을 수도 있기 때문이다.

크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기

Posted by 홍반장

2005/11/15 09:36 2005/11/15 09:36
Response
No Trackback , No Comment
RSS :
http://tcbs17.cafe24.com/tc/rss/response/1389

« Previous : 1 : 2 : 3 : 4 : 5 : 6 : ... 22 : Next »

블로그 이미지

- 홍반장

Archives

Recent Trackbacks

Calendar

«   2024/04   »
  1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30        
Statistics Graph

Site Stats

Total hits:
181122
Today:
1
Yesterday:
209