LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 02-19-2004, 10:58 AM   #1
afz
LQ Newbie
 
Registered: Oct 2003
Location: Mexico
Posts: 7

Rep: Reputation: 0
Can't Start X Server


The Computer doesn't go to Graphic Mode as usual, It just stays in console (text) mode.

When I type startx, the following error appears:


[root@terminal root]# startx

xauth: error in locking authority file /root/.Xauthority
xauth: error in locking authority file /root/.Xauthority
xauth: error in locking authority file /root/.Xauthority
xauth: error in locking authority file /root/.Xauthority

Fatal server error: Can't read lock file /tmp/.X0-lock

When reporting a problem related to a server crash, please send the full server output, not just the last messages. Please report problems to xfree86@xfree86.org.


giving up. xinit: Connection refused (errno 111): unable to connect to X server
xinit: No such process (errno 3): Server error.
xauth: error in locking authority file /root/.Xauthority


I'm logging in as root, and the same error is given when I log in as any other user.

I can't create new users, because when I use the command useradd, or adduser, this error pops out:


[root@terminal root]# adduser test
adduser: unable to lock password file


The adduser command is not very important for me.

Please help me fix the X_server error.

Note: There is no knldiag.
 
Old 02-19-2004, 12:39 PM   #2
RobertP
Member
 
Registered: Jan 2004
Location: Manitoba, Canada
Distribution: Debian
Posts: 454

Rep: Reputation: 32
This error message can be found via Google. It seems to happen with some corruption of the filesystem, perhaps from an improper shutdown. Did you have a bad shutdown earlier? Do you get any messages about the filesystem when you reboot? You can look in /var/log/messages for such messages.

Some suggested solutions are moving the old .Xauthority file
e.g. mv .Xauthority OLD.Xauthority
and rebooting or starting X (this should be a safe procedure)

or doing a fsck.

as root
#telinit 1
#fsck /dev/hdax
This could mess up your filesystem, so be careful. Read man fsck for details.

You may want to poke around looking at permissions on the .Xauthority file or its directory to see why it cannot be used.
 
Old 02-19-2004, 01:22 PM   #3
afz
LQ Newbie
 
Registered: Oct 2003
Location: Mexico
Posts: 7

Original Poster
Rep: Reputation: 0
Yes I had a bad Shutdown, and I have problems at boot. this are some messages from
/var/log:
-------------------- beginning of messages -------------------

Feb 18 13:03:03 dbserver1 fsck: /dev/hda1: UNEXPECTED INCONSISTENCY; RUN fsck MANUALLY.
Feb 18 13:03:03 dbserver1 fsck: ^I(i.e., without -a or -p options)
Feb 18 13:03:05 dbserver1 fsck: /dev/hda1 contains a file system with errors, check forced.
Feb 18 13:03:05 dbserver1 fsck: Pass 1: Checking inodes, blocks, and sizes
Feb 18 13:03:05 dbserver1 fsck: e2fsck 1.24a (02-Sep-2001)
Feb 18 13:03:13 dbserver1 fsck: Error reading block 110 (Attempt to read block from filesystem resulted in short
read) while doing inode scan. Ignore error? yes
Feb 18 13:03:41 dbserver1 fsck: Error reading block 163983 (Attempt to read block from filesystem resulted in sh
ort read) while doing inode scan. Ignore error? yes
Feb 18 13:04:18 dbserver1 fsck: Error reading block 229578 (Attempt to read block from filesystem resulted in sh
ort read) while doing inode scan. Ignore error? yes
Feb 18 13:04:51 dbserver1 fsck: Error reading block 524575 (Attempt to read block from filesystem resulted in sh
ort read) while doing inode scan. Ignore error? yes
Feb 18 13:05:03 dbserver1 fsck: Pass 2: Checking directory structure
Feb 18 13:05:04 dbserver1 fsck: Entry 'issue' in /etc (96001) has deleted/unused inode 97239. Clear? yes
Feb 18 13:05:04 dbserver1 fsck: Entry 'issue.net' in /etc (96001) has deleted/unused inode 97240. Clear? yes
Feb 18 13:05:07 dbserver1 fsck: Entry 'ide' in
Feb 18 13:05:07 dbserver1 fsck: /lib/dev-state (208044) has an incorrect filetype (was 2, should be 1).
Feb 18 13:05:07 dbserver1 fsck: Fix? yes
Feb 18 13:05:11 dbserver1 fsck: Pass 3: Checking directory connectivity
Feb 18 13:05:11 dbserver1 fsck: Pass 4: Checking reference counts
Feb 18 13:05:11 dbserver1 fsck: Inode 97237 ref count is 1, should be 2. Fix? yes
Feb 18 13:05:11 dbserver1 fsck: Inode 208044 ref count is 10, should be 9. Fix? yes
Feb 18 13:05:11 dbserver1 fsck: Pass 5: Checking group summary information
Feb 18 13:05:11 dbserver1 fsck: Inode 208044 ref count is 10, should be 9. Fix? yes
Feb 18 13:05:11 dbserver1 fsck: Pass 5: Checking group summary information
Feb 18 13:05:12 dbserver1 fsck: Block bitmap differences: -21389 -21396 -21397 -21399 -21400 -21401 -21402 -214
03 -21404 -21405 -21409 -21410 -21411 -21412 -21413 -21415 -21416 -21417 -21418 -21419 -21420 -21421 -21430 -214
31 -21432 -21433 -21434 -21435 -21436 -104185 -104186 -104187 -104188 -104189 -104190 -104191 -106267 -106268 -1
06269 -106270 -106271 -106272 -106273 -200961 -200962 -200963 -200964 -200965 -200966 -200967 -201185 -201186 -2
01187 -201188 -201189 -201190 -201191 -204516 -204517 -204518 -204519 -204520 -204521 -204522 -211994 -211995 -2
11996 -211997 -211998 -211999 -212000 -212004 -212005 -212006 -212007 -212008 -212009 -212010 -397415 -397416 -3
97417 -397418 -397419 -397420 -397421 -562193 -562194 -562195 -562196 -562197 -562198 -562199 -562200
Feb 18 13:05:12 dbserver1 fsck: Fix? yes
Feb 18 13:05:12 dbserver1 fsck: Free blocks count wrong for group #0 (11770, counted=11799).
Feb 18 13:05:12 dbserver1 fsck: Fix? yes
Feb 18 13:05:12 dbserver1 fsck: Free blocks count wrong for group #3 (19355, counted=19369).
Feb 18 13:05:12 dbserver1 fsck: Fix? yes
Feb 18 13:05:12 dbserver1 fsck: Free blocks count wrong for group #6 (17755, counted=17790).
Feb 18 13:05:12 dbserver1 fsck: Fix? yes
Feb 18 13:05:12 dbserver1 fsck: Free blocks count wrong for group #12 (28564, counted=28571).
Feb 18 13:05:12 dbserver1 fsck: Fix? yes
Feb 18 13:05:12 dbserver1 fsck: Free blocks count wrong for group #17 (25213, counted=25221).
Feb 18 13:05:12 dbserver1 fsck: Fix? yes
Feb 18 13:05:12 dbserver1 fsck: Free blocks count wrong (622556, counted=622649).
Feb 18 13:05:12 dbserver1 fsck: Fix? yes
Feb 18 13:05:12 dbserver1 fsck: Inode bitmap differences: -273515 -273516
Feb 18 13:05:12 dbserver1 fsck: Fix? yes
Feb 18 13:05:12 dbserver1 fsck: Free inodes count wrong for group #17 (14463, counted=14465).
Feb 18 13:05:12 dbserver1 fsck: Fix? yes
Feb 18 13:05:12 dbserver1 fsck: Free inodes count wrong (404998, counted=405000).
Feb 18 13:05:12 dbserver1 fsck: Fix? yes
Feb 18 13:05:12 dbserver1 fsck: /dev/hda1: ***** FILE SYSTEM WAS MODIFIED *****
Feb 18 13:05:12 dbserver1 fsck: /dev/hda1: 43000/448000 files (0.3% non-contiguous), 272966/895615 blocks
Feb 18 13:05:56 dbserver1 rc.sysinit: Remounting root filesystem in read-write mode: succeeded

-------------------- end of messages -------------------

I Did mv the .Xauthority to OLD.Xauthority
then I ran the command "startx. and the same error happened.

About the fsck: It seems like there is not a man for that command.
Or at least it cannot be displayed.

But that command is executed when I boot so.. I think the filesystem should be O.K. by now... I'll reboot again to see what happends.

Last edited by afz; 02-19-2004 at 01:23 PM.
 
Old 02-19-2004, 05:31 PM   #4
RobertP
Member
 
Registered: Jan 2004
Location: Manitoba, Canada
Distribution: Debian
Posts: 454

Rep: Reputation: 32
Yes, that's the thing. You need to run fsck manually. Did you install an ext3 filesystem? They are much faster at recovering from this sort of thing.

Check the type of the filesystem by
cat /etc/fstab
Then you need to reboot to a rescue cd or floppy and without mounting your hard drive
fsck -t ext2 /dev/hda1
Make the ext2 ext3 if that is your file type
Make the hda1 hdxx for your system, according to the cat /etc/fstab
See http://www.pafis.shh.fi/reference/ma...00000000000000

This looks like the sort of mess ext2 filesystems get into. It is a toss up whether fsck can fix it.
It may be just as well to re-install and use ext3 this time. I have a server with multiple users logged on and running and had no trouble recovering with ext3 (it was automatically done at reboot).

Try fsck. If that does not work, re-install.
 
Old 02-20-2004, 11:48 AM   #5
afz
LQ Newbie
 
Registered: Oct 2003
Location: Mexico
Posts: 7

Original Poster
Rep: Reputation: 0
ext2

I have ext2.

OK, I'll boot with a Floppy and run fsck manually.
And then my file system will be fixed.

Thanks !
 
Old 02-24-2004, 12:13 PM   #6
afz
LQ Newbie
 
Registered: Oct 2003
Location: Mexico
Posts: 7

Original Poster
Rep: Reputation: 0
Thumbs up It is fixed !

Everything works now.
-The X server and even the SAPDB database that stopped working, everything is working fine. And all I did is a manual fsck.

Thanks RobertP


Last edited by afz; 02-24-2004 at 12:14 PM.
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
X server won't start pappsynz Linux - Newbie 9 10-13-2005 11:23 AM
X Server won't start ronkymac Linux - Software 5 05-17-2005 07:39 AM
Can't start X server linx win Fedora 15 04-22-2004 09:40 AM
Cant start x server Zolan Linux - Newbie 2 03-24-2004 03:48 PM
can't start x server petez5 Linux - General 1 09-12-2003 07:16 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

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