在linux系统中curlftpfs自动挂载ftp


yum install -y http://ftp.tu-chemnitz.de/pub/linux/dag/redhat/el6/en/x86_64/rpmforge/RPMS/rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm

yum install -y curlftpfs

mkdir -R /mnt/ftp

chmod 777 /mnt/ftp

echo "curlftpfs -o rw,allow_other,uid=0,gid=0,umask=001 -o nonempty ftp://user:password@xx.xx.xx.xx /home/nas/ftp">>/mnt/a.sh

chmod 777 /etc/rc.local

echo "/bin/bash /mnt/a.sh">>/etc/rc.local

/bin/bash /mnt/a.sh

注意:一定不能写入fstab,否则会导致系统无法正常启动


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM