Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
PostPosted: Fri Jan 03, 2014 11:07 am 
Offline
Senior Member

Joined: Sun May 23, 2010 1:57 pm
Posts: 315
Website: http://www.jebblue.net
For anyone who wonders why we aren't notified when a new kernel comes out so we can make sure our systems are running properly and as secure as possible, there's a new Linode kernel out:

https://www.linode.com/kernels/


Top
   
PostPosted: Fri Jan 03, 2014 11:09 am 
Offline
Senior Member

Joined: Mon Jul 05, 2010 5:13 pm
Posts: 392
FWIW, there's an RSS feed: https://www.linode.com/kernels/rss.xml


Top
   
PostPosted: Fri Jan 03, 2014 11:43 am 
Offline
Senior Member

Joined: Sun May 23, 2010 1:57 pm
Posts: 315
Website: http://www.jebblue.net
I don't do RSS, what do you recommend? Can I set it up to send me an email notification? I do email just never did RSS so do I use a special reader or process the XML visually with my mind or what do you recommend so I can get a notification when a new kernel comes out so my Linode isn't vulnerable? Is there a mailing list? As least then I can get an email?

edit:
How about the Kernels API, when I'm on my Linode I can run uname -r and get back 3.12.6-x86-linode55. Ok cool, so can I hit the API and ask for "latest kernel version" and get back 3.12.6-x86-linode55 and know Ok there's not a new one or if it's different then it must be new, I can have my Linode email me.

Here's the kernel API: https://www.linode.com/api/utility/avail.kernels

I don't want "kernels" plural, I just want to pass in "I'm on xyz, do you have anything newer?" or at least, what's the latest standard 32 bit kernel?


Top
   
PostPosted: Fri Jan 03, 2014 12:39 pm 
Offline
Senior Member

Joined: Sun Mar 07, 2010 7:47 pm
Posts: 1970
Website: http://www.rwky.net
Location: Earth
Some email clients support RSS as well, Thunderbird does they just appear like mini web pages and you get unread notifications when new items appear.

There's also various services out there that can email you when feeds are updated (have a google).

Or you can have a quick and dirty bash script, something like this

Code:
curl -s https://www.linode.com/kernels/rss.xml | grep "Latest.*$(uname -r)" > /dev/null
if [ $? -eq 1 ]
then touch /var/run/reboot-required
fi


That checks if your kernel is the latest and creates /var/run/reboot-required which on ubuntu will trigger a reboot required warning when you log in, you could make it a cron job if you like.

_________________
Paid support
How to ask for help
1. Give details of your problem
2. Post any errors
3. Post relevant logs.
4. Don't hide details i.e. your domain, it just makes things harder
5. Be polite or you'll be eaten by a grue


Top
   
PostPosted: Fri Jan 03, 2014 12:47 pm 
Offline
Senior Member

Joined: Wed Jan 21, 2009 7:13 pm
Posts: 126
Location: Portugal
jebblue wrote:
I don't do RSS, what do you recommend? Can I set it up to send me an email notification?


This can help you ..

http://www.allthingsrss.com/rss2email/

Just install on you linode and wait for the email!


Top
   
PostPosted: Fri Jan 03, 2014 1:20 pm 
Offline
Senior Member

Joined: Sun May 23, 2010 1:57 pm
Posts: 315
Website: http://www.jebblue.net
obs wrote:
Some email clients support RSS as well, Thunderbird does they just appear like mini web pages and you get unread notifications when new items appear.

There's also various services out there that can email you when feeds are updated (have a google).

Or you can have a quick and dirty bash script, something like this

Code:
curl -s https://www.linode.com/kernels/rss.xml | grep "Latest.*$(uname -r)" > /dev/null
if [ $? -eq 1 ]
then touch /var/run/reboot-required
fi


That checks if your kernel is the latest and creates /var/run/reboot-required which on ubuntu will trigger a reboot required warning when you log in, you could make it a cron job if you like.


I thought about doing something like that obs thanks. My understanding with Google dropping support for RSS is that it will be going away so I imagine at some point this will start failing.

I suppose the same approach would work with the api.kernels call too though.

edit:

I changed your curl line to use my key (not abc123) and verified that echo $? does indeed get set correctly.

Code:
curl -s "https://api.linode.com/?api_key=abc123&api_action=avail.kernels&isXen=1" | grep "Latest.*$(uname -r)"


I added an email notification line after your line to set the reboot stated (cool idea I wasn't aware how that happened).

Code:
mail -s "New Linode Kernel is available - Reboot Required" me@mydomain.foo


So the script for anyone who wants to use obs' script with the API instead of the RSS feed URL:

Code:
#!/bin/bash

curl -s "https://api.linode.com/?api_key=abc123&api_action=avail.kernels&isXen=1" | grep "Latest.*$(uname -r)" > /dev/null
if [ $? -eq 1 ]; then
  #echo "test"
  touch /var/run/reboot-required
  mail -s "New Linode Kernel is available - Reboot Required" me@mydomain.foo
fi


Thanks obs Happy New Year :)


Top
   
PostPosted: Fri Jan 03, 2014 10:08 pm 
Offline
Senior Member

Joined: Fri Jan 09, 2009 5:32 pm
Posts: 634
jebblue wrote:
My understanding with Google dropping support for RSS is that it will be going away so I imagine at some point this will start failing.


Google didn't invent RSS, does not control RSS, nothing of the sort. Google dropped Google Reader, which was a very popular RSS client. There are a number of others (eg I migrated to feedly)


Top
   
PostPosted: Sat Jan 04, 2014 8:12 am 
Offline
Senior Member

Joined: Fri Jul 03, 2009 2:31 am
Posts: 54
ICQ: 897607
Exactly. Google still provides RSS feeds here and there (e.g. new apps in the Google App Marketplace) and you can find RSS readers in Chrome app store (both as apps and as extensions). RSS may be slowly fading away but it's not because of Google.

The loss of Google Reader caused a lot of heartburn (including me) but feedly.com has replaced it without a hiccup. I use the "Press" app on Android devices as my client with feedly as the backend.

Linode has other useful RSS feeds as well, such as Lassie events from your linodes.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group