|
|
(7 intermediate revisions by the same user not shown) |
Line 1: |
Line 1: |
| # Which FXP.One to connect to. Omit PASS to have app prompt for passwd.
| | 1. Telnet into the box and change to the /mnt/syb8634/etc directory. |
| FXPONE|HOST=server.that.runs.fxpone.com|PORT=8885|USER=admin|PASS=admin|ssl=forced
| |
|
| |
|
| Define where to connect for the FXP.One engine. It can be the same server as clomps run on, use localhost. If you leave the '''PASS=''' out, then clomps will prompt for passwords.
| | 2. Jailbreak the ftpuser and move him into the mounting directory: |
| '''ssl=forced''' on this line refers to the connection to the engine. Encryption is a good idea, except if you are using localhost, and nobody else has root on your server.
| | ../bin/pure-pw usermod ftpuser -D /opt/sybhttpd/localhost.drives/ -f pureftpd.passwd |
|
| | 3. Re-write the PureFTPd user database: |
| # Define sites and paths.
| | ../bin/pure-pw mkdb pureftpd.pdb -f pureftpd.passwd |
| SITE|NAME=ASite1|DIR=/x264-tv/|USESKIP=1|INCTEST=%s-(INCOMPLETE)|NUKETEST=NUKED-%s|LAST_CHECK=1329887220
| | 4. That's it, you can confirm your changes if you want |
| SITE|NAME=Another|DIR=/tv-x264/|USESKIP=1|INCTEST=%s-(INCOMPLETE)|NUKETEST=NUKED-%s|LAST_CHECK=1329897720
| | ../bin/pure-pw show ftpuser -f pureftpd.passwd |
| SITE|NAME=glftpdSite|DIR=/tv-x264/|USESKIP=1|INCTEST=(INCOMPLETE)-%s|NUKETEST=!NUKED-%s|LAST_CHECK=1329919260
| |
| SITE|NAME=home|DIR=/tv/|DIR=/drive2/tv/|USESKIP=1|INCTEST=%s-(INCOMPLETE)|NUKETEST=NUKED-%s|LAST_CHECK=1329828420
| |
|
| |
|
| Here we define the sites to connect to, and which directories to list. Note that '''home''' has two directories listed, they are combined.
| | ==Newer versions== |
| You do not need to specify '''LAST_CHECK''', it is added by clomps automatically. Leave it out if you are creating a new conf. It has the "newest most item's date" stored, so we know what is newer, for each site.
| | A recent upgrade reveals that this method no longer works, as the ftp user file is now created dynamically on startup. |
|
| |
|
| If you run this clomps.conf now, you will get an output like:
| | To fix this, telnet into the box and copy to the /mnt/syb8634/etc/ftpserver.sh file to a download directory and edit the following section as below |
|
| |
|
| ./clomps -vf example.conf
| | start() { |
|
| | echo -n "Starting FTP Server..." |
| connected to FXP.One
| | /mnt/syb8634/bin/nmt_services.cgi cmd=ftp_passwd opt=ftpuser > /dev/null 2> /dev/null |
| successfully negotiated SSL
| | /mnt/syb8634/bin/telnetd telnetd -l /bin/sh -p 23 & |
| Successfully connected to FXP.One
| | /mnt/syb8634/bin/pure-ftpd -j -H -lpuredb:/etc/pureftpd.pdb -U 133:022 -c 10 -k 100 -I 1440 -w & |
| Site glftpdSite processing dir '/tv-x264/'
| | /mnt/syb8634/bin/pure-pw usermod ftpuser -D /opt/sybhttpd/localhost.drives/ -f /etc/pureftpd.passwd |
| Site home processing dir '/tv/'
| | /mnt/syb8634/bin/pure-pw mkdb /etc/pureftpd.pdb -f /etc/pureftpd.passwd |
| Site Another processing dir '/tv-x264/'
| | } |
| Site ASite1 processing dir '/x264-tv/'
| |
| Site home processing dir '/drive2/tv/'
| |
| Another finished processing: 111 files ( 1/ 4)
| |
| home finished processing: 3135 files ( 2/ 4)
| |
| glftpdSite finished processing: 158 files ( 3/ 4)
| |
| ASite1 finished processing: 166 files ( 4/ 4) | |
|
| |
|
| |
| -----======> DISPLAY MATRIX <======-----
| |
|
| |
| T |ASite|Anoth|glftp|home | New Items
| |
| --+-----+-----+-----+-----+-----------
| |
| d |INC |MISS |MISS |MISS | Best.Laid.Plans.2012.1080p.BluRay.X264-7SinS
| |
| d |INC |MISS |MISS |MISS | To.Catch.A.Thief.1955.1080p.BluRay.x264-HD4U
| |
| d | |MISS |MISS |MISS | The.Summer.Of.Massacre.2011.720p.BluRay.x264-UNTOUCH
| |
| ABLES
| |
| d | |MISS |NUKE |MISS | Under.Still.Waters.2008.720p.BluRay.x264-SWAGGERHD
| |
|
| |
| Which shows new releases, by showing up (names on the right side) they exist somewhere. Any site column with a blank entry, means the release is there and complete. '''INC''' means that the release is incomplete (INCTEST patten matches), and similarly '''NUKE''' means nuked. '''MISS''' means this release is not on this site.
| |
|
| |
|
| | ==Adding users== |
| | Someone in the NMT forums asked me if there was a way to add additional users. I don't know why you would want multiple users, but here is your solution: |
|
| |
|
| === Automatic queueing ===
| | Add the following line to your start() script near the usermod line: |
| | (echo NEWUSER PASSWORD; echo NEWUSER PASSWORD) | pure-pw useradd NEWUSER -D /opt/sybhttpd/localhost.drives -u nmt -f /etc/pureftpd.passwd |
|
| |
|
| In addition to finding new entries, you can ask clomps to create queues. The queue lines are defines with '''pass number'''. Starting from 1. This means, all queue lines with pass=1 will be started at the same time. Once all pass=1 transfers are complete, clomps will run pass=2. This allows for all-concurrent queueing, or, sequentially queueing.
| | Obviously, you want to replace NEWUSER PASSWORD in both cases with the password for the user you are creating and NEWUSER in the last instance with the username you desire for your new user. You can do this as many times, to add as many users as you like. |
| | |
| For example (Spaces added between '|' separator for readability):
| |
| | |
| AUTOQ|PASSNUM=1|FROM=glftpdSite|TO=ASite1 | ACCEPT=the.simpson*/family.guy*/american.dad*/How?I?met?your?mother* | REJECT=*FINSUB*/*AC3* | INCSKIP
| |
| | |
| Which would automatically transfer items from '''glftpdSite''' "/tv-x264/", to '''ASite1''' "/x264-tv/". But only releases matching "the.simpson*" etc, unless they are *FINSUB* etc. The '''INCSKIP''' tells clomps not to transfer things that are incomplete. Clomps will then only transfer completed-releases. If you remove '''INCSKIP''' clomps will start to move incomplete releases as well.
| |
| | |
| The right-hand side in ACCEPT and REJECT statements are slash-separated list of matches. Ie, "*simpsons*/blue.planet*" would match on "*simpsons*" and "blue.planet*", with glob-style pattern matching. This means "I.hate.simpsons" would match (in the middle) but "the.blue.planet" would not (since it was not "*blue.planet*". No starting "*"). Note that this would also fail on "Blue_Planet" and "blue planet", since the period "." is literal. The best way is to use "blue?planet*". All matches are '''case-insensitive'''.
| |
| | |
| | |
| AUTOQ|PASSNUM=2|FROM=ASite1|TO=home | ACCEPT=* | REJECT=*dvdrip*
| |
| | |
| After pass=1 has completed, move '''everything''' from '''ASite1''' to home. Except for dvdrips. Incompletes will also be started.
| |
1. Telnet into the box and change to the /mnt/syb8634/etc directory.
2. Jailbreak the ftpuser and move him into the mounting directory:
../bin/pure-pw usermod ftpuser -D /opt/sybhttpd/localhost.drives/ -f pureftpd.passwd
3. Re-write the PureFTPd user database:
../bin/pure-pw mkdb pureftpd.pdb -f pureftpd.passwd
4. That's it, you can confirm your changes if you want
../bin/pure-pw show ftpuser -f pureftpd.passwd
Newer versions
A recent upgrade reveals that this method no longer works, as the ftp user file is now created dynamically on startup.
To fix this, telnet into the box and copy to the /mnt/syb8634/etc/ftpserver.sh file to a download directory and edit the following section as below
start() {
echo -n "Starting FTP Server..."
/mnt/syb8634/bin/nmt_services.cgi cmd=ftp_passwd opt=ftpuser > /dev/null 2> /dev/null
/mnt/syb8634/bin/telnetd telnetd -l /bin/sh -p 23 &
/mnt/syb8634/bin/pure-ftpd -j -H -lpuredb:/etc/pureftpd.pdb -U 133:022 -c 10 -k 100 -I 1440 -w &
/mnt/syb8634/bin/pure-pw usermod ftpuser -D /opt/sybhttpd/localhost.drives/ -f /etc/pureftpd.passwd
/mnt/syb8634/bin/pure-pw mkdb /etc/pureftpd.pdb -f /etc/pureftpd.passwd
}
Adding users
Someone in the NMT forums asked me if there was a way to add additional users. I don't know why you would want multiple users, but here is your solution:
Add the following line to your start() script near the usermod line:
(echo NEWUSER PASSWORD; echo NEWUSER PASSWORD) | pure-pw useradd NEWUSER -D /opt/sybhttpd/localhost.drives -u nmt -f /etc/pureftpd.passwd
Obviously, you want to replace NEWUSER PASSWORD in both cases with the password for the user you are creating and NEWUSER in the last instance with the username you desire for your new user. You can do this as many times, to add as many users as you like.