Re-organized the forum to more cleanly delineate the development section, as the end user support side appears to have taken a life of its own!

Author Topic: tftpd  (Read 3929 times)

March 15, 2011, 08:21:47 am
For some reason I can't seem to get this to work for me. I've got telnet (along with inetd) up and running on a modified romfs image, but I can't seem to get tftpd to work. The port is open, but when I actually try to transfer anything I get an access denied error.

my inetd.conf looks like this

telnet  stream  tcp     nowait  root    /bin/telnetd
tftp  dgram   udp     wait    root  /bin/tftpd -s /home

Any ideas would be welcome, since I am rapidly running out of different things to try.

March 15, 2011, 09:57:09 am
I actually run my tftpd as daemon.

i think it runs like
Code: [Select]
/usr/sbin/in.tftpd -l -R 4096:32767 -s /silo/tftproot/"
not sure if i can write to the ftp server via put; my permissions probably don't allow it anyhow, but reading from it, works just fine, I use it to server all kinds of images and data for my PXE environment.

  • No avatar
  • *****
March 15, 2011, 02:34:15 pm
Have you mounted /home ?

Is /home read / write.

Can always download mine to take a look how I did it.
See the firmware hacking forum for that.

March 16, 2011, 01:53:28 am
Home is setup properly, I left the init script intact, and just added a sleep call after camera& (to prevent reboots that happened when inetd executed immediately) and called inetd.

Home, being a ram disk, is writeable. Even if it wasn't though, I should still be able to GET files if tftpd is running correctly.

  • No avatar
  • *****
March 16, 2011, 02:53:04 am

are those setup appropriately?

You have the source for the tftpd app, look at it.
grep access denied in the source, and see what its looking for specifically.

You are starting it via inetd? or manually?  You state both, which is it?
Turn on verbose logging, and check your logs.

Manual here -

March 16, 2011, 04:50:49 am
It seems my issue is mainly with tftp client I was using. The tftpd appears to require full paths, since it apparently cannot be passed a home directory, which is a problem since the tftp client I was using (windows) reacts badly to leading /'s

I thought I was pretty specific about starting tftpd through inetd, not sure where you got the impression I was running it manually from. Also, last time I checked, the firmware on the cameras do not use log files. In addition (for completeness), the minimal tftpd code from the uClinux distribution included in the board support package, does not use hosts.allow or host.deny, nor does appear it support verbose logging (or being passed any switches, or config files).

  • No avatar
  • *****
March 16, 2011, 08:24:40 am
1) How can I know what kernel you're running with?

I run my own build, Oliver is working on his, who knows what you're doing.

2)  I didn't see that Oliver and you had post when I read things, one post said inetd and the other showed it running as a daemon.

3) There are multiple tftpd servers in the user folder.
Nothing is stopping you from using a third party one either.

Appears you have sorted it out though, so there you go.

There isn't anything magical about the builds - basically its all linux underneath, so standard linux troubleshooting applies.

March 16, 2011, 09:02:11 am
If I was rolling my own kernel, I probably would have mentioned it. As it is, I couldn't tell you what kernel version its running, since I haven't looked. I'm not doing anything that (hopefully) requires fiddling with the kernel.

I am aware of only one tftpd in the user folder (the one in the tftpd subfolder). The version of busybox (the other place I would expect to find it) does not appear to include more than a client. If I've missed another tftp server, please point it out to me, as I could do with a little more functionality.

Compiling a third party one is the next step after trying the ones that are already there :)