<?xml version="1.0" encoding="utf-8"?>
        <?xml-stylesheet type="text/css" href="http://www.zhyfly.org/blog/styles/feed.css"?>
<rss version="2.0"
 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
 xmlns:dc="http://purl.org/dc/elements/1.1/"
 xmlns:admin="http://webns.net/mvcb/"
>
<channel>
<title>ZhyFly's Blog</title>
<link>http://www.zhyfly.org/blog</link>
<description>... come on, what are you looking for?</description>
<dc:language>en-us</dc:language>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:date>2007-04-27T22:28:18+08:00</dc:date>
<admin:generatorAgent rdf:resource="http://nanoblogger.sourceforge.net" />
<item>
<link>http://www.zhyfly.org/blog/archives/2007/04/27/usage_of_rar4linux/index.html</link>
<title>Usage of rar4linux</title>
<dc:date>2007-04-27T22:04:53+08:00</dc:date>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:subject>5.Software</dc:subject>
<description><![CDATA[<pre>
<code>#unrar x foo.rar .</code>
<code>#rar a foo.rar dir/</code>
</pre>]]></description>
</item>
<item>
<link>http://www.zhyfly.org/blog/archives/2007/04/27/my_subversion_basic_working_period/index.html</link>
<title>My SubVersioN Basic Working Period.</title>
<dc:date>2007-04-27T22:00:33+08:00</dc:date>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:subject>5.Software</dc:subject>
<description><![CDATA[<pre>
<code>#mkdir ~/tmpDir</code>
<code>#cd ~/tmpDir/</code>
<code>#svnadmin create /svn/c_dip</code>
<code>#mkdir -p bmp2raw/{trunk,tags,branches}</code>
<code>#touch bmp2raw/trunk/{bmp2raw.c,Makefile}</code>
<code>#svn import . file:///svn/c_dip --message "First available <bmp2raw.c> version."</code>

<code>#mkdir ~/Project/svn/c_dip</code>
<code>#cd ~/Project/svn/c_dip/</code>
<code>#svn checkout file:///svn/c_dip/bmp2raw bmp2raw</code>
<code>#cd bmp2raw/trunk/</code>
<code>#svn add foo</code>
<code>#svn delete foo</code>
<code>#svn copy foo bar</code>
<code>#svn move foo bar</code>
<code>#svn commit --message "First Change."</code>

<code>#svn log file:///svn/c_dip/</code>
<code>#svn log file:///svn/c_dip/bmp2raw/trunk/</code>
<code>#svn list --verbose file:///svn/c_dip/</code>
<code>#svn list --verbose file:///svn/c_dip/bmp2raw/trunk/</code>

<code>#mkdir -p ~/tmpDir/tmp</code>
<code>#cd ~/tmpDir/tmp/<code>
<code>#mkdir -p raw2bmp/{trunk,tags,branches}</code>
<code>#touch raw2bmp/trunk/{raw2bmp.c,Makefile}</code>
<code>#svn import . file:///svn/c_dip --message "First avaliable <raw2bmp.c> version."</code>

<code>#cp /svn/c_dip/hooks/pre-revprop-change.tmpl /svn/c_dip/hooks/pre-revprop-change</code>
<code>#chmod a+x /svn/c_dip/hooks/pre-revprop-change</code>
<code>#svnadmin setlog /svn/c_dip/ -r 3 msgr3</code>
</pre> 
<p></p>
<pre>
<code>#svn command URL</code>
<code>#svnadmin command PATH</code>
</pre>
<p></p>
<pre>
'line'
&lt;file&gt;
[directory]
</pre>]]></description>
</item>
<item>
<link>http://www.zhyfly.org/blog/archives/2007/04/25/modifying_previous_wrong_log_message_in_the_repository_of_svn/index.html</link>
<title>Modifying previous wrong log message in the repository of SVN</title>
<dc:date>2007-04-25T10:54:11+08:00</dc:date>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:subject>5.Software</dc:subject>
<description><![CDATA[<p>If you are using <code>svn</code>, and you made a wrong log message (using --message "real message"), then you want to modify it. But how to deal with this situation?</p>
<p>It's really easy to use the hook of <em>SVN</em>, look at the <em>/path/to/repos/hooks</em> directory and you will find a file named <b>pre-revprop-chage.tmpl</b>, hm, this is the tricky.</p>
<ol>
<li>rename the <b>pre-revprop-change.tmpl</b> to <em>pre-revprop-change</em>.
<pre>
<code>#mv /path/to/repos/hooks/pre-revprop-change.tmpl /path/to/repos/hooks/pre-revprop-change</code>
</pre>
</li>
<li>change file access permissions to executable.
<pre>
<code>#chmod +x /path/to/repos/hooks/pre-revprop-change</code>
</pre>
</li>
<li>modify the previous wrong log message from a file <b>msg</b>.
<pre>
<code>#svnadmin setlog /path/to/repos/ -r REVISION msg</code>
</pre>
</li>
<li>check out if it works.
<pre>
<code>#svn log -r REVISION file:///path/to/repos</code>
</pre>
</li>
</ol>]]></description>
</item>
<item>
<link>http://www.zhyfly.org/blog/archives/2007/04/25/executing_shell_script_in_makefile/index.html</link>
<title>Executing Shell script in Makefile</title>
<dc:date>2007-04-25T08:33:52+08:00</dc:date>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:subject>1.GNU/Linux</dc:subject>
<description><![CDATA[<p>It's convenient to use Makefile to manage your project, this is obvious for me. However, sometimes I want to execute shell in Makefile. Then here is an example like this:</p>
<pre>
GCC = gcc
G++ = g++
RM = rm

BINS = bmp2raw

all: $(BINS)

%:%.c
    $(GCC) -o $@ -g $<

convert:
    for i in $(shell ls *.bmp);do (./bmp2raw $$i $${i%.*}); done

clean:
    $(RM) $(BINS)
</pre>
<p>This is a Makefile to manage a project converting .bmp file to .raw file using C. Besides it can also <em>convert</em> all the <b>.bmp</b> files in the current directory to <b>.raw</b> files without changing the name of the files (just the extension). Therefore, typing</p>
<pre>
<code>#make convert</code>
</pre>
<p>will get the fruit. :)</p>]]></description>
</item>
<item>
<link>http://www.zhyfly.org/blog/archives/2007/02/09/how_to_ssh_a_remote_machine_without_password_securely/index.html</link>
<title>How to SSH a remote machine without password securely</title>
<dc:date>2007-02-09T10:34:52+08:00</dc:date>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:subject>1.GNU/Linux</dc:subject>
<description><![CDATA[<p>Many of us use the excellent OpenSSH as a secure, encrypted replacement for the venerable telnet and rsh commands. However, it's annoying to enter the password everytime you login a remote machine. Here will give you some good idea about SSH a remote mahcine without password securely. And you can use rsa1, rsa, and dsa authentication as you like.</p>
<dl>
<dt>rsa1</dt>
<dd>Use rsa1 authentication:
<pre>
user@localbox# ssh-keygen -t rsa1
Generating public/private rsa1 key pair.
Enter file in which to save the key (/home/user/.ssh/identity):
        (hit enter)
Enter passphrase (empty for no passphrase):
        (enter a passphrase)
Enter same passphrase again:
        (enter it again)
Your identification has been saved in /home/user/.ssh/identity.
Your public key has been saved in /home/user/.ssh/identity.pub.
The key fingerprint is:
a4:e7:f2:39:a7:eb:fd:f8:39:f1:f1:7b:fe:48:a1:09 user@localbox
user@localbox# scp ~/.ssh/identity.pub user@remotebox:
user@localbox# ssh user@remotebox
user@remotebox's password:
user@remotebox# cat ~/identity.pub >> ~/.ssh/authorized_keys
user@remotebox# exit
user@localbox#
</pre>
You'd better enter a <em>passphrase</em> when <code>ssh-keygen</code> prompts for.
</dd>
<dt>rsa</dt>
<dd>Use rsa authentication:
<pre>
user@localbox# ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/home/user/.ssh/id_rsa):
        (hit enter)
Enter passphrase (empty for no passphrase):
        (enter a passphrase)
Enter same passphrase again:
        (enter it again)
Your identification has been saved in /home/user/.ssh/id_rsa.
Your public key has been saved in /home/user/.ssh/id_rsa.pub.
The key fingerprint is:
a4:e7:f2:39:a7:eb:fd:f8:39:f1:f1:7b:fe:48:a1:09 user@localbox
user@localbox# scp ~/.ssh/id_rsa.pub user@remotebox:
user@localbox# ssh user@remotebox
user@remotebox's password:
user@remotebox# cat ~/id_rsa.pub >> ~/.ssh/authorized_keys
user@remotebox# exit
user@localbox#
</pre>
You'd better enter a <em>passphrase</em> when <code>ssh-keygen</code> prompts for.
</dd>
<dt>dsa</dt>
<dd>Use dsa authentication:
<pre>
user@localbox# ssh-keygen -t dsa
Generating public/private dsa key pair.
Enter file in which to save the key (/home/user/.ssh/id_dsa):
    (hit enter)
Enter passphrase (empty for no passphrase):
    (enter a passphrase)
Enter same passphrase again:
    (enter it again)
Your identification has been saved in /home/user/.ssh/id_dsa.
Your public key has been saved in /home/user/.ssh/id_dsa.pub.
The key fingerprint is:
a4:e7:f2:39:a7:eb:fd:f8:39:f1:f1:7b:fe:48:a1:09 user@localbox
user@localbox# scp ~/.ssh/id_dsa.pub user@remotebox:
user@localbox# ssh user@remotebox
user@remotebox's password:
user@remotebox# cat ~/id_dsa.pub >> ~/.ssh/authorized_keys2
user@remotebox# exit
user@localbox#
</pre>
You'd better enter a <em>passphrase</em> when <code>ssh-keygen</code> prompts for.
</dd>
</dl>
<p>After that you should install <a href="http://www.gentoo.org/proj/en/keychain/index.xml">keychain</a> in your <em>/usr/bin/</em> directory of your localbox refer to README in the keychain tarball. Then add the following lines into your <em>~/.bash_profile</em>:</p>
<pre>
# ssh-agent daemon                                                                                                  
/usr/bin/keychain ~/.ssh/id_rsa #take rsa for an example
# redirect ~/.ssh-agent output to /dev/null to zap the annoying                                                     
# "Agent PID" message                                                                                               
source ~/.keychain/${HOSTNAME}-sh > /dev/null
</pre>
<p>I used <em>keychain-2.6.8</em> version for the test, if your version is different, you should hack the above code for your version.</p>
<p>At last, relogin in your localbox and it will display something like:</p>
<pre>
KeyChain 2.6.8; http://www.gentoo.org/proj/en/keychain/
Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL

 * Initializing /home/user/.keychain/[hostname]-sh file...
 * Initializing /home/user/.keychain/[hostname]-csh file...
 * Initializing /home/user/.keychain/[hostname]-fish file...
 * Starting ssh-agent
 * Adding 1 ssh key(s)...
Enter passphrase for /home/user/.ssh/id_rsa: 
Identity added: /home/flyzhy/.ssh/id_rsa (/home/user/.ssh/id_rsa)
</pre>
<p>Remember to Enter the passphrase when you generate the key using <code>ssh-keygen</code>. Then, you can securely ssh the remotebox without password.</p> 
<h3>Reference</h3>
<ul>
<li>OpenSSH key management (Part 1) <a href="http://www-128.ibm.com/developerworks/cn/linux/security/openssh/part1/index.html">Chinese</a> | <a href="http://www-128.ibm.com/developerworks/library/l-keyc.html">English</a></li>
<li>OpenSSH key management (Part 2) <a href="http://www-128.ibm.com/developerworks/cn/linux/security/openssh/part2/index.html">Chinese</a> | <a href="http://www-128.ibm.com/developerworks/library/l-keyc2.html">English</a></li>
<li>OpenSSH key management (Part 3) <a href="http://www-128.ibm.com/developerworks/cn/linux/security/openssh/part3/index.html">Chinese</a> | <a href="http://www-128.ibm.com/developerworks/library/l-keyc3.html">English</a></li>
</ul>]]></description>
</item>
<item>
<link>http://www.zhyfly.org/blog/archives/2007/02/09/vacation_make_the_website_closed/index.html</link>
<title>Vacation make the website closed.</title>
<dc:date>2007-02-09T09:57:40+08:00</dc:date>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:subject>7.Miscellaneous</dc:subject>
<description><![CDATA[<p>Spring Festival which is the most important festival during the year in China is coming, all Chinese people come back to home to stay with the family. Therefore, we students have a long vacation and that's why you can not access the web site during the vacation. Sorry for that but wish everyone happiness in the new year.  <img src="http://www.flyzhy.org/blog/moods/smilies/wink.gif" alt=";)" /> </p>  ]]></description>
</item>
<item>
<link>http://www.zhyfly.org/blog/archives/2006/12/18/gnulinux_man_sections/index.html</link>
<title>GNU/Linux man sections</title>
<dc:date>2006-12-18T19:20:32+08:00</dc:date>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:subject>1.GNU/Linux</dc:subject>
<description><![CDATA[<p>The most common sections under GNU/Linux, and their human readable names, are:</p>
<pre>
Section The human readable name
   1    User commands that may be started by everyone.
   2    System calls, that is, functions provided by the kernel.
   3    Subroutines, that is, library functions.
   4    Devices, that is, special files in the /dev directory.
   5    File format descriptions, e.g. /etc/passwd.
   6    Games, self-explanatory.
   7    Miscellaneous, e.g. macro packages, conventions.
   8    System administration tools that only root can execute.
   9    Another (Linux specific) place for kernel routine documentation.
   n    (Deprecated) New documentation, that may be moved to a more appropriate section.
   o    (Deprecated) Old documentation, that may be kept for a grace period.
   l    (Deprecated) Local documentation referring to this particular system.
</pre>]]></description>
</item>
<item>
<link>http://www.zhyfly.org/blog/archives/2006/12/16/delete_some_certain_file_in_recursive_directories/index.html</link>
<title>Delete some certain file in recursive directories</title>
<dc:date>2006-12-16T14:46:36+08:00</dc:date>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:subject>3.Language</dc:subject>
<description><![CDATA[<p>I have many many pitures in recursive directories from Microsoft Windows XP, you know, it always creates a file named "<em>Thumbs.db</em>" to the default picture viewer in Microsoft Windows XP, so I want to delete all these files in my GNU/Linux system. You will know it's so easy to realize this in GNU/Linux or UNIX with the usage of <code>tree</code> and other Shell command.</p>
<p>Write a simple shell script as follows:</p>
<pre>
#!/bin/bash
# rm_ThumbsDOTdb.sh
for i in $(tree -a -f -i|grep 'Thumbs.db')
do
  rm -f $i
done
</pre>
<p>Copy this file to a directory in your <em>$PATH</em> and change directory to that you want to deal with and run:</p>
<pre>
<code>#rm_ThumbsDOTdb.sh</code>
</pre>
<p>You will get what you want now.  <img src="http://www.flyzhy.org/blog/moods/smilies/smiley.gif" alt=":)" /> </p>]]></description>
</item>
<item>
<link>http://www.zhyfly.org/blog/archives/2006/12/16/squid_to_setup_direct_proxy_server/index.html</link>
<title>squid to setup direct proxy server</title>
<dc:date>2006-12-16T14:35:49+08:00</dc:date>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:subject>5.Software</dc:subject>
<description><![CDATA[<p>The simplest application of <a href="http://www.squid-cache.org/">squid</a> is to setup a direct proxy server, that would let the clients to know the proxy server name(probably the IP address of the proxy server) and the http port. However, it's easy to make this come true, just follow me now.  <img src="http://www.flyzhy.org/blog/moods/smilies/wink.gif" alt=";)" /> </p>
<h3>Prepare</h3>
<p>The default user and group of squid would be <b>nobody</b> and <b>nogroup</b>, so the first thing you should do is to add this user (nobody) belongs to the <b>nogroup</b> group. If you have no this default user and group in your system(Slackware would create them while the installation. To check whether you have them in your system, just do the following:</p>
<pre>
<code>#cat /etc/group | grep nogroup</code>
nogroup::99:
<code>#cat /etc/passwd | grep nobody</code>
nobody:x:99:99:nobody:/:
</pre>
<p>If you got some messages like above, you got the default user and group now. Or else do the following operation:</p>
<pre>
<code>#groupadd nogroup</code>
<code>#useradd -g nogroup -d / -p passwd nobody</code>
</pre>
<h3>Download, compile and install</h3>
<p>Download the latest stable version of squid from <a href="http://www.squid-cache.org/">squid-cache</a> which probably like <em>squid-x.y-STABLE.tar.gz</em>.</p>
<p>Then compiling and installing squid as follows:</p>
<pre>
<code>#tar xvfz squid-x.y-STABLE.tar.gz</code>
<code>#cd squid-x.y-STABLE</code>
<code>#mkdir -p /usr/local/squid</code>
<code>#./configure --prefix=/usr/local/squid</code>
<code>#make</code>
<code>#make install</code>
</pre>
<h3>Configure</h3>
<p>The first squid configuration would be <em>/usr/local/squid/etc/squid.conf</em>, sometimes maybe you can use <em>/etc/squid/squid.conf</em> as the configuration file of squid. Anyway, my configuration is shown in the following:</p>
<pre>
acl deny_ip_01 dst 1.1.1.1
http_access deny deny_ip_01
acl deny_url_01 url_regex http://www.www.www
http_access deny deny_url_01
http_port 3128
cache_mgr FlyZhy.Org@Gmail.Com
cache_mem 64 MB
cache_dir ufs /usr/local/squid/var/cache 1024 16 256
cache_access_log /usr/local/squid/var/logs/access.log
cache_log /usr/local/squid/var/logs/cache.log
cache_store_log /usr/local/squid/var/logs/store.log
pid_filename /usr/local/squid/var/logs/squid.pid
#dns_nameservers 211.64.142.7
acl all src 0.0.0.0/0.0.0.0
#acl manager proto cache_object
# let 222.195.148.* to use the proxy server
#acl wan src 222.195.148.0/255.255.255.255
#acl localhost src 127.0.0.1/255.255.255.255
#acl to_localhost dst 127.0.0.0/8
acl SSL_ports port 443
acl Safe_ports port 80      # http
acl Safe_ports port 21      # ftp
acl Safe_ports port 443     # https
acl Safe_ports port 70      # gopher
acl Safe_ports port 210     # wais
acl Safe_ports port 1025-65535  # unregistered ports
acl Safe_ports port 280     # http-mgmt
acl Safe_ports port 488     # gss-http
acl Safe_ports port 591     # filemaker
acl Safe_ports port 777     # multiling http
acl CONNECT method CONNECT
#http_access allow manager localhost
#http_access allow wan
#http_access deny manager
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports
#http_access deny all
http_reply_access allow all
icp_access allow all
maximum_object_size 4096 KB
coredump_dir /usr/local/squid/var/cache
</pre>
<p>After the configuration of <b>squid.conf</b>, run <code>#/usr/local/squid/sbin/squid -z</code> to create the swap directories etc. According to this configuration you should have the following structure:</p>
<pre> 
<code>#tree -a -f -L 1 /usr/local/squid</code>
/usr/local/squid
|-- /usr/local/squid/bin
|-- /usr/local/squid/etc
|-- /usr/local/squid/libexec
|-- /usr/local/squid/man
|-- /usr/local/squid/sbin
|-- /usr/local/squid/share
`-- /usr/local/squid/var
<code>#tree -a -f -L 2 /usr/local/squid/var</code>
/usr/local/squid/var
|-- /usr/local/squid/var/cache
|   |-- /usr/local/squid/var/cache/00
|   |-- /usr/local/squid/var/cache/01
|   |-- /usr/local/squid/var/cache/02
|   |-- /usr/local/squid/var/cache/03
|   |-- /usr/local/squid/var/cache/04
|   |-- /usr/local/squid/var/cache/05
|   |-- /usr/local/squid/var/cache/06
|   |-- /usr/local/squid/var/cache/07
|   |-- /usr/local/squid/var/cache/08
|   |-- /usr/local/squid/var/cache/09
|   |-- /usr/local/squid/var/cache/0A
|   |-- /usr/local/squid/var/cache/0B
|   |-- /usr/local/squid/var/cache/0C
|   |-- /usr/local/squid/var/cache/0D
|   |-- /usr/local/squid/var/cache/0E
|   |-- /usr/local/squid/var/cache/0F
|   `-- /usr/local/squid/var/cache/swap.state
`-- /usr/local/squid/var/logs
    |-- /usr/local/squid/var/logs/access.log
    |-- /usr/local/squid/var/logs/cache.log
    |-- /usr/local/squid/var/logs/squid.pid
    `-- /usr/local/squid/var/logs/store.log
</pre>
<h3>Starting squid</h3>
<p>After all the preparation, then we modify the <em>/etc/rc.d/rc.local</em> file to make squid running automatically while booting the system:</p>
<pre>
# squid
if [ -x /usr/local/squid/sbin/squid ]; then
    echo -ne "Starting squid ...\n"
    echo -ne "\t\tHTTP Proxy Server: 222.195.148.225\n"
    echo -ne "\t\tPort: 3128\n"
    /usr/local/squid/sbin/squid
</pre>
<p>Ok, enjoy!</p>]]></description>
</item>
<item>
<link>http://www.zhyfly.org/blog/archives/2006/12/15/ftp_server_with_a_200gb_harddisk_using_vsftpd/index.html</link>
<title>FTP server with a 200GB harddisk using vsftpd</title>
<dc:date>2006-12-15T17:32:41+08:00</dc:date>
<dc:creator>Haiyong Zheng</dc:creator>
<dc:subject>1.GNU/Linux, 5.Software</dc:subject>
<description><![CDATA[<p>I have seted up the vsFTPd server with this <a href="/blog/archives/2006/02/08/T22_45_51/index.html">HowTo</a> that I written. However, I indeed met some problems while setting up a FTP server with a 200GB harddisk using vsftpd.</p>
<h3>Harddisk Partition</h3>
<p>First I have partitioned the harddisk as follows:</p>
<pre>
+------------------------------------+
|  hda1 |    hda2    | hda3   | hda4 |
| /boot | Linux Swap |  /     | N/A  |
| 100MB |   777MB    | others | 10GB |
+------------------------------------+
</pre>
<p>Unfortunately <em>hda3</em> which is the root partition and is bigger than 180GB got some error while booting the system, then I adjusted the partitions as follows:</p>
<pre>
+-----------------------------------+
| hda1 |    hda2    |  hda3  | hda4 |
|  /   | Linux Swap | /home  | N/A  |
| 10GB |   777MB    | others | 10GB |
+-----------------------------------+
</pre>
<p>Then I got the result I want and everything was ok.</p>
<p>I installed Slackware Linux 11.0 with the default installation of <em>vsftpd-2.0.5-i486-1.tgz</em>, then I put the same configuration as <a href="/blog/archives/2006/02/08/T22_45_51/index.html">my vsftpd HowTo</a>. However I got the error like:</p>
<pre>
OOPS: vsftpd: refusing to run with writable anonymous root
</pre>
<p>At last, I found the reason of this problem that I always have the following permission of the directory <b>/home/ftp</b>:</p>
<pre>
drwxr-xr-x   4 flyzhy  ftp       96 2006-09-08 12:07 ftp/
</pre>
<p>It's OK with this permission of this directory, however, if I changed the owner to <em>ftp</em> which is like:</p>
<pre>
drwxr-xr-x   4 ftp  ftp       96 2006-09-08 12:07 ftp/
</pre>
<p>I got the above error again, at last I changed the permission of this directory to:</p>
<pre>
dr-xr-xr-x   4 ftp     ftp       96 2006-09-08 12:07 ftp/
</pre>
<p>and everything went to ok, so it's not permitted to have the writable permission if you want someone login your ftp anonymous, also change the permission mode of <em>/ftp/incoming</em> to <em>777</em> to let anonymous to upload files.</p>
<p>Here lists the <em>/etc/vsftpd.conf</em> file without the comment lines:</p>
<pre>
anonymous_enable=YES
local_enable=YES
write_enable=YES
local_umask=022
anon_upload_enable=YES
anon_mkdir_write_enable=YES
anon_umask=022
dirmessage_enable=YES
message_file=.message
xferlog_enable=YES
connect_from_port_20=YES
xferlog_file=/var/log/vsftpd.log
xferlog_std_format=YES
ftpd_banner=Welcome to OUC-IPL-FTP.
ls_recurse_enable=YES
listen=YES
</pre>
<p>Also, if you want to limit the max number of clients and per ip as well as the speed, add the following lines to <em>/etc/vsftdp.conf</em>:</p>
<pre>
#max_clients=NUMBER
#max_per_ip=NUMBER
#
#anon_max_rate=NUMBER
#local_max_rate=NUMBER
# bytes
#anon_max_rate=5000000
#local_max_rate=5000000
</pre>
<p>At last, add some lines to <em>/etc/rc.d/rc.local</em> to let the system run <code>vsftpd</code> while booting:</p>
<pre>
# /etc/rc.d/rc.local
# vsftpd
if [ -x /usr/sbin/vsftpd ]; then
    echo -ne "Starting vsftpd ...\n"
    /usr/sbin/vsftpd &amp;
fi
</pre>
<p>After starting the <code>vsftpd</code> program, you can let the system user login the FTP using their own <em>user</em> and <em>password</em>, that would login to their own HOME in the system and also have all the permissions there.</p>
<p>OK, enjoy the FTP world now!</p>]]></description>
</item>
</channel>
</rss>
