How to properly configure xstartup file for TightVNC with Ubuntu VPS GNOME environment

前端 未结 3 2041
隐瞒了意图╮
隐瞒了意图╮ 2021-02-07 15:50

I\'d like to access my Ubuntu 16.10 VPS (Contabo) with using a GNOME environment with VNC, however I am still facing some issues that I couldn\'t solve so far. To install and co

3条回答
  •  温柔的废话
    2021-02-07 16:27

    Your vnc log file tells you about problem. You need to install few packages:
    sudo apt-get install metacity gnome-panel

    UPDATE 1:

    You need only x-window-manager or metacity. Both provides window manager and you need only one. From screenshot I see only two problems - grey screen and missing indicators.

    To fix missing indicators install one more package:
    sudo apt-get install indicator-applet-complete

    To fix grey screen you need --force-desktop commandline option. And if you don't want default nautilus window you can add --no-default-window:
    nautilus --force-desktop & or nautilus --force-desktop --no-default-window

    Also GNOME Flashback (Metacity) session in Ubuntu 16.10 use unity-settings-daemon not gnome-settings-daemon. Don't forget to install it if you decide to change that.

    To get better working desktop you also need to exports:

    export XDG_CURRENT_DESKTOP="GNOME-Flashback:GNOME"
    export XDG_MENU_PREFIX="gnome-flashback-"
    

    If you decided to use unity-settings-daemon then XDG_CURRENT_DESKTOP should be GNOME-Flashback:Unity.

    In both cases you also need gnome-flashback. Install it and make sure it also started. Depending on settings daemon you might need to adjust / change GSettings. Defaults are configurated for unity-settings-daemon.

    UPDATE 2:

    I would probably let gnome-session to start session:

    #!/bin/sh
    
    xrdb $HOME/.Xresources
    xsetroot -solid grey
    
    export XKL_XMODMAP_DISABLE=1
    export XDG_CURRENT_DESKTOP="GNOME-Flashback:Unity"
    export XDG_MENU_PREFIX="gnome-flashback-"
    
    gnome-session --session=gnome-flashback-metacity --disable-acceleration-check &
    

    And to install required packages just do sudo apt-get install gnome-session-flashback

    UPDATE 3:

    Looks like nautilus does not show desktop icons and background, because desktop icons are disabled.

    You can enable it with gsettings set org.gnome.desktop.background show-desktop-icons true or by installing ubuntu-settings.

提交回复
热议问题