User(s) browsing this thread: 1 Guest(s)
|
[200] lundftpd installation, configuration and setup package
|
|
12-15-2010, 10:11 PM
(This post was last modified: 12-19-2010 03:04 PM by dc11ab.)
|
|||
|
|||
|
lundftpd installation, configuration and setup package
LundFTPD is a small, yet feature rich FTP server made by lundman, author of llink and other NMT utilities and hacks.
Detailed information: http://www.lundman.net/wiki/index.php/LundFTPD DOWNLOAD CSI package available: http://www.lundman.net/wiki/images/7/7e/...3.17.1.zip Go to CSI menu and "Install from file..." CSI: http://www.nmtinstaller.com USAGE Connect with FTP client: User: nmt Password 1234 Port 2223 * You may want to change the password as the nmt user has full admin privileges. * Connection over SSL is enabled/available. * Default FTP-root is /opt/sybhttpd/localhost.drives/ If you want to change the configuration, open the file "lundftpd.conf" (typically in the install directory /share/Apps/lundftpd/) with your text editor. One easy way to do this is to connect to the NMT with SMB or NFS, browse to the lundftpd.conf file and open it with Notepad, vi, Textedit or your favorite text editor of choice. To add more users, connect to LundFTPD via FTP client and send FTP RAW commands: site ADDUSER <username> <password> <IP's> where IP's is * (a single asterisk/star) if you want the user to be able to connect from anywhere. site SETRATIO <username> <ratio> This sets the user's ul/dl ratio. Set to -1 for free/no ratio. site SETFLAGS <username> <user flag> - Set user's userflag level. UF_NONE is already set as default when a user is created above, UF_ALL means full admin rights. For more information, issue the FTP command site help CHANGELOG 3.17.1 - Minor package update: * FTP root changed from /share/ to /opt/sybhttpd/localhost.drives/ * All internal file checking enabled * groups_default disabled 3.17.0 - First CSI package release Original post below. I successfully compiled LundFTPD 3.17 for my C200. While that in itself is a triumphant success for someone like me (yay!), I still need some help to figure out how to implement and install it properly, and perhaps make a CSI package out of it. - How can I maintain the start_app.sh community script, yet "swap" the FTP server? There is "/nmt/apps/etc/ftpserver.sh stop", but I'm not sure it's reliable enough to put in a daemon startup scrip for lundftpd. - Do I need to add a script that, upon a first time install -for instance via CSI - adds a user nmt password 1234 account, or can I simply tar/zip/CSI-package the existing installation I have? - Are there any recommended settings in the conf file to think about, having in mind a general and similar setup to the existing FTP service from the NMT Apps? I'm thinking some people have USB disks instead of SATA_DISK, for instance. - I did compile with openssl included, but I have not made any keys etc. How should this be handled? (I personally have no need of a secure connection as I only transfer on my LAN, but I guess others could be interested). Any other comment or pointer would be most welcome, thank you! Audio, video, disco - I hear, I see, I learn. Wiki. Wiki? Wiki! |
|||
|
12-15-2010, 11:17 PM
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
What I did was, create the ftp-data/ files with the default user and password and tar that all up. So when you install it for the first time, those files are already there. You just have to make sure you don't pollute the files. I would also do a default/standard SSL cert so it works by default.
Generally, lundftpd is setup to have a root directory somewhere, could even be next to ftp-data/ like ftp-root/, and in there you can make symlinks to everywhere else. Like HDD->SATA_DISK or similar. I don't think I did that last time though, and just make the FTP root be /opt/sybhttpd/localhost.drives/ If you stick lftpd on a different port you don't have to worry about the default one, but if you want to make a replacement package, you do need to kill the default one first. You can probably use the script you mentioned, or simply kill pureftpd before starting lftpd. |
|||
1 user says Thank You to lundman for this post |
|
12-15-2010, 11:55 PM
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
Oh, I didn't know you already packaged it up for the NMT, but now I see:
http://www.lundman.net/wiki/index.php/LundFTPD_Download I'll check that setup and conf file, then! But I need to revisit the compile; I have no idea if Racestats is included, for instance. Does this indicate that it's there, or what should I look for in the config.status or so? Code: ftp> site RACESThank's for helping out a layman! Audio, video, disco - I hear, I see, I learn. Wiki. Wiki? Wiki! |
|||
|
12-16-2010, 12:32 AM
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
I think nearly everything is on by default.
Come to think of it, doing the "ship the ftp-data/ files" idea is not very good. That means if you ever get a new version, you'd lose all your accounts and settings. Better would be to have the install script use ./lundftpd -a to add the first account, if it does not exist... |
|||
|
12-16-2010, 12:41 AM
(This post was last modified: 12-16-2010 12:45 AM by dc11ab.)
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
Hmm, how should I pass arguments? It appears to be an interactive dialogue, so this doesn't work:
./lundftpd -a nmt 1234 UF_ALL *@*.*.*.* q -1 N I read this on your page: * Full remote administration features (minus setting user's passwords )Oh, and is the lftpd.pem found in your package suitable for reusing in a distributed CSI package? Audio, video, disco - I hear, I see, I learn. Wiki. Wiki? Wiki! |
|||
|
12-16-2010, 05:49 AM
(This post was last modified: 12-16-2010 05:49 AM by lundman.)
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
Yeah you can do..
You can do "site adduser" etc, but it does require the very first account. I would possibly try something like: Code: # printf "admin\npasswd\nUF_ALL\n*\nq\n-1\nn\n" | ./lundftpd -aThe pem file should be fine, and the passwd entry in features should be updated, it has been added. |
|||
|
12-16-2010, 12:45 PM
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
That works, I should be able to package version 3.17 in CSI format!
But it will get ugly because I haven't figured out how to handle the first initialization if it already encounters an existing installation, for instance if $INSTALLDIR/ftp-data/users already exist. Simple idea is to just die with echo "Error: existing installation detected, quitting." && exit 1 but I'm thinking there could be smarter ways to deal with this. I just haven't figured them out ![]() Some random thoughts: How about if we want to upgrade? If we only upgrade the binary, we might miss some new feature in the lundftpd.conf. it should at least make a backup of existing conf, and in an ideal world sed and replace current values into the new conf file. Will a binary upgrade/replacement care less how and what files exist, e.g. what users file contains, or is there a version dependency or something like that to take into account? Audio, video, disco - I hear, I see, I learn. Wiki. Wiki? Wiki! |
|||
|
12-16-2010, 02:13 PM
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
The .conf file has not changed much recently. The user file has not either, but there are upgrade features built in. I would not worry too much about those two, if the defaults are sane. You can make special case tests/sed in future install scripts if the conf does change
In the install script, I would do something like Code: if [ ! -f ftp-data/users ]; thenie, if there is no file called ftp-data/users, add the default user. |
|||
|
12-16-2010, 08:45 PM
(This post was last modified: 12-16-2010 09:08 PM by dc11ab.)
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
I've made a CSI package of LundFTPd-3.17 that appears to work (at least on my setup!).
And I took the liberty to host it on lundman's site ![]() http://www.lundman.net/wiki/images/7/76/...d-3.17.zip You should be able to "Install from file.." via the CSI. If you don't like that you can simply unzip/untar and install the files as you prefer. I'd appreciate anyone trying it out as I haven't covered all kinds of tests, I've basically just installed in CSI, connected and transferred a file: Code: $ ftp 192.168.1.23 2223I put the default root share to /share/ and the port to: 2223 (perhaps I should have set /opt/sybhttpd/localhost.drives as default ftp root to make it more flexible?) From top during idle: Code: Mem: 172640K used, 18656K free, 0K shrd, 33680K buff, 71856K cachedAnyway, when doing a large binary transfer: Code: Mem: 187648K used, 3648K free, 0K shrd, 2752K buff, 123552K cachedLundman; if the package is confirmed OK, would you mind adding it to your CSI repository? A little help info for new users in the xml (the one that presents for CSI users), such as the port to connect to etc. probably wouldn't hurt
Audio, video, disco - I hear, I see, I learn. Wiki. Wiki? Wiki! |
|||
|
12-16-2010, 11:52 PM
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
Yeha I can add it to repository, that's no issue. The reason for 3 process btw, is one is for the connections, one is for file-checking (sfv etc) and one is for dirlistings. That doesn't change, even with more users.
I'll try it out after work too.. |
|||
|
12-17-2010, 12:03 AM
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
Great, thank you!
The conf should really be revisited by someone who actually knows the app... I think I disabled some/most of the file checking because I was concerned about overall performance. Too worried? Audio, video, disco - I hear, I see, I learn. Wiki. Wiki? Wiki! |
|||
|
12-17-2010, 02:47 AM
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
I wouldn't really disable any of the file checking, since it only comes into effect if you upload something of that type (and if you do, you want it checked).
Really, little needs to be changed in the .conf, and indeed, much can be broken by changing too much
|
|||
|
12-17-2010, 08:03 AM
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
In the lundftpd.conf file checking section I see references that doesn't exist on most peoples NMT's unless they have symlinked this themselves or installed vaidyasrs ipkg CSI package:
/usr/local/bin/unarj /usr/local/bin/gunzip /usr/local/bin/lha /usr/local/bin/dmsdiz And even with ipkg, gunzip was the only one I could find. I don't think we should enable such checks unless we are certain that the dependencies are in place. Or does LundFTPd handle that gracefully? And just to verify: INTERNAL means that LundFTPd handles it by itself (built-in routines)? Audio, video, disco - I hear, I see, I learn. Wiki. Wiki? Wiki! |
|||
|
12-17-2010, 08:09 AM
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
i cant figure out how to create users, when i try to edit the file it says i dont have permission, and i have no idea how to do it from the pch.
|
|||
|
12-17-2010, 08:30 AM
(This post was last modified: 12-17-2010 08:32 AM by dc11ab.)
|
|||
|
|||
|
RE: lundftpd installation, configuration and setup package
You shouldn't edit a file to add users.
I know 2 ways to do user administration: 1. Connect via telnet to the FTP server (as root) and do "manual" user insertion: # ./lundftpd -a And follow the steps: username, password, level (UF_ALL is max) IP-range (only star, for instance: * <enter> q <enter>) ratio (-1 for unlimited) 2. Connect via FTP to the server and issue the SITE command (on my machine that only works with non-capitals: site) If you don't have telnet or so, I still think you should use a terminal to connect (On Windows: cmd.exe or putty, on Mac: Terminal, on Linux and other *nixes; mostly any shell). This should take you there # ftp ip.of.your.nmt 2223 # nmt # 1234 # site help The command is: site ADDUSER <USR> <PW> <IPS> Example: site ADDUSER TonyMontana fUAR234!8f * The last * means that the user can connect from anywhere. If you want to restrict the user to only connect from a certain IP range you can set that. All user commands: Code: |-[ USER RELATED COMMANDS ]----------------------------------------------------|If you connect via an FTP client, such as FileZilla, some feature a "Send RAW command"-function (or worded similarly). This is where you enter the "site" commands! (capital or not) Audio, video, disco - I hear, I see, I learn. Wiki. Wiki? Wiki! |
|||
|
« Next Oldest | Next Newest »
|

Twitter
Facebook
NMT Wiki
Search
Member List
Help
A-400 [13 May 2013]






![[+]](images/collapse_collapsed.gif)



)

