You are not logged in.

#126 2011-07-04 03:30:19

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: Paconky: displays repo and AUR pkg info in conky

Just a heads-up that I've renamed python-aur to python3-aur, so if you're running paconky.py, make sure you install the new package.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#127 2011-09-04 06:40:37

creative2innovative
Member
Registered: 2011-08-16
Posts: 61

Re: Paconky: displays repo and AUR pkg info in conky

Xyne wrote:

Just a heads-up that I've renamed python-aur to python3-aur, so if you're running paconky.py, make sure you install the new package.

Xyne, it would be better if you can post all the necessary steps to run it. I have also downloaded from

http://xyne.archlinux.ca/old_projects/paconky/    build it and installed it in my system, now what should i do to make it work ??

Offline

#128 2011-09-06 18:19:17

creative2innovative
Member
Registered: 2011-08-16
Posts: 61

Re: Paconky: displays repo and AUR pkg info in conky

Waiting for someone to reply...!!

Offline

#129 2011-09-06 19:05:47

fsckd
Forum Fellow
Registered: 2009-06-15
Posts: 4,173

Re: Paconky: displays repo and AUR pkg info in conky

Wait a little more. Patience is a virtue. Meanwhile read: https://wiki.archlinux.org/index.php/Fo … te#Bumping


aur S & M :: forum rules :: Community Ethos
Resources for Women, POC, LGBT*, and allies

Offline

#130 2011-09-06 19:59:47

creative2innovative
Member
Registered: 2011-08-16
Posts: 61

Re: Paconky: displays repo and AUR pkg info in conky

fsckd wrote:

Wait a little more. Patience is a virtue. Meanwhile read: https://wiki.archlinux.org/index.php/Fo … te#Bumping


ok from now on i will take care and thanks for the link.

Offline

#131 2011-09-06 23:46:14

stealthy
Member
Registered: 2011-05-02
Posts: 67

Re: Paconky: displays repo and AUR pkg info in conky

I had trouble getting this to run properly. I think that paconky.py takes slightly too long to display the stats before conky updates again. (I have it set to 1 sec).

So what I did was:

cp /path/to/paconky.py /usr/bin/paconky
chmod +x /usr/bin/paconky

Open up roots crontab (crontab -e)

#Paconky
* */1 * * * /usr/bin/paconky /tpm/paconky > /home/stealth/Programming/paconky.stats

Then add it to /etc/conky/conky.conf

${execp cat /home/stealth/Programming/paconky.stats}

Last edited by stealthy (2011-09-06 23:47:55)


clipodder-git A small simple cron-friendly podcast downloader, with support for arbitrary user defined media types (pdf, html, etc...)

Offline

#132 2011-09-07 03:40:48

creative2innovative
Member
Registered: 2011-08-16
Posts: 61

Re: Paconky: displays repo and AUR pkg info in conky

stealthy wrote:

I had trouble getting this to run properly. I think that paconky.py takes slightly too long to display the stats before conky updates again. (I have it set to 1 sec).

So what I did was:

cp /path/to/paconky.py /usr/bin/paconky
chmod +x /usr/bin/paconky

Open up roots crontab (crontab -e)

#Paconky
* */1 * * * /usr/bin/paconky /tpm/paconky > /home/stealth/Programming/paconky.stats

Then add it to /etc/conky/conky.conf

${execp cat /home/stealth/Programming/paconky.stats}

Thanks for the reply. Friend can you post the config files of it. so it get's more clear for me.I used perl, bash and python script so now i am totally confused about what to do. It would be really nice if you could post the config files and how to use it.

Offline

#133 2011-09-07 09:15:57

stealthy
Member
Registered: 2011-05-02
Posts: 67

Re: Paconky: displays repo and AUR pkg info in conky

creative2innovative, I'm not sure what you mean. I'm using the python 3 script from, http://xyne.archlinux.ca/scripts/conky/

The file needs to be moved to /usr/bin/, otherwise python's sys.argv picks up ">" (write output to file)
It also needs to be made executable (chmod +x)

#Example
cp /path/to/paconky.py /usr/bin/paconky
chmod +x /usr/bin/paconky

Next you need to go in as root (sudo bash)
Then add the following to crontab

#Paconky 
* */1 * * * /usr/bin/paconky/[some_random_cache_path] > /home/[your_username]/.paconky.stats

Then add this line to /etc/conky/conky.conf

${execp cat /home/[your_username]/.paconky.stats}

Here is my /etc/conky/conky.conf, although it is mostly irrelevant.

alignment top_left
background yes
border_width 1
cpu_avg_samples 2
default_color white
default_outline_color black
default_shade_color black
draw_borders no
draw_graph_borders yes
draw_outline no
draw_shades no
use_xft yes
xftfont DejaVu Sans Mono:size=9
gap_x 10
gap_y 80
minimum_size 5 5
net_avg_samples 2
no_buffers yes
out_to_console no
out_to_stderr no
extra_newline no
own_window yes
own_window_class Conky
#own_window_type desktop
stippled_borders 0
update_interval 1.0
uppercase no
use_spacer none
show_graph_scale no
show_graph_range no
double_buffer yes
own_window_argb_visual yes
own_window_hints undecorated,below,skip_taskbar,sticky
own_window_transparent yes


TEXT
#${scroll 16 $nodename - $sysname $kernel on $machine | }
$hr
Uptime:$color $uptime
Frequency (in MHz):$color $freq
Frequency (in GHz):$color $freq_g
RAM Usage:$color $mem/$memmax - $memperc% ${membar 4}
Swap Usage:$color $swap/$swapmax - $swapperc% ${swapbar 4}
CPU Usage:$color $cpu% ${cpubar 4}
Processes:$color $processes  ${color black}Running:$color $running_processes
$hr
File systems:
 / $color${fs_used /}/${fs_size /} ${fs_bar 6 /}
Networking:
Up:${upspeed eth0} ${color black} - Down:$color ${downspeed eth0}
$hr
[paconky]
${execp cat /home/stealth/Programming/paconky.stats}
#${voffset 900}
$hr
[mlopt status] 
${exec cat /etc/pacman.d/conky.stats}
$hr
[server status]
${exec cat /home/stealth/server_raid_status}
$hr
[new torrents]
${exec cat /home/stealth/torrent_status}

Last edited by stealthy (2011-09-07 09:18:59)


clipodder-git A small simple cron-friendly podcast downloader, with support for arbitrary user defined media types (pdf, html, etc...)

Offline

#134 2011-09-08 08:12:20

creative2innovative
Member
Registered: 2011-08-16
Posts: 61

Re: Paconky: displays repo and AUR pkg info in conky

stealthy wrote:

creative2innovative, I'm not sure what you mean. I'm using the python 3 script from, http://xyne.archlinux.ca/scripts/conky/

The file needs to be moved to /usr/bin/, otherwise python's sys.argv picks up ">" (write output to file)
It also needs to be made executable (chmod +x)

#Example
cp /path/to/paconky.py /usr/bin/paconky
chmod +x /usr/bin/paconky

Next you need to go in as root (sudo bash)
Then add the following to crontab

#Paconky 
* */1 * * * /usr/bin/paconky/[some_random_cache_path] > /home/[your_username]/.paconky.stats

Then add this line to /etc/conky/conky.conf

${execp cat /home/[your_username]/.paconky.stats}

Here is my /etc/conky/conky.conf, although it is mostly irrelevant.

alignment top_left
background yes
border_width 1
cpu_avg_samples 2
default_color white
default_outline_color black
default_shade_color black
draw_borders no
draw_graph_borders yes
draw_outline no
draw_shades no
use_xft yes
xftfont DejaVu Sans Mono:size=9
gap_x 10
gap_y 80
minimum_size 5 5
net_avg_samples 2
no_buffers yes
out_to_console no
out_to_stderr no
extra_newline no
own_window yes
own_window_class Conky
#own_window_type desktop
stippled_borders 0
update_interval 1.0
uppercase no
use_spacer none
show_graph_scale no
show_graph_range no
double_buffer yes
own_window_argb_visual yes
own_window_hints undecorated,below,skip_taskbar,sticky
own_window_transparent yes


TEXT
#${scroll 16 $nodename - $sysname $kernel on $machine | }
$hr
Uptime:$color $uptime
Frequency (in MHz):$color $freq
Frequency (in GHz):$color $freq_g
RAM Usage:$color $mem/$memmax - $memperc% ${membar 4}
Swap Usage:$color $swap/$swapmax - $swapperc% ${swapbar 4}
CPU Usage:$color $cpu% ${cpubar 4}
Processes:$color $processes  ${color black}Running:$color $running_processes
$hr
File systems:
 / $color${fs_used /}/${fs_size /} ${fs_bar 6 /}
Networking:
Up:${upspeed eth0} ${color black} - Down:$color ${downspeed eth0}
$hr
[paconky]
${execp cat /home/stealth/Programming/paconky.stats}
#${voffset 900}
$hr
[mlopt status] 
${exec cat /etc/pacman.d/conky.stats}
$hr
[server status]
${exec cat /home/stealth/server_raid_status}
$hr
[new torrents]
${exec cat /home/stealth/torrent_status}


thank for your guidance...!! smile

Offline

#135 2011-09-09 11:56:05

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: Paconky: displays repo and AUR pkg info in conky

sorry, been busy...


@creative2innovative
Use the paconky.py script. The old paconky is deprecated, which is why it's in "old projects" on my site. The script uses the pyalpm bindings and is much more efficient and versatile than the original.

I'll edit the paconky.py script page to make the setup clearer as soon as I get some time to organize the local files.


stealthy wrote:

I had trouble getting this to run properly. I think that paconky.py takes slightly too long to display the stats before conky updates again. (I have it set to 1 sec).

I've explained why you shouldn't update it that often several times in this thread, but let me explain again.

The script checks the mirrors for new databases. Running it every second means that it's querying the server every second. That is a complete waste of CPU cycles on your computer, and a waste of both your bandwidth and the server's. In short, don't do that.

Use conky's "execpi" command and use an interval of no less than 3600 (1 hour). The sync databases are only updated once every hour at most, and much less frequently on average.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#136 2011-09-09 20:27:04

stealthy
Member
Registered: 2011-05-02
Posts: 67

Re: Paconky: displays repo and AUR pkg info in conky

Xyne, that's pretty much exactly what I have done. Cron updates the script every hour, then writes the output to a file. This way conky can just cat that file.

Last edited by stealthy (2011-09-09 20:27:18)


clipodder-git A small simple cron-friendly podcast downloader, with support for arbitrary user defined media types (pdf, html, etc...)

Offline

#137 2011-09-09 21:07:43

Zom
Member
From: Sweden
Registered: 2007-10-27
Posts: 430

Re: Paconky: displays repo and AUR pkg info in conky

stealthy wrote:

Xyne, that's pretty much exactly what I have done. Cron updates the script every hour, then writes the output to a file. This way conky can just cat that file.

cat:ing the file every time conky updates is still a big waste of CPU. execpi would still be the better option here.

Offline

#138 2011-09-10 14:27:59

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: Paconky: displays repo and AUR pkg info in conky

Zom wrote:
stealthy wrote:

Xyne, that's pretty much exactly what I have done. Cron updates the script every hour, then writes the output to a file. This way conky can just cat that file.

cat:ing the file every time conky updates is still a big waste of CPU. execpi would still be the better option here.

It's a big waste of disk IO too.

Keep it simple and use execpi... that's what it's there for. wink

Last edited by Xyne (2011-09-10 14:28:13)


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#139 2011-09-11 01:54:23

stealthy
Member
Registered: 2011-05-02
Posts: 67

Re: Paconky: displays repo and AUR pkg info in conky

Xyne wrote:
Zom wrote:
stealthy wrote:

Xyne, that's pretty much exactly what I have done. Cron updates the script every hour, then writes the output to a file. This way conky can just cat that file.

cat:ing the file every time conky updates is still a big waste of CPU. execpi would still be the better option here.

It's a big waste of disk IO too.

Keep it simple and use execpi... that's what it's there for. wink

Cat'ing the output file is not a big "waste" of disk I/O, its very minimal. Everytime you cat something in /var/log completely cancels out the unused disk I/O you would of had.

I am keeping it simple, I want to update all my conky values without having to lower the update interval.


clipodder-git A small simple cron-friendly podcast downloader, with support for arbitrary user defined media types (pdf, html, etc...)

Offline

#140 2011-09-11 10:25:59

Zom
Member
From: Sweden
Registered: 2007-10-27
Posts: 430

Re: Paconky: displays repo and AUR pkg info in conky

stealthy wrote:

Cat'ing the output file is not a big "waste" of disk I/O, its very minimal. Everytime you cat something in /var/log completely cancels out the unused disk I/O you would of had.

I am keeping it simple, I want to update all my conky values without having to lower the update interval.

No, you're not "keeping it simple". You don't have to touch the update interval, execi acts separately from that. That's the whole deal behind execi and execpi (except it can't update more often than conkys update interval, but yeah).

Do an experiment yourself, use two conkies, one with exec and one with execi set to cat every 30 seconds or so. The one doing an exec every time conky updates will use a lot more of the CPU than the one who uses execi. Hell, even the manual points out that exec is wasteful:

       exec command
              Executes  a  shell command and displays the output in conky. warning: this takes a lot more resources than other variables.
              I'd recommend coding wanted behaviour in C and posting a patch.

execi/execpi doesn't solve the problem, but it can act somewhat as a workaround.

The only difference would be that you won't see available updates in conky up to 30 seconds after the cron script has ran. Which shouldn't be that much of a deal.

Offline

#141 2011-09-11 11:29:01

stealthy
Member
Registered: 2011-05-02
Posts: 67

Re: Paconky: displays repo and AUR pkg info in conky

Ok your right, I'll eat my words.

I'm not trying to kiss your a** or anything but here is a script that I wrote a while back, you might find it interesting, http://pastie.org/2517769


clipodder-git A small simple cron-friendly podcast downloader, with support for arbitrary user defined media types (pdf, html, etc...)

Offline

#142 2011-10-25 19:30:50

forkboy
Member
From: Blackpool, England
Registered: 2005-09-03
Posts: 74

Re: Paconky: displays repo and AUR pkg info in conky

I find this script segfaults conky on upgrading to the latest version in extra - 1.8.2git20111024-1

Offline

#143 2011-10-26 10:34:05

slamhound
Member
Registered: 2011-07-26
Posts: 44

Re: Paconky: displays repo and AUR pkg info in conky

I think the ${voffset 1} is causing that. Removing that from the footer line allowed the script to run in conky for me (with the newest version: 1.8.2git20111026-1).

Offline

#144 2011-10-26 17:03:51

forkboy
Member
From: Blackpool, England
Registered: 2005-09-03
Posts: 74

Re: Paconky: displays repo and AUR pkg info in conky

Still segfaults for me sad

Offline

#145 2011-10-26 17:52:57

slamhound
Member
Registered: 2011-07-26
Posts: 44

Re: Paconky: displays repo and AUR pkg info in conky

Ah, yeah; I guess I was wrong about that. I just tried upgrading conky on a second computer. Got the segfault, tried removing the voffset and it still segfaulted. So it did work on my other computer after one segfault, but I guess I'm not now sure why it worked. I'll check that one again when I get home to see whether it is still working.

Offline

#146 2011-10-26 18:15:33

forkboy
Member
From: Blackpool, England
Registered: 2005-09-03
Posts: 74

Re: Paconky: displays repo and AUR pkg info in conky

I'd already didn't have voffset in mine, tried xyne's script as it is on the website without any modifications and same result

(OT I can't understand why the devs have started using a git snapshot instead of stable releases...)

Offline

#147 2011-10-27 15:16:40

slamhound
Member
Registered: 2011-07-26
Posts: 44

Re: Paconky: displays repo and AUR pkg info in conky

Well, I tried one other thing that is currently working. I noticed in some of the conky bug reports (bugs that are supposed to be fixed), people sometimes had problems with execpi and objects as the first word in the output that is to be printed. So I adjusted the script to make sure that ${color} was not the first thing in the output of the script. Either putting a character (e.g., ".") before ${color} in the header or removing the first ${color} so the first line started with [ stopped conky from segfaulting. I don't use different colors, so this isn't a problem for me. So it's working for now; I'll see whether that continues to work.

EDIT: Well, worked all day on one computer, but tried making the change on the other and now it segfaults there. Don't know why the same change on the same script sometimes leads to this problem and sometimes it doesn't.

Last edited by slamhound (2011-10-27 20:02:45)

Offline

#148 2011-11-01 20:21:09

amsri
Member
Registered: 2011-06-17
Posts: 48

Re: Paconky: displays repo and AUR pkg info in conky

Is there any solution to the segmentation fault problem with the latest conky git.

Offline

#149 2011-11-04 13:32:41

forkboy
Member
From: Blackpool, England
Registered: 2005-09-03
Posts: 74

Re: Paconky: displays repo and AUR pkg info in conky

I've had to downgrade to conky-1.8.1-3 and put conky in IgnorePkg in pacman.conf.  Thing that annoys me now is paconky is always showing conky as an available upgrade.

Offline

#150 2011-11-07 21:52:28

forkboy
Member
From: Blackpool, England
Registered: 2005-09-03
Posts: 74

Re: Paconky: displays repo and AUR pkg info in conky

paconky works again with the latest conky in the repos - 1.8.2git20111107-1 yey!

Offline

Board footer

Powered by FluxBB