LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Debian (https://www.linuxquestions.org/questions/debian-26/)
-   -   Should I automatically update my server? (https://www.linuxquestions.org/questions/debian-26/should-i-automatically-update-my-server-4175512312/)

maples 07-25-2014 10:15 PM

Should I automatically update my server?
 
Hi!
I recently installed Debian on my home server. I was wondering if I should set up something (probably cron) to automatically update it? It's just for my personal use, so if a service goes down for a minute or two I don't really care.

Is this something that I should implement, or am I an idiot and need to shut up? :D

Thanks!

descendant_command 07-25-2014 10:27 PM

Apticron is probably what you want.

By default it just emails you when there are available updates.

jdkaye 07-26-2014 09:33 AM

As you're using Debian Wheezy (stable) you're not going to get that many updates whatever you do. Since it only takes 4 words (2 commands, 2 words each) typed on a terminal, I wonder if it's worth the effort. I use Jessie (testing) and update my desktop every day. Jessie has plenty of updates and updating it typically takes about 2-3 minutes.
jdk

273 07-26-2014 01:57 PM

I agree with jdkaye that the updates are few enough not to bother. I run Sid day-to-day on my desktop and netbook and there are updates every day. However, I run wheezy on my Pi and updates are few and far between so I just SSH in now and again and run an update.

Firerat 07-26-2014 02:19 PM

personally I update manually, however. I do use cron-apt, which basically runs apt-get update, and downloads required packages ready for the install.


The introduction
http://www.debian-administration.org/articles/162

frieza 07-26-2014 03:42 PM

i would have to concur that automatic updates are probably not necessary, and in some cases can be a bad Idea, although system breaking bugs in updates are usually pretty well vetted from the updates before they go live, but some do, so it would be best to at least search for any bug reports on the updates before applying them, though for a home server this might be overkill, either way running updates manually gives you an opertunity to create a backup before installing the updates.

maples 07-26-2014 05:21 PM

Thanks for the replies!

From what it sounds, it doesn't look like I will do it. Many have mentioned that there aren't that many updates anyway, and it wouldn't be worth the potential problems.

Thanks anyway!

(PS- it's 6 words, plus my (fairly long) password. The server is 99.999% headless (I use SSH, except when I screw it up :banghead:) and I don't allow root login. :D But I get your point.)

273 07-26-2014 05:27 PM

You could always allow apt-get with sudo and no password? I know people have reasons for not using sudo, and there are risks with no password but if you're OK with it then it could be a good fit for this task.

maples 07-26-2014 05:43 PM

Quote:

Originally Posted by 273 (Post 5210066)
You could always allow apt-get with sudo and no password? I know people have reasons for not using sudo, and there are risks with no password but if you're OK with it then it could be a good fit for this task.

True...I might look into that. Thanks for the idea!

273 07-26-2014 05:50 PM

Quote:

Originally Posted by maples (Post 5210071)
True...I might look into that. Thanks for the idea!

You're welcome -- I'm thinking of doing it myself on my Pi. The initial configuration actually allows for passwordless sudo for everything so it was one of the first things I corrected but I may allow apt-get passwordless as it would be more convenient when using my phone to update it. I take it you're using keys for SSH and not passwords to save time and make things more secure also?

maples 07-26-2014 11:35 PM

Quote:

Originally Posted by 273 (Post 5210073)
You're welcome -- I'm thinking of doing it myself on my Pi. The initial configuration actually allows for passwordless sudo for everything so it was one of the first things I corrected but I may allow apt-get passwordless as it would be more convenient when using my phone to update it. I take it you're using keys for SSH and not passwords to save time and make things more secure also?

Really? Raspian defaults to passwordless sudo? That seems a bit...insecure. But, on the other hand, I think the Pi is attracting many non-Linux users (at least, from the YT videos I've seen), and they're trying to make things less confusing.

Yes, I'm using SSH keys...I've been using them ever since I heard of them. It saves time, but it can be a pain if you realize that you need to SSH into the server on another computer...but I have one on my flash drive, and I usually have it with me. Of course, the one time that I will need it will be the one time I forget the flash drive at home... :)

maples 07-26-2014 11:43 PM

OK, I've added this line to my sudoers file, so I can run apt-get without the password. I think I'll just stick with this for a while, and see how it works for me.

Code:

anthony ALL=(ALL) NOPASSWD:/usr/bin/apt-get
Thanks for all the help!

273 07-27-2014 08:34 AM

Glad to help. Yes, the setup on the Pi seems a weird idea to me.

jamison20000e 07-27-2014 08:50 AM

I would think automatic updates should require automatic checks, more so on the sid side?


All times are GMT -5. The time now is 09:11 PM.