kde not finding DISPLAY environment variable

I upgraded from opensuse 12.3 to 13.1 through zypper. Since upgrade I am not able to login into KDE. I press login, briefly login screen disappers, when I expect KDE splash, it returns to login.

I used ‘startkde’ from console to find out what is happening. It seems KDE is not finding DISPLAY environment variable. But I am able to login into GNOME, ICEWM,TWM.

While in console, after login, if I check environment variables, I see no DISPLAY variable. But GNOME,TWM,ICEWM have no problem and I am dropped to graphical login every boot ( obviously kdm is starting ), but not KDE.

Any help to understand this ? Thanks in advance.

Well, it’s normal that you don’t have a DISPLAY variable in console. This is set during graphical login and only visible there.
(it specifies the X display applications should connect to after all, so it doesn’t make sense in text mode)

But to your actual problem:
Maybe not all KDE packages got upgraded?

Did you disable all additional (non-13.1) repos before the upgrade?
Please post your repo list:

zypper lr -d

And please post /var/log/kdm.log and ~/.xsession-errors-:0 (this file is deleted on login I think, so better log in to text mode after a failed KDE login and backup that file). Somewhere in there should be a clue why KDE is not starting.
You can upload them to http://susepaste.org/ and post a link if they are too big.

You could try to run “startkde” from an xterm inside an IceWM or twm session. It should find the $DISPLAY then and try to start KDE.
Maybe you would get a useful error message then?

My suggestion:

Rename “.profile” as “OLD.profile”
rename “.bashrc” as “OLD.bashrc”

if you are using a shell other than bash, then instead to the equivalent for the startup files for whatever shell you use.

Then see if works.

I’m guessing that perhaps there is something in your shell startup that is causing problems.

Another possibility is that you edited “/etc/profile” and/or “/etc/bashrc” and broke something.

Did you disable all additional (non-13.1) repos before the upgrade?
Please post your repo list:

zypper lr -d

This is my repository list,

linux-gv4m:~ # zypper lr -d
#  | Alias                            | Name                             | Enabled | Refresh | Priority | Type   | URI                                                                                 | Service
---+----------------------------------+----------------------------------+---------+---------+----------+--------+-------------------------------------------------------------------------------------+--------
 1 | 8051_IDE                         | 8051_IDE                         | No      | Yes     |   99     | rpm-md | http://download.opensuse.org/repositories/home:/cyberorg:/livextra/openSUSE_12.3/   |        
 2 | Subpixel_Infinality              | Infinality_subpixel              | No      | Yes     |   99     | rpm-md | http://download.opensuse.org/repositories/home:/ketheriel:/infinality/Tumbleweed/   |        
 3 | Tumbleweed                       | Tumbleweed                       | Yes     | Yes     |   99     | rpm-md | http://download.opensuse.org/repositories/openSUSE:/Tumbleweed/standard/            |        
 4 | download.opensuse.org-oss        | Main Repository (Sources)        | No      | Yes     |   99     | yast2  | http://download.opensuse.org/source/distribution/12.3/repo/oss/                     |        
 5 | gEDA                             | gEDA                             | No      | Yes     |   99     | rpm-md | http://download.opensuse.org/repositories/home:/Dmitry_R:/geda/openSUSE_12.3/       |        
 6 | home:dstoecker                   | home:dstoecker                   | Yes     | Yes     |   99     | rpm-md | http://download.opensuse.org/repositories/home:/dstoecker/openSUSE_13.1/            |        
 7 | network:cluster:xtreemos         | network:cluster:xtreemos         | No      | Yes     |   99     | rpm-md | http://download.opensuse.org/repositories/network:/cluster:/xtreemos/openSUSE_12.3/ |        
 8 | openSUSE Current OSS             | openSUSE Current OSS             | Yes     | Yes     |   99     | yast2  | http://download.opensuse.org/distribution/openSUSE-current/repo/oss/                |        
 9 | openSUSE Current non-OSS         | openSUSE Current non-OSS         | Yes     | Yes     |   99     | yast2  | http://download.opensuse.org/distribution/openSUSE-current/repo/non-oss/            |        
10 | openSUSE Current non-OSS updates | openSUSE Current non-OSS updates | Yes     | Yes     |   99     | rpm-md | http://download.opensuse.org/update/openSUSE-non-oss-current                        |        
11 | openSUSE Current updates         | openSUSE Current updates         | Yes     | Yes     |   99     | rpm-md | http://download.opensuse.org/update/openSUSE-current/                               |        
12 | openSUSE:12.3:NonFree            | openSUSE:12.3:NonFree            | No      | Yes     |   99     | yast2  | http://download.opensuse.org/distribution/12.3/repo/non-oss/                        |        
13 | openSUSE:12.3:Update             | openSUSE:12.3:Update             | No      | Yes     |   99     | rpm-md | http://download.opensuse.org/update/12.3/                                           |        
14 | openSUSE_subpixel                | openSUSE_subpixel                | No      | Yes     |   99     | rpm-md | http://repos.opensuse-community.org/subpixel/openSUSE_Tumbleweed/                   |        
15 | packman                          | Packman_Tumbleweed               | Yes     | Yes     |   99     | rpm-md | http://packman.inode.at/suse/openSUSE_Tumbleweed                                    |        
16 | repo-update-non-oss              | openSUSE-12.2-Update-Non-Oss     | No      | Yes     |   99     | rpm-md | http://download.opensuse.org/update/12.2-non-oss/                                   |        
17 | science                          | science                          | No      | Yes     |   99     | rpm-md | http://download.opensuse.org/repositories/science/openSUSE_12.3/    

And please post /var/log/kdm.log and ~/.xsession-errors-:0 (this file is deleted on login I think, so better log in to text mode after a failed KDE login and backup that file). Somewhere in there should be a clue why KDE is not starting.

My kdm.log -

http://susepaste.org/90593347

startkde run on konsole in icewm.

linux-gv4m:~ # startkde
/usr/bin/startkde: line 117: .: krandrstartup: file not found


This may also give a clue. In kdm login screen, i happened to choose metacity as a window manager . From that time, I neither have a window manager,nor kde login screen.May be kde auto llogging to an empty window manager ?

Thanks.

This is not a problem. I have other accounts which are not regularly used and root account which is never used, for all I have the same response.

Well, this could definitely could need some cleanup! :wink:
You could remove all those disabled repos (especially those from 12.2).

So you are using Tumbleweed, not 13.1.
Why didn’t you mention this?

But well, this shouldn’t have caused your problem.

linux-gv4m:~ # startkde
/usr/bin/startkde: line 117: .: krandrstartup: file not found

That’s why KDE cannot be started, yes.
You miss the file /usr/bin/krandrstartup.
Try to reinstall kscreen, that’s what contains it:

zypper in -f kscreen

Then it should work.

This happens if the old kdebase4-workspace (which used to contain krandrstartup upto 12.3) is updated after kscreen is installed. (shouldn’t happen normally, unless you installed kscreen manually).

This may also give a clue. In kdm login screen, i happened to choose metacity as a window manager . From that time, I neither have a window manager,nor kde login screen.May be kde auto llogging to an empty window manager ?

Could be.
Remove the file ~/.dmrc, that saves the last used session.
Or just press Ctrl+Alt+Backspace twice to kill the X session and return to the login screen.

That’s why KDE cannot be started, yes.
You miss the file /usr/bin/krandrstartup.
Try to reinstall kscreen, that’s what contains it:

zypper in -f kscreen

Then it should work.

This happens if the old kdebase4-workspace (which used to contain krandrstartup upto 12.3) is updated after kscreen is installed. (shouldn’t happen normally, unless you installed kscreen manually).

Could be.
Remove the file ~/.dmrc, that saves the last used session.
Or just press Ctrl+Alt+Backspace twice to kill the X session and return to the login screen.

Thank you very much. Both advises worked. :slight_smile: