1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Tomato ND USB Mod

Discussion in 'Tomato Firmware' started by teddy_bear, Dec 17, 2008.

  1. CBR900

    CBR900 Addicted to LI Member

    I managed to get a usb flash memory formated in fat system and now it is working and can access it through lan and wan. thx alot teddy_bear.

    Here also I like to be able to use a webcam with my asus wl-500gp.
  2. eRd12

    eRd12 Addicted to LI Member

    So we have field to write script. I need to put the firmware to the printer. I have to download this firmware to jffs partition and put the script into this field "hotplug".
    If I put something like that it should work?

    cat /jffs2/sihp1018.dl>/dev/usb/lp0

    or maybe we have to put more?
  3. teddy_bear

    teddy_bear LI Guru Member

    eRd12,

    Almost... But you also may want to check if you've just plugged the printer in or removed it, and if it's the correct device. You also can add some delay - just in case. Something like that:
    Code:
    if [ $PRODUCT = "Your_Printer_Product_ID_Here" ]
    then
      if [ $ACTION = "add" ]
      then
        sleep 5
        cat /jffs2/sihp1018.dl > /dev/usb/lp0
      fi
    fi
    
    To see what's the Product ID is for your printer, if you don't know it, you can use the following hotplug script:
    Code:
    echo "Hotplug: "$(date) >> /var/log/hotplug.log
    echo "Action: "$ACTION". Product: "$PRODUCT". Interface: "$INTERFACE >> /var/log/hotplug.log
    Then the /var/log/hotplug.log will contain a new record every time you add or remove usb device, and you can see what product id is for each one of them.

    I'm typing this based on the info available elsewhere - I don't have a printer that requires firmware upload every time, and can't really test this... If something not working correctly, you can try searching OpenWRT or Oleg's firmware forums for help.
  4. eRd12

    eRd12 Addicted to LI Member

    Everything works great!! Thank you very much!!

    Working script for 1018:
    Code:
    if [ $PRODUCT = "3f0/4117/100" ]
    then
      if [ $ACTION = "add" ]
      then
        sleep 5
        cat /jffs/sihp1018.dl > /dev/usb/lp0
      fi
    fi
    There must be jffs, not jffs2 and everything works!
  5. SeeFool

    SeeFool LI Guru Member

    Where can I find the direction to configure Samba network share and FTP server to access usb drive using Win XP/Vista with this new firmware?

    Thanks.
  6. eRd12

    eRd12 Addicted to LI Member

    I can't connect with intel 2200bg with this firmware. With the latest Oleg it war working fine. Is it using other driver ?
  7. teddy_bear

    teddy_bear LI Guru Member

    dadaniel, please check your PM.
    Yes, Tomato uses older Broadcom wireless driver. You can find a bunch of comments regarding this issue on this board. I attemted to update WL driver in builds 05 and 07, but they had issues and now I rolled it back to the original version (see my comments above in this thread). I may try it again, but for now 2200bg clients are not supported.
  8. dadaniel

    dadaniel LI Guru Member

    Hello teddy_bear!

    I tried it again, but no luck. I did nvram erase, entered all data and then reboot.

    I noticed that i get NO samba authentication at all! When I drop in a file it crashes.

    See attached log and screenshot.


    Thanks for your great work!!

    Attached Files:

  9. ray123

    ray123 Networkin' Nut Member

    teddyBear,
    Great set of enhancements!!! Thanks very much.

    Some issues, though. BTW, I have an Asus WL-520GU.
    1) I dl'ed all the source files and rebuild the various versions.
    The original ND and your version v.04 built to exactly the same size as the downloaded trx files. But your dl'ed v.09 file is 3584000 bytes and the one I built is 3567616. Does your build have something extra that your v.09 source doesn't have? Maybe a last-minute addition?

    2) Hotplug of a flash drive works. But when I reboot the router, the flash drive doesn't get mounted. Surprise!! I have to unplug it and then plug it in again to get it to mount.

    I was able to use ftp, cifs, and samba----all work okay. So far everything has worked great. Haven't tried a printer yet, though.
  10. teddy_bear

    teddy_bear LI Guru Member

    ray123,

    1. Everything should be in the archive. Did you run "make distclean" between building versions 04 and 09? 09 contains changes to uclibc (needed for Samba) in the toolchain which doesn't get recompiled if you simply do "make clean"... Better yet - to make sure you do a clean build - copy all files from the archives all over - starting from Linksys sources, then Tomato and my mod. After uclibc is updated, you can still create earlier builds (04 and earlier) - and they should be exactly the same size as before since the extra stuff from uclibc is not used.

    2. Hotplugging and recognizing USB devices is not 100% reliable. For example, I tested it with 5 USB flash drives - 1 formatted as Ext2, and the other 4 as FAT32 - from 1GB to 16GB size each. The Ext2 formatted drive, and 2 FAT-formatted drives never failed to get recognized and mounted - either on reboot, or when hotplugging. 1 other FAT drive is not recognized at all 1 time out of 10 (timeout error in logs, have to replug it in to get recognized), and the other one is always recognized but not always gets auto-mounted. Check if your drive is actually never mounted on rebooting, or just sometimes. Probably it's a timing issue somewhere... Since replugging usually helps I don't worry about it too much for now. With early builds before 04 you may have to reboot the router to get USB back alive after timeouts - so there's a big improvement :). But I will definitely look into it.
  11. me2az

    me2az Networkin' Nut Member

    Thank for your work teddy_bear!

    I miss two features from Victek/Trzepako/roadkill mods - ARP Binding and IPID Adjust.
  12. hoogax

    hoogax Networkin' Nut Member

    Hey, I just saw this was updated. I previously asked before Samba was included if I would be able to put music from an external HDD plugged into the USB to my Asus WL-520GU and then play it over the network on my ps3. Is this now possible? I'm a complete newbie when it comes to all of this so before I start trying to figure it out I'd like to make sure it's possible even. Thanks.
  13. Nite

    Nite Networkin' Nut Member

    Hey teddy_bear,

    Your USB addition to Tomato is excellent, especially the hotplug support. It's much appreciated!

    I too, have an Asus 520gU and this will be helpful in getting my 1018 to function properly as DD-WRT has no hotplug support that I can find. However, I was wondering if it might be possible to integrate VPN support into your build? That's the only reason I'd continue to use DD-WRT at this point. At this point I'm trying to decide between your build and SgtPepper's VPN GUI build.

    Either way, great work and good luck in the future!

    Edit: I just noticed your mention of no serious mods in the future: in that case, how difficult is it to merge your mod with SgtPepper's? Would it still fit on the Asus 520gU? Thanks again.
  14. erixlion

    erixlion Networkin' Nut Member

    SILLY question, I pluged 1G USB flash, and in USB NAS page, I saw:

    Attached Storage Devices:
    SanDisk Corporation Cruzer Mini. Serial #: 2006087682191FA16FA

    But how can I access into this storage?

    I did this:
    telnet 192.168.0.1
    username: root
    pass: donttellyou
    cd /mnt
    ll
    .... there is nothing show up.

    I knew I got alot of files on this flash drive, the flash is fat format, but why I can't find them?

    I actived the FILE SHARING function, user group: WORKGROUP codepage: 437
    how to use this feature?

    real newbie here, anyone can give me a light? thanks

    BTW, whre can I find a guide on how to use FTP with this firmware?

    really apreciate!
  15. ray123

    ray123 Networkin' Nut Member

    Ha!

    I just knew that people would be asking about VPN. I have no use for it myself, but when I was messing around with DD-WRT I saw lots of people asking for it.

    FWIW, I have a kernel mod that will cut down the jffs2 overhead by 64KB. Would that be enough to add VPN?
  16. dadaniel

    dadaniel LI Guru Member

    Maybe someone will combine SgtPepper's and teddy_bear's ;) That would be a great combo especially for the routers with 8mb flash :)
  17. raccoon8888

    raccoon8888 Guest

    hello, please help me!

    i have latest tomoto 1.23 nd usb mod installed on wl520gu router and tried to get my hp1018 printer working with it. but when i turn on jffs2 and format the partition, i only got 60k space available in 384k total on jffs which is not big enough to hold sihp1018.dl(127k) there. is any way to expand the available space on jffs?

    any help would be appreciated.
  18. SgtPepperKSU

    SgtPepperKSU Network Guru Member

    If this USB mod is added to the git repository, it would be pretty trivial for anyone to combine the two.
  19. teddy_bear

    teddy_bear LI Guru Member

    SgtPepper,
    Yep, I'm still going to get it to the git repository - as soon as I'm done modding and fixing my own bugs... Or maybe sooner, as all bugs will never get fixed :)...

    raccoon8888,
    Yep, it's only 60KB left in 09 for JFFS on 4MB routers. You can use an USB flash drive for additional storage though...

    Nite,
    I don't believe both mods - VPN w/GUI and complete USB/FTP/Samba will fit onto 4Mb flash. But if I finally get my stuff into the git repository, it should be easy enough to create versions containing just some combinations of the features - like VPN/USB/FTP and no Samba etc.

    dadaniel,
    I'm trying to avoid making special versions now with some excluded features - it's a bit of a pain before the code is in the git repository. But once it's there, it should be much easier to do it.

    ray123,
    I'm interested in JFFS mod, if it bumps available JFFS space by ~60K. If I finally update the Broadcom WL driver, the firmware binary size will increase for another ~100K, and there will be no JFFS space left at all on 4MB flash. Your mod should still leave ~40K - not enough for extra apps, but good for those who want to store some scripts and other small files.
  20. SgtPepperKSU

    SgtPepperKSU Network Guru Member

    Well, you may be the first :wink:. So far I have been the only one that has pushed any changes out there, and only one other person has asked for push access (and it's looking like he might not continue his mod). So, I definitely didn't mean that as a dig to hurry you up - just mentioning that once there are multiple feature branches in the repo, it should only take a "git merge" for each desired feature to get a combined build.

    And, having those bug fixes in the git repository (even just your local one before pushing everything out to the server) may even be useful. That way you can look back on exactly what was changed and what the intent was and easily revert fixes that don't work out the way you planned. Then, when everything is to the point you want to push it (not that it needs to be "done" to do that - just before you tag it as a release), you can push out all the individual commits you made or just one big one with all your changes squashed together.
  21. mitek76

    mitek76 Networkin' Nut Member

    128MB now working

    Thanks a lot for this effort. Now I'm able to see all of my memory on mod'ed ASUS WL500GP.
  22. Nite

    Nite Networkin' Nut Member

    Thanks for the reply teddy_bear. How difficult is it to enable hotplug support? I realize this is the Tomato forum, but is the enabling of hotplug script support in Tomato somewhat comparable to what's required to enable it in DD-WRT?

    Again, thanks for the help.
  23. ray123

    ray123 Networkin' Nut Member

    No joy.

    I have a script that creates the tomato tree from scratch, by un-taring all the requisite tarballs. WRT, then tomato, then tom-ND, then your ND-USB-v.09. It also follows the instructions as to which directories to delete, etc. Didn't pull in the v.04 at all, since I figured that v.09 superceded that entirely.

    I've been messing around with Linux kernel & drivers ever since the 0.95 days, and I learned early on that you almost always need to do a distclean & make oldconfig. So these days I just automatically do that-----and go get another beer while it's chugging along. :)

    Like I said, my build of your V.04 was the exact same size as in your bin-tar. But V.09 was not the same size. Oddly, Samba seemed to work okay with the original uClibc. However, I then rebuild uClibc from the tools-src directory and installed it. The build got a little bigger, but still much smaller that your v.09 binary.

    I tried to rebuild the other tools, but that failed. Google turned up lots of people saying the same thing. Evidently the newer versions of GCC & Bison choke on some bad code in the hndtools tree.

    I then noticed that v.09 tarball had a usb.2.4.35 tree. So I pulled that into the Linux tree and rebuilt. Now my trx file is 3,579,904. The dl'ed tomato-ND-USB-v09.trx is 3,584,000. Size difference is 4096 bytes.
    So something is not the same.

    If I had to guess, I'd say that the size difference is due to the V.09 source tarball not having the usb.2.4.35, or the uclibc binaries, and/or the original hndtools xgcc.
    Can you make a new source tarball of your exact directory tree and put that on the dl page? Probably that would resove the issue.

    Thanks.
  24. ray123

    ray123 Networkin' Nut Member

    Using v.09, USB thumbdrives seem to work a lot better.
    Being the intrepid explorer, I plugged in a 4-port USB hub (got it free-after-rebate 4 years ago from OfficeMax), and then 2 of the thumb drives that I have floating around. An old old old 64MB one and a newer 2GB one. Both are FAT-the way they came, and I've been using them on various Wndows machines for years.

    Wonder of wonders, this is working flawlessly on v.09. The router is an Asus WL-520GU.
    Looking at the logfile, it recognized the 4-port hub, and then each individual drive. Interestingly, it also says that the motherboard (can you call it that?) has 2 USB ports.

    Since the main usage of a USB thumbdrive would be to add extra storage space to the router, it is absolutely necessary that it will recognize and mount the USB drives when it boots. Generally routers are stuck in some out of the way location where there is no convenient access to remove and re-insert a USB drive or cable.

    So far (knock on wood), v.09 has worked every time-----and I've been rebooting the router a lot.

    One of these days I'll get around to hooking up a printer----which was the reason I bought this 520GU router in the first place.

    Regards,
    Ray
  25. teddy_bear

    teddy_bear LI Guru Member

    Sorry for all these problems. Now I'm not sure anymore if the sources I uploaded for 09 are exactly the same used when I built 09 :(. Although I was sure about that before... Anyway, I will upload the next build very soon making sure the sources match the build, and hopefully it will resolve this issue.
    I'm glad it's working for you flawlessly, but if you are going to use an USB drive exclusively on the router, I strongly recommend to reformat it as native Ext2 or Ext3. The support for FAT fs is definitely not perfect in kernel 2.4.x, and I'm not sure if it's better in 2.6. I had numerous different inconsistent issues with FAT-formatted drives during testing, especially with write access (read-only is fine), while Ext2/Ext3 formatted drives were 100% reliable.
  26. teddy_bear

    teddy_bear LI Guru Member

    for Intel Centrino 2200bg owners

    If you have Intel 2200bg or similar Intel wireless card that can't connect to your Tomato router, please try the following commands in Telnet or SSH session:
    Code:
    nvram set wl_reg_mode=off
    nvram set wl0_reg_mode=off
    nvram commit
    reboot
    After restarting the router, your Intel client most probably should be able to connect. If it works, thank Toastman for his research, findings and testing leading to this solution.

    I will add this setting to the GUI in the next build of my mod. But if you don't want to upgrade, or just want to use vanilla Tomato, these commands hopefully will help to solve connectivity problem for most Intel clients.
  27. ray123

    ray123 Networkin' Nut Member

    Per PM, I can now build to the exact same size as Teddy Bear's binary. Thanks.

    BTW, I now have 4 (four) USB flash drives plugged in.
    1) An old Micro Advantage 64MB,
    2) a Corsair Voyager 4GB,
    3) a Memorex Traveldrive 2GB
    4) a 2GB SD camera card plugged into a $1.95 SD-to-USB card reader (http://www.dealextreme.com/details.dx/sku.11)

    They all mount ok. They are all FAT formatted, since that's what is required by Windows and by my Philips DVD player. And, of course, FAT is what is used by digital camera SD cards. When/if I ever decide to permanantly use a USB flash drive on my router, I'll format it as ext2.

    I'm only doing this because I'm a wild and crazy guy. I get a big kick out of adding disk drives [albeit solid state], ftp, and Samba on a router, of all things! Next thing you know, people are going to be putting folding@home or SETI@home or LHC@home or distributed.net on their routers! Kinky!

    Oh, one more thing. Not all the USB drives always get mounted when the router reboots. Probably a timing problem. Somehow I doubt that Teddy Bear considered somebody plugging in 4 USB drives.
  28. ray123

    ray123 Networkin' Nut Member

    Ah......jffs2 partition is either marginally usable, or not usable at all due to the size.
    After spending a couple of days pouring over the mtd & jffs2 kernel code, this looks to be a challenge.

    The Asus WL-520GU flash memory has eraseblocks of 64kb. Jffs2 really really really wants to claim 5 EBs for operational overhead. The TB v.04 has 11 EBs free, leaving 6EBs or 384kb available for /jffs storage. V.09 has 6 EB's leaving 1 EB or 64kb for storage. Alas, V.11 has only 4 EBs free----so there is no available storage for /jffs. Teddy Bear had better stop adding features pretty soon!

    I had started looking into modifications to jffs2 to claim fewer than 5 EBs, but that now looks non-productive. And the jffs2 developer community seems to be focussing on larger flash chips, not small ones like these routers have.

    I believe that I'll start looking to see if the original jffs (pre-jffs2) can reasonably be used in these routers. After all, we don't need high performance or multi-gigabyte drives. We just need permanent read-mostly, write-seldomly storage, with very small sizes. One EB (64kb) might arguably be adequate (barely), although 2 (128kb) would probably be the minimum acceptable.
  29. eRd12

    eRd12 Addicted to LI Member

    Thanks a lot! It is working great with this feature!
  30. Toastman

    Toastman Super Moderator Staff Member Member

    ThankseRd12,

    Can you keep your eye on it, and report if any client who is associated suddenly loses internet connectivity, but still shows as connected? Just had one user with an Atheros AR5007EG ask me, but nothing conclusive - usually this sort of comment is not accurate.

    EDIT: This may be something to do with the infamous Windows Zero Configuration Utility.....
  31. teddy_bear

    teddy_bear LI Guru Member

    Ok guys, another update, build 11 is up there (use the link in the first post). Changes:

    • Another attempt to upgrade Broadcom Wireless driver to version 4.150.10.5. It seems to be pretty stable now in AP mode. However more testing is needed in different wireless modes.
    • Included SpeedMod by Rodney (hopefully working this time).
    • Added functionality to the GUI to unmount (safely remove) USB drives, reworked the list of attached usb devices.
    • Fixed "Kernel BUG" error when transfering files to shared USB FAT-formatted drives using Samba.
    • Added "Regulatory Mode" setting (off | g | h) to "Advanced -> Wireless" page. This should solve connectivity problems for Intel Centrino (2200bg etc) wireless cards without manually issuing nvram commands.
    • Allowed up to 100 applications in UPnP.

    Please note that the new wireless driver adds about 100K to the firmware binary size. This leaves *NO JFFS SPACE* at all on routers with 4MB flash. The last stable build with decent amount of JFFS space was 04 - with no Samba, and older WL driver. Use that build for now if JFFS space is important for you. If any of the developers/modders provides suggestions of how to decrease the firmware size without loosing functionality, I'll appreciate it :).

    If you are using Samba with FAT/FAT32-formatted drives, the router may "hang", or you can get timeout or other errors while trying to copy large files to your FAT shares using Windows Explorer. The read access should be fine though. This is not the firmware or Samba problem, this is a limitation of vfat filesystem, and it's implementation in linux kernel. The reason for that is that Windows Explorer sets the file size in advance, before sending the actual file in. Samba then asks vfat linux module to expand file to this size, and the kernel fills this whole space with zeros. If your router seems to be hanging and not responding, unplug the USB drive that you just tried to copy the file to - the router should come back up in a few moments.

    To work around this you can: (1) use ext3/ext2 formatted drives if you need write access to the share, (2) use FTP for writing files, and only allow read-only access to FAT drives in Samba, or (3) do not use Windows Explorer for copying large files to FAT shares, use other file managers - like FAR (old version 1.70 or earlier, new versions work the same way as Windows Explorer) or Total Commander (untested) - they do not preallocate space, so this works.

    This mod is still "work in progress", and I don't have neither time nor enough motivation to make custom builds with some features excluded (i.e. "no Samba" version or "older driver" version etc). You can compile it yourself from sources, making any adjustments you want, or wait until I decide to do so.

    Many thanks to anyone who helped with testing and provided a feedback, especially to Toastman for contributing a lot of time into this doing extensive research and testing.
  32. eRd12

    eRd12 Addicted to LI Member

    Flashed with v.11 build and everything is working fine! What for is 802.11d and h (I couldn't find simple definition on the web)? I have it off and then in nvram I have wl_reg=off so needed to work with 2200bg but I would like to know what this d and h bring :thumbup:
  33. teddy_bear

    teddy_bear LI Guru Member

    I don't know more than you do about this :confused:... But the driver sets itself up differently depnding on the value, and I just thought it would be nice to have this as an advanced option for someone who knows :).
  34. dadaniel

    dadaniel LI Guru Member

    I created a new ext3-partition on my 320GB USB disk with Ubuntu 8.10 and then tried to mount it with tomato.

    The log shows this error:

    01:00:15 WL500GP user.err kernel: EXT3-fs: unsupported inode size: 256
    Jan 1 01:00:15 WL500GP user.warn kernel: EXT2-fs warning (device sd(8,1)): ext2_read_super: mounting ext3 filesystem as ext2
    Jan 1 01:00:15 WL500GP user.warn kernel:
    Jan 1 01:00:15 WL500GP user.warn kernel: EXT2-fs: unsupported inode size: 256
    Jan 1 01:00:15 WL500GP user.err kernel: EXT3-fs: unsupported inode size: 256

    EDIT:
    Found something that solves the problem:

    you should go to the command line, create your file system using mkfs.ext2 (don't forget the -j parameter since this turns on journalling - and effectively creates an ext3 file system), and specify the inode size using the -I parameter:

    Code:

    mkfs.ext2 -j -I 128 /dev/...
  35. davidehue

    davidehue Networkin' Nut Member

    UPDATE: The problem has been solved. I leave the "Public, private, and anonymous directory" fields BLANK, and everything work fine now :)
    Thanks for the firmware.. :thumbup:

    -------------------------------------------------------------------------------
    Sorry I have a newbie question. I've flashed my WL520-GU with the latest update firmware (build 11). I've tried mounting usb flashdisk and it's detected on the router.
    I've enabled the FTP server, and create some user name and passwords, but when I tried to login to the FTP server using the user name and password created before, it always failed.
    The only way that works is to login as admin (after the "allow super user to login" activated)

    Please help :)
    --------------------------------------------------------------------------------

    Thanks
  36. Toastman

    Toastman Super Moderator Staff Member Member

    eRd12 - IEE 80211 "d" and "h" additions apparently brought nothing useful for our applications, and are redundant. Here's something I dug up on "h":

    IEEE 802.11h: Encyclopedia II - IEEE 802.11h - Spectrum and Transmit Power Management Extensions

    IEEE 802.11h is the IEEE standard for Spectrum and Transmit Power Management Extensions. It solves problems like interference with satellites and radar using the same 5 GHz frequency band. It was originally designed to address European regulations but is now applicable in many other countries. The standard provides Dynamic Frequency Selection (DFS) and transmit Power Control (TPC) to the IEEE 802.11a MAC.
  37. bltong

    bltong Guest

    Will USB modem support be added to tomato like "http://koppel.cz/cdmawifi/english/" does on ASUS WL-500 series.
  38. mstombs

    mstombs Network Guru Member

    Roadkill tried upgrading squashfs to V3.x which compresses the filesystem better - but broke web upgrades?

    On other mips devices gcc 4.x can produce smaller binaries but even starting from OpenWRT toolchain builds is a big job!

    Thread here re reducing the size of libraries

    http://forum.openwrt.org/viewtopic.php?pid=79138

    Note if libraries are pruned it may break installing new packages via ipkg on the ext drive.
  39. dadaniel

    dadaniel LI Guru Member

    I get 4,6MB/s when uploading and 4,0 MB/s when downloading from a 320GB Western Digital Passport attached to Asus WL500GPv1.

    Why is download slower than upload?


    And I noticed one cosmetic bug:

    When Remove/Umount in Attached Devices is pressed, it says "Please wait..." forever. I have to click on refresh, then it changes to "Not mounted"

    And why there are two instances of vsftpd running? One for LAN and one for WAN?! (see screenshot)

    Attached Files:

    • ftp.jpg
      ftp.jpg
      File size:
      49.3 KB
      Views:
      67
  40. davidehue

    davidehue Networkin' Nut Member

    I tried mounting 80GB Fujitsu SATA 2.5" harddisk, buat it's not detected. I also tried mounting 4GB V-Gen Usb Flashdisk, it's detected, but it's not mounted. Could somebody help me?

    Thanks

    [​IMG]
  41. teddy_bear

    teddy_bear LI Guru Member

    No idea...
    Do you have "auto refresh" enabled on that page? I think that might be the case when auto-refresh is disabled, I'll fix it for the next build.
    I think vsftpd creates a separate process for each client connection. Once all connections are closed, you should only have one listening instance running.
  42. dadaniel

    dadaniel LI Guru Member

    Please attach the logfile or post the last few lines
  43. davidehue

    davidehue Networkin' Nut Member

  44. davidehue

    davidehue Networkin' Nut Member

    Friends,

    I also have a little question, how to access the router's ftp server from WAN?
    I use dynamic IP, and I have configured DDNS to access the router from WAN. But I don't have any idea how to access the FTP server.
  45. eRd12

    eRd12 Addicted to LI Member

    Maybe you should try this in your browser:
    Code:
    your_public_ip:21
    :unsure:
  46. davidehue

    davidehue Networkin' Nut Member

    I think it's impossible coz my IP is not a static IP, that's why I use NO-IP as the DDNS service.
    Btw, it's has been solved. I did an experiment by configuring the port forwarding from external port 21 to internal port 21 on my wl520gu, and now I can access the ftp server from LAN using my DDNS, but it always failed when I tried access it from other connection.

    Here's the error message:

    [​IMG]

    and here's the error logs:
    Code:
    19 14:56:14 unknown ftp.info vsftpd[481]: [admin] FTP command: Client "118.136.xxx.xxx", "PASV"
    Jan 19 14:56:14 unknown ftp.info vsftpd[481]: [admin] FTP response: Client "118.136.209.184", "227 Entering Passive Mode (192,168,1,1,130,116)"
    Jan 19 14:56:38 unknown user.info kernel: vlan1: dev_set_promiscuity(master, 1)
    Jan 19 14:56:38 unknown user.info kernel: device vlan1 entered promiscuous mode
    Jan 19 14:56:38 unknown user.info kernel: vlan1: dev_set_allmulti(master, 1)
    Jan 19 14:56:38 unknown user.info kernel: vlan1: add 01:00:5e:00:00:02 mcast address to master interface
    Jan 19 14:56:38 unknown user.info kernel: device br0 entered promiscuous mode
    Jan 19 14:57:03 unknown user.info kernel: device br0 left promiscuous mode
    Jan 19 14:57:03 unknown user.info kernel: vlan1: dev_set_allmulti(master, 1)
    Jan 19 14:57:03 unknown user.info kernel: vlan1: dev_set_promiscuity(master, -1)
    Jan 19 14:57:03 unknown user.info kernel: device vlan1 left promiscuous mode
    Jan 19 14:57:03 unknown user.info kernel: vlan1: dev_set_allmulti(master, -2)
    Jan 19 14:57:03 unknown user.info kernel: vlan1: del 01:00:5e:00:00:02 mcast address from master interface
    Jan 19 14:57:04 unknown user.info kernel: vlan1: dev_set_promiscuity(master, 1)
    Jan 19 14:57:04 unknown user.info kernel: device vlan1 entered promiscuous mode
    Jan 19 14:57:04 unknown user.info kernel: vlan1: dev_set_allmulti(master, 1)
    Jan 19 14:57:04 unknown user.info kernel: vlan1: add 01:00:5e:00:00:02 mcast address to master interface
    Jan 19 14:57:04 unknown user.info kernel: device br0 entered promiscuous mode
    Jan 19 14:59:11 unknown authpriv.warn dropbear[567]: Failed reading '/etc/dropbear/dropbear_dss_host_key', disabling DSS
    Jan 19 14:59:11 unknown authpriv.info dropbear[569]: Running in background
    Jan 19 14:59:41 unknown authpriv.info dropbear[569]: premature exit: Terminated by signal
    Jan 19 15:00:02 unknown syslog.info root: -- MARK --
    Jan 19 15:00:40 unknown authpriv.warn dropbear[609]: Failed reading '/etc/dropbear/dropbear_dss_host_key', disabling DSS
    Jan 19 15:00:41 unknown authpriv.info dropbear[611]: Running in background
    Jan 19 15:01:29 unknown authpriv.info dropbear[611]: premature exit: Terminated by signal
    
    and this:

    Code:
     unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "227 Entering Passive Mode (192,168,1,1,157,107)"
    Jan 19 15:26:45 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "NOOP"
    Jan 19 15:26:45 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "200 NOOP ok."
    Jan 19 15:26:45 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "CWD /"
    Jan 19 15:26:45 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "250 Directory successfully changed."
    Jan 19 15:26:45 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "TYPE A"
    Jan 19 15:26:45 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "200 Switching to ASCII mode."
    Jan 19 15:26:45 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "PASV"
    Jan 19 15:26:45 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "227 Entering Passive Mode (192,168,1,1,77,129)"
    Jan 19 15:26:46 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "NOOP"
    Jan 19 15:26:46 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "200 NOOP ok."
    Jan 19 15:26:46 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "CWD /"
    Jan 19 15:26:46 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "250 Directory successfully changed."
    Jan 19 15:26:46 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "TYPE A"
    Jan 19 15:26:46 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "200 Switching to ASCII mode."
    Jan 19 15:26:46 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "PASV"
    Jan 19 15:26:46 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "227 Entering Passive Mode (192,168,1,1,129,241)"
    Jan 19 15:26:47 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "NOOP"
    Jan 19 15:26:47 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "200 NOOP ok."
    Jan 19 15:26:47 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "CWD /"
    Jan 19 15:26:47 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "250 Directory successfully changed."
    Jan 19 15:26:47 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "TYPE A"
    Jan 19 15:26:47 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "200 Switching to ASCII mode."
    Jan 19 15:26:47 unknown ftp.info vsftpd[511]: [admin] FTP command: Client "118.136.xxx.xxx", "PASV"
    Jan 19 15:26:47 unknown ftp.info vsftpd[511]: [admin] FTP response: Client "118.136.xxx.xxx", "227 Entering Passive Mode (192,168,1,1,45,114)"
    
    Sometimes all the folder appeared when I login as admin from WAN, but when I tried open the folder, the error message appeared again :frown:
  47. davidehue

    davidehue Networkin' Nut Member

    Finally, I can mount an external HDD :)

    Now I need some tutorial how to access the drive using SAMBA? Currently, I can only access it using FTP server from my LAN and still getting failed to access it from WAN
  48. cr00kedview

    cr00kedview LI Guru Member

    teddy_bear:

    I notice that something is listening on port 9100. This is used by SWAT, normally.. Is SWAT included in the build, or has it been cut out?
  49. teddy_bear

    teddy_bear LI Guru Member

    Yep, there's a bug - I forgot to open FTP port when you enable WAN access :( ... As a workaround, for now you can manually forward port 21 (or whatever you specify as a FTP port) to the router LAN IP address (i.e. 192.168.1.1) on the "Port Forwarding -> Basic" page. I will fix this in the next build.

    It's the p910nd printer server.
  50. davidehue

    davidehue Networkin' Nut Member

    Thanks for all your efforts bro :)

    Btw, could you give me the instructions to share the HDD via SAMBA? Is this type of sharing can be access through WAN also?
  51. huyou

    huyou Networkin' Nut Member

    Anyone know a way to get Unicode file name support on the router? Should I use other ftp server or try to install a samba 3?
  52. dadaniel

    dadaniel LI Guru Member

    @teddy_bear:

    Can you verify that mass storage devices are sync'ed and umount'ed when executing "Shutdown" of the router? I get strange "EXT3-fs warning: mounting fs with errors, running e2fsck is recommended" messages after some days.

    My western digital passport drive has the feature that after some time without accessing the drive it goes to sleep itself, and then spins up in case of accessing it again. But this produces I/O errors in the log, because the router does not wait for the drive spinning up.
    Is there any value in the usb/mass storage driver that can be tweaked?


    I noticed another cosmetic bug:

    In 'USB and NAS - FTP Server', the user/password fields go yellow (always only the field which is clicked second), but the data entered is correct
  53. jnappert

    jnappert Addicted to LI Member

    @teddy_bear:

    Since several days i installed this mod on my ASUSWL500gp v1. It is rock stable. Very good work ;-)

    As i am running 7 other APs (WRT54GLs) in WDS-mode connected to this router, i tried to compile vanilla tomato with upgraded broadcom drivers from the ND USB-Mod-source (ver 11). As these devices run in "router"-mode, the other services are not necessary.

    I found the drivers in a separat folder and integrated it in vanilla source by "overwriting". The compile starts as usual but fails with error 2...


    Best Regards
  54. teddy_bear

    teddy_bear LI Guru Member

    No, Samba is only for your local network. To access it from the WAN, you'll need to VPN to your network first... Setup should be pretty easy, I hope. Once you set the workgroup name, and activate Samba, you should see your router in that workgroup on your network (My Network Places - > View workgroup computers).
    If you're using built-in Samba, your problem might be that your codepage is missing - to save space I only included a few. But that only helps when transfering files back and force between the shared drive and other network machines. However, when you move your drive from the router to, for example, Windows machine, the file names may get screwed. And Samba 3 is the only way around it as far as I know...
    Yes, it tries to unmount all drives on reboot/shutdown... Still, I have the similar message in logs when mounting Ext2 drive: "EXT2-fs warning: mounting unchecked fs". You can verify if a message stays the same even if you manually unmount the drive before rebooting. Yours says "with errors" however, now just "unchecked". Maybe it's worth to check it with e2fsck on a Linux box...
    As for gettings the drive out of "sleep" mode, I do not know if it's possible to tweak the driver to handle it properly. I'll see if I can find out anything.
    It's a bit more complicated... First you have to make sure you deleted directories as described in readme_compile before extracting the driver folder on the top of the vanilla Tomato. Also, the driver update was intended to be applied after my other mods, not just by itself, so it relies on some changes from the other folders in the archive. Check for my changes (marked with !!TB) in the nvram/defaults.c - there should be one or 2 new default values needed for the new driver. As far as I remember, the only other change you need to get from my other mods is the release/src/btools folder. I know a few people tried to do the same, and succeded - so it should be possible :)...
  55. cr00kedview

    cr00kedview LI Guru Member

    Haha, wow, totally didn't even remember that. My bad, I guess the SWAT port is 901.

    Thanks for the info, though ;)


  56. davidehue

    davidehue Networkin' Nut Member

    Wow.. it's so simple. I've tried enabling the SAMBA service. The set the workgroup name to WORKGROUP. After that, I tried browsing on my network places, under workgroup, I found the router name is UNKNOWN. Is it normal?

    I tried to copy some files to the share drive, it can't be done, coz I hadn't set any share specified so it's treated as read only. After I set some share name and the policy is Read/Write, I couldn't access the share drive at all. These are the pictures:

    [​IMG]

    [​IMG]

    And about VPN, could you give me some references how to activate VPN using this version of tomato?

    Thanks bro, you're the best :thumbup:

    PS: Waiting for the next build with FTP enabled from WAN :)
  57. ray123

    ray123 Networkin' Nut Member


    Yes. The router's name is the "Hostname" field of the Basic/Network web page. If you haven't set it to anything it comes up as "unknown". This applies to both the Samba browsing and the "uname" command when logged into the router with telnet.

    Somebody really needs to write a good user's manual for Tomato.
  58. j-dev

    j-dev Guest

    Confirmation of success with Asus WL-500gP V2

    I flashed my Asus WL-500g Premium V2 with this Tomato mod a couple of days ago. It has been working perfectly, so thank you for your effort! (Still need to test with Bittorrent running.)

    Teddy Bear, have you thought about merging your mod with the official Tomato project (sorry if I'm going over old ground here)? Seems like a sensible thing to do, since your additions are common requirements.

    A grey area, but it would be nice to have webcam support included... maybe even embedded pan/tilt controls within the Tomato interface. I certainly don't expect you to take things this far. Perhaps something I'll do myself... when I have some spare time.

    Has anyone had success connecting a webcam to a Tomatofied router?

    :thumbup:
  59. ray123

    ray123 Networkin' Nut Member

    JFFS

    Teddy Bear, How close do you think you are to being done with adding features? I ask because of the JFFS size issue with routers with 4MB flash. Like my ASUS WL-520GU.

    As you know, jffs2 overhead is 5 blocks (5 * 64KB = 320KB). Jffs2 development is concentrating on large flash sizes, and doesn't care about small sizes like routers have. FWIW, newest jffs2 in the latest 2.6.x kernel has only 3 blocks of overhead-but that doesn't help us.

    I have come up with a mod to jffs which works with only 2 to 2.5 blocks (128kb to 160KB) overhead. Your V.11 build has 4 blocks available, for about 100KB of usable jffs storage.

    I can made some more changes and get that down to 1 block overhead, giving 192KB of usable jffs space. But at a potential cost. If power is lost while writing to the jffs there is a good chance that the filesystem will be corrupted and be unrecoverable. That *probably* is acceptable to us, because I'd think that we would rarely be writing to the jffs. I'd think that most of the writing we'd do would be during initial setup, and once that was done we'd only read and never write.

    But----if you are planning to be adding more code and hence shrinking the available space for JFFS, my mods wouldn't do any good because there'd not be enough jffs space for even that.

    Comments? Thoughts? Anybody?
  60. teddy_bear

    teddy_bear LI Guru Member

    ray123,

    I *hope* I'm done with features... But you never know for sure, do you :)?

    The next build is probably going to be 4K larger than the last one though. Will it consume another block, or will we still have 4 blocks available? I expect to restore gpio utility that I temporarily removed from the last build, and replace upnp daemon with miniupnpd (+4K).

    That is going to be it for now, but we will be running very tight on space... Even if you'll be able to get JFFS overhead down to 1 block, upating any of the components to a newer version, or future Tomato update to 1.24 may take another block or two out of JFFS space rendering it almost useles on 4MB flash... Although it would be good to have JFFS enabled, it's up to you to decide if it's worth the efforts considering the risk.

    The other possible approach would be to get rid of JFFS completely, and enable Flashfs - it's what Oleg used in his firmware. I'm not sure about the exact overhead of Flashfs, but I remember having some space available when I tested it on 4MB router even though the firmware binary was about 100K+ larger than my mod currently. This is just another option to consider...
  61. NewG

    NewG Networkin' Nut Member

    First I have to thank you for all your work! I'm using an asus 520gu and I moved over from DDWRT. I have to say that your version of Tomato is a heck of a lot better than DDWRT. I have a hub hooked up and a USB stick and cardreader hooked up and mounting just fine. However, I have a seagate 120gb in a usb2 enclosure that refuses to mount. Its an ext3 format that was recognized in DDWRT so I'm not really sure why it wont mount. Should I reformat and try it again?

    Also, I have a Canon d760 that is recognized in the GUI but I'm not really sure how to hook it up to print.

    I apologize if this isn't the correct place to ask these questions...
  62. teddy_bear

    teddy_bear LI Guru Member

    Yes, it's the correct place to ask questions. Doesn't mean you'll get the answers though :)...

    Is your Seagate drive recognized by the router and displayed in the "attached devices" list, and only refuses to mount? Or is it not recognized at all? Could you post the part of the log showing what happens after you connect the drive?

    As for the printer, I don't have d760 - but if it's recognized you should be able to print to it. You can follow these directions to set up your printer in Windows. That said, there are some printer models that do not work well with the included printer driver and print server. Hopefuly that won't be the case with your Canon though...
  63. NewG

    NewG Networkin' Nut Member

    Well I guess I'm SOL on the Canon printer. I followed the directions to set up the printer and still a no go. I guess it was about time to get a new printer anyway :p

    As to the seagate... the enclosure is recognized but won't mount.
    Here is the log:
    Hopefully thats all ya needed
  64. teddy_bear

    teddy_bear LI Guru Member

    That's what the problem is. The Ext3/Ext2 in kernel 2.4 doesn't support inode size 256, it's only enabled in kernel 2.6. Check this post for a workaround.

    Did it work in DD-WRT? What version? Since they still use 2.4 kernel for Broadcom routers, they must have applied some patches to allow expanded inodes if you counld mount your drive...
  65. NewG

    NewG Networkin' Nut Member

    Thanks for the info and help! It always surprises me that there are people out there that are willing to help.

    I have formatted this one harddrive about 50 times now so I dont even remember what the format was when I tried it with DDWRT. But now that I used the ext2 -j format with the instructions you sent me, the seagate mounts just fine. Now if I could only go beyond the 520gu ability to transfer faster than 1.6mb/s ;)

    *edit*

    nevermind... well I'm getting 2.1mb/s sustained through the wired connection and not wireless. I think the folks over at DDWRT are right when they question whether the USB on the 520gu is 2.0 or not.

    Again thanks so much for the hard work and a great firmware!
  66. eRd12

    eRd12 Addicted to LI Member

    I'm running win xp pro sp3 and have 4965agn intel card. I don't know why but once per couple of minutes I have this notice that I am connected to my wifi network (baloon in right down corner). Everything is working fine, time of connection is not 0. I just don't why it is showing so often.
  67. teddy_bear

    teddy_bear LI Guru Member

    Weird... Was it happening with official Tomato, or only with my builds? And connection duration is not getting reset every time you see the popup? If so, then probably you're not getting disconnected - not sure why popup keeps coming up. Anything interesting in the router log?

    You may try to uncheck "Show icon in notification area when connected" box in the connection properties - but leave the other one (Notify me when there's no connectivity) checked. That may (or may not) help to get rid of the annoying popup...
  68. djinn23

    djinn23 Networkin' Nut Member

    I finally signed up. I think I have been following this thread since rev3 or so. I just wanted to say thanks!! I have been awaiting this functionality for my device for some time in tomato and am glad you ran with the torch. In your latest build, all of the functionality I desire is present (and working)!

    I have noted you have been very helpful in this thread too . . .and you appear to be having fun with it. I hope that now that it is done you will add the stuff up to the SVG or whatever like Pepper frequently suggested so that others may use your work and refine it. . . . as you are self proclaimed to not be the best. From your work here I would assume you underestimate yourself!!.

    It is great to know that people are still willing to work for the good of the people and donate their efforts out to the greater community.


    Thanks again for your hard work and dedication to this project!

    J
  69. Engineer

    Engineer Network Guru Member

    I too wanted to chime in with a huge thank you for your (and other's) efforts in this teddy_bear. I've been following this thread since nearly the beginning and am greatful (and amazed) be the work you folks have done on this. I salute you!
  70. teddy_bear

    teddy_bear LI Guru Member

    New build 12 is available (use the link in the first post). Changes:
    • A bunch of bug fixes: corrected firewall rules when WAN access is enabled for FTP server, cosmetic GUI fixes, fixed "Measure Noise Floor" function on the Device List page (it no longer disables wireless).
    • Improved support for Ext2/Ext3 filesystems (allow expanded inodes, forward compatibility). You should now be able to mount Ext3 drives with inode size 256.
    • UPnP daemon is replaced with MiniUPnPd which includes NAT-PMP support and auto-cleaning for unused rules.
    • Restored gpio utility temporarily removed from previous build when upgrading WL driver.
    Hopefully I'm done with features in this mod :), and will only work on bug fixes and stability issues. I will push my sources to git repository in the next couple days - that should allow other people to combine different features easier.
  71. CBR900

    CBR900 Addicted to LI Member

    thanks a lot for this great work
  72. noyp

    noyp Addicted to LI Member

    hi mate, is there any chance that you could include the usb modem support ?
  73. RockT

    RockT Networkin' Nut Member

    Hi teddy,

    I have two questions regarding v12;

    - Do I need to clear nvram when going from v11?
    If so, this is really inconvenient...

    - Have you updated the ND driver from v11?
    If so, could you make a note in the release notes...?

    All in all, thank you very much, you rock... :)

    Rainer
  74. teddy_bear

    teddy_bear LI Guru Member

    No :(. Maybe someone else would be interested in doing so, but not me...

    1. No, you don't have to clear nvram going from v11 to v12. However, if you have any issues, it's always the first thing you need to do to troubleshoot.

    2. No, it's the same WL driver as in V11, otherwise I would have add it to the release notes :).
  75. voxabox

    voxabox Addicted to LI Member

    A friend has asked me to look into this as well (for WL-520gU and verizon UM175)
    I have not get a hold of his router and the modem; however, I read that it is not possible with the WL-520gU
    Hopefully the info was specific to the usb modem with a Huawei K2540 chipset
    It'd be extremely nice to be able to share internet access via the WL-520gU and a 3G USB modem

    Cheers,
    -v
  76. davidehue

    davidehue Networkin' Nut Member

    Nice... thanks a lot bro, will try it ASAP :thumbup:
  77. NewG

    NewG Networkin' Nut Member

    I may be dating myself in an attempt to be cool... but 'you da man Teddy!"

    I will most definitely try out the update. Good to see the inode thing included :thumbup:

    If everything goes right, by the end of the day I'll have 2TB of NAS, a network printer and a wireless bridge hooked up to my soft modded (w/upgrade harddrive) xbox :biggrin:

    Damn I love firmware hacks!

    Again, thanks for all the hard work Teddy
  78. dadaniel

    dadaniel LI Guru Member

    @teddy_bear:

    It seems that as soon as my drive gets the I/O-Errors on spin-up, it is marked as not good (mounting with errors).
    Have you found out something? I know buying a drive that never spins down is an option, but I need the spindown because the whole thing is located in my bedroom.
  79. teddy_bear

    teddy_bear LI Guru Member

    dadaniel,
    No, I have not found anything yet... What happens when your drive spins down? Does it get unmounted? Or it stays mounted all the time, but gets IO errors when you try to access it and get it out of sleep mode?

    Is there anything interesting in logs when the drive spins up? Do you have any problems with data on the drive, other than "mounting fs with errors" message in the log?

    As a workaround you can probably experiment with hdparm (you can get it from Optware) utility, -B and -S options, to keep the drive alive, and maybe set cron jobs (or scheduled tasks in Tomato) to control its behaviour on schedule - but I have not tried this myself...
  80. dadaniel

    dadaniel LI Guru Member

  81. mstombs

    mstombs Network Guru Member

    Mod runs fine on a WRT54G-TM, USB is disabled by default, thanks!

    Code:
    Total / Free Memory	29.94 MB / 17.41 MB (58.15%)
    Loaded it to test miniupnpd, seems to work fine, Skype and uTorrent both use NAT-PMP or upnp but router fails the Microsoft upnp test http://www.microsoft.com/windows/using/tools/igd/default.mspx (even if NAT-PMP not loaded)

    Code:
    Test 5 - UPnP Support Test Not supported  
    
    
    Result: 
    The operating system is Windows XP
    UPnP is enabled by the firewall
    UPnP services are running
    UPnP Discovery is enabled
    Detecting Internet Gateway Devices on the network
    1 IGD(s) found
    IGD Device Information:
    Manufacturer Name : Tomato
    Model Name : Tomato router
    Model Number : 1
    get_StaticPortMappingCollection() returned NULL IStaticPortMappingCollection
    get_StaticPortMappingCollection() returned NULL IStaticPortMappingCollection
    get_StaticPortMappingCollection() returned NULL IStaticPortMappingCollection
    Failed to get port mapping from the IGD
    miniupnp usually passes this test, I will investigate further... sometime...
  82. teddy_bear

    teddy_bear LI Guru Member

    Strange, it passed this test every time I tried it :):
    Code:
    Test 5 - UPnP Support Test Supported  
    
    Result: 
    The operating system is Windows XP
    UPnP is enabled by the firewall
    UPnP services are running
    UPnP Discovery is enabled
    Detecting Internet Gateway Devices on the network
    1 IGD(s) found
    IGD Device Information:
    Manufacturer Name : Tomato
    Model Name : Tomato router
    Model Number : 1
    0 existing port mappings were found: 
    This test will add 20 port mappings to the IGD
    Using the local computer's IP address (192.168.1.2) for testing
    
    ***********************************************************
    Adding a new port mapping to the IGD:
    External Port : 61133
    Internal Port : 61075
    Protocol : UDP
    Internal Client : 192.168.1.2
    Enabled : TRUE
    Description : removeme0
    
    [..............................................................]
    
    20 new port mappings have been added successfully
    There are 20 port mappings on the IGD
    Waiting for 60 seconds
    There are 20 Port Mappings on the IGD
    Deleting all the test port mappings from the IGD
  83. teddy_bear

    teddy_bear LI Guru Member

    Looks like we're out of luck then... Unless someone backports that functionality into 2.4 kernel - and it doesn't look like it's going to be easy :(...
  84. Toastman

    Toastman Super Moderator Staff Member Member

    msTombs, the test worked OK for me here

    You might know the answer to this one since you've been playing with miniUPnP for some time - how many port forwards does it support in the table? Test here said "was able to open 14 connections" - there were 6 already. Does that indicate max 20? If so, we need to increase this up towards 100, if possible.
  85. NewG

    NewG Networkin' Nut Member

    the newest version worked out great for me. Everything is set up and running well. An ext3 (inode 256)formatted drive worked out just fine. Everything seems stable to me since I haven't had to reboot since the upgrade was finished.


    2tb of NAS... gotta love it.
  86. mstombs

    mstombs Network Guru Member

    will check PC firewall etc, still doesn't work here - but haven't rebooted old PC yet.

    [edit] Have rebooted, now PC passes the M$ test - but now I've lost the Internet Gateway icon (yes I wanted to do that, but would like to have control!)

    The M$ test only expects the router to support 20, so it only adds enough to take it to 20. The test sometimes fails because another process removes its port forward during the test, so it claims 20 not sustained! I am not aware of any hard limit in miniupnp - I will ask on the miniupnp forums.

    I also like the port restriction you have enabled for miniupnp that's not in the GUI!
  87. Toastman

    Toastman Super Moderator Staff Member Member

    Ah, thanks for looking. Yesterday I thought I counted 23 in there, but not sure if I remembered right now.
  88. teddy_bear

    teddy_bear LI Guru Member

    In "My Network Places" window (at least in WinXP, not sure about Vista) you should see the "Show/Hide icons for networked UPnP devices" icon on the left, in the "Network Tasks" box. Note that if you "hide" it using this button, it also turns off UPnP in Windows firewall. If you use Windows Firewall, you can go to the firewall settings, and turn it back on. If you don't use Windows firewall it doesn't matter - but if UPnP is off in Windows Firewall, M$ test will fail even if Windows Firewall itself is turned off... It won't affect other applications - only M$ test :)...
  89. teddy_bear

    teddy_bear LI Guru Member

    Just uploaded new build 14 which includes:

    Older, but better and more complete, Speedmod implementation. This improves the router stability under heavy load with many concurrent connections.

    A minor fix for FAT filesystem support that should help to prevent crashes when copying large files to FAT shares using Samba. Everything I said in this post still applies, it just should work a little better.

    Nothing new, so no need to update if v12 works fine for you.

    Also, the sources are now available from the git repository (see this post for a brief overview of git commands). Although Victek already managed to get the new WL driver and miniupnpd stuff into his RAF mod, hopefully git will simplify this process for others going forward.
  90. ray123

    ray123 Networkin' Nut Member


    Maybe if git was a little bit more user friendly......
    I've spent the last 3 hours trying to just get the v14 source code so I can compile it. I've got a directory with 191 MB of stuff, but can't figure out how to get the source files out. The documentation tells me how to all sorts of complex things I don't care about------but doesn't tell me how to just get the danged latest copy of TB's v14 source code. I don't really want to learn yet another version control system. Hell, I don't even know that the git clone worked properly!

    Here's what it said (note: I'm running this on a Windows machine):
    HTML:
    c:\program files\git\bin>git clone git://repo.or.cz/tomato.git i:\tom14
    Initialized empty Git repository in i:/tom14/.git/
    remote: Counting objects: 57759, done.
    remote: Compressing objects: 100% (41180/41180), done.
    remote: Total 57759 (delta 14203), reused 57759 (delta 14203)
    Receiving objects: 100% (57759/57759), 189.86 MiB | 242 KiB/s, done.
    Resolving deltas: 100% (14203/14203), done.
    warning: remote HEAD refers to nonexistent ref, unable to checkout.
    Frankly, looking at the tree (http://repo.or.cz/git-browser/by-commit.html?r=tomato.git) makes me want to cry. One of the best things about when I retired was that I didn't have to struggle with ClearCase anymore---and I was the ClearCase admin for our group. These branching trees grow so quickly and rapidly become unwieldy.
  91. ray123

    ray123 Networkin' Nut Member

    Teddy Bear,
    With respect to sizes of features and JFFS......
    Using flashfs is a non-starter. The main constraint is the nature of flash chips and the 64KB eraseblock size. It doesn't matter how clever you are, there is nothing you can to to get around that constraint. I currently have mods that will work with as little as 3 blocks (192KB) of JFFS. JFFS2 is going the wrong direction for routers and other embedded devices, though. They are focussing on multi-MB and GB flash memories, rather than 100's of KBs like routers have.
    I switched Tomato from JFFS2 to JFFS (aka JFFS1), plus made a few minor changes to optimize for very small available space. I'm working on another set of changes that will still work even with as little as 128KB (2 EBs). That's very good news, since v12 has only 4EBs (256K) available----and JFFS2 requires a minimum of 5 EBs.

    While I'm letting the JFFS mods cook, I got slightly sidetracked with USB flash drives & USB hard-drives. It is becoming quite clear that some kind of offboard drive will be necessary in order to add other features to Tomato---such as VPN, maybe webcam support, scanner support, etc. I have a couple of 4 port USB hubs and and showbox-full of USB flash drives and USB hard drive boxes. Including an IOMagic box that will take camera cards and copy them to its internal hard drive. This will let you access its hard drive and its camera card slots when you plug it into your computer.
    Anyway....I ran into some issues with continually plugging & unplugging various and multiple USB devices. Your USB code in the V12 release is a great base, and I was able to get all these working reliably with just some minor modifications. One of the problems is that if you have multiple USB devices plugged in--especially multiple USB flash drives--that the device name (and therefore mount path) will change depending on timing and on what order the devices happen to be detected. I've got some fairly simple changes that will solve that problem. In a simple manner--no editing /etc/fstab or /etc/usb/hotplug/agent files. Simple hands-off operation so you don't have to be a Linux guru.

    When I finish with all this, I'll (somehow) publish the changes, for you (or anybody who cares to) incorporate into another release. I'll also undertake to write up some user documentation, with perhaps some guidelines on how to add new packages--like the aforementioned VPN, webcam, etc. I'm kinda waiting for a) you to finish up and get to a stable version that you're satisfied with, and 2) tweaking and testing the JFFS code for ultra-low memory.

    With 1GB SD cards available for $5 and SD-to-USB adapters for $2, and BUY.COM has 8GB USB thumbdrives for $15 (!!)------you can add plenty of storage for adding lots of features to a router if it has a USB port. But you still need some onboard storage such as JFFS as a base to bootstrap from. So if your new stuff isn't much larger that the current size, my new jffs code will give us what we need. Heck, it should be easy to install ipkg on a USB drive and then we'd have a package manager.
  92. davidehue

    davidehue Networkin' Nut Member

    I've upgraded my WL520GU to build 12, but still can't access the FTP through WAN? Anybody succeed accessing the FTP through WAN?
  93. dadaniel

    dadaniel LI Guru Member

    I know what is wrong:

    Code:
    Status:	Verbindung hergestellt, warte auf Willkommensnachricht...
    Antwort:	220 (vsFTPd 2.0.7)
    Befehl:	USER dadaniel
    Antwort:	331 Please specify the password.
    Befehl:	PASS *******
    Antwort:	230 Login successful.
    Befehl:	SYST
    Antwort:	215 UNIX Type: L8
    Befehl:	FEAT
    Antwort:	211-Features:
    Antwort:	 EPRT
    Antwort:	 EPSV
    Antwort:	 MDTM
    Antwort:	 PASV
    Antwort:	 REST STREAM
    Antwort:	 SIZE
    Antwort:	 TVFS
    Antwort:	211 End
    Status:	Verbunden
    Status:	Empfange Verzeichnisinhalt...
    Befehl:	PWD
    Antwort:	257 "/"
    Befehl:	TYPE I
    Antwort:	200 Switching to Binary mode.
    Befehl:	PASV
    Antwort:	227 Entering Passive Mode (192,168,1,1,148,174)
    Status:	Vom Server gesendete Adresse für den Passiv-Modus ist nicht routingfähig. Benutze stattdessen die Serveradresse.
    Befehl:	LIST
    Fehler:	Zeitüberschreitung der Verbindung
    Fehler:	Verzeichnisinhalt konnte nicht empfangen werden
    
    It sends the internal IP!

    Please fix that Teddybear!
  94. teddy_bear

    teddy_bear LI Guru Member

    Guys,

    I'm not sure why you can't connect - but I just tested FTP WAN access from my office network, and it worked. I could ftp to my router using dynamic no-ip address (ftp://<my-no-ip-name>.no-ip.com) from the outside when WAN access was enabled, and couldn't when it was disabled.

    Are you sure the network you're connecting from allows outgoing connections on FTP port 21? Many corporate networks have it disabled, so it very well might be the case.
  95. teddy_bear

    teddy_bear LI Guru Member

    That's why it took me so long to get my stuff there... But after you get a hold of it, it really is not that hard... By the way, it was your mistake to start reading git documentation - the StPepper's post with a brief overview is better to start with ;).
    Did you checkout any branch after cloning the repository? You need to do that to get the actual source files:
    Code:
    git checkout origin/<BranchName>
    OR 
    git checkout -b <BranchName> origin/<BranchName>
    My main branch is "tomato-ND-USBmod" - by checking out that one you'll get the latest version. Or you can checkout the tag - I'll be adding a tag to each new build.

    Also, doing it on Windows machine may not be a good idea. At least symlinks (if any) and Linux file attributes (such as executable attribute for scripts) will be lost...

    Alternatively, instead of installing git and checking out branches, you can download the snapshot of the whole branch three in a .tar format - in the git repo Web UI click on the tag or branch name, and then select "tree - snapshot" link (i.e. here's the link for my v14 build snapshot). Please note this will be a huge tarball and will take some time before download starts, as it will include the complete firmware sources and the toolchain.
  96. teddy_bear

    teddy_bear LI Guru Member

    Do you mean that the device name is changing after reboots? If so, yes - that's the case, but I didn't worry about it because unless you reboot it always comes up with the same name, no matter how many times you unplug and replug it. But I agree that there might be cases when it's important to keep the same device names even after you reboot. Or did you see the names changing between reboots, just by unplugging/replugging devices?

    I believe that I'm done with features, and will only work on any issues that may come up. So we can start getting your changes in - if not now then pretty soon.
    Yep, it's easy - that's what I have. I installed Optware ipkg-opt on a flash drive, and several Optware packages - asterisk and a few others.
  97. SgtPepperKSU

    SgtPepperKSU Network Guru Member

    @ray123:

    If all you want to do is get the latest source and compile it, there's no reason you need to use git. From the repository web-site, there should be a "snapshot" link for each commit that downloads a tar.gz with the entire tree as it appeared at that point in time. There is also such a "snapshot" link for each head. For instance, the latest tomato-ND-USBmod source is always downloadable with this link. I got that from clicking on tomato-ND-USBmod's "tree" link and selecting "snapshot". Unless you plan to push changes back to the repository or want to have a local history of changes, you don't actually need to use git at all.

    Hope that helps.

    @teddy_bear:

    When announcing a release it may be useful to include the "snapshot" link to the tagged commit and possibly even the link to the raw diff between the tomato release and yours (you can get that by clicking "base" next to the desired tomato release then clicking "diff" next to your release). That way people who just want to download and not deal with versioning control, can do so just as if you were hosting tarballs and diffs as before. See my last release announcement for an example of what I'm talking about. Notice that all five links in the third paragraph all point to the git repo.
  98. dadaniel

    dadaniel LI Guru Member

    I have no problem connecting to other ftp servers. As you can see above it sends the wrong adress. it should send the wan adress when connecting from outside and should send the internal adress when connecting from lan. otherwise this can't work in passive mode
  99. go_cp

    go_cp Networkin' Nut Member

    Is there a loop.o available for this version of Kernel

    First of all thanks to the great firmware update and hard work.

    I upgraded to your firmware from DD-WRT and love it. I have the /opt (ext3 filesystem) on the usb drive. After certain number of mounts, I would like for e2fsck to be run on this filesystem. To do that I have a virtual filesystem (an ext3 filesystem as a file) that I would like to load using loop device and run e2fsck on the /opt fs. When on DD-WRT I was using the whiterussian/open-wrt kmod-loop package to load the virtual fs. I tried an insmod on the whiterussion loop.o (when in your fw) and it failed with:

    insmod: unresolved symbol __down_failed_interruptible

    pointing to kernel version being incompatible (whiterussian uses 2.4.30). Do you have the loop.o for the 2.4.20 kernel?
  100. teddy_bear

    teddy_bear LI Guru Member

    Thanks!
    Apparently I overcomplicated firewall rules needed, and managed to fool vsftpd to think it always receives connections from LAN... Hopefully I'll finally get it fixed in the next build :).

Share This Page