dnschneid / crouton

Chromium OS Universal Chroot Environment
https://goo.gl/fd3zc?si=1
BSD 3-Clause "New" or "Revised" License
8.56k stars 1.24k forks source link

xfce doesn't work properly without second instance #239

Closed stanchiang closed 11 years ago

stanchiang commented 11 years ago

using Samsung Chromebook ARM Problem: crouton started out fine, but for reasons i don't understand the GUI became buggy. My hackish solution: start another instance exactly like the first one i.e. "sudo startxfce4". with this, the second instance works as expected. i then close the first one and go about my business.

Please help, what can I do to solve the root issue and have it work the first time?

/////////////////////////////////////////// first instance issues: --the cursor turns from the default arrow into a black "x" whenever it's hovering over applications or the terminal. --i can no longer resize windows from the edges or resize/close windows from the upper-right corner --there is only one available workspace, it normally has 4 --clicking/right-clicking on files and buttons with the cursor still works

/////////////////////////////////////////// first instance in chrome OS shell from start to finish Welcome to crosh, type 'help' for a list of commands. crosh> shell chronos@localhost / $ sudo startxfce4 /usr/bin/startxfce4: Starting X server

[dix] Could not init font path element /usr/share/fonts/X11/misc, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/cyrillic, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/100dpi/:unscaled, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/75dpi/:unscaled, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/Type1, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/100dpi, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/75dpi, removing from list! [dix] Could not init font path element /var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType, removing from list! /usr/bin/xinit: XFree86_VT property unexpectedly has 0 items instead of 1 Agent pid 23032 xfdesktop[23063]: starting up

(xfce4-settings-helper:23066): xfce4-settings-helper-WARNING **: Failed to get the _NET_NUMBER_OF_DESKTOPS property. xfce4-settings-helper: Another instance is already running. Leaving...

(xfce4-session:23047): Wnck-CRITICAL **: wnck_workspace_activate: assertion `WNCK_IS_WORKSPACE (space)' failed

(polkit-gnome-authentication-agent-1:23073): GLib-CRITICAL **: g_variant_new_string: assertion `string != NULL' failed

(polkit-gnome-authentication-agent-1:23073): polkit-gnome-1-WARNING **: Failed to register client: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.gnome.SessionManager was not provided by any .service files

\ (zeitgeist-datahub:23071): WARNING **: recent-manager-provider.vala:133: Desktop file for "file:///usr/bin/chromium-browser" was not found, exec: exo-helper-1, mime_type: application/octet-stream xfce4-panel: No window manager registered on screen 0. To start the panel without this check, run with --disable-wm-check.

(xfce4-session:23047): Wnck-CRITICAL **: wnck_workspace_get_number: assertion `WNCK_IS_WORKSPACE (space)' failed running 'ssh-agent -s -k' unset SSH_AUTH_SOCK; unset SSH_AGENT_PID; echo Agent pid 23032 killed; /usr/bin/xinit: connection to X server lost

waiting for X server to shut down xscreensaver: 23:59:28: SIGHUP received: restarting... xscreensaver: 23:59:28: running as stan/stan (1000/1000)

xscreensaver: 23:59:28: Can't open display: :2 xscreensaver: 23:59:28: running as stan/stan (1000/1000)

xscreensaver: 23:59:28: Errors at startup are usually authorization problems. But you're not logging in as root (good!) so something else must be wrong. Did you read the manual and the FAQ?

          http://www.jwz.org/xscreensaver/faq.html
          http://www.jwz.org/xscreensaver/man.html

Unmounting /usr/local/chroots/precise... chronos@localhost / $

//////////////////////////////////////////////// second instance

crosh> shell chronos@localhost / $ sudo startxfce4 /usr/bin/startxfce4: Starting X server

[dix] Could not init font path element /usr/share/fonts/X11/misc, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/cyrillic, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/100dpi/:unscaled, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/75dpi/:unscaled, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/Type1, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/100dpi, removing from list! [dix] Could not init font path element /usr/share/fonts/X11/75dpi, removing from list! [dix] Could not init font path element /var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType, removing from list! /usr/bin/xinit: XFree86_VT property unexpectedly has 0 items instead of 1 Agent pid 24136 xfdesktop[24156]: starting up xfce4-settings-helper: Another instance is already running. Leaving...

\ (zeitgeist-datahub:24167): WARNING **: recent-manager-provider.vala:133: Desktop file for "file:///usr/bin/chromium-browser" was not found, exec: exo-helper-1, mime_type: application/octet-stream

(polkit-gnome-authentication-agent-1:24169): GLib-CRITICAL **: g_variant_new_string: assertion `string != NULL' failed

(polkit-gnome-authentication-agent-1:24169): polkit-gnome-1-WARNING **: Failed to register client: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.gnome.SessionManager was not provided by any .service files running 'ssh-agent -s -k' unset SSH_AUTH_SOCK; unset SSH_AGENT_PID; echo Agent pid 24136 killed; /usr/bin/xinit: connection to X server lost

waiting for X server to shut down xscreensaver: 23:58:56: SIGHUP received: restarting... xscreensaver: 23:58:56: running as stan/stan (1000/1000)

xscreensaver: 23:58:56: Can't open display: :3 xscreensaver: 23:58:56: running as stan/stan (1000/1000)

xscreensaver: 23:58:56: Errors at startup are usually authorization problems. But you're not logging in as root (good!) so something else must be wrong. Did you read the manual and the FAQ?

          http://www.jwz.org/xscreensaver/faq.html
          http://www.jwz.org/xscreensaver/man.html

Not unmounting /usr/local/chroots/precise as another instance is using it. chronos@localhost / $

stanchiang commented 11 years ago

now the first two instances have been corrupted. It only works properly when i do sudo startxfce4 a 3rd time

tedm commented 11 years ago

if you can get to the above prompt, try sudo unmount-chroot -help, I think there is a -p switch to show what processes it can't shut down.

Also, xscreensaver above indicates there may be other x sessions running, so you may have x display files in use or locked, check /tmp and . files. Do you have any apps that are auto-saving to say ~/Downloads? Did you try removing xscreensaver temporarily (killing the pid)?

dnschneid commented 11 years ago

I don't think that's at all relevant to his issue.

It just sounds like the window manager isn't running. Try running xfwm4 --replace from a terminal window inside the chroot.

stanchiang commented 11 years ago

great call David! running that line instantly fixed the issue. Do you know what might have caused the window manager to stop running? and how I can avoid it in the future?

dnschneid commented 11 years ago

Try going to Settings -> Session and Startup -> Session tab and make sure xfwm4 has a restart style of "immediately".

You can avoid the issue by not checking "save session" when you go to log out.

stanchiang commented 11 years ago

got it. thanks again.