LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-26-2004, 03:01 PM   #1
wswartz
Member
 
Registered: Nov 2003
Posts: 56

Rep: Reputation: 15
Receiving files via TFTP


I'm trying to use my linux (Fedora Core 1) laptop to receive files via TFTP. I have a switch and a router. Both of these can download code or upload their configuration to a TFTP server. I can download code to them with no problem but I can't seem to upload their config to the TFTP server.

I've checked iptables and it isn't running on my machine. I used nmap to see if port 69 is open and it is. I've looked in the /etc/xinetd.d/tftp file and here is my config from /etc/xinetd.d/tftp file:

{
disable = no
socket_type = dgram
protocol = udp
wait = yes
user = root
server = /usr/sbin/in.tftpd
server_args = -c -s /tftpboot
per_source = 11
cps = 100 2
flags = IPv4
}

I've read that the "-c" in the server_args line should allow me to write to the tftp server but it doesn't seem to work. Any ideas? Where is logging done for tftp so I might be able to see any errors and such?

Thanks, BS
 
Old 04-28-2004, 03:39 PM   #2
wswartz
Member
 
Registered: Nov 2003
Posts: 56

Original Poster
Rep: Reputation: 15
Anyone out there with any thoughts? By the way, I checked the permissions on the /tftpboot directory; they are all read/write for everyone.

BS
 
Old 06-09-2004, 02:25 PM   #3
nattydred
LQ Newbie
 
Registered: Jun 2004
Posts: 5

Rep: Reputation: 0
how did thus turn out . im having the same problem
 
Old 06-27-2004, 09:44 PM   #4
MadProf
LQ Newbie
 
Registered: Jun 2004
Posts: 3

Rep: Reputation: 0
Check /etc/hosts.allow file .....
 
Old 06-28-2004, 08:38 AM   #5
nattydred
LQ Newbie
 
Registered: Jun 2004
Posts: 5

Rep: Reputation: 0
here is my hosts.allow file

######################

#
# hosts.allow This file describes the names of the hosts which are
# allowed to use the local INET services, as decided
# by the '/usr/sbin/tcpd' server.
#
ALL:ALL



is this correct????
 
Old 07-01-2004, 10:31 PM   #6
MadProf
LQ Newbie
 
Registered: Jun 2004
Posts: 3

Rep: Reputation: 0
ok


First check if tftp process if up :

[root@Iago log]# netstat -na | egrep 69
udp 0 0 0.0.0.0:69 0.0.0.0:*


if ok, then verify if you have ipchains or iptables running:

find / -name iptables -print


iptables -L

to verify if and/or what is allowed into your box.

if no acl issue ,

then verify permission on the tftp directory ..


Let me know that fixes your problem or not ...


Good Luck
 
Old 07-02-2004, 08:49 AM   #7
nattydred
LQ Newbie
 
Registered: Jun 2004
Posts: 5

Rep: Reputation: 0
here are the permission on my tftpboot dir
[root@mis-fr2-roberts root]# ls -al /tftpboot
total 8
drwxrwxrwx 2 root root 4096 Jun 15 22:04 .
drwxr-xr-x 22 root root 4096 Jul 2 08:19 ..

i get the same error if my iptables are started ot stoped

MMOB-1-MSFC2-1#copy run tftp
Address or name of remote host []? 10.5.6.50
Destination filename [mmob-1-msfc2-1-confg]?
TFTP: error code 1 received - File not found

%Error opening tftp://10.5.6.50/mmob-1-msfc2-1-confg (Undefined error)


and i did check to see if tftp was working

[root@mis-fr2-roberts root]# netstat -na | egrep 69
udp 0 0 0.0.0.0:69 0.0.0.0:*
unix 2 [ ACC ] STREAM LISTENING 4675 /tmp/orbit-root/linc-aa2-0-150db71520d69
unix 2 [ ACC ] STREAM LISTENING 4843 /tmp/orbit-root/linc-abf-0-722690f79b997


any other ideas
 
Old 07-02-2004, 11:24 PM   #8
MadProf
LQ Newbie
 
Registered: Jun 2004
Posts: 3

Rep: Reputation: 0
tftp

It possible that your problem is that tftp directory does not give rw access.

Verify the directory permission:

[root@Iago tftp]# ls -al
total 40
drwxr-xr-x 3 tftpd root 4096 Jun 28 00:08 .
drwxr-xr-x 22 root root 4096 Jun 27 22:00 ..
drwxr-xr-x 2 tftpd root 4096 Jun 27 22:08 archives
-rw-r--r-- 1 tftpd tftpd 815 Jun 27 22:07 configd.confg
-rw-rw-rw- 1 tftpd tftpd 1334 Jun 27 23:59 fr.confg
-rw-rw-rw- 1 tftpd tftpd 2919 Jun 27 22:40 r1-confg
-rw-rw-rw- 1 tftpd tftpd 1894 Jun 27 23:53 r2.confg
-rw-rw-rw- 1 tftpd tftpd 1853 Jun 27 23:53 r3.confg
-rw-rw-rw- 1 tftpd tftpd 2212 Jun 27 23:53 r4.confg
-rw-rw-rw- 1 tftpd tftpd 1816 Jun 30 08:55 terminal-server.confg



create a user for tftp:
useradd -d /dev/null -s /bin/nologin tftpd
/usr/sbin/useradd -d /dev/null -s /bin/nologin tftpd

Create a directory with the right permissions:
mkdir /usr/local/tftp
Give ownership to tftpd
chown -R tftpd /usr/local/tftp

This should definitely fix the server side of TFTP .... The router side appears to have correct syntax.



Good luck
 
Old 09-20-2004, 03:44 PM   #9
charon79m
Member
 
Registered: Oct 2003
Distribution: Just about anything... so long as it is Debain based.
Posts: 297

Rep: Reputation: 30
TFTP by default won't create a file...

The TFTPD will not allow a remote person to create a file. You must first create the file then tftp will fill that file with the data.

The -c is the fix...

I'm having an issue with this too. Anyone have any ideas as to how to pass the -c option from within the /etc/inet.conf file?

MrKnisely
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
tftp baparekh Linux - Networking 8 03-11-2005 07:50 AM
Problem receiving files with Licq Reil Willy Linux - Networking 2 03-16-2004 05:56 PM
.s files - a very simple question (tftp) webamoeba Linux - Newbie 2 11-28-2003 06:39 AM
TFTP-Problem: TFTP timed out Bikerpete Linux - General 2 08-14-2003 05:25 AM
help with tftp please Tigger Linux - Security 3 06-11-2003 05:37 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:01 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration