#1  
Old 10th September 2008, 23:14
KenKnight KenKnight is offline
Senior Member
 
Join Date: Nov 2005
Posts: 137
Thanks: 0
Thanked 3 Times in 2 Posts
Default su not working

Hi all,

I've got one of the debian sarge perfect install vm's running and su is not working properly. I've googled the problem and haven't found any answers that are working.

I built the same HOWTO from scratch and (debian sarge) and it is working fine.

Right now any time I type su username it does nothing. Any suggestions?

Cheers!
Ken
Reply With Quote
Sponsored Links
  #2  
Old 11th September 2008, 02:09
jon jon is offline
Member
 
Join Date: Jan 2007
Location: Canada
Posts: 91
Thanks: 13
Thanked 5 Times in 5 Posts
Send a message via Skype™ to jon
Default

have you verified that su is installed? Try (as root) aptitude search ~i su
Reply With Quote
  #3  
Old 11th September 2008, 04:13
KenKnight KenKnight is offline
Senior Member
 
Join Date: Nov 2005
Posts: 137
Thanks: 0
Thanked 3 Times in 2 Posts
Default

Yes, it is installed. I can type su --help and it returns help. I can type su username and it "acts" like it is doing something, but if I create a directory next, it is still created as the root.

Thanks,
Ken
Reply With Quote
  #4  
Old 11th September 2008, 05:08
jon jon is offline
Member
 
Join Date: Jan 2007
Location: Canada
Posts: 91
Thanks: 13
Thanked 5 Times in 5 Posts
Send a message via Skype™ to jon
Default

what exactly are you typing?
Reply With Quote
  #5  
Old 11th September 2008, 05:36
KenKnight KenKnight is offline
Senior Member
 
Join Date: Nov 2005
Posts: 137
Thanks: 0
Thanked 3 Times in 2 Posts
Default

Hi,

I'm logged in as root and I type;

su username

replace username with a valid username. Again this works on a physical machine built using the debian sarge perfect setup, but is not working on the downloaded vm.

Thanks,
Ken
Reply With Quote
  #6  
Old 11th September 2008, 15:25
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,748 Times in 2,579 Posts
Default

Strange. Do you see any errors in the logs?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #7  
Old 15th September 2008, 22:19
KenKnight KenKnight is offline
Senior Member
 
Join Date: Nov 2005
Posts: 137
Thanks: 0
Thanked 3 Times in 2 Posts
Default

Ok,

here is what I've determined at this point.

1) if i issue the "su usename" then the auth.log is reporting session opened for user "username" by root (or whatever uid).

2) If I immediately create a directory it is being created as root.


3) if I type exit and then hit enter, the auth.log is reporting that the session was closed.


If I do this same routine on my main box (not vm), it works just fine and after the su username command I'm seeing that I'm logged in as that user.

Any suggestions?

Thanks,
Ken
Reply With Quote
  #8  
Old 16th September 2008, 19:30
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,748 Times in 2,579 Posts
Default

I'm really confused. That's the first time I hear something like this, and I can't think of an explanation...
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #9  
Old 16th September 2008, 20:46
ralic ralic is offline
Member
 
Join Date: Jun 2008
Posts: 69
Thanks: 0
Thanked 11 Times in 11 Posts
Default

Quote:
Originally Posted by KenKnight View Post
Any suggestions?
Check that the user account has a valid login shell in /etc/passwd. Post the corresponding entry here if you are unsure. Don't worry, /etc/passwd rarely contains any secret info these days.

After you've su'd to the user, what is the result of typing
Code:
whoami
?

Have you confirmed that the dir is really being created by root? I mean did you do
Code:
ls -l
after creating the dir?

I ask because I've seen an instance where a user gets a "#" prompt (forget exactly why, but it was related to problem with home dir file permissions), which gives the illusion of 'root', but isn't.

Edit:
Could you post the actual log entries from auth.log?

Last edited by ralic; 16th September 2008 at 20:52. Reason: Request for logs entries.
Reply With Quote
  #10  
Old 17th September 2008, 15:36
KenKnight KenKnight is offline
Senior Member
 
Join Date: Nov 2005
Posts: 137
Thanks: 0
Thanked 3 Times in 2 Posts
 
Default Resolved

Here's the process;

Code:
server:~# cd /var/www/web2
server:/var/www/web2# cd web
server:/var/www/web2/web# su fwd_admin
server:/var/www/web2/web# whoami
root
server:/var/www/web2/web#
As it turns out it was the etc/passwd did not have a valid shell assigned to it even though this user is set to be the administrator of the site and have shell access.

Thank you ralic for pointing me in the right direction and to everyone else for the help! Really appreciate it.

Cheers!
ken
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Getting e-mail working hansoffate Installation/Configuration 29 13th August 2008 17:33
DNS stop working MZH General 3 22nd February 2008 12:10
spamassassin stop working after woody to sarge update shark_tico Server Operation 1 19th October 2006 15:01
PHP & MySQL working, but AREN'T WORKING???? lipp9000 Installation/Configuration 4 21st July 2006 18:01
ftp not working pesja Installation/Configuration 3 17th July 2006 13:37


All times are GMT +2. The time now is 05:58.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.