app教程网 综合百科 centos vsftpd配置(vsftpd status)

centos vsftpd配置(vsftpd status)

3.使用rpm-IVH VSFTPD-2 . 2 . 2-11 . el6 _ 3.1 . src . rpm安装软件包:

[root@localhostbirdofprey]#rpm-ivhvsftpd-2.2.2-11.el6_3.1.src.rpm

在安装过程中,系统会提示类似如下的错误:

warning:vsftpd-2.2.2-11.el6_3.1.src.rpm:HeaderV3RSA/SHA1Signature,keyIDc105b9de:NOKEY

1:vsftpdwarning:usermockbuilddoesnotexist-usingroot

###########################################[100%]

warning:usermockbuilddoesnotexist-usingroot

warning:groupmockbuilddoesnotexist-usingroot

warning:usermockbuilddoesnotexist-usingroot

warning:groupmockbuilddoesnotexist-usingroot

warning:usermockbuilddoesnotexist-usingroot

warning:groupmockbuilddoesnotexist-usingroot

此时,您需要使用adduser mockbuild命令来创建一个mockbuild用户:

[root@localhostbirdofprey]#addusermockbuild

4.重复使用rpm-IVH VSFTPD-2 . 2 . 2-11 . el6 _ 3.1 . src . rpm来安装软件包:

[root@localhostbirdofprey]#rpm-ivhvsftpd-2.2.2-11.el6_3.1.src.rpm

warning:vsftpd-2.2.2-11.el6_3.1.src.rpm:HeaderV3RSA/SHA1Signature,keyIDc105b9de:NOKEY

1:vsftpd###########################################[100%]

5、使用命令CD/root/rpmbuild/SOURCES/vsftpd/SOURCES进入vsftpd源码包目录,

And use tal-zxvf vsftpd-2.2.2.tar.gz to decompress the vsftpd-2.2.2.tar.gz source package:

[root@localhostSOURCES]#tar-zxvfvsftpd-2.2.2.tar.gz

6.使用命令cd vsftdp-2.2.2进入vsfftpd-2.2.2的源目录:

[root@localhostSOURCES]#cdvsftpd-2.2.2

7. Use the command 6. Feature modification function. C file; The line content is: vsf_cmdio_write_raw(p_sess,' utf8 \ r \ n');

修改为://vsf_cmdio_write_raw(p_sess,' UTF8\r\n ')。

8.使用命令vi opts.c修改opts.c文件;

修改handle_opts函数,如下所示:

void

handle_opts(structvsf_session*p_sess)

{

str_upper(p_sess-ftp_arg_str);

//if(str_equal_text(p_sess-ftp_arg_str,'UTF8ON'))

//{

//vsf_cmdio_write(p_sess,FTP_OPTSOK,'AlwaysinUTF8mode.');

//}

//else

//{

//vsf_cmdio_write(p_sess,FTP_BADOPTS,'Optionnotunderstood.');

//}

}

9.返回到上层目录,用tar-zcvf vsftpd-2.2.2.tar.gz vsftpd-2 . 2 . 2/command重新压缩vsftpd-2.2.2.tar.gz文件:

[root@localhostSOURCES]#tar-zcvfvsftpd-2.2.2.tar.gzvsftpd-2.2.2/

我们可以使用ls-命令查看列表中vsftpd-2.2.2.tar.gz文件的创建时间已经是当前的创建时间,如下所示:

-rw-rw-r。 1 Simulation Construction Simulation Construction 186982 May 3 15: 39 VSFTPD-2.2.2.tar.gz-RW-R-R-. 1 simulation construction simulation construction 2828 February 13 00: 06 vsftpd-2.2.2-uint-uigid.patch-rw-r-r-. 1 simulation build simulation build 1640 February 13 00:06 vsftpd-2. 2. 2- V6. patch-rw-r-r- only. 1 simulation construction simulation construction 514 February 13 00: 06 vsftpd-close-STD-FDS. patch-rwxr-xr-x.1 mock build mock build 338 February 13 00: 06 vsftpd _ conf _ migrate.sh-rw-r-. 1 simulation build simulation build 125 February 13 00: 06 vsftpd.ftpusers-rwxr-xr-x.1 mock build 2824 February 13 00:06 vsftpd.init-rw-r-r-. 1 simulation construction simulation construction 335 February 13 00:06 vsftpd.pam-rw-r-r-. 1 simulation build simulation build 361 February 13 00: 06 vsftpd. user _ list-rw-r-r-. 1 simulation build simulation build 345 February 13 00:06 vsftpd.xinetd10, enter the specification directory under the source package,

[root@localhostSPECS]#rpmbuild-bbvsftpd.spec

此时,将会报告以下错误,因为系统缺少依赖包:

Error: Failed to generate dependency: vsftpd-2.2.2-11.el6.1.x86 _ 64tcp _ wrappers-vsftpd-2.2.2-11.el6.1.x86 _ 64 requires libcap-devel. We can find the following RPM software package from the Lisi 6.4 installation disk to start.

libattr-2。4 .44-7 .el6。i686。rpm libcap-devel-2.16-5.5。el6。x86 _ 64。rpmlibattr-2。4 .44-7 .el6。x86 _ 64。rpm TCP _ wrappers-devel-7.6-57。el6。i686。rpmlibattr-devel-2。4 .44-7.el 6。i686。rpm TCP _ wrappers-开发将以上各包使用rpm -ivh * .rpm -force - nodeps命令进行强制安装:

[root@localhostrpm]#rpm-ivh*.rpm--force--nodeps

warning:libattr-2.4.44-7.el6.i686.rpm:HeaderV3RSA/SHA1Signature,keyIDc105b9de:NOKEY

Preparing.###########################################[100%]

1:libattr###########################################[8%]

2:libcap###########################################[17%]

3:tcp_wrappers-libs###########################################[25%]

4:libattr###########################################[33%]

5:libcap###########################################[42%]

6:tcp_wrappers-libs###########################################[50%]

7:tcp_wrappers-devel###########################################[58%]

8:libcap-devel###########################################[67%]

9:libattr-devel###########################################[75%]

10:tcp_wrappers-devel###########################################[83%]

11:libcap-devel###########################################[92%]

12:libattr-devel###########################################[100%]

12.再次使用rpmbuild -bb vsftpd.spec重新编译vsftpd-2 . 2 . 2-11 . El 6.1 . x86 _ 64 . rpm包:

[root@lo

本文来自网络,不代表本站立场,转载请注明出处:https: