Announcement

Collapse
No announcement yet.

Unable to start xserver

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Unable to start xserver

    Hi there!
    I'm having trouble with my system. All was nice and smooth and suddenly, when it boots, the screen stays black after Kubuntu logo. If I go to the command line by using CTRL+ALT+F1 and try to initiate xserver by typing xinit, it returns "server error". Among other things, it also says: "parse_vt_settings: cannot open /dev/tty0 (permission denied).
    Any idea about how to fix this so system initiates normally?
    Thanks in advance!
    Last edited by Fernando; Nov 16, 2017, 06:49 AM.

    #2
    Try using: startx
    Windows no longer obstructs my view.
    Using Kubuntu Linux since March 23, 2007.
    "It is a capital mistake to theorize before one has data." - Sherlock Holmes

    Comment


      #3
      Or, startkde

      But first, I'd check the owner of ~/.Xauthority
      It sometimes gets changed to root when doing maintenance work on a system. If it is owned by root then you'll get a black screen when you attempt to log in.

      If it is owned by you, as it should be, then perhaps your display configuration changed due to an update or something else.

      What is your GPU?
      Last edited by GreyGeek; Nov 16, 2017, 11:42 AM.
      "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
      – John F. Kennedy, February 26, 1962.

      Comment


        #4
        Hi.
        Thanks for the help!

        startx returned "xauth: timeout in locking ~/.Xauthority"
        Then the screen went black for a while until finally returned a lot of lines in which it seemed like xserver attempted to start but, among other things, said "xf86EnableIOports: failed to set IOPL for I/O (Operation not permitted)".

        startkde, on the other hand, returned: "$DISPLAY is not set or cannot connect to the x server".

        I checked .Xauthority and the owner is root, but I didn't know how to change that. Anyway, the system doesn't even load the users login screen so I don't know if that is the problem...
        According to lspci, my system GPU is a "Intel Corporation 4th generation Core Processor Family Integrated Graphics Controller (rev 06)".

        Comment


          #5
          Well, I found out how to change ownership of .Xauthority and did it. Then I did
          Code:
          sudo startx
          and I got rid of the timeout problem and also got the mouse cursor on an otherwise totally black screen. I rebooted and nothing new happened: I am back where I was, a black screen. Ownership of .Xauthority has gone back to root so it makes me think that was not the problem.

          Comment


            #6
            By the way, if I try xinit, it somewhere returns "...server already running".
            If I try to kill it with xkill, it says "Unable to open display """ (the two first quotation marks belong to the actual message on the screen).

            Comment


              #7
              The simplest way to fix the ownership of .Xauthority is to simply delete it. A new copy will be created when you reboot.

              Use the following to remove the file:
              Code:
              sudo rm ~/.Xauthority
              You can reboot from the terminal using:
              Code:
              sudo shutdown -r now
              BTW, in your post above (#5) if you had simply used "startx" (no sudo) you probably would have fixed the problem.
              Last edited by Rod J; Nov 17, 2017, 06:17 AM.
              Desktop PC: Intel Core-i5-4670 3.40Ghz, 16Gb Crucial ram, Asus H97-Plus MB, 128Gb Crucial SSD + 2Tb Seagate Barracuda 7200.14 HDD running Kubuntu 18.04 LTS and Kubuntu 14.04 LTS (on SSD).
              Laptop: HP EliteBook 8460p Core-i5-2540M, 4Gb ram, Transcend 120Gb SSD, currently running Deepin 15.8 and Manjaro KDE 18.

              Comment


                #8
                I completely (I guess) uninstalled and reinstalled xserver-xorg and kubuntu-desktop and regained ownership of .Xauthority. Then I did startx (no sudo) and got the mouse again. Unexpectedly, a window appeared asking permission for dropbox to change permission to its own folder. That's the only graphics I have got in two days.

                Rod, I tried what you proposed but it didn't work.
                I'm lost by now...

                Comment


                  #9
                  Sounds to me like your user /home directory is hosed; items in it owned by root and not your user. I say that because you did identify that .Xauthority was owned by root. 99.99+% of the contents in /home should NOT be owned by root. The way stuff in /home gets changed to ownership by root is running starting graphical applications from the konsole using sudo (sudo kate; sudo dolphin notably) and them making changes to files.
                  Windows no longer obstructs my view.
                  Using Kubuntu Linux since March 23, 2007.
                  "It is a capital mistake to theorize before one has data." - Sherlock Holmes

                  Comment


                    #10
                    In a Konsole issue:
                    sudo chown -R yourname:yourname /home/yourname
                    "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
                    – John F. Kennedy, February 26, 1962.

                    Comment


                      #11
                      Originally posted by GreyGeek View Post
                      In a Konsole issue:
                      sudo chown -R yourname:yourname /home/yourname
                      Don’t type that litterally of course. Replace yourname with the username that you use to login with.
                      Windows no longer obstructs my view.
                      Using Kubuntu Linux since March 23, 2007.
                      "It is a capital mistake to theorize before one has data." - Sherlock Holmes

                      Comment


                        #12
                        Greygeek: I took ownership of my whole /home folder by typing what you said but, unfortunately, it didn't fix the problem.
                        Snowhog: I knew that, thanks!
                        Any other ideas?

                        What kills me is that xinit returns: "server already running".
                        Last edited by Fernando; Nov 20, 2017, 02:40 AM.

                        Comment


                          #13
                          Maybe it's nothing, but I can get the command like in tty1 through tty6 but not in tty7...

                          Comment


                            #14
                            Originally posted by Fernando View Post
                            Maybe it's nothing, but I can get the command like in tty1 through tty6 but not in tty7...
                            TTY7 and 8 are reserved for the GUI. I doubt you need more that 6 terminals.

                            The simplest way to confirm that the problem is in user settings is by adding and logging into a new user.

                            To add a user, log into TTY1 and then:
                            sudo adduser <USERNAME>

                            Then, restart sddm and log in as the new user:
                            sudo service sddm restart

                            When your done, you can remove the new user:
                            sudo deluser --remove-home <USERNAME>

                            Please Read Me

                            Comment


                              #15
                              "sudo service sddm restart" returned: "Failed to restart sddm.service: Unit sddm not found.". I installed sddm (not that I remember uninstalling it) and started it. That gave me a blank screen again. I rebooted and now I can't even get to the command line using CRTL+ALT+F1. I have no signal on my monitor but for TTY7 and that's a black screen.
                              So... I don't know.
                              Last edited by Fernando; Nov 21, 2017, 02:44 AM.

                              Comment

                              Working...
                              X