Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add extend for monitoring Poudriere #512

Merged
merged 3 commits into from
Mar 26, 2024
Merged

Conversation

VVelox
Copy link
Collaborator

@VVelox VVelox commented Mar 26, 2024

No description provided.

@VVelox VVelox merged commit 80d6ac6 into librenms:master Mar 26, 2024
3 checks passed
@VVelox VVelox deleted the poudriere branch March 26, 2024 23:07
@dlangille
Copy link
Contributor

As a daily poudriere user, can you share screen shots please?

@VVelox
Copy link
Collaborator Author

VVelox commented Mar 26, 2024

@dlangille None yet. This is just the initial extend. Just starting work on the code to make use of it now. :)

Take a peak at the JSON produced by it. Anything you would like to see there?

Was thinking ccache, but thinking that may be better as it's own thing.

Need to find a good method for doing total resource usage as well as using ps only grabs the info at the moment.

@VVelox
Copy link
Collaborator Author

VVelox commented Mar 26, 2024

Been looking at process accounting and there does not appear to be way to get jail info from sa or lastcomm.

@dlangille
Copy link
Contributor

I was not familiar with the status commands until today so I'm starting from zero here.

@VVelox
Copy link
Collaborator Author

VVelox commented Mar 26, 2024

Yeah, just found them this week. Was a massive life saver as it saved my from having to create something messy to figure out the name combinations.

@dlangille
Copy link
Contributor

FYI, just tried it out.

A few notes:

  • poudriere being FreeBSD-specific, why not use /usr/local/bin/perl?
  • put the required deps in the header somewhere? pkg install p5-File-Slurp p5-JSON - there many be others, those are what I had to install
[23:59 pkg01 dvl /usr/local/etc/snmp] % ./poudriere             
Argument "?" isn't numeric in addition (+) at ./poudriere line 272.
.... many times repeated.

I'm using poudriere-3.4.1 on FreeBSD 14.0

@VVelox
Copy link
Collaborator Author

VVelox commented Mar 28, 2024

Same version of poudriere here. What does the output of poudriere -N status -f and and poudriere -N status -b look like?

@dlangille
Copy link
Contributor

[0:19 pkg01 dvl ~] % poudriere -N status -f 
SET        PORTS   JAIL     BUILD                STATUS      QUEUE BUILT FAIL SKIP IGNORE FETCH REMAIN TIME     URL
-          default 132amd64 2023-11-09_00h23m34s done           20    19    0    0      0     ?      1 00:06:59 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-default&build=2023-11-09_00h23m34s
-          default 140amd64 2024-02-02_22h23m20s interactive    80    80    0    0      0     0      0 17:36:28 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default&build=2024-02-02_22h23m20s
-          dvl     124amd64 2023-09-10_17h16m35s done            2     2    0    0      0     ?      0 00:05:05 https://services.unixathome.org/poudriere/build.html?mastername=124amd64-dvl&build=2023-09-10_17h16m35s
-          dvl     132amd64 2023-11-24_23h43m44s done            1     1    0    0      0     ?      0 00:01:03 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-dvl&build=2023-11-24_23h43m44s
-          dvl     140amd64 2024-03-15_12h25m44s done            9     9    0    0      0     0      0 00:03:25 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-dvl&build=2024-03-15_12h25m44s
deleteme   default 140amd64 2024-01-27_19h58m15s done         1138  1137    1    0      0     0      0 03:16:17 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-deleteme&build=2024-01-27_19h58m15s
deleteme2  default 140amd64 2024-01-28_17h49m40s done         1138  1137    1    0      0     0      0 01:56:09 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-deleteme2&build=2024-01-28_17h49m40s
deleteme3  default 140amd64 2024-02-01_17h09m25s done         1137  1135    1    1      0     0      0 02:26:04 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-deleteme3&build=2024-02-01_17h09m25s
gelt       default 132i386  2023-08-17_04h29m21s done           16    16    0    0      0     ?      0 00:02:12 https://services.unixathome.org/poudriere/build.html?mastername=132i386-default-gelt&build=2023-08-17_04h29m21s
pg13       default 132amd64 2023-12-18_04h23m29s done            0     0    0    0      0     ?      0 00:00:07 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-default-pg13&build=2023-12-18_04h23m29s
pg13       default 140amd64 2024-03-24_06h58m48s done          110   110    0    0      0     0      0 01:10:00 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-pg13&build=2024-03-24_06h58m48s
pg14       default 132amd64 2023-12-18_04h23m39s done            0     0    0    0      0     ?      0 00:00:08 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-default-pg14&build=2023-12-18_04h23m39s
pg14       default 140amd64 2024-03-24_08h08m53s done          111   111    0    0      0     0      0 01:11:23 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-pg14&build=2024-03-24_08h08m53s
pg16       default 132amd64 2023-12-18_04h23m50s done            0     0    0    0      0     ?      0 00:00:07 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-default-pg16&build=2023-12-18_04h23m50s
pg16       default 140amd64 2024-03-27_04h29m09s done            8     8    0    0      0     0      0 00:29:10 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-pg16&build=2024-03-27_04h29m09s
php81      default 140amd64 2024-01-12_06h12m18s done           19    19    0    0      0     0      0 00:10:04 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-php81&build=2024-01-12_06h12m18s
php82      default 140amd64 2024-03-24_10h34m02s done          457   457    0    0      0     0      0 01:53:15 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-php82&build=2024-03-24_10h34m02s
php83      default 140amd64 2024-03-24_12h27m22s done          455   455    0    0      0     0      0 01:54:01 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-php83&build=2024-03-24_12h27m22s
primary    default 132amd64 2023-12-18_04h18m10s done            4     4    0    0      0     ?      0 00:04:55 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-default-primary&build=2023-12-18_04h18m10s
primary    default 140amd64 2024-03-27_04h18m12s done            0     0    0    0      0     0      0 00:00:30 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-primary&build=2024-03-27_04h18m12s
primary    dvl     132amd64 2023-10-27_12h23m21s sigint        280     0    0    0      0     ?    280 00:00:06 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-dvl-primary&build=2023-10-27_12h23m21s
primary    dvl     140amd64 2024-01-02_14h40m18s done            2     1    0    0      0     ?      1 00:04:35 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-dvl-primary&build=2024-01-02_14h40m18s
snmp       default 140amd64 2023-12-28_15h02m57s done            1     1    0    0      0     ?      0 00:03:50 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-snmp&build=2023-12-28_15h02m57s
unifi      default 132amd64 2023-12-18_04h23m11s done            0     0    0    0      0     ?      0 00:00:07 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-default-unifi&build=2023-12-18_04h23m11s
unifi      default 140amd64 2024-03-27_04h18m47s done            0     0    0    0      0     0      0 00:00:11 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-unifi&build=2024-03-27_04h18m47s
webs02     default 132amd64 2023-08-14_04h28m52s done            0     0    0    0      0     ?      0 00:00:05 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-default-webs02&build=2023-08-14_04h28m52s
webs02php7 default 132amd64 2023-08-14_04h29m01s crashed         ?     0    0    0      0     ?      0 00:00:01 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-default-webs02php7&build=2023-08-14_04h29m01s
wikis      default 132amd64 2023-12-18_04h23m21s done            0     0    0    0      0     ?      0 00:00:05 https://services.unixathome.org/poudriere/build.html?mastername=132amd64-default-wikis&build=2023-12-18_04h23m21s
wikis      default 140amd64 2024-03-27_04h19m03s done           13    13    0    0      0     0      0 00:10:02 https://services.unixathome.org/poudriere/build.html?mastername=140amd64-default-wikis&build=2024-03-27_04h19m03s

@dlangille
Copy link
Contributor

[0:21 pkg01 dvl ~] % poudriere -N status -b
[0:22 pkg01 dvl ~] % 

@VVelox
Copy link
Collaborator Author

VVelox commented Mar 28, 2024

Derp. Should of asked for poudriere -N status -b -f. That said noticed I need to add -l to the it as well. Just working in getting package size totals.

@VVelox
Copy link
Collaborator Author

VVelox commented Mar 28, 2024

BTW thanks. <3

@dlangille
Copy link
Contributor

No worries, happy to help. I've got it added to my snmp config now. I'm not seeing it listed in apps yet.

@VVelox
Copy link
Collaborator Author

VVelox commented Mar 28, 2024

W00t! Okay. I see the problem. Looks like it for some reason fetch for multiple ones there is ? instead of a number.

That said made the fix in the next version being worked on.

Yeah, that all has not been started yet and will likely be a bit before it gets merged. That unforutnately takes awhile. Got a few other things such as improved NFS support that is also waiting.

@dlangille
Copy link
Contributor

Let me know if there's anything you want me to test. Sometimes I have a bit of capacity during business hours as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants