Murda Posted March 7, 2006 Report Share Posted March 7, 2006 (edited) Hi. I read posts about this thread on this forum, I just want to take them a bit further. System Updates Startup-Script [solved], How could I do this? Auto update 1. I want to configure my computer to check for updates daily (that is explained in those threads above, consider this one solved) 2. I want to get mail with other msec security warnings daily (it would be better if i get them in the same mail as those, not in a new one) with all packages that were updated, and if some server could not be contacted, I can run update manually or if the server has been dropped out permanently, I can pick a new one from Easy-Urpmi 3. I want to set urpmi not to update packages which contain text like "kernel", "kernel-source", "irssi" etc. because I want to update them manually if there's any need for them I were thinking that the script would look like this: urpmi.update -a urpmi --auto-select --auto --skip kernel kernel-source irssi Is it right? And what about that mail? A log file would be another option. PS. This is all about learning, just want to learn a bit more of these things. edit: [solved] Thanks. -Murda Edited March 9, 2006 by Murda Quote Link to comment Share on other sites More sharing options...
ianw1974 Posted March 7, 2006 Report Share Posted March 7, 2006 My script just reads: urpmi.update -a urpmi --update --auto-select --auto and works perfectly fine for me. Set in /etc/cron.daily. Once script has been created, don't forget to: chmod +x scriptfilename Of course, incorporate the skip for things you don't want to update. kernel-source is the only thing to update, kernel will not. Quote Link to comment Share on other sites More sharing options...
devries Posted March 7, 2006 Report Share Posted March 7, 2006 2. it´s saver not to send security reports over the internet (these are not encrypted in anyway). Better use a local mail folder. So in te MCC instead of your email adress put your username and in your mail program (for example kmail) create a local mail acount (so not pop3 but local). 3. In /etc/config/urpmi (or something like that, can´t check the correct path right now) there is a blacklist where you can add packages that won´t be updated. Quote Link to comment Share on other sites More sharing options...
Murda Posted March 7, 2006 Author Report Share Posted March 7, 2006 2. it´s saver not to send security reports over the internet (these are not encrypted in anyway). Better use a local mail folder. So in te MCC instead of your email adress put your username and in your mail program (for example kmail) create a local mail acount (so not pop3 but local). Actually, my msec sends those reports to a local mailbox. I have postfix up and running. I've configured that in MCC to send them to "murda", not "murda@somewhere.net". I'm sorry that I didn't mention this before. But the question still remains, how can I put those reports that urpmi gives to my mailbox? Thanks, Murda. Quote Link to comment Share on other sites More sharing options...
ianw1974 Posted March 7, 2006 Report Share Posted March 7, 2006 Normally, you need to update /etc/aliases so that root: is pointing to murda. Then run /usr/bin/newaliases. Then it will end up in your mailbox. Quote Link to comment Share on other sites More sharing options...
Murda Posted March 7, 2006 Author Report Share Posted March 7, 2006 Normally, you need to update /etc/aliases so that root: is pointing to murda. Then run /usr/bin/newaliases. Then it will end up in your mailbox. But how do i make that urpmi installation output to go to that mailbox? root is already pointing to a mailbox named murda. Is there a local folder somewhere where I could dump log files and they appear as mail? I just found out that i don't need any information about installed packages. Msec runs a Diff check every night and reports those packages that have been modified, installed or deleted. The only thing now that would be nice is getting those error messages to a mailbox. Or is msec doing that too? At least i've never seen a mail like that (got some errors though when updating manually, but never seen a mail notifying me about that). I've been looking for this all around MCC but can't find it anywhere. Thanks. -Murda Quote Link to comment Share on other sites More sharing options...
ianw1974 Posted March 7, 2006 Report Share Posted March 7, 2006 As far as I know, when /etc/cron.daily runs it's job, the output gets sent to the root mailbox, which is then redirected to murda. If it's not, check your /etc/crontab to make sure it's emailing to the correct place. Quote Link to comment Share on other sites More sharing options...
devries Posted March 7, 2006 Report Share Posted March 7, 2006 I don´t think I understand what mail you´re talking about. You want the diff and secuity mail send not to your local mail folder but to an external mail box? Then just put in a normal email adress instead of your username. Or forward the mail in the local mail box to an external mail adress. Quote Link to comment Share on other sites More sharing options...
Murda Posted March 7, 2006 Author Report Share Posted March 7, 2006 As far as I know, when /etc/cron.daily runs it's job, the output gets sent to the root mailbox, which is then redirected to murda. If it's not, check your /etc/crontab to make sure it's emailing to the correct place. Ok, I'll do that. I tell you how it worked out in a few days. Quote Link to comment Share on other sites More sharing options...
Murda Posted March 8, 2006 Author Report Share Posted March 8, 2006 Ok, i have that update script in /etc/cron.daily/update.cron. It has -rwxr-xr-x like everything else there. Yesterday i used urpmi --auto-select to see if there's anything that needs updating. There was packages like tar and unzip. I didn't update them. I just put the auto update script to cron. Today I used it again. It says "everything has been installed" (translation from finnish), but the report e-mail didn't tell me anything about it. Maybe tomorrow.. Quote Link to comment Share on other sites More sharing options...
Murda Posted March 9, 2006 Author Report Share Posted March 9, 2006 (edited) Today I used it again. It says "everything has been installed" (translation from finnish), but the report e-mail didn't tell me anything about it. Maybe tomorrow.. Ok, today it gave me a Diff report to my mailbox. Not what I was looking for but it'll do. Consider this one solved. edit: some spelling mistakes. -Murda Edited March 9, 2006 by Murda Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.