This answer applies to versions of Ubuntu running Compiz.
This answer assumes Unity is being run through Compiz. If you don't have compiz installed (ex: on non-Unity versions of Ubuntu, such as the Gnome-based Ubuntu 18.04 and later) this answer doesn't apply to you.
You just need to turn the Unity plugin back on. The problem is this is a pain in the bottom because you've now got no graphical method to do this. So:
Try to open a terminal with Ctrl+Alt+T.
This may not work but you can try right clicking on the desktop and selecting "Open terminal here." Otherwise, you may need to change to a "hard" terminal by pressing
Ctrl+Alt+F1 and log in.
The first part tells the terminal which display you want it to load on (otherwise it won't have a clue).
If you switched to a TTY in step 1, switch back to the graphical server by pressing Ctrl+Alt+F7 (or Ctrl+Alt+F8 sometimes).
There there should be a CompizConfig Settings Manager waiting for you.
Find the Unity plugin. Enable it (detailed instructions just below). You will be asked "Ubuntu Unity Plugin requires the plugin OpenGL. Enable Ubuntu Unity Plugin / Enable OpenGL"
1) To enable the Unity Plugin: Click "Desktop" (left side) --> Ubuntu Unity Plugin. You can also type "unity plugin" into the "Filter" search box. Screenshot:
From here, click the checkbox for "Enable Ubuntu Unity Plugin":
2) To enable OpenGL: click "General" (left side) --> then check the box for "OpenGL", as shown below. You can also type "opengl" into the "Filter" search box to bring it up.
Everything should spring into life but if it doesn't, you might have to restart. You can do that by going back to the terminal and running sudo reboot.
It is a good idea to check your graphics driver is configured to use hardware acceleration and it is configured to use OpenGL. Try searching Ask Ubuntu and Ubuntu Forums for information specific to your GPUs and Ubuntu flavour. For hybrid graphics users see the last section "Hybrid Graphics" below.
The first part tells the terminal which display you want it to load on (otherwise it won't have a clue).
Press Ctrl+Alt+F7 (or Ctrl+Alt+F8 sometimes) to get back to the graphical display where there should be a CompizConfig Settings Manager screen sitting there.
Find the Unity plugin. Enable it.
Everything should spring into life but if it doesn't, you might have to restart. You can do that by going back to tty1 and running sudo reboot.
I would really prefer the stable PPA, but it does not seem to have packages for 13.04 yet. Update: these seem to be available as of Sep. 25. I would install this stable PPA - you can try but I have not tested it.
The Ubuntu-supplied Nvidia drivers were already installed and I simply installed from this PPA by adding it and doing a package update using update-manager.
UPDATE: As of Oct. 6, ppa:xorg-edgers/ppa seems to contain bumblebee as well. So if you install from this PPA, you might want to try skipping the addition of the Bumblebee PPA and installing it from here instead.
If you chose the stable PPA in step 1, install the Bumblebee stable PPA as follows:
sudo apt-add-repository ppa:bumblebee/stable
UPDATE: After adding the PPA(s), update your package lists:
sudo apt-get update
If you already had nvidia drivers installed from Ubuntu's standard repositories, simply upgrade to get the new version from the repository chosen in step 1:
The easiest way to do this is to press Ctrl+Alt+T to get a terminal and then issue:
rm -rf ~/.compiz-1 ~/.config/compiz-1
and your unity session will come back before your eyes..
This technique is better than re-launching ccsm, because you can get into OP's error condition without even accidentally de-selecting unity in ccsm; you can get it simply by accidentally pressing the "preferences" button in ccsm.
Install ccsm (CompizConfig Settings Manager) by running in a terminal: sudo apt-get install compizconfig-settings-manager compiz-fusion-plugins-extra.
Start ccsm, and select the category Desktop. Enable the Ubuntu Unity Plugin; if asked to resolve conflicts, select the MIDDLE button for all conflicts. Close ccsm when done.
I have an Asus U36SD using an "Optimus" (Intel + Nvidia GPUs) set-up. I had Ubuntu 12.04 working just fine, but upgrading to 12.10, this problem appeared and persisted in 13.04.
I have managed to fix it trough the following steps:
I would really prefer the stable PPA at https://edge.launchpad.net/~ubuntu-x-swat/+archive/x-updates, but it does not seem to have packages for 13.04 yet. Update: these seem to be available as of Sep. 25. I would install this stable PPA - you can try but I have not tested it.
The Ubuntu-supplied Nvidia drivers were already installed and I simply installed from this PPA by adding it and doing a package update using update-manager. UPDATE:
UPDATE: As of Oct. 6, ppa:xorg-edgers/ppa seems to contain bumblebee as well. So if you install from this PPA, you might want to try skipping the addition of the Bumblebee PPA and installing it from here instead.
If you chose the stable PPA in step 1, install the Bumblebee stable PPA as follows:
sudo apt-add-repository ppa:bumblebee/stable
UPDATE: After adding the PPA(s), update your package lists:
sudo apt-get update
If you already had nvidia drivers installed from Ubuntu's standard repositories, simply upgrade to get the new version from the repository chosen in step 1.:
You just need to turn the Unity plugin back on. The problem is this is a pain in the bottom because you've now got no graphical method to do this. So:
Try to open a terminal with Ctrl+Alt+T.
This may not work but you can try right clicking on the desktop and selecting "Open terminal here." Otherwise, you may need to change to a "hard" terminal by pressing Ctrl+Alt+F1 and log in.
Install
compizconfig-settings-manager
by runningThen run it with this:
The first part tells the terminal which display you want it to load on (otherwise it won't have a clue).
If you switched to a TTY in step 1, switch back to the graphical server by pressing Ctrl+Alt+F7 (or Ctrl+Alt+F8 sometimes).
There there should be a CompizConfig Settings Manager waiting for you.
Find the Unity plugin. Enable it (detailed instructions just below). You will be asked "Ubuntu Unity Plugin requires the plugin OpenGL. Enable Ubuntu Unity Plugin / Enable OpenGL"
Everything should spring into life but if it doesn't, you might have to restart. You can do that by going back to the terminal and running
sudo reboot
.A solution good for me (has solved the same problem):
in a terminal:
and then
In 13.04 and 14.04:
unity --replace
is deprecated. Instead, use the following:Reboot if it doesn't work right away.
For 12.10 and below:
Press Ctrl+Alt+T for a terminal and run
ccsm
, then re-enable your 'Unity' plugin.You also may then need to run a
unity --replace
.It is a good idea to check your graphics driver is configured to use hardware acceleration and it is configured to use OpenGL. Try searching Ask Ubuntu and Ubuntu Forums for information specific to your GPUs and Ubuntu flavour. For hybrid graphics users see the last section "Hybrid Graphics" below.
You might want to run the compizconfig-settings-manager package and make sure that the Unity plugin is checked (see What are some of the issues with CCSM and why would I want to avoid it?).
For 12.04 And Newer
Change to
tty1
by pressing Ctrl+Alt+F1 and log in.Install
compizconfig-settings-manager
by runningThen run it by doing this:
The first part tells the terminal which display you want it to load on (otherwise it won't have a clue).
Press Ctrl+Alt+F7 (or Ctrl+Alt+F8 sometimes) to get back to the graphical display where there should be a CompizConfig Settings Manager screen sitting there.
Find the Unity plugin. Enable it.
Everything should spring into life but if it doesn't, you might have to restart. You can do that by going back to
tty1
and runningsudo reboot
.If unity still does not load try:
Reboot if it doesn't work right away.
For 11.10 And Older
If you hope into a TTY (Ctrl+Alt+F1 through F6) and run:
It will reset Unity back on TTY 7 (Ctrl+Alt++F7).
You can also try just:
But that won't work if a windows manager is already running on display 0 (it will give you an error, just use
unity --replace
in that case).If Unity absolutely refuses to restart try this:
Install
gnome-panel
:Than run it on display 0:
You should then have Gnome 2 style panels on your desktop, which you can use to logout.
Hybrid Graphics
Some very useful information and further reading for hybrid graphics users can be found here.
Once GPUs are configured appropriately for 3D acceleration and OpenGL you can:
Install Nvidia drivers from https://edge.launchpad.net/~xorg-edgers/+archive/ppa:
or:
I would really prefer the stable PPA,
but it does not seem to have packages for 13.04 yet. Update: these seem to be available as of Sep. 25. I would install this stable PPA - you can try but I have not tested it.The Ubuntu-supplied Nvidia drivers were already installed and I simply installed from this PPA by adding it and doing a package update using
update-manager
.Install Bumblebee from https://launchpad.net/~bumblebee/+archive/stable
UPDATE: As of Oct. 6,
ppa:xorg-edgers/ppa
seems to contain bumblebee as well. So if you install from this PPA, you might want to try skipping the addition of the Bumblebee PPA and installing it from here instead.If you chose the stable PPA in step 1, install the Bumblebee stable PPA as follows:
UPDATE: After adding the PPA(s), update your package lists:
If you already had nvidia drivers installed from Ubuntu's standard repositories, simply upgrade to get the new version from the repository chosen in step 1:
Perform the following commands to 'repair' Unity (from brandon-bertelsen's answer to Unity doesn't load, no Launcher, no Dash appears):
The easiest way to do this is to press Ctrl+Alt+T to get a terminal and then issue:
and your unity session will come back before your eyes..
This technique is better than re-launching ccsm, because you can get into OP's error condition without even accidentally de-selecting unity in ccsm; you can get it simply by accidentally pressing the "preferences" button in ccsm.
I had this problem too. I solved it with deleting the content of the ~/.config/compiz-1/compizconfig file and relog.
I have had exactly the same issue.
If you have Compiz Config Settings Manager installed it may be that the Unity Desktop Plugin is disabled.
Log in to a Unity 2D desktop and check that it is enabled in CCSM like this,
Unity Shell will not load in the default desktop if the tickbox is not checked and you will get the session in your picture.
Developers are always fixing bugs, so an alternative is to wait, and to follow progress on bug fixing (subscribe to Unity development in Launchpad).
Press Ctrl+Alt+F2.
Log in.
Run
sudo shutdown -r now
in a terminal.At the login screen after your system restarts, choose Unity 2D (for now) by right-clicking the sprocket icon.
Wait for a fix for Unity 3D/Ubuntu 11.10 (e.g. a week).
Update your system to get the fix; in a terminal type
sudo apt-get update && sudo apt-get upgrade
.UPDATE: I was able to resolve this by using
ccsm
, from Unity 2D login.(This is adapted from this Ubuntu Forums post.)
At the login screen, select Unity 2D and login.
Install
ccsm
(CompizConfig Settings Manager) by running in a terminal:sudo apt-get install compizconfig-settings-manager compiz-fusion-plugins-extra
.Start
ccsm
, and select the category Desktop. Enable the Ubuntu Unity Plugin; if asked to resolve conflicts, select the MIDDLE button for all conflicts. Closeccsm
when done.Restart, select Unity (3D) and login.
I have an Asus U36SD using an "Optimus" (Intel + Nvidia GPUs) set-up. I had Ubuntu 12.04 working just fine, but upgrading to 12.10, this problem appeared and persisted in 13.04. I have managed to fix it trough the following steps:
Install Nvidia drivers from https://edge.launchpad.net/~xorg-edgers/+archive/ppa.
OR:
I would really prefer the stable PPA at https://edge.launchpad.net/~ubuntu-x-swat/+archive/x-updates,
but it does not seem to have packages for 13.04 yet. Update: these seem to be available as of Sep. 25. I would install this stable PPA - you can try but I have not tested it.The Ubuntu-supplied Nvidia drivers were already installed and I simply installed from this PPA by adding it and doing a package update using
update-manager
. UPDATE:(what I did) or:
(stable release for 13.04 too now - not tested by me).
Install Bumblebee from https://launchpad.net/~bumblebee/+archive/stable
UPDATE: As of Oct. 6, ppa:xorg-edgers/ppa seems to contain bumblebee as well. So if you install from this PPA, you might want to try skipping the addition of the Bumblebee PPA and installing it from here instead.
If you chose the stable PPA in step 1, install the Bumblebee stable PPA as follows:
UPDATE: After adding the PPA(s), update your package lists:
If you already had nvidia drivers installed from Ubuntu's standard repositories, simply upgrade to get the new version from the repository chosen in step 1.:
Install Bumblebee
Perform the following commands to 'repair' Unity (from brandon-bertelsen's answer to Unity doesn't load, no Launcher, no Dash appears):