Re: Ok so Now which backup should I use

2023-05-18 Thread Celejar
On Thu, 18 May 2023 15:13:46 +0800
Jeremy Ardley  wrote:

...

> This may not be an issue for entry level Debian users, but anyone who does 
> anything serious will want to compile from package source.

They will?

-- 
Celejar



Re: Ok so Now which backup should I use

2023-05-18 Thread Jeremy Ardley



On 17/5/23 15:36, to...@tuxteam.de wrote:

Not many. An "apt-file search /usr/local" turns up exactly three packages.
And I'd venture the guess that those three are doing this by mistake.


I did a very brief search and many well known packages default to /usr/local. 
It's just the packagers at Debian who change this to /etc

Defaulting to /usr/local include:

nginx http://nginx.org/en/docs/configure.html
kamailio https://github.com/kamailio/kamailio/blob/master/INSTALL
postfix https://www.postfix.org/INSTALL.html
dovecot 
https://doc.dovecot.org/installation_guide/dovecot_community_repositories/compiling_source/

I'm pretty confident most well known packages don't use /etc and instead use 
the /usr/local tree.

This may not be an issue for entry level Debian users, but anyone who does 
anything serious will want to compile from package source.

Back on topic. Backing up /usr/local should be SOP irrespective of distribution 
and level of user competence.

--
Jeremy
(Lists)



Re: Ok so Now which backup should I use

2023-05-17 Thread tomas
On Wed, May 17, 2023 at 02:56:32PM +0300, Anssi Saari wrote:
>  writes:
> 
> > On Wed, May 17, 2023 at 09:53:36AM +0300, Anssi Saari wrote:
> 
> >> It's an odd claim. I typically don't have anything in /usr/local except
> >> what I put there myself [...]
> 
> > Not many. An "apt-file search /usr/local" turns up exactly three packages.
> > And I'd venture the guess that those three are doing this by mistake.
> 
> Not many what?

Not many packages.

> Are you really responding by not quoting the part you're
> commenting on? Why?

[...]

> It seems to me you're using the wrong tool to reach a wrong conclusion
> with very little knowledge of the topic, that being Debian
> packaging. Why do you think apt-file is the correct tool?

Because it tells me what any Debian package would put in /usr/local, 

> I'd appreciate a little restraint when contradicting what I said. You
> don't have to vomit all of your half baked thoughts to the list. And
> definitely don't automatically assume people don't know what they're
> talking about.

Sigh. Here's a full quote:

You wrote:
> Celejar  writes:
> 
> > On Tue, 16 May 2023 09:52:07 +0800
> > Jeremy Ardley  wrote:
> >
> >>
> >> On 16/5/23 09:11, pa...@quillandmouse.com wrote:
> >> > I'd suggest backing up /etc, since that's where your system settings
> >> > are. I also back up /var, since that's typically where your logs and
> >> > mail are.
> >>
> >> There is a lot relevant of stuff in /usr/local
> >>
> >> For instance some programs use /usr/local/etc rather than /etc
> >
> > They do? I see that my /usr/local/etc is empty. What programs use this
> > directory
> 
> It's an odd claim. I typically don't have anything in /usr/local except
> what I put there myself. Some Debian packages do create a directory in
> /usr/local/share but leave it empty.

I repeat: "Some Debian packages..."

...to which I replied "Not many" (three, it seems).

Can we now declare this tempest in a teapot closed?

Cheers
-- 
t


signature.asc
Description: PGP signature


Re: Ok so Now which backup should I use

2023-05-17 Thread Anssi Saari
 writes:

> On Wed, May 17, 2023 at 09:53:36AM +0300, Anssi Saari wrote:

>> It's an odd claim. I typically don't have anything in /usr/local except
>> what I put there myself [...]

> Not many. An "apt-file search /usr/local" turns up exactly three packages.
> And I'd venture the guess that those three are doing this by mistake.

Not many what? Are you really responding by not quoting the part you're
commenting on? Why?

It seems to me you're using the wrong tool to reach a wrong conclusion
with very little knowledge of the topic, that being Debian
packaging. Why do you think apt-file is the correct tool?

I'd appreciate a little restraint when contradicting what I said. You
don't have to vomit all of your half baked thoughts to the list. And
definitely don't automatically assume people don't know what they're
talking about.




Re: Ok so Now which backup should I use

2023-05-17 Thread tomas
On Wed, May 17, 2023 at 09:53:36AM +0300, Anssi Saari wrote:
> Celejar  writes:
> 
> > On Tue, 16 May 2023 09:52:07 +0800
> > Jeremy Ardley  wrote:
> >
> >> 
> >> On 16/5/23 09:11, pa...@quillandmouse.com wrote:
> >> > I'd suggest backing up /etc, since that's where your system settings
> >> > are. I also back up /var, since that's typically where your logs and
> >> > mail are.
> >> 
> >> There is a lot relevant of stuff in /usr/local
> >> 
> >> For instance some programs use /usr/local/etc rather than /etc
> >
> > They do? I see that my /usr/local/etc is empty. What programs use this
> > directory
> 
> It's an odd claim. I typically don't have anything in /usr/local except
> what I put there myself [...]

Not many. An "apt-file search /usr/local" turns up exactly three packages.
And I'd venture the guess that those three are doing this by mistake.

/usr/local is for the "local installation" (well, duh), not for the distro.
That's FHS, and Debian packaging rhymes pretty well with FHS.

Cheers
-- 
t


signature.asc
Description: PGP signature


Re: Ok so Now which backup should I use

2023-05-17 Thread Jeremy Ardley



On 17/5/23 14:53, Anssi Saari wrote:

It's an odd claim. I typically don't have anything in /usr/local except
what I put there myself. Some Debian packages do create a directory in
/usr/local/share but leave it empty. So what goes in /usr/local is
mostly software I've compiled myself and maybe some little
scripts. Basically stuff I might use both as both root and normal
user. If it's just for my non-privileged user account then it typically
goes in $HOME/bin or the more modern $HOME/.local/bin.


Programs compiled from source rather than as part of a distro package 
may use /usr/local as a default.


For example kamailio defaults configuration to /usr/local/etc and 
homebrew defaults packages to /usr/local


--
Jeremy
(Lists)



Re: Ok so Now which backup should I use

2023-05-17 Thread Anssi Saari
Celejar  writes:

> On Tue, 16 May 2023 09:52:07 +0800
> Jeremy Ardley  wrote:
>
>> 
>> On 16/5/23 09:11, pa...@quillandmouse.com wrote:
>> > I'd suggest backing up /etc, since that's where your system settings
>> > are. I also back up /var, since that's typically where your logs and
>> > mail are.
>> 
>> There is a lot relevant of stuff in /usr/local
>> 
>> For instance some programs use /usr/local/etc rather than /etc
>
> They do? I see that my /usr/local/etc is empty. What programs use this
> directory

It's an odd claim. I typically don't have anything in /usr/local except
what I put there myself. Some Debian packages do create a directory in
/usr/local/share but leave it empty. So what goes in /usr/local is
mostly software I've compiled myself and maybe some little
scripts. Basically stuff I might use both as both root and normal
user. If it's just for my non-privileged user account then it typically
goes in $HOME/bin or the more modern $HOME/.local/bin.

So for me, /usr/local is useful to back up but typically it amounts to
very little data. My Debian router has all of 812 kB in there, for
example.



Re: Ok so Now which backup should I use

2023-05-16 Thread DdB
Am 16.05.2023 um 02:17 schrieb Maureen L Thomas:
> I have everything I need including a third HDD.  There are so many
> backup programs I have to wonder which one will work for my needs.  I
> just need to make a backup of my home directory so if I do something
> stupid like play with /var and have no idea how to fix it.  Is there
> something else I need to back up besides /home?  I appreciate your help.
> 
> Moe
> 

TBH, I have always preferred to use my own hand-scripted backup using
standard tools, bacause i am willing to tailor it to special use cases i
might encounter. And a basic backup has to offer the feature to restore
in any way, i want.
But, just recently, i decided to create a backup for my neighbor on
their laptop, and did not wwant to write everything from scratch. After
searching a bit, i opted for fsarchiver, a simple tool, that is already
on some ubuntu live cd. Learning its commandline is not so difficult,
the biggest problem AFAICT is, that there is only one (french) developer
and thus the tool has not seen a huge amount of public testing. But i
pucked it anyway, had several backups and - who would have thought:
several restore operations carried out since. And i am happy with the
choice. You might take a look as well: https://www.fsarchiver.org/

just my 2 cents, DdB



Re: Ok so Now which backup should I use

2023-05-16 Thread Celejar
On Tue, 16 May 2023 09:52:07 +0800
Jeremy Ardley  wrote:

> 
> On 16/5/23 09:11, pa...@quillandmouse.com wrote:
> > I'd suggest backing up /etc, since that's where your system settings
> > are. I also back up /var, since that's typically where your logs and
> > mail are.
> 
> There is a lot relevant of stuff in /usr/local
> 
> For instance some programs use /usr/local/etc rather than /etc

They do? I see that my /usr/local/etc is empty. What programs use this
directory

-- 
Celejar



Re: Ok so Now which backup should I use

2023-05-16 Thread Anssi Saari
Maureen L Thomas  writes:

> I have everything I need including a third HDD.  There are so many backup 
> programs I have to wonder which one will work for my needs.  I
> just need to make a backup of my home directory so if I do something stupid 
> like play with /var and have no idea how to fix it.  Is there
> something else I need to back up besides /home?  I appreciate your help.

I use bup. It's a fairly simple command line tool. It can generate error
correction data for my backups too which I thought is great but as you
say, there are many

I back up /boot /etc /home /root usr/local /var/lib/dpkg 
/var/lib/apt/extended_states
on my main desktop. Probably different directories on my other computers.

I can't remember why /var/lib/dpkg and /var/lib/apt/extended_states though.

/boot is a little suspect too but I do have a custom Grub theme in
there but that's the only thing worth backing up in /boot.

I also save partition tables with sfdisk and Debian package selections
with dpkg --get-selections "*", just in case. My desktop especially has
a fair number of partitions on the boot drive with three operating
system. So, good to keep a copy of that.



Re: Ok so Now which backup should I use

2023-05-16 Thread David Christensen

On 5/15/23 17:17, Maureen L Thomas wrote:
I have everything I need including a third HDD.  There are so many 
backup programs I have to wonder which one will work for my needs.  I 
just need to make a backup of my home directory so if I do something 
stupid like play with /var and have no idea how to fix it.  Is there 
something else I need to back up besides /home? I appreciate your help.


Moe



I will assume that you have one desktop computer with one internal 
drive, that you have two USB HDD's for backups, that you will connect 
one USB HDD at a time, and that you will rotate the USB HDD's periodically.



Start keeping records of your system administration activities.  The 
simplest approach is to use a USB flash drive.  Create a log.txt file 
and type your notes into that.  Copy and paste console sessions into the 
log.txt.  Copy files you create, modify, or delete to the USB flash 
drive.  This information will be invaluable for future reference and 
trouble shooting.



Keep using Brasero to burn optical discs containing the data that you 
want to keep indefinitely (archives).



If your system drive is an SSD, emptying the trash and running fstrim(8) 
prior to taking an image will reduce the image file size.



I would start by using Clonezilla to save a compressed full image of the 
internal drive to a file on a USB HDD:


https://clonezilla.org/


Clonezilla is non-trivial.  If you get stuck, try the clonezilla-live 
mailing list archives (or subscribing and posting):


https://sourceforge.net/p/clonezilla/mailman/


Once you have an image, do a full backup onto the USB HDD (see below).


Then immediately rotate the USB HDD's, take a compressed full image, do 
a full backup, and move the first USB HDD off-site.



After a period of time, or when the current USB HDD is nearly full, 
fetch the off-site USB HDD, rotate disks, take a compressed full image, 
do a full backup, and move the previous USB HDD off-site.  Repeat 
periodically.



As the USB HDD's fill up, delete the oldest images and backups to make 
room for new images and backups.



As for a Debian backup package:

https://wiki.debian.org/BackupAndRecovery


I have been using rsync(1) over ssh(1) for backups for many years.  If 
you are comfortable with a terminal, command-line interface, 
configuration files, rsync(1), ssh(1), crontab(1), etc., I suggest 
rsnapshot(1):


https://manpages.debian.org/bullseye-backports/rsnapshot/rsnapshot.1.en.html


If you want a simpler, single-user, GUI desktop backup application, I 
suggest backintime(1):


https://manpages.debian.org/buster/backintime-common/backintime.1.en.html


Evaluate the backup solution by using a test directory with some small 
test files under your home directory.  Verify that you can backup.  Then 
modify or delete a test file and verify that you can restore it.  If you 
like the backup tool, reconfigure it to backup your home directory and 
any data directories you have created.  Backing up /etc would be nice, 
if you can figure that out.



Restoring a Clonezilla image is more involved.  You will need a blank 
drive of exactly the same size as your current system drive, plus a 
drive case and tools for removing and installing drives (including an 
anti-static wrist strap).  After taking a full image, remove the system 
drive, install the blank drive, restore the image, boot the computer, 
and test.  If all is well, put the previous drive in the case.  If not, 
zero the new drive and try again.  If you cannot get the new drive 
working, remove it, reinstall the previous drive, and put the new drive 
in the case until you are ready to try again.



David



Re: Ok so Now which backup should I use

2023-05-15 Thread Charles Kroeger
When you have things going your way, why not just image the whole disc and
sleep well.

I have used this for years. It is proprietary yes, and runs on an old
version of Linux.

https://www.terabyteunlimited.com/image-for-linux/

I have no interest in these people, I don't get a commission for
advertising them. 

If you duel boot you can also make an image of that other
OS too, keep them both on a single disc using their respective file systems
on two partitions named for the purpose.  GParted working from a bootable
disc or stick, works well for setting that up.  IFL you put on
something that can be booted first in case things are really screwed. It is
pretty straight forward with no surprises.

An image before a large dist-upgrade especially with the word nvidia in the
list of packages, I would do without hesitation. 

-- 
salve debian invictum



Re: Ok so Now which backup should I use

2023-05-15 Thread Jeremy Ardley



On 16/5/23 09:11, pa...@quillandmouse.com wrote:

I'd suggest backing up /etc, since that's where your system settings
are. I also back up /var, since that's typically where your logs and
mail are.


There is a lot relevant of stuff in /usr/local

For instance some programs use /usr/local/etc rather than /etc

and your custom installed fonts amongst lots of other stuff are in

/usr/local/share


--
Jeremy
(Lists)



Re: Ok so Now which backup should I use

2023-05-15 Thread paulf
On Mon, 15 May 2023 20:17:48 -0400
Maureen L Thomas  wrote:

> I have everything I need including a third HDD.  There are so many 
> backup programs I have to wonder which one will work for my needs.  I 
> just need to make a backup of my home directory so if I do something 
> stupid like play with /var and have no idea how to fix it.  Is there 
> something else I need to back up besides /home? I appreciate your
> help.
> 
> Moe

I'd suggest backing up /etc, since that's where your system settings
are. I also back up /var, since that's typically where your logs and
mail are.

Which backup program you use depends on features, like whether you want
it to fire off at the same time every day. Like whether you want a GUI
or terminal program. Etc. Personally, I wrote my own backup script
using rsync, which fires off each day at about 7:38.

Paul


-- 
Paul M. Foster
Personal Blog: http://noferblatz.com
Company Site: http://quillandmouse.com
Software Projects: https://gitlab.com/paulmfoster



Ok so Now which backup should I use

2023-05-15 Thread Maureen L Thomas
I have everything I need including a third HDD.  There are so many 
backup programs I have to wonder which one will work for my needs.  I 
just need to make a backup of my home directory so if I do something 
stupid like play with /var and have no idea how to fix it.  Is there 
something else I need to back up besides /home? I appreciate your help.


Moe