You're welcome. I wish I could remember where I got that, because it's not something I came up with.
Enjoy it.
Printable View
And here I thought zenity was just for dialog boxes, thanks for the info.
Attachment 252618
Makes me wonder what else is buried in Ubuntu command line :confused:
For goodness sakes!
So much info in this thread my brain feels like it's being twisted or something. Has anybody found a particularly useful bunch of pages amongst the 2276 that are in this thread? To help narrow things down a little? I have conky installed and i'm at the what next stage.
See Conky PitStop in my signature. Check out Conky at Deviant Art and there is always the Conky Archive thread at #!.
Other than that what do you mean by: at the next stage. :lolflag::lolflag:
zenity is installed by 'default' on Ubuntu! thanks grumblebum2
wrt: "gems"
What I don't know could fill a warehouse,
What I do know could fill an outhouse.
So I got my system updated to 2.6.32-58 recently, and I was hoping that would fix the problem. I didn't know what else got updated along the way but here's the log (command: gedit /var/log/apt/history.log )
Don't see a vnstat update or anything but...oh well it's working!Code:Start-Date: 2014-04-29 17:06:43
Install: linux-image-2.6.32-58-generic (2.6.32-58.120), linux-headers-2.6.32-58-generic (2.6.32-58.120), linux-headers-2.6.32-58 (2.6.32-58.120)
Upgrade: libcupsppdc1 (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11), libcupsimage2 (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11), libcupscgi1 (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11), libcupsdriver1 (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11), linux-generic (2.6.32.57.64, 2.6.32.58.65), cups-client (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11), cups-common (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11), libcups2 (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11), linux-headers-generic (2.6.32.57.64, 2.6.32.58.65), dpkg (1.15.5.6ubuntu4.6, 1.15.5.6ubuntu4.7), linux-image-generic (2.6.32.57.64, 2.6.32.58.65), cups (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11), libcups2-dev (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11), cups-bsd (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11), linux-libc-dev (2.6.32-57.119, 2.6.32-58.120), libcupsmime1 (1.4.3-1ubuntu1.10, 1.4.3-1ubuntu1.11)
End-Date: 2014-04-29 17:07:45
Earlier post:
Tried using that and it didn't work. *shrugs*
As usual, code + screenshot:
http://i.imgur.com/gfx1jgqm.pngCode:# Create own window instead of using desktop (required in nautilus)
own_window yes
own_window_hints undecorated,below,skip_taskbar
background yes
# Use double buffering (reduces flicker, may not work for everyone)
double_buffer yes
# fiddle with window
use_spacer right
use_xft yes
# window size controls
minimum_size 170 570 ## width, height
maximum_width 170 ## width
# Update interval in seconds
update_interval 3.0
# Minimum size of text area
minimum_size 160
# Draw shades?
draw_shades yes
# Text stuff
draw_outline no # amplifies text if yes
draw_borders no
uppercase no # set to yes if you want all text to be in uppercase
# Stippled borders?
stippled_borders 8
# border margins
border_margin 4
# border width
border_width 1
# Default colors and also border colors, grey90 == #e5e5e5
default_color white
default_shade_color black
default_outline_color white
own_window_colour brown
own_window_transparent yes
# Text alignment, other possible values are commented
#alignment top_left
alignment top_right
#alignment bottom_left
#alignment bottom_right
# Gap between borders of screen and text
gap_x 5
gap_y 5
# stuff after 'TEXT' will be formatted on screen
override_utf8_locale yes
xftfont Terminus:size=8
xftalpha 0.8
TEXT
${color #FF6666} SYSTEM PROFILE
${color slate grey}System: ${color }Th${color FF0000}i${color }nkPad X200 P8400
${color slate grey}Computer Name: ${color }$nodename
${color slate grey}Kernel: ${color }$kernel
${color slate grey}Distro: ${color }${pre_exec lsb_release -d | cut -f 2 } x64
${color slate grey}Uptime: ${color }$uptime
${if_existing /proc/acpi/battery/BAT0/state}${color slate grey}Battery: ${color }${battery_percent}% ${color green}\
${if_match ${battery_percent} < 70}${color yellow}${endif}\
${if_match ${battery_percent} < 50}${color orange}${endif}\
${if_match ${battery_percent} < 30}${color red}${endif}\
${battery_bar}${color}${endif}
${color #FF6666} SYSTEM SUMMARY
${color slate grey}CPU: ${color } $freq MHz at ${acpitemp}°C
${color slate grey}Core A: ${color }${cpu cpu1}% ${alignr}${cpubar cpu1 9,80}
${color slate grey}Core B: ${color }${cpu cpu2}% ${alignr}${cpubar cpu2 9,80}
${color slate grey}Load: ${alignr}${font Monospace:size=8}${color #6699FF}1.00 = 50% ${color #DDDD66}2.00 = 100%${font}
${color }${color #66FFFF}${loadavg 1} ${color #66FFFF}${loadavg 2} ${color #66FFFF}${loadavg 3} ${color #66FFFF}1${color slate grey} / ${color #66FFFF}5${color slate grey} / ${color #66FFFF}15${color slate grey}min
${color slate grey}Swap: ${color } ${alignr}$swap ${color slate grey}of ${color } $swapmax
${color slate grey}Memory:${color } ${alignr}$mem ${color slate grey}of ${color } $memmax
${color slate grey}Usage: ${alignr}${color }$memperc% ${membar 9,80}
${color slate grey}Storage: ${alignr}${color }${fs_used /} ${color slate grey}of ${color }${fs_size /}
${color slate grey}Free: ${alignr}${color }${fs_free /} ${fs_bar 9,80 /}
${color #FF6666} ACTIVE PROCESSES
${color slate grey}Processes: ${color }$processes ${alignr}${color slate grey}Running: ${color }$running_processes
${color #3366FF}Process Name: ${alignr}% CPU
${color #ddaa00}${top name 1} ${alignr}${top_mem cpu 1}
${color slate grey}${top name 2} ${alignr}${top cpu 2}
${color slate grey}${top name 3} ${alignr}${top cpu 3}
${color slate grey}${top name 4} ${alignr}${top cpu 4}
${color slate grey}${top name 5} ${alignr}${top cpu 5}
${color #FF6666} NETWORK NUMBERS
${color #FF0000}${if_empty ${exec cat /proc/net/arp | grep eth0}}${if_empty ${exec cat /proc/net/arp | grep wlan0}}No network connection
${else}${color slate grey}Internal IP: ${alignr}${color }${addr wlan0}
${color slate grey}External IP: ${color }${alignr}${execi 1800 wget -O - http://ip.tupeux.com | tail}
${color slate grey}Router: ${alignr}${color }${wireless_essid wlan0}
${color slate grey}Signal: ${color }${wireless_link_qual_perc wlan0}% ${alignr}${color }${wireless_bitrate wlan0}
${color slate grey}Down: ${color }${downspeed wlan0} ${color slate grey}${alignr}Up: ${color }${upspeed wlan0}
${color slate grey}Session Total Down: ${alignr}${color }${totaldown wlan0}
${color slate grey}Session Total Up: ${alignr}${color }${totalup wlan0}
${color slate grey}Connections: ${color #3366FF}In: ${color }${tcp_portmon 1 32767 count} ${alignr}${color #3366FF}Out: ${color }${tcp_portmon 32768 61000 count}${endif}
${else}${color slate grey}LAN IP: ${alignr}${color }${addr eth0}
${color slate grey}External IP: ${color } ${alignr}${execi 1800 curl ifconfig.me}
${color slate grey}Down: ${color }${downspeed eth0} ${alignr}${color slate grey}Up: ${color }${upspeed eth0}
${color slate grey}Session Total Down: ${alignr}${color }${totaldown eth0}
${color slate grey}Session Total Up: ${alignr}${color }${totalup eth0}
${color slate grey}Connections: ${color #3366FF}In: ${color }${tcp_portmon 1 32767 count} ${alignr}${color #3366FF}Out: ${color }${tcp_portmon 32768 61000 count}${endif}
${color #ddaa00}Month Total Down: ${alignr}${color }${execi 300 vnstat -i wlan0+eth0 -m | grep "`date +"%b '%y"`" | awk '{print $3 $4}'}
${color #ddaa00}Month Total Up: ${alignr}${color }${execi 300 vnstat -i wlan0+eth0 -m | grep "`date +"%b '%y"`" | awk '{print $6 $7}'}
Yea, there is nothing in the log showing vnstat being updated. And you showed that the two databases are there.
The code you show above is correct unless you edited /etc/vnstat.conf
I copied mine to ~/.vnstatrc and changed the date format to get rid of the " ' " in the month line the same as Habitual suggested.Code:FILES
/var/lib/vnstat/
This directory contains all databases the program uses. Files are named according to the moni‐
tored interfaces.
/etc/vnstat.conf
Config file that will be used unless $HOME/.vnstatrc exists. See vnstat.conf(5) for more infor‐
mation.
If you can't get them joined in one output, which is really strange, why not show both separately at least until you get it worked out.Code:{snip}
# date output formats for -d, -m, -t and -w
# see 'man date' for control codes
#DayFormat "%x"
DayFormat "%d/%m/%y"
MonthFormat "%b %y"
#TopFormat "%x"
TopFormat "%d/%m/%y"
{snip}
Just a thought, not a proper fix but at least it should show something.Code:WLAN
${color #ddaa00}Month Total Down: ${alignr}${color }${execi 300 vnstat -i wlan0 -m | grep "`date +"%b '%y"`" | awk '{print $3 $4}'}
${color #ddaa00}Month Total Up: ${alignr}${color }${execi 300 vnstat -i wlan0 -m | grep "`date +"%b '%y"`" | awk '{print $6 $7}'}
ETH
${color #ddaa00}Month Total Down: ${alignr}${color }${execi 300 vnstat -i eth0 -m | grep "`date +"%b '%y"`" | awk '{print $3 $4}'}
${color #ddaa00}Month Total Up: ${alignr}${color }${execi 300 vnstat -i eth0 -m | grep "`date +"%b '%y"`" | awk '{print $6 $7}'}
If You use "$execp" anyway, which check string for Conky command in it to run it, You might use one "$execp" command instead of 6, and one AWK instead of 3 AWK + 3 GREP + 3 CUT:
will show all drives with device name containing "/dev/".Code:${execp df -H |awk '$1 ~ "/dev/" {++i; sub(/\/dev\//,"",$1); hd[i]=$1"${alignr}"$3" / "$2" ["$5"]";} END{for (x=1; x<=i; x++) print hd[x];}'}
No need for "$if_existing" command also.
If Conky will show all disks in one line (don't have Conky on this machine to test), add "\n" at the end of each string
Code:hd[i]=$1"${alignr}"$3" / "$2" ["$5"]\n"
@ Sector11
The regular line vnstat -i eth0+wlan0 -m works now. Perhaps I failed to communicate that in the post. =)