LinuxQuestions.org
Review your favorite Linux distribution.
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 07-13-2019, 12:59 AM   #1
mbox frex
LQ Newbie
 
Registered: Dec 2017
Posts: 6

Rep: Reputation: Disabled
ubuntu server 18.04 LTS


hi, after installing zsh on Ubuntu server 18.04 LTS, i cant log in to root, it says No such file or directory
 
Old 07-13-2019, 03:58 AM   #2
ehartman
Member
 
Registered: Jul 2007
Location: Delft, The Netherlands
Distribution: Slackware
Posts: 672

Rep: Reputation: 317Reputation: 317Reputation: 317Reputation: 317
Quote:
Originally Posted by mbox frex View Post
hi, after installing zsh on Ubuntu server 18.04 LTS, i cant log in to root, it says No such file or directory
That's normal in all ubuntu versions, they do not use the root account, but setup sudo rights for the normal (first) user you specified in the install.
It IS possible to enable root but you have to do it using sudo from the normal user account.
 
Old 07-13-2019, 05:29 AM   #3
mbox frex
LQ Newbie
 
Registered: Dec 2017
Posts: 6

Original Poster
Rep: Reputation: Disabled
how do i solve i
 
Old 07-13-2019, 05:39 AM   #4
ehartman
Member
 
Registered: Jul 2007
Location: Delft, The Netherlands
Distribution: Slackware
Posts: 672

Rep: Reputation: 317Reputation: 317Reputation: 317Reputation: 317
Quote:
Originally Posted by mbox frex View Post
how do i solve i
In general, although I've never done this myself:
login as your normal user.
become root with "sudo -s" (you may have to enter your password again)
now make sure that there are entries for root: in /etc/passwd and /etc/shadow,
if not, create them (they should be the first line).
the entry in the passwd file should look like
Code:
root:x:0:0:Superuser:/root:/bin/bash
and the directory /root MUST exist.
use "passwd root" to set a GOOD (hard to break) password for that root user.
exit the sudo session
now try su to become root. If it works, log out completely and login again AS root.

PS: this sets only LOCAL access as root, remote you will still have to enter as "your normal user" and either use su or sudo, this is a security measure to prevent password carckers ON your server.
 
  


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
LXer: Canonical Preps Emergency Point Releases for Ubuntu 16.04 LTS and Ubuntu 14.04 LTS LXer Syndicated Linux News 0 02-25-2019 09:30 AM
LXer: Canonical Patches OpenSSL Regression in Ubuntu 16.04 LTS, 14.04 LTS and 12.04 LTS LXer Syndicated Linux News 0 09-27-2016 12:32 PM
LXer: Ubuntu 12.04.5 LTS (Precise Pangolin) Released with Linux Kernel from Ubuntu 14.04 LTS LXer Syndicated Linux News 0 08-08-2014 08:00 AM
LXer: How to upgrade Ubuntu 12.04 LTS to Ubuntu 14.04 LTS LXer Syndicated Linux News 0 05-05-2014 07:51 PM
LXer: I update Ubuntu 6.06 LTS and 8.04 LTS ... one has SSH issues, one does not LXer Syndicated Linux News 0 05-20-2008 07:30 AM

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

All times are GMT -5. The time now is 09:42 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