LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Ubuntu (https://www.linuxquestions.org/questions/ubuntu-63/)
-   -   Solving boot to commandline problem (https://www.linuxquestions.org/questions/ubuntu-63/solving-boot-to-commandline-problem-921083/)

bosth 12-29-2011 10:48 AM

Solving boot to commandline problem
 
Hello,
I'm a Slackware user, but I installed Ubuntu on my father's netbook and he's been using it fairly happily for the last year or so.

He's currently on vacation and says he "gets an error message" when he tries to boot into Ubuntu. It turns out that the message is just the command prompt:
Code:

$USER@$COMPUTER $
There is nothing else on screen and let's assume he didn't or can't catch the messages during booting, and let's assume he "changed nothing" which caused it to break. And he's probably running whatever version of Ubuntu came out "about a year ago".

I figure I could probably muddle my way through and fix it ... if I had the computer in front of me.

I've asked if he's booting into a recovery mode (Ubuntu has that as a boot option, right?), but I doubt he's making that simple of a mistake.

Coming from a Slackware background and only slightly familiar with Ubuntu my first thought was to get him to try:
Code:

sudo init 4
and see what happens, but it'll get tedious quickly to get him to try things and then have him transcribe the error messages by hand into another computer just to email it back to me. I'm looking for any suggestions on how to proceed.

Thanks!

eSelix 12-29-2011 11:01 AM

"init 4" will not help, as Ubuntu will not use runlevels (but of course it can be configured). You should check /var/log/Xorg.0.log for errors after trying to start "service gdm start".

I suspect that you need to recompile video drivers. If you used proprietary then just download and run installer as root in the console. But it can be anything, you need to check log, also /var/log/syslog.

bosth 12-29-2011 11:16 AM

Quote:

Originally Posted by eSelix (Post 4561038)
"init 4" will not help, as Ubuntu will not use runlevels (but of course it can be configured). You should check /var/log/Xorg.0.log for errors after trying to start "service gdm start".

I suspect that you need to recompile video drivers. If you used proprietary then just download and run installer as root in the console. But it can be anything, you need to check log, also /var/log/syslog.

Right, so init won't get me anywhere on Ubuntu... If I had the computer myself, I'd be going through the logs, but I'm not going to get him to do that. I just want a few things for him to try, to see if we can get it going. I assume you'll need a sudo in front of any service commands, right?

Any other suggestions?

Thanks.

273 12-29-2011 11:21 AM

<aside>
One thing to try is to simply type:
sudo startx
It may work and, if not, could give some clues as to what is not working.
</aside>

bosth 12-29-2011 11:30 AM

Quote:

Originally Posted by 273 (Post 4561055)
<aside>
One thing to try is to simply type:
sudo startx
It may work and, if not, could give some clues as to what is not working.
</aside>

Wouldn't it just be
Code:

startx
since he doesn't want to have a root session?

273 12-29-2011 11:35 AM

Very probably. I don't think that's ever worked for me though -- I don't seem to have permission to do so.
Edit: When running Ubuntu and Debian whenever I've been dropped into the shell on startup the way I've started X is by sudoing it as it doesn't work without.
I know it's different but I tried to run:
startx -- :1 vt8
Just now and the result was:
X: user not authorized to run the X server, aborting.

inspiron_Droid 12-29-2011 11:36 AM

Code:

sudo tellinit:3:
or edit /etc/initab

Code:

defaultrunlevel
:3:


widget 12-29-2011 12:58 PM

With out more info it is hard to say what the problem is.

Ubuntu takes you to a # (root) prompt in recovery mode so that does seem to say he is not booting that way.

Code:

startx
is the way to go. If that does not work it will give some clues. Make sure he gets the messages from the screen if it fails.

Adding sudo to it would indeed, if it worked, put him in as root and this could only make things worse.

bosth 12-29-2011 01:37 PM

Ok thanks for the answers. I've just heard back and startx reports (in his words) something like:
Code:

You do not have access to program or feature X
I assume this is actually the message
Code:

X: user not authorized to run the X server, aborting.
reported by 273 above.

As I said, I'd be digging through the X.org logs, but I'd rather not have him do that... though maybe
Code:

grep EE /var/log/Xorg.0.log
would be produce reasonably short output. Before I do that though, any other suggestions?

eSelix 12-29-2011 01:56 PM

Better using context feature
Code:

grep -C 3 EE /var/log/Xorg.0.log
Even more better would be if he can take a photo of screen and paste it here, for example last lines:
Code:

cat /var/log/Xorg.0.log

bosth 12-29-2011 04:28 PM

Photos are a good idea... results pending.

bosth 01-08-2012 01:51 PM

1 Attachment(s)
Ok, finally heard back with the attached jpg, but as you can see the grep command was typed incorrectly so not much to go on. Could a full disk or /tmp partition be behind this I wonder?

eSelix 01-09-2012 02:27 PM

1. startx will not work without root privilages. Anyway, in Ubuntu to start X with normal login window, is command
Code:

sudo service gdm start
or in older versions
Code:

sudo /etc/init.d/gdm start
2. IO Error relates to X, so I don't think it has something common with disk, but this cannot be excluded, so check
Code:

df -h
3. Log is necessary, do it again
Code:

grep  -C  5  EE  /var/log/Xorg.0.log

bosth 01-09-2012 05:56 PM

Quote:

Originally Posted by eSelix (Post 4570428)
1. startx will not work without root privilages. Anyway, in Ubuntu to start X with normal login window, is command...

Interesting (from a Slackware perspective). I only use X by running startx as user.

Quote:

Originally Posted by eSelix (Post 4570428)
2. IO Error relates to X, so I don't think it has something common with disk, but this cannot be excluded, so check
Code:

df -h
3. Log is necessary, do it again
Code:

grep  -C  5  EE  /var/log/Xorg.0.log

Yes I'm waiting for the results of the commands typed correctly. I thought of the disk space problem since I've seen X perform very strangely when it can't write to /tmp.

I think in the end, I will probably end up fixing this when he has returned and I have it my own hands!

eSelix 01-10-2012 04:09 AM

Quote:

I only use X by running startx as user.
Sorry, I just checked and I was in mistake. You can also run startx as usual user in Ubuntu.


All times are GMT -5. The time now is 10:23 AM.