« Previous : 1 : 2 : 3 : 4 : 5 : ... 13 : Next »
출처 (네이버 번역):  http://j2k.naver.com/j2k_frame.php/korean/www-06.ibm.com/jp/domino01/mkt/cnpages7.nsf/page/default-002CC43F

원문 출처 : http://www-01.ibm.com/support/docview.wss?uid=std7f7e24f944e3f7e8149257340002cc43f

추가 문서 : http://www.westnet.com/~gsmith/content/linux-pdflush.htm

해당 문서의 저작권은 IBM 에게 있습니다. 사용자의 요청이 있을경우 자삭 합니다.

Kernel 2.6의VM tunables

Kernel 2.6에 두어 더티 페이지의 플래시 폴리시에 영향을 주는 중요한 파라미터에 대해 해설합니다.


내용/목차


메모리 부하와I/O부하가 동시에 높아지는 서버에 대하고, 한편에서는 파일I/O에 의해 페이지 캐쉬가 다량의 메모리를 소비해, 한편으로 메모리가 요구될 때 마다 매회 캐쉬의 플래시와 페이지의 해방 처리의 오버헤드가 발생하고 퍼포먼스가 저하하는 경우가 있습니다.그러한 예로서는, 클라이언트수가 매우 많이I/O부하도 높은, 대규모HPC클러스터내의NFS서버등을 들 수 있습니다.

이러한 경우에, 페이지 캐쉬의 메모리 사용량을 의도적으로 적게 억제하는 것으로 상기와 같은 메모리 컨텐션 상태를 회피해, 전체적으로도 퍼포먼스를 개선할 수 있는 경우가 있습니다.

종래의Kernel 2.4그럼proc파일 시스템의bdflush그렇다고 하는 파일(/proc/sys/vm/bdflush)(이)가, 버퍼 캐쉬의 플래시 빈도를 컨트롤 하는 인터페이스로서 존재하고 있었습니다만,Kernel 2.6그럼 이 인터페이스는 철폐되었습니다.그 대신에,proc파일 시스템에 아래와 같은 4개의 파일이 준비되어 이전과 제어의 방법은 다릅니다만 같은 목적을 달성할 수 있습니다.아래와 같은 파일은 모두 /proc/sys/vm 디렉토리에 존재합니다.

dirty_background_ratio
----------------------
전메모리에 대한 더티 페이지(*)의 비율이 이 퍼센티지에 이르면,pdflushdemon가 눈을 떠 페이지 해방의 처리를 개시합니다.디폴트는10(%)입니다.

*: 메모리상에서 내용이 갱신되었지만 아직 디스크에 써지지 않은 페이지.플래시(=디스크에 써) 되면 「클린 페이지」가 되어, 인 액티브하고 깨끗한 페이지는 곧바로 다른 용도에 재이용할 수 있습니다.

dirty_ratio
-----------------
전메모리에 대한 더티 페이지의 비율이 이 퍼센티지에 이르면, 눈을 떴다pdflush하지만 실제로 더티 페이지의 서두 처리를 개시합니다.이 값을 통상보다 낮게 설정하는 것으로, 어느 일시점으로 메모리상에 존재하는 더티 페이지의 양을 적게 억제할 수가 있습니다.디폴트는40(%)입니다.

dirty_writeback_centisecs
-------------------------
pdflushdemon는 정기적으로 눈을 떠 낡은 데이터를 디스크에 써냅니다.그 시간 간격을1/100초단위로 지정합니다.디폴트는500, 즉 5초간격입니다.

dirty_expire_centisecs
----------------------
더티 페이지가 「더티」가 되고 나서 이 파라미터로 지정한 시간만 경과하면,pdflushdemon는 그 더티 페이지를 「낡은 데이터」라고 간주라고 디스크에의 서두의 대상으로 합니다.이것도1/100초단위로 지정합니다.디폴트는3000, 즉30초입니다.이것에 작은 값을 설정하면 그 만큼 빨리 더티 페이지가 플래시 되게 되어, 더티 페이지의 감소에 기여합니다.

주의: 상기의 파라미터를 변경하는 것으로 실제로 어느 정도 퍼포먼스가 향상할까는 서버의 구성, 서비스나 어플리케이션의 특성 등에 크게 의존하기 때문에, 통틀어 몇%라고 하는 것은 말할 수 없습니다.실제의 환경에 있어Trial&Error그리고 실험적으로 최적치를 발견하도록 해 주세요.


문서 정보
유효기간: 2009년8월23일




본문서에 대해
본문서에서는,IBM제품에 대해Linux(을)를 사용하는데 있어서 유용이라고 생각되는 기술 정보나Hints&Tips(을)를 제공하겠습니다. 본문서의 정보는, 한정된 검증 환경에 있어서의 결과에 근거하는 것이어, 모든 환경에서 동일한 결과를 보증하는 것이 아닙니다. 본문서의 정보에 근거해 도입·설정이 실시되는 경우에는, 충분한 검증 테스트를 실시해 주세요.또, 미리 각사보다 제공되는 정보 및 제품의 메뉴얼을 봐 주세요.
본문서의 정보에 근거해 도입·설정·운용한 결과에 대해서,IBM(은)는 어떠한 보증도 책임도 지기 어려우므로 미리 양해 바랍니다.


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

Posted by 삐꾸강아쥐

2008/12/09 23:17 2008/12/09 23:17
, ,
Response
0 Trackbacks , 0 Comments
RSS :
http://blog.blog.n-nuri.com/rss/response/585

Trackback URL : http://blog.blog.n-nuri.com/trackback/585

Leave a comment
[로그인][오픈아이디란?]

Squid.conf document

Sponsors

Introduction

Two important goals of many small businesses are to:

  • Reduce Internet bandwidth charges
  • Limit access to the Web to only authorized users.

The Squid web caching proxy server can achieve both these goals fairly easily.

Users configure their web browsers to use the Squid proxy server instead of going to the web directly. The Squid server then checks its web cache for the web information requested by the user. It will return any matching information that finds in its cache, and if not, it will go to the web to find it on behalf of the user. Once it finds the information, it will populate its cache with it and also forward it to the user's web browser.

As you can see, this reduces the amount of data accessed from the web. Another advantage is that you can configure your firewall to only accept HTTP web traffic from the Squid server and no one else. Squid can then be configured to request usernames and passwords for each user that users its services. This provides simple access control to the Internet.

Download and Install The Squid Package

Most RedHat Linux software products are available in the RPM format. Downloading and installing RPMs isn't hard. If you need a refresher, Chapter 6, "Installing Linux Software", provides details. It is best to use the latest version of Squid.

Starting Squid

Use the chkconfig configure Squid to start at boot::

[root@bigboy tmp]# chkconfig squid on

Use the service command to start, stop, and restart Squid after booting:

[root@bigboy tmp]# service squid start
[root@bigboy tmp]# service squid stop
[root@bigboy tmp]# service squid restart

You can test whether the Squid process is running with the pgrep command:

[root@bigboy tmp]# pgrep squid

You should get a response of plain old process ID numbers.

The /etc/squid/squid.conf File

The main Squid configuration file is squid.conf, and, like most Linux applications, Squid needs to be restarted for changes to the configuration file can take effect.

The Visible Host Name

Squid will fail to start if you don't give your server a hostname. You can set this with the visible_hostname parameter. Here, the hostname is set to the real name of the server bigboy.

visible_hostname bigboy

Access Control Lists

You can limit users' ability to browse the Internet with access control lists (ACLs). Each ACL line defines a particular type of activity, such as an access time or source network, they are then linked to an http_access statement that tells Squid whether or not to deny or allow traffic that matches the ACL.

Squid matches each Web access request it receives by checking the http_access list from top to bottom. If it finds a match, it enforces the allow or deny statement and stops reading further. You have to be careful not to place a deny statement in the list that blocks a similar allow statement below it. The final http_access statement denies everything, so it is best to place new http_access statements above it

Note: The very last http_access statement in the squid.conf file denies all access. You therefore have to add your specific permit statements above this line. In the chapter's examples, I've suggested that you place your statements at the top of the http_access list for the sake of manageability, but you can put them anywhere in the section above that last line.

Squid has a minimum required set of ACL statements in the ACCESS_CONTROL section of the squid.conf file. It is best to put new customized entries right after this list to make the file easier to read.

Restricting Web Access By Time

You can create access control lists with time parameters. For example, you can allow only business hour access from the home network, while always restricting access to host 192.168.1.23.

#
# Add this to the bottom of the ACL section of squid.conf
#
acl home_network src 192.168.1.0/24
acl business_hours time M T W H F 9:00-17:00
acl RestrictedHost src 192.168.1.23

#
# Add this at the top of the http_access section of squid.conf
#
http_access deny RestrictedHost
http_access allow home_network business_hours

Or, you can allow morning access only:

#
# Add this to the bottom of the ACL section of squid.conf
#
acl mornings time 08:00-12:00

#
# Add this at the top of the http_access section of squid.conf
#
http_access allow mornings

Restricting Access to specific Web sites

Squid is also capable of reading files containing lists of web sites and/or domains for use in ACLs. In this example we create to lists in files named /usr/local/etc/allowed-sites.squid and /usr/local/etc/restricted-sites.squid.

# File: /usr/local/etc/allowed-sites.squid
www.openfree.org
linuxhomenetworking.com

# File: /usr/local/etc/restricted-sites.squid
www.porn.com
illegal.com

These can then be used to always block the restricted sites and permit the allowed sites during working hours. This can be illustrated by expanding our previous example slightly.

#
# Add this to the bottom of the ACL section of squid.conf
#
acl home_network src 192.168.1.0/24
acl business_hours time M T W H F 9:00-17:00
acl GoodSites dstdomain "/usr/local/etc/allowed-sites.squid"
acl BadSites dstdomain "/usr/local/etc/restricted-sites.squid"

#
# Add this at the top of the http_access section of squid.conf
#
http_access deny BadSites
http_access allow home_network business_hours GoodSites

Restricting Web Access By IP Address

You can create an access control list that restricts Web access to users on certain networks. In this case, it's an ACL that defines a home network of 192.168.1.0.

#
# Add this to the bottom of the ACL section of squid.conf
#
acl home_network src 192.168.1.0/255.255.255.0

You also have to add a corresponding http_access statement that allows traffic that matches the ACL:

#
# Add this at the top of the http_access section of squid.conf
#
http_access allow home_network

Password Authentication Using NCSA

You can configure Squid to prompt users for a username and password. Squid comes with a program called ncsa_auth that reads any NCSA-compliant encrypted password file. You can use the htpasswd program that comes installed with Apache to create your passwords. Here is how it's done:

1) Create the password file. The name of the password file should be /etc/squid/squid_passwd, and you need to make sure that it's universally readable.

[root@bigboy tmp]# touch /etc/squid/squid_passwd
[root@bigboy tmp]# chmod o+r /etc/squid/squid_passwd

2) Use the htpasswd program to add users to the password file. You can add users at anytime without having to restart Squid. In this case, you add a username called www:

[root@bigboy tmp]# htpasswd /etc/squid/squid_passwd www
New password:
Re-type new password:
Adding password for user www
[root@bigboy tmp]#

3) Find your ncsa_auth file using the locate command.

[root@bigboy tmp]# locate ncsa_auth
/usr/lib/squid/ncsa_auth
[root@bigboy tmp]#

4) Edit squid.conf; specifically, you need to define the authentication program in squid.conf, which is in this case ncsa_auth. Next, create an ACL named ncsa_users with the REQUIRED keyword that forces Squid to use the NCSA auth_param method you defined previously. Finally, create an http_access entry that allows traffic that matches the ncsa_users ACL entry. Here's a simple user authentication example; the order of the statements is important:

#
# Add this to the auth_param section of squid.conf
#
auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/squid_passwd

#
# Add this to the bottom of the ACL section of squid.conf
#
acl ncsa_users proxy_auth REQUIRED

#
# Add this at the top of the http_access section of squid.conf
#
http_access allow ncsa_users

5) This requires password authentication and allows access only during business hours. Once again, the order of the statements is important:

#
# Add this to the auth_param section of squid.conf
#
auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/squid_passwd

#
# Add this to the bottom of the ACL section of squid.conf
#
acl ncsa_users proxy_auth REQUIRED
acl business_hours time M T W H F 9:00-17:00

#
# Add this at the top of the http_access section of squid.conf
#
http_access allow ncsa_users business_hours

Remember to restart Squid for the changes to take effect.

Forcing Users To Use Your Squid Server

If you are using access controls on Squid, you may also want to configure your firewall to allow only HTTP Internet access to only the Squid server. This forces your users to browse the Web through the Squid proxy.

Making Your Squid Server Transparent To Users

It is possible to limit HTTP Internet access to only the Squid server without having to modify the browser settings on your client PCs. This called a transparent proxy configuration. It is usually achieved by configuring a firewall between the client PCs and the Internet to redirect all HTTP (TCP port 80) traffic to the Squid server on TCP port 3128, which is the Squid server's default TCP port.

Squid Transparent Proxy Configuration

Your first step will be to modify your squid.conf to create a transparent proxy. The procedure is different depending on your version of Squid.

Prior to version 2.6: In older versions of Squid, transparent proxy was achieved through the use of the httpd_accel options which were originally developed for http acceleration. In these cases, the configuration syntax would be as follows:

httpd_accel_host virtual
httpd_accel_port 80
httpd_accel_with_proxy on
httpd_accel_uses_host_header on

Version 2.6 and Beyond: Newer versions of Squid simply require you to add the word "transparent" to the default "http_port 3128" statement. In this example, Squid not only listens on TCP port 3128 for proxy connections, but will also do so in transparent mode.

http_port 3128 transparent

Configuring iptables to Support the Squid Transparent Proxy

The examples below are based on the discussion of Linux iptables in Chapter 14, "Linux Firewalls Using iptables". Additional commands may be necessary for you particular network topology.

In both cases below, the firewall is connected to the Internet on interface eth0 and to the home network on interface eth1. The firewall is also the default gateway for the home network and handles network address translation on all the network's traffic to the Internet.

Only the Squid server has access to the Internet on port 80 (HTTP), because all HTTP traffic, except that coming from the Squid server, is redirected.

If the Squid server and firewall are the same server, all HTTP traffic from the home network is redirected to the firewall itself on the Squid port of 3128 and then only the firewall itself is allowed to access the Internet on port 80.

iptables -t nat -A PREROUTING -i eth1 -p tcp --dport 80 \
-j REDIRECT --to-port 3128
iptables -A INPUT -j ACCEPT -m state \
--state NEW,ESTABLISHED,RELATED -i eth1 -p tcp \
--dport 3128
iptables -A OUTPUT -j ACCEPT -m state \
--state NEW,ESTABLISHED,RELATED -o eth0 -p tcp \
--dport 80
iptables -A INPUT -j ACCEPT -m state \
--state ESTABLISHED,RELATED -i eth0 -p tcp \
--sport 80
iptables -A OUTPUT -j ACCEPT -m state \
--state ESTABLISHED,RELATED -o eth1 -p tcp \
--sport 80

Note: This example is specific to HTTP traffic. You won't be able to adapt this example to support HTTPS web browsing on TCP port 443, as that protocol specifically doesn't allow the insertion of a "man in the middle" server for security purposes. One solution is to add IP masquerading statements for port 443, or any other important traffic, immediately after the code snippet. This will allow non HTTP traffic to access the Internet without being cached by Squid.

If the Squid server and firewall are different servers, the statements are different. You need to set up iptables so that all connections to the Web, not originating from the Squid server, are actually converted into three connections; one from the Web browser client to the firewall and another from the firewall to the Squid server, which triggers the Squid server to make its own connection to the Web to service the request. The Squid server then gets the data and replies to the firewall which then relays this information to the Web browser client. The iptables program does all this using these NAT statements:

iptables -t nat -A PREROUTING -i eth1 -s ! 192.168.1.100 \
-p tcp --dport 80 -j DNAT --to 192.168.1.100:3128
iptables -t nat -A POSTROUTING -o eth1 -s 192.168.1.0/24 \
-d 192.168.1.100 -j SNAT --to 192.168.1.1
iptables -A FORWARD -s 192.168.1.0/24 -d 192.168.1.100 \
-i eth1 -o eth1 -m state
--state NEW,ESTABLISHED,RELATED \
-p tcp --dport 3128 -j ACCEPT
iptables -A FORWARD -d 192.168.1.0/24 -s 192.168.1.100 \
-i eth1 -o eth1 -m state --state ESTABLISHED,RELATED \
-p tcp --sport 3128 -j ACCEPT

In the first statement all HTTP traffic from the home network except from the Squid server at IP address 192.168.1.100 is redirected to the Squid server on port 3128 using destination NAT. The second statement makes this redirected traffic also undergo source NAT to make it appear as if it is coming from the firewall itself. The FORWARD statements are used to ensure the traffic is allowed to flow to the Squid server after the NAT process is complete. The unusual feature is that the NAT all takes place on one interface; that of the home network (eth1).

You will additionally have to make sure your firewall has rules to allow your Squid server to access the Internet on HTTP TCP port 80 as covered in Chapter 14, "Linux Firewalls Using iptables".

Manually Configuring Web Browsers To Use Your Squid Server

If you don't have a firewall that supports redirection, then you need to configure your firewall to only accept HTTP Internet access from the Squid server, as well as configure your PC browser's proxy server settings manually to use the Squid server. The method you use depends on your browser.

For example, to make these changes using Internet Explorer

  1. Click on the "Tools" item on the menu bar of the browser.
  2. Click on "Internet Options"
  3. Click on "Connections"
  4. Click on "LAN Settings"
  5. Configure with the address and TCP port (3128 default) used by your Squid server.

Here's how to make the same changes using Mozilla or Firefox.

  1. Click on the "Edit" item on the browser's menu bar.
  2. Click on "Preferences"
  3. Click on "Advanced"
  4. Click on "Proxies"
  5. Configure with the address and TCP port (3128 default) used by your Squid server under "Manual Proxy Configuration"

Squid Disk Usage

Squid uses the /var/spool/squid directory to store its cache files. High usage squid servers need a large amount of disk space in the /var partition to get optimum performance.

Every webpage and image accessed via the Squid server is logged in the /var/log/squid/access.log file. This can get quite large on high usage servers. Fortunately, the logrotate program automatically purges this file.

Troubleshooting Squid

Squid logs both informational and error messages to files in the /var/log/squid/ directory. It is best to review these files first whenever you have difficulties.The squid.out file can be especially useful as it contains Squids' system errors.

Another source of errors could be unintended statements in the squid.conf file that cause no errors; mistakes in the configuration of hours of access and permitted networks that were forgotten to be added are just two possibilities.

By default, Squid operates on port 3128, so if you are having connectivity problems, you'll need to follow the troubleshooting steps in Chapter 4, "Simple Network Troubleshooting", to help rectify them.

Note: Some of Squid's capabilities go beyond the scope of this book, but you should be aware of them. For example, for performance reasons, you can configure child Squid servers on which certain types of content are exclusively cached. Also, you can restrict the amount of disk space and bandwidth Squid uses.

Conclusion

Tools such as Squid are popular with many company mangers. By caching images and files on a server shared by all, Internet bandwidth charges can be reduced.

Squid's password authentication feature is well liked because it allows only authorized users to access the Internet as a means of reducing usage fees and distractions in the office. Unfortunately, an Internet access password is usually not viewed as a major security concern by most users who are often willing to share it with their colleagues. Although it is beyond the scope of this book, you should consider automatically tying the Squid password to the user's regular login password. This will make them think twice about giving their passwords away. Internet access is one thing, letting your friends have full access to your e-mail and computer files is quite another.

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

Posted by 삐꾸강아쥐

2008/12/04 13:31 2008/12/04 13:31
,
Response
0 Trackbacks , 0 Comments
RSS :
http://blog.blog.n-nuri.com/rss/response/583

Trackback URL : http://blog.blog.n-nuri.com/trackback/583

Leave a comment
[로그인][오픈아이디란?]

Taking a Backup Using Snapshots

출처 : http://tldp.org/HOWTO/LVM-HOWTO/snapshots_backup.html#snapbackcreate

사용자(작성자) 요청이 있을경우 자삭 합니다.


Taking a Backup Using Snapshots

Following on from the previous example we now want to use the extra space in the "ops" volume group to make a database backup every evening. To ensure that the data that goes onto the tape is consistent we use an LVM snapshot logical volume.

A snapshot volume is a special type of volume that presents all the data that was in the volume at the time the snapshot was created. For a more detailed description, see Section 3.8, Snapshots. This means we can back up that volume without having to worry about data being changed while the backup is going on, and we don't have to take the database volume offline while the backup is taking place.

Note

In LVM1, this type of volume was read-only, but LVM2 creates read/write snapshots by default.

13.4.1. Create the snapshot volume

There is a little over 500 Megabytes of free space in the "ops" volume group, so we will use all of it to allocate space for the snapshot logical volume. A snapshot volume can be as large or a small as you like but it must be large enough to hold all the changes that are likely to happen to the original volume during the lifetime of the snapshot. So here, allowing 500 megabytes of changes to the database volume which should be plenty.

# lvcreate -L592M -s -n dbbackup /dev/ops/databases 
lvcreate -- WARNING: the snapshot must be disabled if it gets full
lvcreate -- INFO: using default snapshot chunk size of 64 KB for "/dev/ops/dbbackup"
lvcreate -- doing automatic backup of "ops"
lvcreate -- logical volume "/dev/ops/dbbackup" successfully created


WarningFull snapshot are automatically disabled
 

If the snapshot logical volume becomes full it will be dropped (become unusable) so it is vitally important to allocate enough space. The amount of space necessary is dependent on the usage of the snapshot, so there is no set recipe to follow for this. If the snapshot size equals the origin size, it will never overflow.

13.4.2. Mount the snapshot volume

We can now create a mount-point and mount the volume

# mkdir /mnt/ops/dbbackup
# mount /dev/ops/dbbackup /mnt/ops/dbbackup

mount: block device /dev/ops/dbbackup is write-protected, mounting read-only

If you are using XFS as the filesystem you will need to add the nouuid option to the mount command:

# mount /dev/ops/dbbackup /mnt/ops/dbbackup -onouuid,ro

13.4.3. Do the backup

I assume you will have a more sophisticated backup strategy than this!

# tar -cf /dev/rmt0 /mnt/ops/dbbackup
tar: Removing leading `/' from member names

13.4.4. Remove the snapshot

When the backup has finished you can now unmount the volume and remove it from the system. You should remove snapshot volume when you have finished with them because they take a copy of all data written to the original volume and this can hurt performance.

# umount /mnt/ops/dbbackup
# lvremove /dev/ops/dbbackup

lvremove -- do you really want to remove "/dev/ops/dbbackup"? [y/n]: y
lvremove -- doing automatic backup of volume group "ops"
lvremove -- logical volume "/dev/ops/dbbackup" successfully removed

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

Posted by 삐꾸강아쥐

2008/11/20 09:43 2008/11/20 09:43
, , ,
Response
0 Trackbacks , 0 Comments
RSS :
http://blog.blog.n-nuri.com/rss/response/579

Trackback URL : http://blog.blog.n-nuri.com/trackback/579

Leave a comment
[로그인][오픈아이디란?]

vsftpd.conf 기본 설정 내용

넥스트라인 기술지원부 삼수(kiss@nextline.co.kr)

 

VSFTP 환경설정(vsftpd.conf)

background=YES (기본값 = NO)
VsFTP 데몬을 background로 실행할 것인지 설정 합니다.


 listen=YES (기본값 = NO)
VsFTP 데몬은 기본적으로 inetd 모드로 동작이 됩니다.

따라서 독립모드(standalone)로 데몬을 운영하실 거라면 이 옵션과 listen 옵션을 모두 YES로 켜주셔야 됩니다. 반대로 VsFTP 데몬을 inetd 모드로 운영하시려면 이 옵션과 listen 옵션을 비활성화 하시면 됩니다.일반적으로 FTP 데몬은 많은 접속이 있을 경우에 standalone 모드로 운영하는것이 좋으며, 많은 접속이 없는 경우에는 inetd 모드로 운영하는것이 시스템 자원효율에 좋습니다. background 옵션과 같이 사용되며, 이 옵션은 listen_port에서 들어오는 요청에 대해서 데몬이 요청을 받아드릴지에 대해 설정합니다. 만약 데몬을 독립모드(standalone)로 운영하실 거라면 background 옵션과 같이 이 옵션도 함께 활성화 시켜야 됩니다.


listen_ipv6=NO (기본값 = NO)

listen 옵션과 동일하지만, IPv6에서 운영할 때 사용 합니다.

일반적으로 IPv6는 사용하지 않으므로 비활성화 하시면 됩니다.


listen_port=21
만약 vsftpd를 xinetd모드가 아닌 독립데몬 (standalone)으로 서비스하려면 위의 listen 지시자를 YES로 설정하시고 listen_port 에 서비스할 포트번호(기본 21번)를 지정하시면 됩니다.


listen_address=none (기본값 = none)
멀티 FTP 데몬을 사용할 때 요청을 받아드릴 IP를 설정합니다.


listen_address6=none (기본값 = none)
listen_address와 동일하며 IPv6에서 운영할 때 사용 합니다.

 
pasv_address=none (기본값 = none)
NAT를 사용하는 클라이언트의 공용 IP를 설정할 때 사용 합니다.
일반적으로 설정하지 않아도 상관 없습니다.

 
nopriv_user=ftpsecure (기본값 = nobody)
VsFTPd가 구동될 서버의 유저를 설정합니다.
 

max_clients=30 (기본값 = 0)
FTP 서버에 접속할 수 있는 클라이언트의 최대수를 제한하는 옵션 입니다. 기본값인 0으로 설정하면 제한을 두지 않습니다.


max_per_ip=3
이 설정은 동시 ftp 접속자수를 제한하는 설정입니다. 첫번째 max_client 는 ftp 접속을 최대 30명까지만 허용한다는 설정입니다. 그리고 max_per_ip 는 한 IP(호스트)에서 동시에 3번까지만 접속이 가능하다는 설정입니다. 이 또한 서비스거부공격(DoS)를 방어하기 위한 방법으로 활용될 수 있습니다.
 

local_max_rate=0 (기본값 = 0)
계정 사용자의 최대전송률을 지정합니다.
업/다운로드의 속도를 제한할 때 사용하며, 단위는 bps 입니다.


trans_chunk_size=0
위의 세가지 설정은 ftp 서비스의 전송속도를 제한 하도록 하는 설정입니다. 즉, 초당 byte 수를 지정할 수 있으며 제한없이 허용하려면 0 으로 설정하시면 됩니다. 이 설정은 vsftpd 가 독립데몬(standalone)모드로 서비스될 때에만 적용되는 것입니다.
 

use_localtime=YES (기본값 = NO)
서버의 FTP 데몬시간을 서버의 표준시간으로 고정할지 설정합니다.

만약 이 옵션을 비활성화 하게되면 표준시각(GMT)를 보여주므로, 한국의 경우 9시간의 오차가 발생합니다.


setproctitle_enable=YES (기본값 = NO)
프로토콜의 현재 상태를 출력해줄 것인지 설정합니다. 이 옵션을 활성화하면 ps 명령어를 사용했을 때 세션의 현재 상태도 보여줍니다. 또한 LTN에서 제공하는 ftpwho 스크립트를 사용할 때에도 이 옵션을 활성화 하셔야 됩니다.
 

user_config_dir=none (기본값 = none)
특정 사용자의 개별 설정 파일을 지정합니다.
이 옵션을 사용하면 /etc/vsftpd/vsftpd.conf의 지시문을 무시하고 사용할 수 있습니다.

② 접속설정

local_enable=YES
로컬 계정 사용자들의 접속을 허용할 것인가의 여부를 결정합니다. YES 로 설정하면 로컬계정사용자의 접속을 허용하는 것이며 NO로 설정하면 허용하지 않는 것입니다. 기본 설정은 YES로 되어있기 때문에 접속을 허용하게 됩니다. 만약 NO로 설정되어 있을 때 로컬 계정으로 접속을 시도하면 “530 This FTP server is anonymous only.”와 같은 에러메시지를 출력하면서 접속을 거부합니다.


pam_service_name=vsftpd
vsftpd에서 PAM설정파일명으로 사용할 파일명을 지정합니다. 이 설정이 적용되면 기본이 vsftpd 이므로 /etc/pam.d/vsftpd 파일이 사용됩니다.


userlist_enable=YES (기본값 = NO)
명시된 사용자만 로그인을 허용할 때 사용하는 옵션입니다.
userlist_deny 옵션이 비활성화 된 상태에서만 작동합니다.


userlist_deny=YES (기본값 = YES)
명시된 사용자가 로그인을 할 수 없도록 제한하는 옵션 입니다.
userlist_enable 옵션이 비활성화 된 상태에서만 작동하며, 서로 반대되는 개념 입니다.

 
userlist_file=/etc/vsftpd.user_list (기본값 = /etc/vsftpd.user_list)
명시된 사용자를 읽어올 파일을 지정합니다.


text_userdb_names=NO (기본값 = NO)
디렉토리 목록의 사용자와 그룹 필드들에 있는 숫자 ID 들이 보이는 것이 기본값 입니다.
당신은 이 파라미터를 활성화 함으로써 글자 이름을 사용할 수도 있습니다. 그러나 이 항목은 성능상의 이유로 기본적으로 비활성화 되어 있습니다.

 
tcp_wrappers=YES
tcp_wrappers 적용 여부를 설정하는 것으로 사용할 것인가(YES) 사용하지 않을 것인가(NO)를 설정합니다. YES로 설정하시면 허용할 호스트는 /etc/hosts.allow 허용하지 않을 호스트는 /etc/hosts.deny에 설정합니다.


ssl_tlsv1=YES (기본값 = YES)
TLS를 사용할 것인지에 대해 설정합니다.
이 옵션은 TLS를 활성화하며, TLS가 가능한 클라이언트가 이용하는데 도움이 됩니다.


ssl_enable=NO (기본값 = NO)
SSL을 통한 보안접속을 지원할 것인지에 대해 설정합니다.
만약 OpenSSL에 대해서 컴파일 되어 있고, 이 옵션을 허용할 경우 vsftpd는 SSL을 통한 보안 접속을 지원합니다. 이 옵션은 제어 연결을 지원(로그인을 포함)하며, 또한 데이터 연결도 지원 합니다. 사용자는 SSL을 지원하는 클라이언트를 필요로 할 것이며, 반드시 필요한 경우에만 허용하는것이 좋습니다. 그러나 vsftpd는 OpenSSL 라이브러리의 보안과 관련한 게런티를 만들 수 없으며, 이 옵션을 활성화 합니다는것은 OpenSSL 라이브러리의 보안을 믿는다는 것을 전제로 합니다.

 
ssl_sslv2=NO (기본값 = NO)
SSL v2 프로토콜 연결을 허용할 것인지에 대해 설정합니다.
이 옵션은 ssl_enable이 활성화 되었을 때만 적용되며, TLS v1 연결들을 선호 합니다.
 

ssl_sslv3=NO (기본값 = NO)
SSL v3 프로토콜 연결을 허용할 것인지에 대해 설정합니다.
이 옵션은 ssl_enable이 활성화 되었을 때만 적용되며, TLS v1 연결들을 선호 합니다.


dsa_cert_file=none (기본값 = none)
SSL 인증서의 위치를 지정합니다. SSL의 암호화 접속을 사용하기 위해, DSA 인증서의 위치를 지정합니다.
 

ssl_ciphers=DES-CBC3-SHA (기본값 = DES-CBC3-SHA)
이 옵션은 vsftpd가 암호화 된 SSL 연결들에 대해 어떤 SSL 암호화 방식을 선택하는지에 따라 사용됩니다. 더 자세한 사항은 관련 암호 메뉴얼 페이지를 보십시요.

암호화를 알리지 않는 것은 원격에서 선택된 암호화 방식의 취약점을 공격하려고 불법적인 원격 공격을 막기 위한 유용한 보안 지침이 될 수 있습니다.


force_local_data_ssl=YES (기본값 = YES)
이 옵션은 ssl_enable이 활성화 되었을 때만 적용되며, 만약 이 옵션이 활성화 되어 있습니다. 모든 비익명 로그인은 데이터 연결 상태에서 데이터를 주고 받기 위해 보안 SSL 연결을 사용하도록 강제적으로 설정됩니다.


force_local_logins_ssl=YES (기본값 = YES)
이 옵션은 ssl_enable이 활성화 되었을 때만 적용되며, 만약 이 옵션이 활성화 되어 있습니다. 모든 비익명 로그인은 비밀번호를 전달하기 위해 보안 SSL 연결을 사용하도록 강제적으로 설정됩니다.
 

③ 대기시간 설정


connect_timeout=60 (기본값 = 60/초)
액티브 모드(Active Mode)를 사용하는 클라이언트의 접속 허용시간을 설정합니다. 클라이언트의 요청패킷(SYN Packet)을 받은뒤, 지정된 시간내에 접속이 안될경우 종료합니다.


accept_timeout=60 (기본값 = 60/초)
패시브 모드(Passive Mode)를 사용하는 클라이언트의 접속 허용시간을 설정합니다. 클라이언트의 요청패킷(SYN Packet)을 받은뒤, 지정된 시간내에 접속이 안될경우 종료합니다.


data_connection_timeout=300 (기본값 = 300/Secs)
데이터 전송시 적용되는 타임아웃값을 설정합니다. 만약 ftp 연결시 큰 파일을 업로드 또는 다운로드 할 때에 전송도중 접속이 끊기는 상황이 발생한다면 이 설정을 주석처리하거나 또는 이 값을 현재 설정값 보다 크게 잡아주시고 재시도 해보십시요.


idle_session_timeout=300 (기본값 = 300/Secs)
ftp 연결에서 idle 타임에 대한 타임아웃값을 설정합니다. 예를 들어 이 값이 600으로 설정되어 있다면 ftp 접속후에 600초(10분)동안 아무런 작업도 없이 놀고 있다면 강제 로그아웃(timeout)시켜 버립니다.


④ 메시지 설정

banner_file=/etc/vsftpd/welcome.msg (기본값 = none)
사용자가 FTP 서버에 접속했을 때 보여줄 환영 메시지 파일을 설정합니다.
 

ftpd_banner=Welcome to blah FTP service.
ftp 서버로 접속할 때에 안내메시지등을 출력하려면 여기서 설정하시면 됩니다. 이 설정이 적용되면 ftp 접속을 하였을 때 "Welcome to blah FTP service"라는 안내문이 출력됩니다. 이 설정에서 한글을 사용할 수도 있습니다. 각 디렉토리별 안내문에 대한 설정은 다음 지시자의 설명을 보시기 바랍니다.

dirmessage_enable=YES
ftp 접속한 사용자가 특정 디렉토리로 이동하였을 때 개별 디렉토리의 메시지를 보여주도록 허용할 것인가(YES) 허용하지 않을 것인가(NO) 를 설정하는 것입니다. 밑에서 설명하고 있는 "message_file" 지시자에서 개별 디렉토리안내 파일로 사용할 파일명을 지정할 수 있습니다.


Message_file=.message
ftp 접속후에 특정 디렉토리로 이동할 때에 디렉토리 안내메시지 파일로 사용할 파일명을 지정한 것입니다. 이 설정은 바로 위에서 설명한 "dirmessage_enable" 이 YES로 설정되어 있을 때 적용됩니다.


⑤ 모드설정


port_enable=YES (기본값 = YES)
데이터 전송을 위해서 Active Mode를 사용할 것인지 설정합니다.
 

connect_from_port_20=YES
ftp 서비스는 기본적으로 21번 포트와 20번 포트를 사용합니다. ftp 접속과 명령어에 사용되는 포트는 21번이며 실제 데이터전송에 사용되는 기본포트는 20번입니다. 이때 20번 포트의 데이터전송 연결을 허용할 것인가(YES) 허용하지 않을 것인가(NO)를 설정하는 지시자 입니다.
 

ftp_data_port=20 (기본값 = 20)
데이터 전송 포트를 지정합니다.
connect_from_port_20 옵션이 활성화 되었을 때 사용되는 포트를 지정합니다.


pasv_enable=YES (기본값 = YES)
데이터 전송을 위해서 Passive mode를 사용할 것인지 설정합니다.
Active Mode로 접근할 수 없는 사용자들을 위해 활성화 하는 것 이 좋습니다.


pasv_promiscuous=NO (기본값 = NO)
동일한 IP주소에서 이루어지는 데이터 연결을 보장해주는 보안체크 기능을 사용할 것인지 설정합니다.


pasv_min_port=0
pasv_max_port=0 (기본값 = 0)
패시브 모드로 연결시 할당될 최대 및 최소 포트를 설정하는 옵션 입니다.
일반적으로 50000~60000 포트를 지정하는 것이 좋으며, 기본값인 0으로 설정하게 되면
well-known port를 제외한 무작위 포트를 이용하게 됩니다.

 

ascii_upload_enable=YES

ascii_download_enable=YES
기본적으로 ASCII 모드로 업로드/다운로드하는 것이 제한되어 있습니다. 이 설정으로 ASCII모드로의 업로드/다운로드를 허용하도록 설정할 수 있습니다.


⑥ 권한설정


local_umask=022
로컬계정 사용자들의 umask 값을 설정하는 지시자입니다. 거의 모든 ftp 서버에서 기본 umask 값은 022 입니다. 하지만 vsftp 에서의 umask 기본값은 077입니다. Umask 값이 077 일 경우에 새로 생성되는 파일의 퍼미션은 600 이 되며 새로 생성되는 디렉토리의 퍼미션은 700 이 됩니다. 당연히 umask 값이 022 일 때보다는 보안이 훨씬 강화됩니다. 여기서 "local_umask=022"의 주석을 제거하여 유효하게 설정하면 대부분의 FTP 서버에서 사용하는 umask 값을 022로 설정하게 됩니다. 만약 022 외에 다른 umask 값을 설정하고자 한다면 그 값을 설정해 주시면 됩니다.


file_open_mode=0644 (기본값 = 0666)
파일이 업로드 되었을 때의 퍼미션을 지정해주는 옵션 입니다.
이 옵션은 반드시 umask 옵션보다 아래에 있어야 됩니다.


dirlist_enable=YES (기본값 = YES)
접속한 디렉토리의 파일리스트를 보여줄 지 설정합니다.


force_dot_files=NO (기본값 = NO)
히든 파일/디렉토리를 보여줄 것인지 설정하는 옵션 입니다.
히든 파일/디렉토리는 dot(.) 으로 시작하는 것을 말합니다.


tilde_user_enable=NO (기본값 = NO)
이 옵션이 활성화되면, vsftpd는 ~chris/pics와 같이 사용자 계정 이름에 틸드 표시가 따라오는 경우의 경로명을 접근하도록 시도하고 해석할 것입니다.

vsftpd는 항상 ~ 와 ~/somthing 을 해석합니다는 것을 주의하시기 바랍니다.
(여기서 ~ 는 기본적으로 로그인 했을 때의 디렉토리로 해석됩니다.)
~user 경로들은 _current_ chroot() 에서 /etc/passwd 파일을 찾을 수 있을 경우에만 해석 될 수 있을 것입니다.


hide_ids=NO (기본값 = NO)
디렉토리 목록에서 UID를 보여주지 않고, 모두 FTP로 표시할 것인지 설정합니다.
이 옵션을 활성화 하면 모든 파일의 소유권이 FTP로 표시되므로 보안에 도움이 될 수 있습니다.
 

write_enable=YES (기본값 = NO)
ftp 로 접속이 된 상태에서 사용할 수 있는 ftp 전용명령어에는 여러가지가 있습니다. 이 설정은 ftp 전용명령어 중에 write 명령어를 허용할 것인가를 결정하는 것입니다. 허용하려면 YES, 허용하지 않으려면 NO 를 설정하시면 됩니다.

 
download_enable=YES (기본값 = YES)
다운로드에 대한 권한을 설정합니다.

 
chmod_enable=YES (기본값 = YES)
사용자가 퍼미션을 변경할 수 있도록 설정합니다.
 

use_sendfile=YES (기본값 = YES)
이 옵션은 당신의 플랫폼에서 sendfile() 시스템 호출을 사용하는 것과 관련된 이익을 테스트 할 때 사용되는 내부 설정입니다.
 

cmds_allowed=PASV,RETR,QUIT (기본값 = none)
사용자에게 허가할 명령어를 지정합니다.

 
deny_file={*.mp3,*.mov} (기본값 = none)
업로드를 거부할 파일명을 지정합니다.

 
hide_file={*.mp3,*.mov} (기본값 = none)
숨길 파일명을 지정합니다.
이 옵션을 사용하면 서버에 실제로 데이터는 존재하지만, FTP 사용자에게는 보이지 않도록
설정하는 기능입니다. 악의적인 사용자에게 간단한 fake를 걸 수 있습니다.

 
async_abor_enable=YES (기본값 = NO)
async ABOR 명령어를 사용할 수 있도록 설정합니다.
일부 FTP 클라이언트에서 파일전송을 취소했을 경우, 취소되지 않은 상태로 있는 경우가
생길 수 있는데 그것을 방지하기 위해 사용할 수 있습니다.
그러나 보안상 좋지 않기 때문에, 비활성화 하시는것이 좋습니다.

 
ls_recurse_enable=YES
ftp 접속에서는 ls 사용시 –R 옵션을 허요하지 않는 것이 기본 설정입니다. –R 옵션이란 서브디렉토리내의 파일들의 리스팅(목록)까지 모두 확인할 수 있도록 하는 것입니다. 서버부하등의 이유로 ftp에서 기본적으로는 지원하지 않지만 vsftpd 에서는 이 옵션을 사용하여 허용하도록 설정할 수 있습니다. 즉, 이 지시자의 값이 YES로 되어 있다면 ftp 접속후에 디렉토리 목록 확인시에 서브디렉토리들의 목록들까지 한번에 볼 수 있는 –R 옵션을 허용하게 됩니다.

 
⑦ 보안설정

 
chroot_list_enable=YES (기본값 = NO)
명시된 사용자가 자신의 홈상위 디렉토리를 접근할 수 없도록 설정합니다.
이 옵션은 chroot_local_user 옵션이 비활성화되어 있어야 사용할 수 있습니다. 전체 적용이 아니라 일부 사용자만 제한할때 편하지만, 개별 적용은 보안상 좋지 않습니다.

 
chroot_list_file=/etc/vsftpd.chroot_list
전체 사용자가 아닌 특정 사용자들에 대하여 자신의 홈디렉토리를 루트디렉토리로 인식하도록 하는 기능으로서 이 기능은 사용자의 홈디렉토리의 상위디렉토리로 벗어나지 못하도록 하는 설정입니다.

먼저 "chroot_list_enable=YES" 로 설정하시고 /etc/vsftpd.chroot_list 파일에는 이 기능을 적용할 사용자계정명을 등록해 두시면 됩니다. 즉, /etc/vsftpd.chroot_list 파일에 등록된 사용자들에 한하여 chroot()기능이 적용되어 자기 자신의 홈디렉토리 상위 디렉토리의 이동이 제한됩니다. 이 파일에 등록할 때에는 한행에 한 사용자 계정씩만 등록하셔야 합니다. 만약 전체 사용자를 대상으로 chroot()기능을 적용하고자 한다면 바로 밑에서 설정하고 있는 "chroot_local_user=YES"로 설정하시기 바랍니다.

 
passwd_chroot_enable=NO (기본값 = NO)
SSH로 접속했을 때 자신의 홈 상위 디렉토리를 접근할 수 없도록 설정합니다.
chroot_local_user 옵션이 활성화되었고, OpenSSH에 패치를 했을경우, SSH 또한 자신의
홈상위 디렉토리를 접근할 수 없도록 설정할 수 있으며, /etc/passwd 파일의 홈 디렉토리
필드의 /home/사용자/./와 같이 "/./"를 붙여 사용자를 홈디렉토리에 제한하게 합니다.

 
chroot_local_user=YES
특정 사용자가 아닌 전체 사용자를 대상으로 chroot()기능을 적용하여 자기 자신의 홈디렉토링 상위 디렉토리로 이동하지 못하도록 하려면 이 설정을 YES로 설정하십시요. 반드시 앞의 설정과 비교해 보시기 바랍니다.
 

만약 위 의 두 설정이 모두 설정되었다면
즉, "chroot_list_enable=YES"와 "chroot_local_user=YES" 설정이 모두 YES로 되어 있다면 /etc/vsftpd.chroot_list 에 등록된 사용자들만 chroot()적용을 받지 않게 됩니다. 즉, 이 두 설정이 모두 YES 로 되어 있다면 /etc/vsftpd.chroot_list 에 등록된 사용자들을 제외한 나머지 사용자들만 chroot()가 적용되어 상위 디렉토리로의 이동이 안된다는 의미입니다.

 
secure_chroot_dir=/usr/share/empty (기본값 = /usr/share/empty)
secure chroot()에 사용될 디렉토리를 지정합니다.
이 옵션에서 지정된 디렉토리는 비어있어야되며, ftp 사용자에 대해 쓰기 권한이 없어야 됩니다.

 
⑧ 로그설정
 

xferlog_enable=YES
ftp 접속후에 파일 업로드와 다운로드에 대한 로그를 남길것인가(YES) 남가지 않을 것인가(NO)를 설정하는 지시자입니다. 이 지시자의 설정은 디스크의 용량을 고려하여 결정해야 합니다. 즉, 파일 업로드/다운로드 로그는 굉장히 많은 용량을 필요로 하고 또한 시스템 부하율도 함께 고려하여 신중히 결정해야 합니다. 물론 로그를 남기는 것이 로그분석과 개별 사용자의 파일 업로드/다운로드 상황을 알 수 있는 방법이기는 하지만 시스템 상황을 고려해야 하는 의미입니다.
 

vsftpd_log_file=/var/log/vsftpd.log
(기본값 = /var/log/vsftpd.log)
VsFTP의 기본 로그 파일을 지정합니다.
이 옵션은 xferlog_enable 옵션과 xferlog_std_format 옵션이 비활성화일 때 작동하며, dual_log_enable 옵션이나 syslog_enable 옵션이 활성화될때 사용됩니다.
 

dual_log_enable=NO (기본값 = NO)
2중 로그를 기록할 것인지에 대해 설정합니다.
만약 이 옵션을 활성화하면, /var/log/xferlog와 /var/log/vsftpd.log에 로그가 기록됩니다.

 
syslog_enable=NO (기본값 = NO)
syslogd 데몬을 이용해서 로그를 기록할 것인지 설정합니다.

 
xferlog_file=/var/log/vsftpd.log
ftp 로그파일의 위치를 결정하는 지시자입니다.
Vsftp는 기본적으로 /var/log/vsftpd.log 파일을 기본 로그파일로 사용합니다. 만약 로그파일 위치나 파일명을 변경하시려면 이 지시자에서 설정 변경하시면 됩니다.
 

xferlog_std_format=YES
로그파일에 남길 로그파일의 포맷을 기본포맷으로 남길 것인가(YES) 아닌가(NO)를 설정하는 지시자 입니다. 리눅스에서 ftp 기본 로그파일을 /var/log/xferlog을 사용합니다. 이 지시자는 이 파일의 표준포맷으로 로그를 남기도록 하는 설정입니다. 이 파일의 포맷보다는 vsftpd 로그포맷을 사용하시는 것이 보다 자세한 로그를 남길 수 있습니다. 즉, 디렉토리생성로그나 또는 로그인 로그 같은 상세로그까지 기록해 줍니다.

 

log_ftp_protocol=YES (기본값 = NO)
FTP Protocol의 모든 내용을 기록할지 설정합니다.
이 옵션을 활성화하면 FTP 명령어와 반응이 모두 로깅되므로 디버그에 유용하게 쓰입니다.
 

no_log_lock=NO (기본값 = NO)
로그 파일을 잠글것인지에 대해서 설정합니다.
이 옵션은 vsftpd가 로그 파일을 기록할 때, 파일을 잠그는 것을 막는 옵션 입니다.
보통은 활성화 하지 않아도 되며, 솔라리스/베리타스 파일 시스템 조합에서 때때로
로그파일을 잠그려는 시도를 하는 운영체제 시스템 버그를 피하기 위해 존재 합니다.

 
session_support=YES
이 설정은 YES로 설정되어 유효하게 되었을 때에는 바이너리파일인 wtmp에 ftp 접속관련 기록을 남기게 됩니다.
Last 라는 명령어는 각 사용자들의 접속기록을 wtmp 파일에서 가져와 확인하는 명령어이므로 이 설정이 적용되면 last 명령어로 ftp 접속기록을 확인 할 수 있게 됩니다.

 
⑨ 가상 사용자 설정
 

guest_enable=NO
가상유저 모드로 운영할 것인지에 대해 설정합니다. (기본값 = NO)
이 옵션을 활성화하면 모든 비익명 사용자는 가상 사용자로 접속이 됩니다.
 

guest_username=ftp
가상유저들의 실제 계정을 지정합니다. (기본값 = ftp)

 
virtual_use_local_privs=NO (기본값 = NO)
가상유저들의 권한을 실제 계정의 권한처럼 허용할 것인지를 설정합니다.
이 옵션이 활성화되어있지 않으면 가상유저는 FTP에 접속해서 파일을 생성하지 못합니다.
또한 가상유저는 기본적으로 anonymous의 권한을 갖고 있습니다.
 

user_sub_token=$USER (기본값 = none)
가상유저들을 지칭할 가상의 변수를 지정합니다.
 

local_root=/home/virtual/$USER (기본값 = none)
가상유저들이 로그인 후 이동될 디렉토리를 지정합니다.

 
⑩ 익명사용자 기본 설정

 
anonymous_enable=NO
익명(anonymous) 접속을 허용할 것인가(YES) 허용하지 않을 것인가(NO)를 결정하는 지시자입니다. 기본값은 YES로 되어있으며 익명계정 접속을 허용하지 않으려면 NO 로 설정하시기 바랍니다.

 
anon_max_rate=0 (기본값 = 0)
익명 사용자의 다운로드 최대전송률을 지정합니다.
다운로드 속도를 제한할때 사용하며, 단위는 bps 입니다.


allow_anon_ssl=NO (기본값 = NO)
익명사용자의 SSL을 통한 보안접속을 지원할 것인지에 대해 설정합니다.
이 옵션은 ssl_enable이 활성화 되었을 때만 적용됩니다.
 

deny_email_enable=YES (기본값 = NO)
로그인 거부 리스트 사용에 대한 설정을 합니다.
/etc/vsftpd.banned_emails 에 설정된 주소로 로그인을 거부할 수 있습니다.
만약 anonymous@ 라고 설정해두면, anonymous@를 사용하는 사용자는 접속할 수 없게됩니다.

 
banned_email_file=/etc/vsftpd.banned_emails
(기본값 = /etc/vsftpd.banned_emails)
로그인 거부 파일을 지정합니다.
deny_email_enable 옵션을 활성화했을 경우에 리스트를 읽어올 파일을 지정합니다.
 

secure_email_list_enable=NO (기본값 = NO)
명시된 이메일 주소로만 접속을 허용할 지 설정합니다.
 

email_password_file=/etc/vsftpd.email_passwords
(기본값 = /etc/vsftpd.email_passwords)
접속을 허용할 이메일 주소 파일을 지정합니다.
secure_email_list_enable 옵션을 활성화했을 경우에 리스트를 읽어올 파일을 지정합니다.

 
ftp_username=ftp (기본값 = ftp)
익명 사용자의 접속에 사용될 계정명을 지정합니다.

 
no_anon_password=NO (기본값 = NO)
익명 사용자가 접속할 때 패스워드를 묻지않고 접속시킬 것인지 설정합니다.
이 옵션을 활성화하면 접속시 패스워드를 묻지 않습니다.
 

one_process_model=NO (기본값 = NO)
클라이언트 접속마다 하나의 프로세스가 작동되도록 할 것인지 설정합니다.
이 옵션을 활성화하면 접속하는 수만큼 프로세스가 작동되므로 효율이 좋습니다.

 
anon_root=/var/ftp/pub (기본값 = none)
익명 사용자의 기본 디렉토리를 지정합니다.
일반적으로 익명 사용자의 접근을 허용하면 ftp_username에 지정된 사용자의 홈 디렉토리가 기본적으로 설정됩니다. 그렇지만 만약 변경할 필요가 있을 경우에 이 옵션을 사용하면 됩니다.

 
⑪ 익명사용자 권한 설정

 
anon_upload_enable=YES
익명(anonymous) 계정 사용자에게 파일 업로드를 허용할 것인가(YES) 허용하지 않을 것인가(NO) 의 여부를 설정하는 지시자입니다. 기본값은 허용하지 않는 NO 입니다. 가능한 익명 계정으로 접속한 사용자에게는 업로드 권한을 허용하지 않는 것이 보안에 훨씬 좋습니다. 따라서 가능한 NO로 설정하시기 바랍니다.
 

anon_mkdir_write_enable=YES
익명(anonymous) 계정 사용자에게 디렉토리 생성권한을 허용할 것인가(YES) 허용하지 않을 것인가(NO)의 여부를 설정하는 지시자 입니다. 기본값은 허용하지 않는 NO 입니다. 가능한 익명계정으로 접속한 사용자에게는 디렉토리 생성권한을 허용하지 않는 것이 보안에 훨씬 좋습니다. 따라서 가능한 NO로 설정하시기 바랍니다.
 

anon_world_readable_only=YES (기본값 = YES)
익명 사용자들의 다운로드에 대한 설정을 합니다.
익명 사용자들이 읽기 가능한 파일을 다운로드 할 수 있게 설정합니다.

 
anon_other_write_enable=NO (기본값 = NO)
익명 사용자의 파일 삭제,변경에 대한 설정을 합니다.
파일 삭제 및 파일명 변경등과 같은 기능을 사용할 수 있게 합니다.

 
chown_uploads=YES (기본값 = NO)
익명 사용자의 소유권 변경에 대한 설정을 합니다.
익명으로 업로드된 파일을 chown_username 옵션으로 명시된 사용자의 소유권으로 변경되도록 할 수 있습니다.

 
anon_umask=022 (기본값 = 077)
익명 사용자의 파일생성 umask 값을 지정 합니다.
umask에 대한 설명은 local_mask의 설명을 참조하시기 바랍니다.

 
chown_username=whoever (기본값 = root)
익명 사용자의 소유권 변경이 가능한 계정명을 설정합니다.

출처 : Tong - bassdot님의 리눅스통

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

Posted by 삐꾸강아쥐

2008/11/07 17:54 2008/11/07 17:54
,
Response
0 Trackbacks , 0 Comments
RSS :
http://blog.blog.n-nuri.com/rss/response/576

Trackback URL : http://blog.blog.n-nuri.com/trackback/576

Leave a comment
[로그인][오픈아이디란?]

[Linux] rsh, rlogin 사용하기

rsh, rlogin 을 사용하기 위해선

1. 우선 rsh rpm이 설치되어 있어야 한다
ex)
rpm -qa|grep rsh
rsh-0.17-38.el5

만약 없다면 해당 OS에 맞는 버전 설치

2. rsh , rlogin 서비스 ON 시키기

런레벨 등록

chkconfig rsh --level 345 on
chkconfig rlogin --level 345 on

service xinetd restart  ## xinetd daemon restart

3. krb 인증과 관련하여 krb5-workstation 패키지를 삭제 합니다.
ex)
rpm -e krb5-workstation-xxxx

4. rsh,rlogin 을 사용하기 위해서
vi   /etc/securetty 의 마지막줄에

rsh, rlogin 을 추가 후
ex)
console
vc/1
vc/2
vc/3
vc/4
vc/5
vc/6
vc/7
vc/8
vc/9
vc/10
vc/11
tty1
tty2
tty3
tty4
tty5
tty6
tty7
tty8
tty9
tty10
tty11
rsh
rlogin


5. /etc/hosts 등록 ( 관리하는 서버들의 호스트를 등록해주면 편합니다. )
ex)
192.168.0.1 node01
192.168.0.2 node02
192.168.0.3 node03
.
.
.
192.168.0.x node0x

6. /etc/hosts.equiv 파일 작성후
rsh, rlogin 을 사용할 노드들을 등록
ex)
node01
node02
node03
.
.
.
node0x

7. 마지막으로 root 폴더에 .rhosts 작성후 /etc/hosts.equiv 와 같은 내용 등록
ex)
node01
node02
node03
.
.
.
node0x

8. 모든 서버에 똑같이 적용 시킨다.

9. test)
rsh node01
rsh node02

접속이 된다면 완료.




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

Posted by 삐꾸강아쥐

2008/09/04 10:15 2008/09/04 10:15
, ,
Response
0 Trackbacks , 0 Comments
RSS :
http://blog.blog.n-nuri.com/rss/response/564

Trackback URL : http://blog.blog.n-nuri.com/trackback/564

Leave a comment
[로그인][오픈아이디란?]