FTPMIRROR(8)

πŸ’… ftpmirror(8) β€” the FTP mirroring bestie πŸ’…

okay so bestie, welcome to ftpmirror, section 8 of the manual (iykyk, admin girlies only). sit down, grab a strawberry drink πŸ“, and let me tell you everything about this icon.


✨ NAME ✨

ftpmirror β€” mirroring a whole directory hierarchy using the FTP protocol. yes, the whole thing. it's giving "copy the entire vibe, not just one file" πŸ¦‹


πŸŽ€ SYNOPSIS πŸŽ€

ftpmirror [package]

🌸 DESCRIPTION 🌸

ftpmirror is a utility that copies a directory hierarchy β€” which we lovingly call a 'mirror' β€” over the FTP protocol. literally the whole tree, no crumbs left behind 🧚

there's a similar perl script out there named mirror, and she's cute too, but ftpmirror uses less memory than mirror. so if your little machine is struggling, ftpmirror is the one holding it down. periodt πŸ’…


πŸ”₯ OPTIONS πŸ”₯

okay so before we go ANY further, a lil heads up: the original documentation for ftpmirror was written in japanese. it lives in README.jis and RELEASE.jis.

if you can help translate any aspect of those files, please hit up Dario Minnucci <debian@midworld.net>. he says he'd be glad to include your contributions here to improve this manual. group project energy 🫢

back in the day, ftpmirror's operation mode was MASTER->SLAVE, but it seems that since version 1.96 the SLAVE->MASTER (reverse mirror) is supported too. glow-up fr fr ✨

this behaviour can be controlled for each package section in the main configuration file, which is /etc/ftpmirror/ftpmirror.cf.

  • MASTER->SLAVE β†’ get-mode = yes (default)
  • SLAVE->MASTER β†’ put-mode = yes

other configuration flags extracted from the original documentation are:

bestie, sorry, but most of them are still undocumented. we work with what we have 😭
  • todo β€” string, default: full-mirror
  • verbose β€” boolean, default: no
  • log-mask β€” comma separated list
  • test-mode β€” boolean, default: no
  • ftp-server β€” string
  • ftp-gateway β€” string
  • ftp-port β€” service, default: ftp
  • ftp-bindaddr β€” ip address
  • ftp-user β€” string, default: anonymous
  • ftp-pass β€” string, default: `whoami`@`hostname`
  • ftp-group β€” string
  • ftp-gpass β€” string
  • ftp-passive β€” boolean, default: no. to enable passive file transfer set ftp-passive to yes.
  • ftp-idle β€” numeric, default: 0
  • ftp-max-idle β€” boolean, default: 0
  • ftp-list-method β€” LIST or STAT or STAT-A or STAT-AT, default: STAT
  • ftp-timeout β€” numeric, default: 300
  • ftp-login-retry β€” numeric
  • ftp-login-delay β€” numeric, default: 60
  • ftp-stats β€” boolean, default: no
  • remote-timezone β€” timezone string, default: undef
  • http-proxy β€” string
  • server β€” string
  • package β€” string
  • put-mode β€” boolean, default: no
  • unlink β€” boolean or 'rename', default: yes
  • unlink-limit β€” size value, default: 0
  • ftp-force-mtime β€” boolean, default: no
  • ignore-mtime β€” boolean, default: no
  • temp-directory β€” pathname, default: $TMPDIR || /tmp
  • lock-directory β€” pathname, default: temp-directory
  • create-directory β€” boolean, default: yes
  • remote-directory β€” string
  • local-directory β€” pathname
  • master-db-directory β€” pathname
  • remote-db-directory β€” pathname
  • local-db-directory β€” pathname
  • lslR-file β€” string
  • lslR-copy β€” pathname
  • transfer-file-regexp β€” regexp
  • transfer-directory-regexp β€” regexp
  • override-file-regexp β€” regexp
  • override-directory-regexp β€” regexp
  • load-local-dirinfo β€” boolean, default: no
  • store-local-dirinfo β€” boolean, default: no
  • load-remote-dirinfo β€” boolean, default: no
  • override-file-uid β€” uid, default: 0
  • override-file-gid β€” uid, default: 0
  • override-file-mode β€” octal value, default: 0644
  • override-directory-mode β€” octal value, default: 0755
  • default-file-uid β€” uid, default: 0
  • default-file-gid β€” gid, default: 0
  • default-file-mode β€” octal value, default: 0644
  • default-directory-mode β€” octal value, default: 0755

🌈 EXAMPLES 🌈

ftpmirror ships a 'ready-to-use' sample package, just for testing purposes. if you wanna run the provided test package, you need to issue the following commands β€” and yes, both commands must be run by the same user (no switching mid-way, bestie, that's not the vibe):

mkdir -p /tmp/upstream
/usr/bin/ftpmirror upstream

this package should copy the directory hierarchy from the original author's FTP location, which is ftp://ftp.intec.co.jp/pub/utils/ftpmirror, straight to your local hard drive at /tmp/upstream. so satisfying when it lands πŸ¦‹


⭐ IMPORTANT CONSIDERATION ⭐

bestie. listen. the inclusion of this configuration is intended to be used occasionally. please don't abuse this site. we are guests there, okay? be polite, be humble, don't be that person. πŸ™ˆ

πŸ‘‘ SEE ALSO πŸ‘‘

for other supported configuration options, go peek at /etc/ftpmirror/ftpmirror.cf, where you'll find commented examples. little cheat sheet, tucked right there for you πŸ’–


πŸ’œ AUTHOR πŸ’œ

ftpmirror was originally written by Ikuo Nakagawa <ikuo@intec.co.jp> πŸ‘‘

this manual page was written by Dario Minnucci <debian@midworld.net>, for the Debian project (but may be used by others). icon behaviour fr πŸ’…


and that's the whole page, bestie πŸŽ€ shoutout to Dario Minnucci <debian@midworld.net> for writing this one, dated June 1, 2007, living in section FTPMIRROR(8). go mirror something and slay πŸ’–βœ¨πŸ¦‹