element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Members
    Members
    • Benefits of Membership
    • Achievement Levels
    • Members Area
    • Personal Blogs
    • Feedback and Support
    • What's New on element14
  • Learn
    Learn
    • Learning Center
    • eBooks
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Dev Tools
    • Manufacturers
    • Raspberry Pi
    • RoadTests & Reviews
    • Avnet Boards Community
    • Product Groups
  • Store
    Store
    • Visit Your Store
    • Choose Another Store
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
Raspberry Pi
  • Products
  • More
Raspberry Pi
Blog Setting up an Xfce Desktop Environment on Pi
  • Blog
  • Forum
  • Documents
  • Events
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Raspberry Pi requires membership for participation - click to join
Blog Post Actions
  • Subscribe by email
  • More
  • Cancel
  • Share
  • Subscribe by email
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: texadactyl
  • Date Created: 25 Mar 2015 12:55 PM Date Created
  • Views 2244 views
  • Likes 4 likes
  • Comments 8 comments
Related
Recommended
  • pi
  • lightdm
  • raspberry_pi_2
  • raspberry_pi_space
  • xfce

Setting up an Xfce Desktop Environment on Pi

texadactyl
texadactyl
25 Mar 2015

image

 

This technote covers setting up the Xfce desktop environment and session manager on a Raspberry Pi.  Folks who use a Linux distribution that make use of Xfce will find the Raspbian Xfce quite familiar.  I find that the look and feel of the desktop and the application menu organization is almost identical to that of Xubuntu which I use at home on Mini-ITX builds.

 

The latest Raspbian image (2015-02-16) from http://www.raspberrypi.org/downloads/ includes Openbox and LXDE as desktop environment options on top of LightDM.  Xfce also uses LightDM so I was not surprised that Xfce installed so easily and was immediately available for use without any “tweaks”.
Note that one can also install the MATE desktop session manager that Linux Mint users are quite familiar with.  Maybe other desktop session managers too although the gating factor would be that they should interoperate with LightDM in order to avoid a lot of re-tooling.
Start with the following and go have a snack or walk the dog while its running:
sudo apt-get -y install xfce4 xfce4-screenshooter
This installs the desktop environment and session manager, the related applications, and a screen-shot application that is the best that I have ever used [(-:].
To try out Xfce once,
    • Logout.
    • At the login prompt, select “Xfce Session” in place of “Default Xsession”.
    • Login.
Note that the next time that you reboot/logout and come back, you will be back to whatever desktop session manager that you were using before.  To make use of Xfce from now on as the default, execute the following:
sudo update-alternatives --config x-session-manager
This will bring up a menu that should look like the following (or similar, depending on what you have been tinkering with):
   Selection    Path                      Priority   Status
------------------------------------------------------------
  0            /usr/bin/startlxde-pi      90        auto mode
  1            /usr/bin/lxsession         49        manual mode
  2            /usr/bin/openbox-session   40        manual mode
  3            /usr/bin/startlxde         50        manual mode
  4            /usr/bin/startlxde-pi      90        manual mode
  5            /usr/bin/startXfce4        50        manual mode
  6            /usr/bin/Xfce4-session     40        manual mode
Assuming your #6 looks like the above, select 6 to make Xfce the default session from now on.
Reboot.  That's it!  Feel free to comment or mail me if you have issues with installing or using Xfce.
  • Sign in to reply

Top Comments

  • texadactyl
    texadactyl over 7 years ago in reply to Former Member +2
    1. Enable auto-login to XFCE environment cd /etc/lightdm sudo your-favorite-editor lightdm.conf Ensure that the [SeatDefaults] section looks like this: [SeatDefaults] autologin-guest=false autologin-user…
  • texadactyl
    texadactyl over 7 years ago in reply to clem57 +1
    Hah! You said the "W" word, not me. (-: My concerns will be, as a former corporate victim: desktop security, performance, and reliability. I suspect that M$ has missed the SoC boat and/or they are trapped…
  • texadactyl
    texadactyl over 4 years ago in reply to mp2100 +1
    Thank you for the syntax corrections. It's hard getting around the 1GB RAM issue. But, I have found improved performance by using an external USB disk for boot as well as operations. I no longer have an…
  • texadactyl
    texadactyl over 4 years ago in reply to mp2100

    Thank you for the syntax corrections.

     

    It's hard getting around the 1GB RAM issue.  But, I have found improved performance by using an external USB disk for boot as well as operations.  I no longer have an MicroSD in use.

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • mp2100
    mp2100 over 4 years ago

    This blog post was very helpful, thank you.  Clear and useful (other sites goooogle found were not clear).  Oh, one correction, lower case letters matter of course, the sudo apt-get Xfce4 needs to be sudo apt-get xfce4.

     

    I loaded xfce4 no problem, onto my old RPi 1 model B, hoping for a speed increase using Midori.  Unfortunately, no such luck, it's still slow.  So it's back to Dillo browser.  Or I'll just use my shiny new RPi 3 model B+.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • texadactyl
    texadactyl over 7 years ago in reply to Former Member

    1. Enable auto-login to XFCE environment

     

    cd /etc/lightdm

    sudo your-favorite-editor lightdm.conf

     

    Ensure that the [SeatDefaults] section looks like this:

    [SeatDefaults]

    autologin-guest=false

    autologin-user=Your-user-login-ID

    autologin-user-timeout=0

    autologin-session=lightdm-autologin

     

    Restart after making those edits.  You should see the auto login.

     

    2. Getting rid of LXDE

     

    The central packages for LXDE seem to be lxde, lxde-common, and lxde-core.  LXDE is quite small and relies heavily on GTK and other infrastructures.  I have forgotten the LXDE-specific shared object and utility packages (E.g. what file manager it installs with); do your own research at LXDE.org | Lightweight X11 Desktop Environment or lubuntu | lightweight, fast, easier.

     

    Are you experienced?  If so or you are feeling brave, you can theoretically use the sudo apt-get remove function on those 3 packages followed by sudo apt-get autoremove (see man page for apt-get).  Mind the confirmation list before proceding as apt is not forgiving once you say proceed.

     

    Do you really want to remove those 3 LXDE central packages and any others that are dependent on them?  IMO, it is probably not worth the potential disruptions considering the space saved.  But, checking out the actual package list and sizes at one of the above 2 LXDE sites could be instructive.

     

    Your call.

     

     

    Good luck.

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • Former Member
    Former Member over 7 years ago

    This is very helpful, thank you!  Do you know how to completely get rid of LDXE and also to enable auto-login to XFCE environment so we don't have to put in the PW every time?

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • texadactyl
    texadactyl over 7 years ago in reply to clem57

    Hah!  You said the "W" word, not me.  (-:

     

    My concerns will be, as a former corporate victim: desktop security, performance, and reliability.  I suspect that M$ has missed the SoC boat and/or they are trapped in their own bloated & scary Windows history.  Admittedly, I have not yet read the 3rd party analyses of Windows 10.  So, I'll try to keep an open mind about Windows 10 and maybe take it out for a spin on a separate MicroSD (wearing the Pi Borg case, of course!).

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
>
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2023 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • Facebook
  • Twitter
  • linkedin
  • YouTube