can't ftp and telnet in Redhat7.2

Posted on 2002-03-19
Last Modified: 2013-12-06
After logon as root, I try to ftp and telnet to the localhost in Konsole. Here's the error message, would you pls help?

# ftp localhost
Connected to localhost.localdomain.
220 xxx FTP server (Version wu-2.6.1-18) ready.
530 Please login with USER and PASS.
530 Please login with USER and PASS.
KERBEROS_V4 rejected as an authentication type
Name (localhost:root): anders
331 Password required for anders.
530 Login incorrect.
Login failed.

# telnet localhost
Connected to localhost.localdomain (
Escape character is '^]'.
Red Hat Linux release 7.2 beta with CLE (Gaga)
Kernel 2.4.12-0.1 on an i686
login: anders

System error
Connection closed by foreign host.

Many thanks!
Question by:andersy
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 6
  • 2
  • +1

Expert Comment

ID: 6881008
Please answer the following questions:

1) does ftp and telnet work as root instead of anders?
2) what does the entry in /etc/passwd look like for "anders"?
3) what are the contents of /etc/shells?
4) what are the contents of /etc/hosts.allow?
5) what are the contents of /etc/hosts.deny?
6) if you are running inetd, what does the ftp and telnet entries look like in /etc/inetd.conf?
7) if you are running xinetd, what are the contents of /etc/xinetd.d/telnet and /etc/xinetd.d/wu-ftpd?
8) what happens when you run "su - anders" as root?

Expert Comment

ID: 6881489
Your FTP stuff appears as though you entered the wrong password for 'anders' or that user doesn't exist.

On most distros root cannot log-on to telnet or ftp for security reasons. If you need root access through telnet you should telnet in as a normal user and then 'su' to root.
LVL 40

Expert Comment

ID: 6881640
This system sure doesn't look like RedHat 7.2 to me. Neither the 7.2 distribution nor the updates provide kernel-2.4.12-0.1. And that might be a cause of the failures being seen.

However, it looks somewhat like the system might be configured for other than normall password/shadow file authentication. The wu-ftp server doesn't normally toss an Kerberos error message and seeing that messages makes me think that it might be Kerberos that is failing or isn't compatible with the FTP and telnet server.
Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.


Author Comment

ID: 6882887
Hello Sixpax,

1. still won't work for root
2. anders:x:500:500:anders:/home/anders:/bin/bash
3. /bin/sh
4 and 5. no content
6. using xinetd
7. telnet:
   service telnet
        flags           = REUSE
        socket_type     = stream
        wait            = no
        user            = root
        server          = /usr/sbin/in.telnetd
        log_on_failure  += USERID
        disable         = no
   service ftp
        socket_type             = stream
        wait                    = no
        user                    = root
        server                  = /usr/sbin/in.ftpd
        server_args             = -l -a
        log_on_success          += DURATION USERID
        log_on_failure          += USERID
        nice                    = 10
        disable                 = no
8. I can su to anders.

Hello MFCRich,

You may be right as I can't login anders in login prompt. Even I change the passwd in User Manager, I still cannot login. Do you know why?

Hello jlevie,

My version is "Red Hat Linux release 7.2 beta with CLE (Gaga)", where CLE is Chinese Language Extension. If it's the problem of Kerberos, do you know how to fix?

FYI: When I try to login FTP using anonymous, it works. I think it should be the problem of authentication. Do you guys have any hints?

Many thanks.
LVL 40

Expert Comment

ID: 6882977
Is the system configured to use Kerberos Authentication?

Author Comment

ID: 6884429
Hello jlevie,

Can you tell me how to check if the system is using Kerberos Authentication?

Expert Comment

ID: 6885695
I know this doesn't answer the problem with your user login, but to allow root to login through telnet or ftp you need to remove/rename the /etc/securetty file.  By default, root is not allowed to login to the machine from a remote connection.

What messages do you get when you try to login as "anders" from a login (console) prompt?
LVL 40

Expert Comment

ID: 6887434
Check /etc/sysconfig/authconfig. If Kerberos is being used there'll be a line containing 'USEKERBEROS==yes' and somewhere you'd have a Kerberos server that all systems would be configured to use.

Author Comment

ID: 6896410

Do you have any other suggestions?
LVL 40

Expert Comment

ID: 6899222
Can the anders user log on the the console?

Also can I see the contents of /etc/sysconfig/authconfig?

Author Comment

ID: 6902550
Hello jlevie,

I can't login as anders, even I've changed the password. I can only login using root.

Here's the content:

# cat authconfig

Pls help!
LVL 40

Expert Comment

ID: 6902702
Okay, according to what's above your system has been configured to use LDAP for user names and authentication. Is that what you intended and do you have an LDAP server that's configured to provide Linux compatible authentication?

Since you say that you've changed the password for anders, my guess if that you've done it on the Linux system. But, since the system has been told to use LDAP that has no affect.

To change the authentication method you'll want to log in on a console, not the GUI, and execute /sbin/authconfig. Uncheck LDAP and leave "Cache Information", "Use NIS" and "Use Hesiod" un-selected on the first screen. On the second screen only "Use Shadow Passwords" and "Use MD5 Passwords" should be selected. Reboot when done and you should be configured for conventional authentication.

Author Comment

ID: 6903236
Oops... I can't login as root in Console! I can only login as root in graphic mode.

Can I directly modify /etc/sysconf/authconfig by setting

BTW, I can't find the file /sbin/authconf.
LVL 40

Accepted Solution

jlevie earned 100 total points
ID: 6903318
Sorry, it's /usr/sbin/authconfig... My bad...

I'm guessing that the system is configured for a GUI login and that's why you are having trouble with root's login.

There's a way to get to a console, even with the GUI login enabled. Alt-Ctrl-F2 will take you to another virtual console (and Alt-Ctrl-F7 will take you back to the GUI). You can run authconfig in a terminal window from root's login, but the terminal type isn't right and the display is a bit messed up. You can still use the tool that way but it's harder to figure out what you are doing.

Author Comment

ID: 6907063
I can login as anders and perform ftp and telnet.
Many thanks!

Featured Post

Secure Your Active Directory - April 20, 2017

Active Directory plays a critical role in your company’s IT infrastructure and keeping it secure in today’s hacker-infested world is a must.
Microsoft published 300+ pages of guidance, but who has the time, money, and resources to implement? Register now to find an easier way.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Little introduction about CP: CP is a command on linux that use to copy files and folder from one location to another location. Example usage of CP as follow: cp /myfoder /pathto/destination/folder/ cp abc.tar.gz /pathto/destination/folder/ab…
This article will explain how to establish a SSH connection to Ubuntu through the firewall and using a different port other then 22. I have set up a Ubuntu virtual machine in Virtualbox and I am running a Windows 7 workstation. From the Ubuntu vi…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question