Installed Packages Notification - pfSense+
-
Re: Installed Packages Notification
Referencing my original post above, I installed a fresh copy of pfSense 2.6.0 CE and then updated it to pfSense+ version 22.05.
@Gertjan Would you happen to know if the pkg_check.php file will work with pfSense+ 22.05? I don't have any packages that need updated so I can't test it. Any ideas? Thanks.
-
@newuser2pfsense said in Installed Packages Notification - pfSense+:
Would you happen to know if the pkg_check.php file will work with pfSense+ 22.05?
Good question.
I'm running these :[22.05-RELEASE][admin@pfSense.myplace.net]/root: pkg update Updating pfSense-core repository catalogue... pfSense-core repository is up to date. Updating pfSense repository catalogue... pfSense repository is up to date. All repositories are up to date. [22.05-RELEASE][admin@pfSense.myplace.net]/root: pkg upgrade Updating pfSense-core repository catalogue... pfSense-core repository is up to date. Updating pfSense repository catalogue... pfSense repository is up to date. All repositories are up to date. Checking for upgrades (0 candidates): 100% Processing candidates (0 candidates): 100% Checking integrity... done (0 conflicting) Your packages are up to date.
manually ones in a while ( as I never trust a system that has been automatized, I have my check-lists ).
The PHP script does basically the same thing as the native FreeBSD OS command "pkg". It (should) tests also pfSense packages.
There was a new pfSense acme.sh version ( ? ) a week or so ago ( can't remember ), I didn't receive any email notifications. This was related to the fact I did not have set up a notification email (yeah, stupid me).
-
@gertjan I just like the idea of getting an email when one of the installed packages has an update so I don't have to login to pfSense once a week to check. I don't want it to install the update, just report the update via email. I'll install manually. That's why I was wondering if the pkg_check.php file would work in pfSense+ 22.05.
-
@newuser2pfsense said in Installed Packages Notification - pfSense+:
That's why I was wondering if the pkg_check.php file would work in pfSense+ 22.05.
#metoo.
As soon as one of these :
or some other FreeBSD package gets updated by Netgate, I will post back here.
edit : I'm pretty sure it works because :
You will have to install the pfSense Cron package ( a must have ) and add this line :
so the script present in /root/pkg_check.php ( this file must be made eXecutable) will be executed by the php interpreter at 07h01 and 13h01 every day.
Btw : the code used are being borrowed from pfSense itself, the update/upgrade scripts (remember : open source !)
-
As I have NUT installed : https://forum.netgate.com/topic/102959/nut-package/902?_=1658479094798 I should reveuive a mail as soon as the update is available.
I'll post here when that happens. -
Finally, it happened :
I got a mail :
13:01:20 The following updates are available and can be installed using System > Package Manager: System_Patches: 2.0_6 ==> 2.0_7 Some packages are part of the base system and will not show up in Package Manager. If any such updates are listed below, run `pkg upgrade` from the shell to install them: pfSense-pkg-System_Patches: 2.0_6 -> 2.0_7 [pfSense]
The GUI showed :
edit : Hummmm, deception : it only offers one patch : Redmine #13424
this is an issue I had build my own patch rule for weeks ago (which is now 'official') - I've ditched it, and activated the 'official', build in patch.
-
@Gertjan Thank you for the post. I didn't even see the System_Patches package in the Package Manager. I've now installed it and it shows version 2.0_7. I can see the same Fix for CRL expiration lifetime default and maximum values (Redmine #13424) entry. I applied the patch and restarted pfSense as well.
Here is the output of the patch when I applied it:
Here is the output to the Patch does not apply cleanly:
Here is the output to the Patch can revert cleanly:
I'm not sure what to do at this point. Revert or not to Revert?
As well, I'm wondering if this System_Patches package will notify the Admin of patches when they become available?
-
@newuser2pfsense said in Installed Packages Notification - pfSense+:
As well, I'm wondering if this System_Patches package will notify the Admin of patches when they become available?
When the pfSense package "System_Patches package" includes a new patch, its version number will change. It will go from 7 to 8. You will see this change in the GUI Dashboard, if you have the installed pfSense packages listed on the dashboard.
But "System_Patches package will not send notifications.
That why I mentioned this cron task above :
and the script file pkg_check.php has to be placed in the /root/ folder.
Now the cron task will execute twice a day, and send a notification when it finds something.
I've got the file from here Auto update check, checks for updates to base system + packages and sends email alerts and modified it so it takes also in account pfSense PLus (22.05) specific updates like the "firmware".
@luckman212 : you want a copy for your git ? -
@Gertjan At least the pkg_check.php file is reporting an update which is what I was wondering most of all.
I'll post a different question concerning the Revert or Not to Revert.
-
Don't revert. You already have that patch installed and it's recommended for 22.05.
Steve
-
@stephenw10 Thanks for the reply Steve. I appreciate your response. I won't revert.
-
@newuser2pfsense said in Installed Packages Notification - pfSense+:
I'll post a different question concerning the Revert or Not to Revert.
That is, when I upgraded to .7 version, the build in patch was marked as already installed.
Has I build my own several weeks ago to apply exacly the same thing.
I preferred to remove mine ( revert it ) and apply the 'official' one, and then delete my home made patch. -
If it shows as applied and can be reverted then whatever was previously applied must be identical to the included patch there.
-
I can confirm that it is working well under pfSense+ (Plus) version 22.05 here. One System patch applied. (red arrow)
Before I was also doing it manually over console with
(13) update from console>>> Creating automatic rollback boot environment... done. >>> Updating repositories metadata... Updating pfSense-core repository catalogue... Fetching meta.conf: . done Fetching packagesite.pkg: . done Processing entries: .. done pfSense-core repository update completed. 14 packages processed. Updating pfSense repository catalogue... Fetching meta.conf: . done Fetching packagesite.pkg: .......... done Processing entries: .......... done pfSense repository update completed. 542 packages processed. All repositories are up to date. Your packages are up to date Netgate pfSense Plus - Netgate Device ID: "John Doe"
-
@dobby_ Thanks for verifying. I haven't had any notifications yet as all of my installed packages are still up to date. I'm just waiting for a package to update to see if I get the notification.
-
I haven't had any notifications yet as all of my installed
packages are still up to date.The only notification was the small sign in the packages list.
pfSense webinterface > System > Advanced > Notifications
could be a nice place to test something out. Or? Realtime
on telegram or eMail report daily or weekly would also
there available. -
@dobby_ said in Installed Packages Notification - pfSense+:
could be a nice place to test something out. Or? Realtime
on telegram or eMail report daily or weekly would also
there available. -