Want To Keep Debian 9.0 Up-to-date

New to Debian (Or Linux in general)? Ask your questions here!

Want To Keep Debian 9.0 Up-to-date

Postby tb75252 » 2017-08-02 01:34

I am using Debian 9.0, 64-bit.
I would like to keep Debian up-to-date with the most recent stable packages. I did searches on the Internet and have then made changes/added entries as follows in /etc/apt/sources.list:
# deb cdrom:[Debian GNU/Linux 9.0.0 _Stretch_ - Official amd64 DVD Binary-1 20170617-13:08]/ stretch main

#deb cdrom:[Debian GNU/Linux 9.0.0 _Stretch_ - Official amd64 DVD Binary-1 20170617-13:08]/ stretch main

#deb http://ftp.us.debian.org/debian/ stretch main
deb http://ftp.us.debian.org/debian/ stable main contrib non-free
#deb-src http://ftp.us.debian.org/debian/ stretch main
deb-src http://ftp.us.debian.org/debian/ stable main contrib non-free

#deb http://security.debian.org/debian-security stretch/updates main
deb http://security.debian.org/debian-security stable main contrib non-free
#deb-src http://security.debian.org/debian-security stretch/updates main
deb-src http://security.debian.org/debian-security stable main contrib non-free

# stretch-updates, previously known as 'volatile'
#deb http://ftp.us.debian.org/debian/ stretch-updates main
deb http://ftp.us.debian.org/debian/ stable-updates main contrib non-free
#deb-src http://ftp.us.debian.org/debian/ stretch-updates main
deb-src http://ftp.us.debian.org/debian/ stable-updates main contrib non-free


Can I safely run
Code: Select all
sudo apt upgrade
?
tb75252
 
Posts: 61
Joined: 2010-10-09 00:27

Re: Want To Keep Debian 9.0 Up-to-date

Postby 4D696B65 » 2017-08-02 01:45

tb75252 wrote:Can I safely run
Code: Select all
sudo apt upgrade
?

Yes but you should always update the package database first with
Code: Select all
sudo apt update
User avatar
4D696B65
 
Posts: 2004
Joined: 2009-06-28 06:09

Re: Want To Keep Debian 9.0 Up-to-date

Postby dasein » 2017-08-02 01:54

The only thing better than getting someone else to answer this for you is for you to learn to answer it for yourself.

Repo management may be strange and unfamiliar to you, but it is not hard.

The Wiki has an entire page devoted to answering this question: https://wiki.debian.org/SourcesList
User avatar
dasein
 
Posts: 7775
Joined: 2011-03-04 01:06
Location: Terra Incantationum

Re: Want To Keep Debian 9.0 Up-to-date

Postby tb75252 » 2017-08-02 02:00

dasein wrote:The only thing better than getting someone else to answer this for you is for you to learn to answer it for yourself.

Repo management may be strange and unfamiliar to you, but it is not hard.

The Wiki has an entire page devoted to answering this question: https://wiki.debian.org/SourcesList

I read that page but I don't see any mention of this:
# stretch-updates, previously known as 'volatile'
#deb http://ftp.us.debian.org/debian/ stretch-updates main
deb http://ftp.us.debian.org/debian/ stable-updates main contrib non-free
#deb-src http://ftp.us.debian.org/debian/ stretch-updates main
deb-src http://ftp.us.debian.org/debian/ stable-updates main contrib non-free

Does it mean that it is not needed?
tb75252
 
Posts: 61
Joined: 2010-10-09 00:27

Re: Want To Keep Debian 9.0 Up-to-date

Postby dasein » 2017-08-02 02:26

tb75252 wrote:I read that page but..

Then I suggest that you read it again. A thorough understanding of that page will allow you to see an inconsistency in your sources that will potentially bite you in the butt in the distant future.

tb75252 wrote:I don't see any mention of this...

And what other Wiki pages did you look at? (I'm not trying to be a hard-ass, but I'll repeat my earlier point: repo management isn't hard, and after 7 years, it's something you should have mastered for yourself long ago. Moreover, the Wiki answers every question you've asked in this thread.)

tb75252 wrote:Does it mean that it is not needed?

Strictly speaking, no, it's not needed, though some folks find it useful. (The Wiki has more details :mrgreen:).
User avatar
dasein
 
Posts: 7775
Joined: 2011-03-04 01:06
Location: Terra Incantationum

Re: Want To Keep Debian 9.0 Up-to-date

Postby Wheelerof4te » 2017-08-02 06:55

Oh, for God's sake. Just rename everything to Stretch. Keeping it at stable will cause problems when the next Debian stable release comes out.
Also, you can remove or disable deb-scr repos if you don't plan on using source packages. That will make your sources.list easier to read, too.

I am using Debian 9.0, 64-bit.


Debian is at 9.1 now, so you should upgrade after renaming everything to Stretch and running

Code: Select all
apt-get update
User avatar
Wheelerof4te
 
Posts: 392
Joined: 2015-08-30 20:14

Re: Want To Keep Debian 9.0 Up-to-date

Postby Lysander » 2017-08-02 07:45

As a hint I would say you wouldn't need a good three quarters of that sources.list.
User avatar
Lysander
 
Posts: 317
Joined: 2017-02-23 10:07
Location: London

Re: Want To Keep Debian 9.0 Up-to-date

Postby Ardouos » 2017-08-02 10:47

All of your questions are answered with Daseins post, so there is no real need to elaborate on it. I agree that learning the fundamentals of repo management is a good way for your stable system to live a smoother, happier life.

In regards to your current sources that you have posted. I would ask yourself "Do I want to be following Stretch/9 for its lifespan? Or do I want to upgrade to the next stable as soon as it is released". A question that you have already answered in your thread title. Therefore if you have read the wiki link provided, you should know what to remove and what to allow.
User avatar
Ardouos
 
Posts: 914
Joined: 2013-11-03 00:30
Location: Elicoor II

Re: Want To Keep Debian 9.0 Up-to-date

Postby ruffwoof » 2017-08-02 10:50

My /etc/apt/source.list contains just

deb http://httpredir.debian.org/debian jessie main
deb http://security.debian.org/ jessie/updates main

and I run

apt-get update
apt-get upgrade

periodically and it has and continues to work well for me. My plan is to upgrade to Stretch once that shifts to being oldstable i.e. use a sources.list with stretch instead of jessie. If you use 'stable' then it will upgrade as soon as a new 'stable' comes out. Bear in mind however that 'stable' in Debian terms means unchanging (changed as little as possible) ... and not stable as in solid. New releases of stable can be liquid as wider usage identifies bugs that the developers missed across all 50,000 or whatever programs in the Debian repositories. By the time a release enters oldstable ... its pretty solid, and that continues to receive security updates. Such stability comes at the cost of running older (extensively tested) versions of programs; Or that the version might be too old for your (newer) hardware.

Note I don't use contrib or nonfree as it works for me without those (including my Nvidia card).
ruffwoof
 
Posts: 196
Joined: 2016-08-20 21:00

Re: Want To Keep Debian 9.0 Up-to-date

Postby tb75252 » 2017-08-02 18:19

One question. You say:
Keeping it at stable will cause problems when the next Debian stable release comes out.
But then at the end of your message you state:
When in doubt, choose Debian Stable

Is this not contradictory?
tb75252
 
Posts: 61
Joined: 2010-10-09 00:27

Re: Want To Keep Debian 9.0 Up-to-date

Postby dasein » 2017-08-02 19:58

tb75252 wrote:Is this not contradictory?

No.

Go read the damn Wiki already!

[rant]For everyone who feels the need to spoonfeed well-documented answers every time someone asks a really basic question, this is what happens when you do. However well-intentioned your motives might be, you end up creating an artificially dependent invalid who can't tell a code name from a release name, or otherwise wipe his own butt, despite having used Debian for nearly eight years.[/rant]

Image
User avatar
dasein
 
Posts: 7775
Joined: 2011-03-04 01:06
Location: Terra Incantationum

Re: Want To Keep Debian 9.0 Up-to-date

Postby MALsPa » 2017-08-02 23:49

tb75252 wrote:One question. You say:
Keeping it at stable will cause problems when the next Debian stable release comes out.
But then at the end of your message you state:
When in doubt, choose Debian Stable

Is this not contradictory?

No, don't look at it that way. "stretch" and "stable" in sources.list basically give you the same packages right now, I think. But they won't contain the same stuff when the next Stable comes out. So just be consistent and go with one name -- "stretch" or "stable" -- throughout your sources.list file.

Definitely take time to do as much searching and reading online as possible -- then you won't have to ask many questions here (and, I guess, everybody will be happy). Just about any question you have has already been asked, or can be answered via the wiki, man pages, and/or web searches.
MALsPa
 
Posts: 614
Joined: 2007-12-07 19:20
Location: albuquerque


Return to Beginners Questions

Who is online

Users browsing this forum: No registered users and 6 guests

fashionable