Subject: Conky: successful autostart setup
From: Alex Kemp
Date: Saturday, 26 December 2015 00:00:00 +0000
To: All

Background:

I chose the beginning of the holiday season to update my home computer to Debian Jessie from Wheezy. It caused the normal amount of pain. There were 2 main problems after startup:

  1. No sound (was fine in Wheezy).
  2. No autostart Conky (appeared fine after manual startup; this issue also occurred with previous Wheezy setup, using the SLiM LM).

Resolution:

This is purely a setup issue.

In brief:

Use the -d option for conky to daemonise (fork to background) + -px option to wait x secs before init.

In exquisite detail:

Current desktop setup:

Twin Conky on Desktop (conkyrc.weather at left; conkyrc at right) (photo: Cumberland Falls)

Conky file locations:

xfce setup:

Session and Startup dialog (XFCE4)

In XFCE4, the scripts and/or binaries that the system will autostart at startup need to be pre-existing. The setup dialog to maintain them is accessed through the menu: (menu):Settings → Session and Startup → Application Autostart → (Add or Edit)

The command that worked for me was: ~/.conky/conkystart.sh &

At pressing 'OK', the xfce4 system creates a desktop file at: ~/.config/autostart/

Extra:
XFCE4 requires compositing ON ((menu):Settings → Windows Manager Tweaks), else the Conky cannot be transparent, or the LM background shows underneath.

In fact, whilst retaining compositing: ON I switched to the following setup for transparency: own_window_type desktop # own_window_transparent yes own_window_argb_visual yes own_window_argb_value 0 own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager own_window_hints below

Conky Startup Files:

Conky 1.9.0-6 options:- $ /usr/bin/conky --help Usage: /usr/bin/conky [OPTION]... Conky is a system monitor that renders text on desktop or to own transparent window. Command line options will override configurations defined in config file.    -v, --version             version    -q, --quiet               quiet mode    -D, --debug               increase debugging output, ie. -DD for more debugging    -c, --config=FILE         config file to load    -C, --print-config        print the builtin default config to stdout                              e.g. 'conky -C > ~/.conkyrc' will create a new default config    -d, --daemonize           daemonize, fork to background    -h, --help                help    -a, --alignment=ALIGNMENT text alignment on screen, {top,bottom,middle}_{left,right,middle}    -f, --font=FONT           font to use    -X, --display=DISPLAY     X11 display to use    -o, --own-window          create own window to draw    -b, --double-buffer       double buffer (prevents flickering)    -w, --window-id=WIN_ID    window id to draw    -x X                      x position    -y Y                      y position    -t, --text=TEXT           text to render, remember single quotes, like -t '$uptime'    -u, --interval=SECS       update interval    -i COUNT                  number of times to update Conky (and quit)    -p, --pause=SECS          pause for SECS seconds at startup before doing anything

/usr/bin/conkystart.sh contents:- #!/bin/bash # /usr/bin/conkystart.sh # universal file to startup conky # using config file in user home dir # 2015-12-26 added -p10 + -d to pause for 10 secs + daemonise conky -p10 -dc ~/.conky/conkyrc

~/.conky/conkystart.sh contents:- #!/bin/bash # 2015-12-26 switched from 'sleep 10 &&' to conky options /usr/bin/conkystart.sh & # -p10 == pause for 10 secs # -d daemon mode (fork to background) # -c locate the config file /usr/bin/conky -p10 -dc ~/.conky/conkyrc.weather

~/.config/autostart/conky.desktop contents:- [Desktop Entry] Categories=Application;System;Settings Comment=Autostart Conky System Stats Desktop Display Encoding=UTF-8 Exec=~/.conky/conkystart.sh & Hidden=false Name=Conky Terminal=false Type=Application Version=1.0 Icon=conky.png

---------
Alex Kemp