Weird SSH issue


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users Weird SSH issue
# 1  
Old 11-04-2004
Weird SSH issue **Solved**

hey all, I guess I'm the newbie on these boards, anyways, hello.

I recently became the admin for a few Solaris machines, and I have recently discovered an issue with SSH on one of my machines.

On one of my machines, I can only SSH into the machine as root. I have tried the newest version of Putty and Secure CRT. What happens is, if I try to log in as a user, the machine prompts for a password like normal, and then after I enter it in, the session just closes. In putty the program exits.

I have done the following to try to resolve the problem.

1. Reset the user password that I was using.
2. Added a AllowUsers line in my sshd_config
3. Created a new user

All three of those did not work. I can log in just fine with root, but nothing else. I do not know if the prior admin did something or what, I am just running out of ideas.

Any ideas?

ps. Thanks!

Last edited by AKM; 11-08-2004 at 02:13 PM..
# 2  
Old 11-04-2004
Can you get in with the user account with telnet, rlogin, and/or ftp? Can you su - user as root?

Check that the user account is okay by looking at it in /etc/passwd - insure it has a valid shell.

ssh to the server as root, then ssh to the same server as user - there may be error messages that you aren't seeing due to the window closing.

Check /var/adm/messages for any errors.
# 3  
Old 11-04-2004
My server is Co-Located, and SSH/ftp is the only means of communication (besides an out of band that is set up at the co-lo). I checked the passwd file, and everything looked good there, also when I su - I get no errors. I did try to connect and tailed that messages file, here is the output.

Nov 4 11:01:13 : [ID 681337 daemon.notice] conn,01336: Connection accepted from xx.xx.xxx.xxx:1555.
Nov 4 11:01:18 : [ID 681337 daemon.notice] auth,01336: none for user xxxx rejected because it is unavailable.
Nov 4 11:01:43 : [ID 681337 daemon.error] err ,01336: No umask found for user xxxx.
Nov 4 11:01:43 : [ID 681337 daemon.notice] auth,01336: password for user xxxx accepted.
Nov 4 11:01:43 : [ID 681337 daemon.notice] conn,01336: Session channel open request accepted.
Nov 4 11:01:43 : [ID 681337 daemon.notice] conn,01336: Child (3598) has exited. Status: 2.
Nov 4 11:01:44 : [ID 681337 daemon.notice] conn,01336: Session channel has been closed (pid: 3598).
Nov 4 11:01:44 : [ID 681337 daemon.notice] conn,01336: Connection closed.
# 4  
Old 11-04-2004
Again, what happens when you ftp as that user?
Again, if you ssh to server as root, and then ssh from that session to same server as user, what happens?

Post the user info from /etc/passwd (I'm looking for the shell)

Did you su - OR su - user - there is a difference.

Are you using kerberos, NIS, or just local files? What version of Solaris? What version of ssh?
# 5  
Old 11-04-2004
Sorry about being so vague, here are the answers.

1. I can ftp as user just fine.
2. The SSH disconnects from the command line.
3. user:x:100:14:System Admin:/home/user:/bin/bash
4. I ran "su - user" earlier
5. I have no idea on the first part of the question, I am running Solaris 8, I am using Secure CRT 4.0.6 and Putty .056 connecting via ssh2

Edited to add: After looking around the system some more, I am actually running vshelld as my ssh daemon. I've looked into the config file, and there are no restrictions in there that should be blocking me. I have restarted the vshelld, but still can not SSH as user, even from a SSH session as root.

Last edited by AKM; 11-04-2004 at 05:18 PM..
# 6  
Old 11-04-2004
You might want to try connecting with the -v option - it may show where it is failing.

See vsh man page

As far as NIS or local files - you can look at /etc/nsswitch.conf to see what it shows for passwd. But this seems to be a ssh problem only (you could ftp as that user).
# 7  
Old 11-08-2004
I was able to solve the problem, thanks for all the help. I looked in the vshelld config file one last time today, and noticed this line:

ChrootUsers {* } # Restricts user's shell, and remote execution to their home directory.

I decided to comment out that line in case the * character in there was throwing off Vshell, besides, I use /etc/passwd to manage user shells anyways.

After making that change I can SSH to that machine just fine, so, problem fixed.

Thanks again Smilie
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Weird issue in converting XLSX to TXT

Hi Guys, I have used Perl scripting to convert XLSX file to TXT file using Perl module Spreadsheet::XLSX. I processed one XLSX file having one column and 65k rows of data . Strangely ,It is merging data for every 2047 row and I could see data in TXT file as Ex: Suppose in XLSX file ,if... (2 Replies)
Discussion started by: Rajk459
2 Replies

2. Shell Programming and Scripting

weird equal variable issue

I run this #!/bin/bash cron=$(ps aux | grep crond | grep -v grep | grep -o crond| uniq) echo "cron :$cron:" if ; then echo "OK: crond service running fine on `hostname`" exit 2 else echo "CRITICAL: crond service not running on `hostname`" exit 0... (2 Replies)
Discussion started by: anil510
2 Replies

3. AIX

Weird nfs issue after TL upgrade

We recently upgraded 2 of our AIX 6.1 servers from TL4 to TL5. Both servers are on the same p7 780 frame, installed at the same time from the same image. Both servers are mounting the same nfs share after reboot what worked perfectly fine until the upgrade. Since the patching, one of the two... (5 Replies)
Discussion started by: zxmaus
5 Replies

4. Shell Programming and Scripting

Weird tail output over ssh

Hello; Am trying to correct the formatting of tail output over ssh. Using the following code: echo "" > $FILE for BOX in $SERVERS do echo "Processing on $BOX" |tee -a $FILE echo "===============================" >> $FILE sudo ssh $BOX 'TERMINAL="vt100" /usr/bin/sh -s' <... (2 Replies)
Discussion started by: delphys
2 Replies

5. UNIX for Advanced & Expert Users

Weird SUID issue

Hi, I am setting up SUID permissions on a binary. It gets set for most of the users, however, 1 in 10 users is unable to set these. For those who works: > chmod 6555 Test > ls -l Test -r-sr-sr-x 1 A B 5524 Nov 15 14:53 Test For those where it doesn't work: > chmod 6555 Test... (14 Replies)
Discussion started by: vibhor_agarwali
14 Replies

6. Shell Programming and Scripting

Report filtering - Weird issue and interesting - UrgentPlease

Hi, Could any one help me to extract data from a report. I would like to get the two lines which are just below the separations I have a report like this -------------------------------------------------------------------------- Pid Command Inuse Pin Pgsp Virtual... (2 Replies)
Discussion started by: ajilesh
2 Replies

7. Shell Programming and Scripting

weird issue about h, g, x in SED

I have a file called merge2.t: Hi Hello how are you. </Endtag> <New> I am fine.</New> This is a test. freelong how Here is the SED: sed -n ' /<\/Endtag>/ !{ H } /<\/Endtag>/ { x p } (4 Replies)
Discussion started by: freelong
4 Replies

8. HP-UX

Weird Issue with crontab.

Hello all, Normally I'm pretty comfortable with crontab, changing and updating (done it many-a-time). But in the last two days I've been pulling my hair out over the following... Details of OS: HP-UX mdirect B.11.23 U ia64 2587410573 unlimited-user license Issue: Execute a script (very... (3 Replies)
Discussion started by: Cameron
3 Replies

9. UNIX for Advanced & Expert Users

Weird Awk issue

Hi All, a bit of a weird one here. I'm trying to pass a variable into an awk command, and I keep getting an error. I have the line nawk -F"," -v red=$random_variable '{print $red}' $w_dir/$file_name > $w_dir/${column_name} that keeps failing with the error nawk: can't open file {print... (17 Replies)
Discussion started by: Khoomfire
17 Replies

10. UNIX for Advanced & Expert Users

weird domain issue.

OK so i have a virtual server where i store files. one day i tied to login and i couldn't connect to my sevrer so i logged into my ssh and checked to see if the process was running. proftp was not. I then tried to start it manually and got the error below. Now the domain listed there is not mine... (2 Replies)
Discussion started by: thirddegreekris
2 Replies
Login or Register to Ask a Question