LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 03-09-2016, 12:41 PM   #1
qajaq
Member
 
Registered: Sep 2008
Location: north-central Florida
Distribution: Lubuntu 19.04, Kubuntu 18.04
Posts: 120

Rep: Reputation: 15
Ubuntu boots to console and allows only root login


I have a laptop set up with Kubuntu 12.04, 64-bit, and I used it for a couple months without problems. Then, after booting it up one evening and copying a batch of files onto the hard drive from a USB stick, the system froze. No soft-reboot would work, so I used the power button. After that, the computer does not boot to the GUI desktop, but only to console, and allows only root to log in.

Note that the files that were copied immediately before the failure were copied to a data partition separate from the system files. All those files are in place.

From the console, as root, I can run startx and get the GUI desktop. I cannot, however, use the su command to change to a regular user. I have tried changing to the user that existed before the failure, and I have created a new user since then and tried it. Neither works.

Obviously, the new user's password was created after the crash. And I've also used the passwd command to reset the pre-existing user's password, so I know it's valid.

The error message I get in both cases is
Quote:
Unable to cd to /home/...
(where the ellipsis represents the user's name). The /home directory has full drwxrwxrwx permissions, as do both users' directories. Both users' directories are owned by the respective users, and all files (including hidden files) have rwx permissions in the owner's column.

Any ideas where I can look further for solutions?
 
Old 03-09-2016, 02:00 PM   #2
Keruskerfuerst
Senior Member
 
Registered: Oct 2005
Location: Horgau, Germany
Distribution: Manjaro KDE, Win 10
Posts: 2,199

Rep: Reputation: 164Reputation: 164
Can you check dmesg or any other log?
 
Old 03-09-2016, 02:57 PM   #3
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,925
Blog Entries: 44

Rep: Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159
Moderator response

Moved: This thread is more suitable in <Ubuntu> and has been moved accordingly to help your thread/question get the exposure it deserves.
 
Old 03-09-2016, 05:42 PM   #4
qajaq
Member
 
Registered: Sep 2008
Location: north-central Florida
Distribution: Lubuntu 19.04, Kubuntu 18.04
Posts: 120

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Keruskerfuerst View Post
Can you check dmesg or any other log?
Yes, I can check /var/log/dmesg, though I have no idea what the result means. I don't even know if newer material is added at the head or the tail. Nor do I know what other logs to look at. Can you offer any guidance here?
 
Old 03-11-2016, 02:29 AM   #5
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by qajaq View Post
Then, after booting it up one evening and copying a batch of files onto the hard drive from a USB stick, the system froze.
we will need more information on this.
i suspect something went very, very wrong there.

Quote:
The /home directory has full drwxrwxrwx permissions, as do both users' directories. Both users' directories are owned by the respective users, and all files (including hidden files) have rwx permissions in the owner's column.
this sounds wrong.
my /home has drwxr-xr-x root:root, and /home/username has drwx------ username:users.
 
Old 03-11-2016, 04:35 AM   #6
descendant_command
Senior Member
 
Registered: Mar 2012
Posts: 1,876

Rep: Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643
...and the root account is disabled on Ubuntu.
 
Old 03-11-2016, 07:06 AM   #7
qajaq
Member
 
Registered: Sep 2008
Location: north-central Florida
Distribution: Lubuntu 19.04, Kubuntu 18.04
Posts: 120

Original Poster
Rep: Reputation: 15
ondoho, I don't know how much more information there is to give. I had several video files on a USB stick, mounted the USB stick on the laptop at /mnt/usb1, copied the files to /video (which is on a partition separate from the root and system files), and let it run. When I went back to it, an hour or so later, the system was non-responsive. Ctrl-C had no effect. Ctrl-Alt-Del had no effect. I held the power button down to shut the machine off, then re-booted.

The system, since then, boots to the console and asks for a login and password. If I enter a regular username and the associated password, the system will very briefly display a message - it looks like a "Last login was..." message, but it disappears too quickly for me to read in detail. Then it again asks for login and password. I can enter username root and root's password and the computer accepts those credentials and runs as root, in console.

When I try to su to another user, I get the error message that the system cannot cd to that user's home directory. However, I can manually cd to those home directories.

The permissions have not changed since I set the machine up. They are set the same now as when I was able to use the machine normally, before the freeze-up.
 
Old 03-11-2016, 07:24 AM   #8
oldtechaa
Member
 
Registered: May 2015
Location: US
Distribution: Fedora
Posts: 364

Rep: Reputation: 83
What filesystem is the main filesystem? If it was ext2 I could believe that it would corrupt something on hard shutdown.
 
Old 03-11-2016, 09:14 AM   #9
qajaq
Member
 
Registered: Sep 2008
Location: north-central Florida
Distribution: Lubuntu 19.04, Kubuntu 18.04
Posts: 120

Original Poster
Rep: Reputation: 15
All partitions on the HDD are ext3 file systems.
 
Old 03-11-2016, 03:21 PM   #10
descendant_command
Senior Member
 
Registered: Mar 2012
Posts: 1,876

Rep: Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643
Was /video mounted?
Maybe your / is full?
 
Old 03-11-2016, 06:53 PM   #11
qajaq
Member
 
Registered: Sep 2008
Location: north-central Florida
Distribution: Lubuntu 19.04, Kubuntu 18.04
Posts: 120

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by descendant_command View Post
Was /video mounted?
Maybe your / is full?
Yes, it was mounted. The root-directory partition has over 25 GB of unused space. No partition, in fact, is anywhere near filled.
 
Old 03-11-2016, 06:58 PM   #12
descendant_command
Senior Member
 
Registered: Mar 2012
Posts: 1,876

Rep: Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643
OK, well back to looking like user error to me ...
 
Old 03-15-2016, 11:27 AM   #13
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by qajaq View Post
I don't know how much more information there is to give. I had several video files on a USB stick, mounted the USB stick on the laptop at /mnt/usb1, copied the files to /video (which is on a partition separate from the root and system files), and let it run.
the actual commands you used.

but to me, too, it looks like you accidentally hosed your system.

and if it really was set up like this from the beginning, then something went wrong there, too.
 
Old 03-15-2016, 12:02 PM   #14
qajaq
Member
 
Registered: Sep 2008
Location: north-central Florida
Distribution: Lubuntu 19.04, Kubuntu 18.04
Posts: 120

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by ondoho View Post
the actual commands you used.
After I plugged in the USB stick and determined the drive and partition to which it was mapped (sdb1), I did this:
Code:
$ su -
password: 
# mount /dev/sdb1 /media/usb1
# cp -a /media/usb1/* /video/
I had previously made sure that the USB stick had nothing on it before I copied the video files (in their respective subdirectories) onto it, and I had checked that the /dev/sda5 partition was mounted to /video.

The files copied correctly, but the computer would not respond to anything after they were in place - except, of course, the power button.

Quote:
and if it really was set up like this from the beginning, then something went wrong there, too.
I'm not sure what you mean by "...set up like this..." but the system was not initially configured to boot to console nor to allow a root log-in. For the first few months, it booted to a grub2 menu screen, defaulting to the Kubuntu OS and allowing my regular user-name log-in (but not allowing a root log-in, which is the norm for Ubuntu). It changed to the console-only, root-log-in-allowed behavior only after this freeze-up.
 
Old 03-18-2016, 01:15 AM   #15
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by qajaq View Post
Code:
$ su -
password: 
# mount /dev/sdb1 /media/usb1
# cp -a /media/usb1/* /video/
that looks ok to me.
of course one could discuss whether there was a need to perform that command while still in superuser mode; had you exited first, there'd simply have been less risk of accidentally doing something fatal.
Quote:
I'm not sure what you mean by "...set up like this..."
i meant the permissions on your home directory/ies, as you quoted earlier.

unfortunately, at this point there's not much anyone can do to help you unless you start seriously troubleshooting your problem (probably from booting into a live system).
 
  


Reply



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
[ubuntu 10.04] root auto login to console mode 54781 Linux - Desktop 8 05-30-2010 03:30 PM
Auto login as root as soon when computer boots up linux_newb Linux - Server 1 01-26-2010 03:39 AM
users cant able to login in any console,but root can login. skumar.v Linux - Security 1 04-19-2008 06:57 AM
Only allow root login on console vvcat Linux - Security 4 03-20-2008 11:01 PM
Please help: console root login incorrect! aponcel Linux - Networking 7 07-19-2001 02:42 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 02:17 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
Open Source Consulting | Domain Registration