Conky

Conky is a system monitor software for the X Window System (Wayland support is a work in progress). It is available for GNU/Linux and FreeBSD. It is free software released under the terms of the GPL license. Conky is able to monitor many system variables including CPU, memory, swap, disk space, temperature, top, upload, download, system messages, and much more. It is extremely configurable, however, the configuration can be a little hard to understand. Conky is a fork of torsmo.

Installation

Install the conky package. There are also alternative packages you can install from AUR with extra compile options enabled:

Some built in variables in conky require additional packages to be installed in order to be utilized, for example mpd for music. As for hard drive temperature, Since kernel 5.6 the drivetemp module will report SATA/SAS temperature through hwmon. See the Lm_sensors#S.M.A.R.T. drive temperature discussion. From conky point of view, drivetemp can be used as a replacement for the hddtemp package and variable by using its variable.

Additional utility:

    Configuration

    The configuration file can be located in one of the following paths (the first one found will be used):

    • /etc/conky/conky.conf

    If none of these files exist, conky will use the default built-in configuration, which you can print out with:

    $ conky --print-config

    Furthermore, you can create a default configuration file with the following command:

    $ mkdir -p ~/.config/conky && conky --print-config > ~/.config/conky/conky.conf

    If you prefer to have a configuration dotfile in home, you can create a file elsewhere and tell conky to use it using arguments.

    For example to tell conky to use a dotfile located in the user's home directory:

    $ conky --config=~/.conky.conf

    Additional example configuration files are available in the upstream wiki article.

    When editing your configuration file while conky is running, conky will update with the new changes every time you write to the file.

    See the SourceForge page for a complete reference for all Conky objects/variables; these are also listed in .

    Dual screen

    When using a dual screen configuration, you will need to play with a few options to place your conky window where you want it on the desktop.

    By adjusting , let us say you are running a 1680x1050 pixels resolution and you want the window on middle top of your left monitor, you will use:

    alignment = 'top_left',
    gap_x = 840,

    The option is self-explanatory, the is the distance, in pixels, from the left border of your screen.

    is an alternative useful option, the following will place the conky window at the top right of the second screen: 
    alignment = 'top_right',
    xinerama_head = 2,

    Configuration file syntax

    Since Conky 1.10 (Circa 2015Q2), configuration files are written with a Lua syntax, like so:

     conky.config = {
       -- Comments start with a double dash
       bool_value = true,
       string_value = 'foo',
       int_value = 42,
     }
     conky.text = [[
     $variable
     ${evaluated variable}
     ]]

    Pre 1.10 use the old syntax, which looks like this:

     bool_value yes
     string_value 'foo'
     int_value 42

    A Lua script is available to convert from the old syntax to the new Lua syntax at the GitHub repository. The script is also at .

    Fonts

    For displaying Unicode pictures and emoji with conky you will need a font that supports this and then configure conky to use the font with the Unicode you want to display. For example:

     ${font Symbola:size=48}☺${font}

    Symbolic fonts

    Symbolic fonts are also very commonly used in more decorated conky configurations, some of the more popular ones include;

    • - PizzaDude Bullet's font
    • - Erik flowers weather icon font with 222 glyphs

    Autostart

    There are several different ways to start Conky automatically, as outlined in Autostarting.

    Conky has a configuration setting which will tell it to fork to the background. This may be desirable for some autostarting setups.

    In conky.conf:

    conky.config = {
        background = true,
    }

    If you use a graphical desktop environment and wish to use a conky.desktop file for autostarting, use the following:

    The parameter delays conky's drawing for 5 seconds at startup to make sure that the desktop had time to load and is up.

    Troubleshooting

    These are known issues people have with conky and their solutions.

    Conky starts and does not display anything on the screen

    First check for syntax errors in your configuration file's text variable. Then double check that your user has permission to run every command inside your configuration file and that all needed packages are installed.

    Transparency

    Conky supports two different types of transparency. Pseudo-transparency and real transparency that requires a composite manager to be installed and running. If you enable real transparency and do not have a composite manager running your conky will not be alpha transparent with transparency enabled for fonts and images as well as the background.

    Pseudo-transparency

    Pseudo-transparency is enabled by default in conky. Pseudo-transparency works by copying the background image from the root window and using the relevant section as the background for conky. Some window managers set the background wallpaper to a level above the root window which can cause conky to have a grey background. To fix this issue you need to set it manually. An example with feh is:

    In :

     sleep 1 && feh --bg-center ~/background.png &

    Enable real transparency

    To enable real transparency, you must have a composite manager running and the following lines added to inside the conky.config array:

     conky.config = {
        own_window = true,
        own_window_transparent = true,
        own_window_argb_visual = true,
        own_window_type = 'desktop',
     }

    If window type "desktop" does not work try changing it to . If that does not work try the other options: , , or override instead.

    Note: Xfce requires enabled compositing, see .

    Semi-transparency

    To achieve semi-transparency in real transparency mode, the following setup must be used in the conky configuration file:

     conky.config = {
        own_window = true,
        own_window_transparent = false,
        own_window_argb_visual = true,
        own_window_argb_value = 90,
        own_window_type = 'desktop',
     }

    To reduce the transparency of the conky window, one can increase the value of towards 255.

    Do not minimize on Show Desktop

    Using Compiz: If the 'Show Desktop' button or key-binding minimizes Conky along with all other windows, start the Compiz configuration settings manager, go to "General Options" and uncheck the "Hide Skip Taskbar Windows" option.

    Using XFCE: If clicking the desktop hides Conky, add inside conky.conf.

    For the other Desktop environments/WM: Try editing conky.conf and adding/changing the following line:

    own_window_type = 'override',

    or

    own_window_type = 'desktop',

    Refer to man page for the exact differences. But the latter option enables you to snap windows to conkys border using resize key-binds in e.g. Openbox, which the first one does not.

    Integrate with GNOME Shell

    Some have experienced problems with conky showing up under GNOME.

    Add these lines to conky.conf:

    own_window = true,
    own_window_type = 'desktop',

    Prevent flickering

    Conky needs Double Buffer Extension (DBE) support from the X server to prevent flickering because it cannot update the window fast enough without it. It can be enabled with Xorg in with line in section. The file has been replaced (1.8.x patch upwards) by which contains the particular configuration files. DBE is loaded automatically as long as it is present within . The list of loaded modules can be checked with grep LoadModule /var/log/Xorg.0.log.

    To enable double buffering, add the option to conky.conf:

     conky.config = {
         double_buffer = true,
     }
    gollark: Apparently?
    gollark: No, you consume it too sometimes.
    gollark: Yes, I probably wouldn't trust any complicated computer stuff with much brain access, realistically.
    gollark: Why not connect your brain to <@160279332454006795>'s heavdrone™s?
    gollark: oh no.

    See also

    This article is issued from Archlinux. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.