Possible Duplicate:
What process created this X11 window?

I need to kill a process that spawned a window which seems to have no PID associated with it. At least that is what xdotool says:

~$ xdotool getwindowpid 79691780
window 79691780 has no pid associated with it.

wmctrl -lp prints 0x04c00004 0 0 N/A Window name

xprop _NET_WM_PID says _NET_WM_PID: not found.

The solutions in What process created this X11 window? don't work. I'm out of ideas, is there really now way of telling which process owns this window?

  • related question on SO: How to convert X11 window id to pid?
    – jw013
    Commented Aug 29, 2012 at 18:34
  • 1
    Next time, before you call possible duplicate, read the question. I'm sure you will find it a shocking surprise, but I am, in fact, capable of reading. I even consider myself quite proficient at using the search field! Of course I have seen both of these questions, and much more. Neither the answers on SOFU nor the various internet sites provided me with an answer.
    – JohnEye
    Commented Aug 29, 2012 at 19:05
  • If you looked at those questions and found their answers wanting, you should state that. Otherwise I have no reason to assume that you have seen those questions. If you had you would know there is no foolproof way to solve this problem in general.
    – jw013
    Commented Aug 29, 2012 at 19:12
  • 1
    The solutions from the other answers were tried and I have posted their results in the question, but you are right, I should have been more explicit. The fact that the other questions had no foolproof answer does not mean that there isn't any. Maybe some hardcore linux guru knows the answer and just doesn't visit this site.
    – JohnEye
    Commented Aug 30, 2012 at 6:51

1 Answer 1


That window may come from a client on a different machine, or from a client on this machine but which is connecting to the X server via TCP. Why don't you xkill it?

You may also want to try its parent windows run

xwininfo -children -id 0x04c00004

to figure it out. And then you can check if the parent window has a pid.

ps -fp "$(
  xprop -id "$(
    xwininfo -children -id 0x04c00004 |
      sed -n 's/.*Parent window id: \([^ ]*\).*/\1/p'
  )" _NET_WM_PID | sed 's/.* //'
  • Root window id: 0x107 (the root window) (has no name), Parent window id: 0x1414050 (has no name). Not very helpful. xkill might work, but I want to be sure the application aborts, which is something xkill does not guarantee. The application was started locally and there is no obvious reason why it should choose to connect to the X server via TCP.
    – JohnEye
    Commented Aug 29, 2012 at 15:54
  • So, does 0x1414050 have a pid? If not, what about it's parent? See xwininfo -root -tree to see the whole tree. Commented Aug 29, 2012 at 16:02
  • Could you please rewrite the script in parts so that I could do the steps manually? It gives a following error: ERROR: Process ID list syntax error.
    – JohnEye
    Commented Aug 29, 2012 at 16:18
  • Never mind, the window just disappeared (probably) when I ran xprop -id 0x1414050
    – JohnEye
    Commented Aug 29, 2012 at 16:30

Not the answer you're looking for? Browse other questions tagged .