LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-01-2004, 11:15 AM   #1
true_atlantis
Member
 
Registered: Oct 2003
Distribution: fedora cor 5 x86_64
Posts: 639

Rep: Reputation: 30
command to login as different user


is there a command that you can give a user name and password that ill log you on to a different user??
 
Old 10-01-2004, 11:26 AM   #2
Bebo
Member
 
Registered: Jul 2003
Location: Göteborg
Distribution: Arch Linux (current)
Posts: 553

Rep: Reputation: 31
Yes, use the command su, like su <user>. To make the environment of <user> to be properly set up, use su - <user>; note the hyphen. This is perhaps more useful, because then you'll end up in <user>'s home dir, and will have everything set up as that user.

If you don't enter a particular user, then you'll login as root.
 
Old 10-01-2004, 12:24 PM   #3
true_atlantis
Member
 
Registered: Oct 2003
Distribution: fedora cor 5 x86_64
Posts: 639

Original Poster
Rep: Reputation: 30
can you give su the password too?
 
Old 10-01-2004, 12:27 PM   #4
Bebo
Member
 
Registered: Jul 2003
Location: Göteborg
Distribution: Arch Linux (current)
Posts: 553

Rep: Reputation: 31
No. I don't know of any command that'll allow for that. Oh well, ftp logins do...
 
Old 10-04-2004, 04:55 PM   #5
Bebo
Member
 
Registered: Jul 2003
Location: Göteborg
Distribution: Arch Linux (current)
Posts: 553

Rep: Reputation: 31
Hello again,

Duh, I just remembered ssh You can make password-less logins using the public/private keypairs with ssh. However, without a password - or rather a passphrase - it is (considered) less secure, but that's up to your judgement if you want to allow it.

There are two articles about this in LinuxAnswers: here and here.
 
  


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
MySQL: Login as Blank User From Command Line tortle Linux - Software 1 05-14-2005 05:01 PM
User Login Problem: "command not found" unless root! DreameR-X Linux - General 15 12-21-2004 11:27 AM
Crazy blank dialog boxes and windows at login. Can't login as user soren625 Linux - General 2 08-11-2004 06:30 AM
Unable To Login to X-System/Command Line as User drdroid Linux - General 4 02-08-2004 08:26 PM
Changin Graphical Login to command line login 3DLirio Linux - Newbie 2 10-16-2003 09:43 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:36 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration