LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 11-06-2003, 11:56 AM   #16
coolamit78
Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: RHEL AS 3/4, Windows XP
Posts: 546

Original Poster
Rep: Reputation: 31

Yapp, the problem is, that I use the Cable Internet service. The server has IP 192.168.0.1 and it itself is set up as gateway by the service provider.

When I give the command on the command line

ftp 192.168.1.10

In this case, it gets connected either as anonymous or as a normal linux user. No problems till here.

But when I specify my real IP in Mozilla, i.e

ftp://202.122.61.30

In this case, I get the message "Connection Refused". IF i try the command

ftp 202.122.61.30 on the command line, even then I get the same message.

Now tell me what do I need to do to solve this problem and get the connection established.

Thanx and Regards,

amit
 
Old 11-06-2003, 04:56 PM   #17
markus1982
Senior Member
 
Registered: Aug 2002
Location: Stuttgart (Germany)
Distribution: Debian/GNU Linux
Posts: 1,467

Rep: Reputation: 46
you bound vsftpd to 192.168.1.0 ? firewalling?
 
Old 11-07-2003, 04:45 AM   #18
yapp
Member
 
Registered: Apr 2003
Location: Netherlands
Distribution: SuSE (before: Gentoo, Slackware)
Posts: 613

Rep: Reputation: 30
* what do you see when you type "nestat -lnt" ?

* have you been playing with the webbased control panel of your router? You need to tell your router it should forward to connection to your machine. These options can be found in the port-forwarding, or NAT-setup menu's of your router.
 
Old 11-28-2003, 12:24 PM   #19
saposmak
Member
 
Registered: Sep 2003
Distribution: Redhat
Posts: 72

Rep: Reputation: 15
Hi.
I am able to connect locally to my FTP server, but as I try to connect to the IP address given to me by whatismyip.com, it connects to what I suppose is either my ISP or my DSL modem. The IP address I have been given is my modem's public IP address, which is dynamic... I called my DSL provider and they said they opened up all the ports for my modem... I don't know what ¨opened up the ports¨ means, but I supposed they had made it so that all ports were redirected to my dsl modem... I guess I should call them again and ask them to just redirect port 21... Help anyone?


markus1982: what do you mean when you say ¨bound vsftpd to x.x.x.x¨?

Last edited by saposmak; 11-28-2003 at 08:38 PM.
 
Old 12-01-2003, 05:22 AM   #20
saposmak
Member
 
Registered: Sep 2003
Distribution: Redhat
Posts: 72

Rep: Reputation: 15
Anyway, I already solved it... I guess I'm pretty much an ignoramus when it comes to remote networking... anyway i finally understood that the router is in my dsl modem, which I don't have access to because my dsl company is so nice that they won't give me the password of my own dsl modem... anyway i called them up, they accessed my modem's router, redirected ports to my pc's ip, and i set up vsftpd.

Note to anyone who might have similar problems: Connecting to your newly set up ftp server through another computer in the same network won't work, for some reason. So you have to try to connect through an outside computer (What i did was disconnect one of my computers at home from the network, then connect it through dial-up). When I tried that, it said ¨Service not available¨ or something like that, but that was because I had to enable that computer to enter the server in the /etc/hosts.allow file.

Anyway it's all up and running now, thanks to anyone who at least thought of helping me... and if anyone needs any details as to how i did it, I'd be happy to help.... although I'm still pretty much a newbie.
 
Old 12-04-2003, 11:21 PM   #21
tr0gd0O0r
Member
 
Registered: Jun 2003
Location: Louisiana
Distribution: Fedora 1
Posts: 60

Rep: Reputation: 15
I've been reading through this thread and seem to be having a fairly similar problem. except for one major difference. I only want to connect from other computers on the same network (I think) I'm living on a college campus and i want to be able to save files directly to my hard drive from computer labs. In this scenario, would I use my real ip or my internal one? Also is this possible? cuz I can't connect to the ftp server when I try to use an ip address.
for example:

ftp localhost - works
ftp 111.111.111.111 (except w/ real or internal ip) doesn't work

any ideas?
 
Old 12-05-2003, 02:37 AM   #22
yapp
Member
 
Registered: Apr 2003
Location: Netherlands
Distribution: SuSE (before: Gentoo, Slackware)
Posts: 613

Rep: Reputation: 30
Quote:
ftp localhost - works
ftp 111.111.111.111 (except w/ real or internal ip) doesn't work

any ideas?
check the interfaces your ftp server is listening on. if it's 0.0.0.0, it listens on all interfaces. Perhaps you have some firewall rules arround, or the initd wrapper code (hosts.allow, hosts.deny)

Code:
netstat -lnt
 
Old 12-05-2003, 07:34 AM   #23
saposmak
Member
 
Registered: Sep 2003
Distribution: Redhat
Posts: 72

Rep: Reputation: 15
Like yapp said, check your hosts, hosts.allow and hosts.deny, and make sure that the server (place where you are connecting to, which if i read correctly is your room computer) has allowed access to the computer(s) where you are trying to connect from.

But anyway, if it's on the same network and all you wanna do is transfer files, why not just use samba?
 
Old 12-05-2003, 09:14 AM   #24
yapp
Member
 
Registered: Apr 2003
Location: Netherlands
Distribution: SuSE (before: Gentoo, Slackware)
Posts: 613

Rep: Reputation: 30
Quote:
Originally posted by saposmak
But anyway, if it's on the same network and all you wanna do is transfer files, why not just use samba?
FTP seams to be very efficient for large file transfers.

Because FTP creates a new connection for every file, copying a lot of small files is faster with samba. (I've seen it happening while copying true-type fonts from an windows xp machine)
 
Old 12-05-2003, 11:57 AM   #25
coolamit78
Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: RHEL AS 3/4, Windows XP
Posts: 546

Original Poster
Rep: Reputation: 31
Hi all..

yapp, few days back, I scanned the ports of my server, and I did not not find any entry for port 21 which is the port for vsftpd by default. I think that is the reason why I and my friends are getting a connection refused message.

This is the output of the netstat -lnt command and I guess it shows the same thing.

[root@amit root]# netstat -lnt
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State
tcp 0 0 127.0.0.1:32768 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:6000 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN

What according to you do i need to do now?

Regards,

amit
 
Old 12-06-2003, 09:22 AM   #26
saposmak
Member
 
Registered: Sep 2003
Distribution: Redhat
Posts: 72

Rep: Reputation: 15
do you have the entry ¨listen_port=21¨ in your /etc/vsftpd/vsftpd.conf?
I didn't at first and I think that was one of the reasons why I couldn't set it up in the beginning.
 
Old 12-08-2003, 03:59 AM   #27
yapp
Member
 
Registered: Apr 2003
Location: Netherlands
Distribution: SuSE (before: Gentoo, Slackware)
Posts: 613

Rep: Reputation: 30
coolamit78,

If you're getting "connection refused" messages, are at least getting a reply. Most likely, the port is being forwarded. Your linux box sends a port-not-open message. Most routers are configured to drop all incoming connections, without giving any reply. (makes your machine completely invisible from the net)

Is vsftp really running? You should see it in the output of "ps auxf".

I've been looking at the port numbers you gave me. I can't really explain the 127.0.0.1:32768, some service seams to be listening on localhost with a high port number. there is one way to see the program listening at this service (the p argument, you need to be root for this. without the 'n' argument, you'll see host and port names, instead of numbers):

Code:
netstat -lntp
netstat -lnp
port 111 is used by the rpc-portmapper, unless you're running an NFS server, you could disable this service. Port 22 is ssh, which is really cool. ssh is an encrypted form of telnet, but can also by used to transfer files, and forward an X11-display to another linux machine.
Port 6000 is used by X11, but you can disable this too. (by providing the "-nolisten tcp" option to /usr/X11R6/bin/X, everywhere X starts.. ie, the startx script, and the /etc/X11/gdm config files)
 
Old 12-08-2003, 04:49 AM   #28
coolamit78
Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: RHEL AS 3/4, Windows XP
Posts: 546

Original Poster
Rep: Reputation: 31
yapp.

thanx for the pointers!...in fact i checked if vsftpd was running or not and when i checked the output of ps -aux, there was no vsftpd..lol...

however, even after I start vsftpd, it is not running.

I checked the status of vsftpd with the command

service vsftpd status

and it says that ' vsftpd dead but subsys locked'

I remember to have killed vsftpd service some 10 days back.and have rebooted my machine many a times during this period...so then what does this mean? I have also reinstalled vsftpd but that dosent make any difference...vsftpd still isnt running....

unless the daemon runs, there is no way i can check other issues with the ftp service.

what can be done now to fix this problem?
 
Old 12-08-2003, 05:08 AM   #29
coolamit78
Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: RHEL AS 3/4, Windows XP
Posts: 546

Original Poster
Rep: Reputation: 31
well..ok....i fixed that problem...i guess there was some error in my vsftpd.conf file.....i removed some doubtful lines...and vsftpd is up and running again...

now, I have called up my ISP and asked them to open port 21 for ftp.

When they open the port, i'll post again with my problems if any...

thanx a lot again for the suggestions yapp...

regards,

amit
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Setting up an ftp server Jmcatch742 Linux - Newbie 3 04-10-2005 05:21 PM
Setting up a FTP server and Game server Spyiish Slackware 38 11-01-2004 05:32 AM
setting up FTP server sulfur Linux - Newbie 4 09-02-2004 07:48 PM
Setting up an FTP server jwijesundra Linux - Networking 10 07-13-2004 07:24 AM
Setting up an FTP Server??? Ricardo77uk Linux - Networking 5 06-25-2001 04:36 PM


All times are GMT -5. The time now is 05:28 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration