Page 4 of 11 FirstFirst ... 23456 ... LastLast
Results 31 to 40 of 109

Thread: My take on setup ipkg on box office device

  1. #31
    Join Date
    Jan 2010
    Posts
    130

    Default to supergizboy

    Here's what you asked for:

    # grep -v '^#' /opt/etc/vsftpd.conf (paste the output here):
    anonymous_enable=YES
    local_enable=YES
    write_enable=YES
    local_umask=022
    anon_upload_enable=YES
    anon_mkdir_write_enable=YES
    dirmessage_enable=YES
    xferlog_enable=YES
    connect_from_port_20=YES
    vsftpd_log_file=/opt/var/log/vsftpd.log
    ascii_upload_enable=YES
    ascii_download_enable=YES
    ftpd_banner=Welcome to My PBO.
    ls_recurse_enable=YES
    listen=YES
    ftp_username=nobody

    # ipkg-cl list (paste output here):
    btpd - 0.0.1-svn174604 -
    ipkg-opt - 0.99.163-10 -
    samba - 3.0.23c-svn234664 -
    uclibc-opt - 0.9.28-13 -
    unicgi - 0.0.1-svn184197 -
    vsftpd - 2.2.2-1 -
    Successfully terminated.

    FYI, when I installed vsftpd I got an error message very similar to an earlier post:
    Configuring vsftpd
    You'll need to add line like
    echo "ftp stream tcp nowait root /opt/sbin/vsftpd /opt/etc/vsftpd.conf" >>/etc/inetd.conf
    to your /unslung/rc.xinetd file -- see the wiki at http://www.nslu2-linux.org for more info
    mkdir: Cannot create directory `/usr/share/empty': Cannot allocate memory
    Successfully terminated.

    And yes, I have the latest firmware.

  2. #32

    Default

    that's odd, exactly what i have, mine working with no issue at all.

    the install message is not an error, it's informational message, tells you to enable auto start vsftpd from inet. but my instruction is to run vsftpd as standalone server (listen=YES), b/c /etc/inetd.conf is read-only.

    try adding this line to /opt/etc/vsftpd.conf,

    local_root=/tmp/hdd/volumes/HDD1
    note: run df -h to check make sure this is where the file system is mounted for your internal hdd

    then reboot your pbo, try manual start first so you can see the error if any.

  3. #33
    Join Date
    Jan 2010
    Posts
    130

    Default

    First, I did :/ # df -h
    Filesystem Size Used Available Use% Mounted on
    /dev/root 63.1M 63.1M 0 100% /
    /dev/mtdblock/3 40.0M 1.2M 38.8M 3% /usr/local/etc
    /dev/rd/0 40.0k 40.0k 0 100% /mnt/rd
    /dev/scsi/host0/bus0/target0/lun0/part1 465.3G 107.8G 357.5G 23% /tmp/hdd/volumes/HDD1
    /dev/scsi/host0/bus0/target0/lun0/part3 151.9M 14.5M 129.6M 10% /tmp/hdd/root

    I added the line "local_root=/tmp/hdd/volumes/HDD1 " to the conf file.

    Then I go to DOS and still get the same error message:
    Connected to venus.
    500 OOPS: vsftpd: not found: directory given in 'secure_chroot_dir':/usr/share/e
    mpty
    500 OOPS: child died
    Connection closed by remote host.


    Thanks for your patience - this has been most frustrating for me.

  4. #34

    Default

    i'll do some deep looking when i get home tonight by my pbo. don't be frustrated, this is the fun part.

    btw, can you post what files you have under /opt/etc (ls -la /opt/etc)

    also can try this,

    1. remove the previous line
    secure_chroot_dir=local_root=/tmp/hdd/volumes/HDD1 from /opt/etc/vsftpd.conf

    2. add this line instead,
    secure_chroot_dir=/tmp/hdd/volumes/HDD1

    reboot.

    added:
    i think i see why you're seeing the error and i'm not, on my pbo, i do have /usr/share/empty directory, can you paste "ls -lah /usr/share" output here?
    Last edited by supergizboy; 03-04-2010 at 09:21 PM.

  5. #35

    Default

    Everytime I FTP in now (From following your instructions with the other guy) it says this:
    Quote Originally Posted by My PBO
    Response: 220 Welcome to My PBO.
    Command: USER root
    Response: 331 Please specify the password.
    Command: PASS
    Response: 500 OOPS: cannot change directory:
    Error: Critical error
    Error: Could not connect to server
    We're all getting closer, any ideas as to what could be wrong?

    EDIT:
    Quote Originally Posted by robfantini View Post
    when i try
    Code:
    mkdir /tmp/hdd/root/opt
    mount -o remount,rw /
    
    # then 
    ln -sf /tmp/hdd/root/opt /opt
    this error happens:
    Code:
    ln: /opt: Cannot allocate memory
    maybe caused by no room on / ?
    Code:
    / # df -h
    Filesystem                Size      Used Available Use% Mounted on
    /dev/root                63.1M     63.1M         0 100% /
    /dev/mtdblock/3          40.0M      1.2M     38.8M   3% /usr/local/etc
    /dev/rd/0                40.0k     40.0k         0 100% /mnt/rd
    /dev/scsi/host0/bus0/target0/lun0/part1    465.3G    454.9G     10.4G  98% /tmp/hdd/volumes/HDD1
    /dev/scsi/host0/bus0/target0/lun0/part3    151.9M     11.6M    132.5M   8% /tmp/hdd/root
    Any suggestion to solve this?
    You have to downgrade your firmware, I said screw it and updated to the latest and greatest and ran into that. As soon as this finally takes off, I'm going to see how difficult it would be to start development on a custom firmware of my own.


    EDIT2: Got it... and it's about bloody time.
    Quote Originally Posted by Do Me Step by Step
    vi /etc/passwd
    replace root::0:0:root::/bin/sh with root::0:0:root:/root:/bin/sh
    Than hit esc
    Type: :wq! than hit enter
    Than back in bash go mkdir /root
    Enjoy
    Last edited by kyle12; 03-05-2010 at 06:08 AM.

  6. #36
    Join Date
    Jan 2010
    Posts
    130

    Default Finally!!

    I thought I posted this yesterday morning, but it wasn't there, so I'll post it now:

    After looking on the Internet for more info on vsftpd, I added the following line to the conf file:
    run_as_launching_user=YES

    Bingo! Works like a charm now!

    And I got vsftpd to autostart on boot by inserting the start line (/opt/sbin/vsftpd /opt/etc/vsftpd.conf &) in the /tmp/package/script/configsamba script.

    Thanks to all on this thread, esp. supergizboy, for your varied input which allowed me to piece together a solution (along with a little bit of my own investigation).

    supergizboy: I wonder why your PBO had the needed directory (/usr/share/empty) and mine didn't? That would have made things much easier for me!

    Coda: Now that I'm capable of file transfer via FTP to my PBO, I must say that I'm not sure what the hoopla is all about in terms of transfer speed. It's very consistent (4.3 MB rate), but my transfer rate via Samba is actually faster (4.7 MB). Oh, well... it was fun learning a bit more about Linux and telnet!

  7. #37

    Default

    Quote Originally Posted by jamaroney View Post
    I thought I posted this yesterday morning, but it wasn't there, so I'll post it now:

    After looking on the Internet for more info on vsftpd, I added the following line to the conf file:
    run_as_launching_user=YES

    Bingo! Works like a charm now!

    And I got vsftpd to autostart on boot by inserting the start line (/opt/sbin/vsftpd /opt/etc/vsftpd.conf &) in the /tmp/package/script/configsamba script.

    Thanks to all on this thread, esp. supergizboy, for your varied input which allowed me to piece together a solution (along with a little bit of my own investigation).

    supergizboy: I wonder why your PBO had the needed directory (/usr/share/empty) and mine didn't? That would have made things much easier for me!

    Coda: Now that I'm capable of file transfer via FTP to my PBO, I must say that I'm not sure what the hoopla is all about in terms of transfer speed. It's very consistent (4.3 MB rate), but my transfer rate via Samba is actually faster (4.7 MB). Oh, well... it was fun learning a bit more about Linux and telnet!
    good job.
    i don't know why i have the /usr/share/empty directory you don't, might be the boot code version, do you have the latest boot code (i think .18)?
    i'd think nfs would be the fastest, especially when you configure it to run as udp instead of tcp, but haven't tested it. tcp has so much overhead.

  8. #38
    Join Date
    Jan 2010
    Posts
    130

    Default

    Actually, I spoke too soon about slower FTP speeds. I use the program WS-FTP LE, and the "Transmission Size" setting (under "Network Buffer Size") was by default set to 512. I upped it to its max of 4096, and speeds immediately jumped up from my original 4.3 MB to around 5.7-6.0. So, now the FTP speed is almost 20% faster than Samba, as opposed to before when it was a bit slower.

    I have bootcode .16, which perhaps explains my PBO's lack of the /usr/share/empty directory. I would like to upgrade the bootcode, but from all I've read in these posts, that currently requires an RMA, and I have no pressing need for it.

    One thing about the ftp, however: While I can move files back and forth no problem, I can't delete/rename/overwrite any existing file on the PBO end. It keeps saying "Permission denied". I checked the attributes for all files in /tmp/hdd/volumes/HDD1, and they indicate rw for all users.

    Any thoughts about this? It's not a big deal, as I can easily delete/rename/overwrite the files via Samba, but it would be nice to not have to go back and forth between FTP and Samba.


    Also, just out of curiosity, I removed these lines from vsftpd.conf:
    local_root=/tmp/hdd/volumes/HDD1
    run_as_launching_user=YES

    and then simply inserted supergizboy's suggestion:
    secure_chroot_dir=/tmp/hdd/volumes/HDD1

    FTP worked just as well, so either string worked in my situation. (Yet the delete/rename/overwrite problem remained).

  9. #39

    Default

    are you logging in with "root" or "anonymous"?

    i think the package was compiled to have secure_chroot_dir pointing to /usr/share/empty, since you don't have that directory, that's why it failed. now you specifically defined secure_chroot_dir to an existing directory, it works. when using run_as_launching_user, it breaks the chroot ftp feature, that's why it works for you.

  10. #40
    Join Date
    Jan 2010
    Posts
    130

    Default

    I log onto Venus via FTP as "anonymous" (and then type anything for a password)
    I just tried logging in as "root" but I don't know the password.
    Would this be why I can't delete/rename/overwrite files?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •