Re: exiftool

2022-07-19 Thread mick crane

On 2022-07-19 10:58, Andy Smith wrote:

Hello,

On Tue, Jul 19, 2022 at 10:03:05AM +0100, mick crane wrote:

I'm sending a load of images to somebody and I want them to be
Attribution-ShareAlike 4.0 International license
Don't want to plaster over images so think to add to exif data.


I've not done it personally but this seems to give an example of
what you want using exiftool:

https://photo.stackexchange.com/a/71428



I don't think it was my exif additions Gimp was complaining about but 
something else.

It's happy enough now but struggling adding the exifdata.
Gimp image>Metadata shows 3 tabs Exif, XMP, IPTC
typing exiftool -CopyrightNotice="Licence: Attribution-ShareAlike 4.0 
International (https://creativecommons.org/licenses/by-sa/4.0/)"

text is in IPTC tab of gimp.
I want to add AttributionURL and AttributionName
https://exiftool.org/TagNames/XMP.html#cc
says is to do with "XMP-cc" but not guessed the syntax as yet.

cheers
mick



Re: exiftool

2022-07-19 Thread mick crane

On 2022-07-19 17:08, Curt wrote:

On 2022-07-19, mick crane  wrote:


I want to add AttributionURL and AttributionName
https://exiftool.org/TagNames/XMP.html#cc
says is to do with "XMP-cc" but not guessed the syntax as yet.


 exiftool -overwrite_original -XMP-cc:AttributionName="Creator" "file
 name.extension"

 exiftool -overwrite_original -XMP-cc:AttributionURL="Creator URL" 
"file

 name.extension"

 exiftool -overwrite_original
 -XMP-cc:license="http://creativecommons.org/licenses/by-sa/4.0/";
 -XMP-cc:AttributionName="Creator"
 -XMP-cc:AttributionURL="http://creatorURL.com"; "file name.extension"


https://libre-software.net/edit-metadata-exiftool/



I've been doing that before without the "-overwrite_original"
but doesn't show up in Gimp metadata menu, is there when view with 
exiftool.
only "exiftool -CopyrightNotice="License: Attribution-ShareAlike 4.0 
International"  file.png"

Shows in Gimp>image>metadata

cheers
mick



Re: Why can't I move the document root for a site in Apache 2? [SOLVED]

2020-08-31 Thread mick crane

On 2020-08-31 21:57, Gary Dale wrote:


Just to be clear, the folder I had to change permissions on is the


I think the document root is just where apache2 looks first.
*Don't know if you are supposed to do it like that* but think the actual 
html files can be anywhere so long as they have the right permissions 
and have a link to them in the document root.

Whenever I've changed anything I do.
#!/bin/bash
find /path_to_html_files/ -type d -exec chmod 750 {} \;
find /path_to_html_files/ -type f -exec chmod 640 {} \;
chown -R root /path_to_html_files/*;
chgrp -R www-data /path_to_html_files/*;

remembering if there is any file wants to be executable.

mick

--
Key ID4BFEBB31



Re: Looking for a generic drag and drop gui for custom commands

2020-09-08 Thread mick crane

On 2020-09-07 21:43, Christoph K. wrote:

Dear all,

I'd like to "automate" a couple of tasks that I (until now) do on the
command line manually. Examples include splitting of video files using
ffmpeg, run backups with specific parameters, display checksums(md5), 
etc.


I'm tired of typing the same long commands that I often need to look up
in my wiki and just replace one or two parameters, usually just the 
file

names.


Put the (ffmpeg) command in a script and run it with argument/s ?

mick

--
Key ID4BFEBB31



Re: LEAN Debian install: Exploring task selection menu

2020-09-10 Thread mick crane

On 2020-09-09 14:27, Richard Owlett wrote:


My proposed alternative is to leave unchecked all options on the
"Software Selection" menu[1] and create appropriate pseudo-packages to
be installed with "apt-get --no-install-recommends"


I suppose if you were *that* concerned you could install a basic system 
and install everything from sources. What that "basic system" would 
contain I don't really know. But that's what the nice people at Debian 
do so you don't have to.


mick
--
Key ID4BFEBB31



Re: LEAN Debian install: Exploring task selection menu

2020-09-12 Thread mick crane

On 2020-09-12 10:53, Brian wrote:

On Sat 12 Sep 2020 at 12:33:56 +0300, Andrei POPESCU wrote:


On Vi, 11 sep 20, 22:47:06, Fabrice BAUZAC-STEHLY wrote:
>
> I've also been bitten by this.  I think it is a UI issue, the options
> are ambiguous.  Would it be possible to simply change the dialog box as
> follows?  --
>
>   Debian desktop environments:
>   [ ] ... GNOME (default)
>   [ ] ... Xfce
>   [ ] ... KDE
>   [ ] ... Cinnamon
>   [ ] ... MATE
>   [ ] ... LXDE

You could contact debian-boot or file a bug against debian-installer 
(or

tasksel?).

Providing a patch increases the chances of having the change accepted.


What is the purpose of "(default)" as part of the Gnome entry?


I wondered that, "default" is usually what happens if you just press 
enter given a YES, no

choice. The dialogue should probably be something like
"If you don't select an alternative GNOME will be installed"
--
Key ID4BFEBB31



Re: LEAN Debian install: Exploring task selection menu

2020-09-12 Thread mick crane

On 2020-09-12 18:42, Brian wrote:

On Sat 12 Sep 2020 at 11:49:18 +0100, mick crane wrote:


On 2020-09-12 10:53, Brian wrote:
> On Sat 12 Sep 2020 at 12:33:56 +0300, Andrei POPESCU wrote:
>
> > On Vi, 11 sep 20, 22:47:06, Fabrice BAUZAC-STEHLY wrote:
> > >
> > > I've also been bitten by this.  I think it is a UI issue, the options
> > > are ambiguous.  Would it be possible to simply change the dialog box as
> > > follows?  --
> > >
> > >   Debian desktop environments:
> > >   [ ] ... GNOME (default)
> > >   [ ] ... Xfce
> > >   [ ] ... KDE
> > >   [ ] ... Cinnamon
> > >   [ ] ... MATE
> > >   [ ] ... LXDE
> >
> > You could contact debian-boot or file a bug against debian-installer
> > (or
> > tasksel?).
> >
> > Providing a patch increases the chances of having the change accepted.
>
> What is the purpose of "(default)" as part of the Gnome entry?

I wondered that, "default" is usually what happens if you just press 
enter

given a YES, no
choice. The dialogue should probably be something like
"If you don't select an alternative GNOME will be installed"


What would happen if a user did not want Gnome? Note that the present
dialog caters for this situation.


Is the "Debian desktop environment" Gnome plus other things ? In which 
case the way it is makes sense.


--
Key ID4BFEBB31



Re: ssh fingerprint mismatch for one single client

2020-09-19 Thread mick crane

On 2020-09-19 22:28, Beco wrote:

Dear linuxers,

I've a server and one of my students is getting a wrong fingerprint 
when

trying to connect via SSH.

After a lot of debug, we are still unable to pinpoint why.

The server didn't change IP or keys, and other students still log in ok
with the correct fingerprint. Just one student, let's call him Bob 
(because

why not), is not getting through.

I've asked Bob to try a different machine, which he does not have, 
being a

poor student. But he had a mobile, so after trying the app juiceSSH and
wifi on, he again got the wrong fingerprint.

I asked him to turn the wifi off for the mobile and yes, he got the 
correct

fingerprint.

I also asked him to run a full antivirus scan in his notebook (windows) 
and

nothing was found.

He also hard-reseted the router, still the problem continues.

He called the ISP for any clues, but it is a small company who doesn't 
know
the word "fingerprint" neither in english nor in their native language. 
So,

not much help there.

I also asked him to check if his IP is what he think it is, and he 
checked

with one of these "what is my IP" website and it is ok.

As for DNS, I asked him to try to ssh directly using the server's IP
instead of the name, but still the wrong fingerprint.

Kinda crazy, right? I run out of ideas...

What else should I try to help that student?

Thanks
Beco


Just wild guess.
Student can connect via the mobile network but not through the ISP 
router?

Might that be the port for ssh on the router ?

mick

--
Key ID4BFEBB31



Re: ssh fingerprint mismatch for one single client

2020-09-19 Thread mick crane

On 2020-09-19 23:42, Beco wrote:

On Sat, 19 Sep 2020 at 18:55, mick crane  wrote:



Just wild guess.
Student can connect via the mobile network but not through the ISP
router?
Might that be the port for ssh on the router ?

mick



Hello Mick,

Thanks for the interest.

Yes, student can connect via mobile.

And, somewhat "yes", student can kind of connect via ISP. It is not 
that

the port is blocking traffic.
The fingerprint appears, and if accepted the wrong one, the password is
asked for.

But then, of course, the connection fail.

Also, he was able to connect the day before. So whatever it is, it is
recent, and just for one single student.

Also, I asked him to check the router port 22 if it was ok. He did a 
hard

reset (factory reset) on it. He took a look and it is open.



Is this Putty or something with keys on student's PC ?
If worked before maybe something went wrong with the saved connection 
but that doesn't explain why cannot connect via phone>router WIFI unless 
there is separate issue there.
I guess I would try connect via command line with verbosity but I'd have 
to look up exactly the syntax.


mick


--
Key ID4BFEBB31



Re: Offline systems

2020-09-20 Thread mick crane

On 2020-09-20 15:46, Peter wrote:

Hi,

I want to setup a few servers(30+) on  intranet network and NONE(not
even a master server or anything like that) of them having internet 
access.


What is best approach so I can still install packages on demand ?

Try to make custom repo  ? But in this case what will be the proper
procedure to update the repo ?

What is your advice ?


You'll want "something" connected to the internet to get updates.
Somebody mentioned jigdo which looked like a good thing.
Depends how paranoid you are. You could take disk or whatever from that 
separate, connected to internet machine and use that as your repository 
I imagine.


mick


--
Key ID4BFEBB31



Re: Offline systems

2020-09-20 Thread mick crane

On 2020-09-20 16:31, Thomas Schmitt wrote:

Hi,

mick crane wrote:

Somebody mentioned jigdo which looked like a good thing.


Jigdo is used for making ISO images from a frame of ISO 9660 metadata 
and
other non-packaged stuff (the .template file), and the .deb packages on 
a

mirror, or in a repository, or in an older ISO image.
The .jigdo file contains the list of packages which shall be inserted 
into

the frame.

So except that you get them wrapped in an ISO image, the packages are 
just
the same as on the mirror server (or other package source) from which 
you

could fetch them by appropriate means.


Have a nice day :)

Thomas


What's the best appropriate means then to fetch mirror and then only 
fetch differences to local copy ? wget does that doesn't it ?

Not that I want to but wondered.

mick


--
Key ID4BFEBB31



Re: Mail transfer agent

2020-09-24 Thread mick crane

On 2020-09-24 18:19, Brian wrote:

On Thu 24 Sep 2020 at 13:35:17 +, mike.junk...@att.net wrote:



On Wednesday, September 23, 2020, 09:14:42 PM CDT, Dan Ritter 
 wrote:

 mutt is an MUA, not an MTA. 

What tasks do you want your mail server to perform? Please be
specific. We will have better advice for you once we know
exactly what you want to have happen.
-dsr-
Thanks, Dan,All I need from an MTA is:1) take mail from fetchmail and
put it in a mailbox for mutt to display,2) take mail from mutt and
send it to my ISP via smtp3) take messages from the system, eg: cron
and deliver them to that same mailbox4) take a simple message on the
CL such as:    echo 'blah' | mail -s 'oops' no...@example.com

I've been using exim for years and it works well but is overkill for
my needs.


I too have been using exim for years in a similar way to the way you
describe. It does the job very well and I just let it get on with it.
I don't really understand what you mean by "overkill" and think you are
fussing over nothing.


I know how I get mail.
I've been using roundcube for a few years. I know I put in the SMTP 
server, account and password for being allowed in the configuration but 
I actually have no idea what is used for the sending. I probably should.


mick



--
Key ID4BFEBB31



Re: Mail transfer agent

2020-09-25 Thread mick crane

On 2020-09-25 08:56, Joe wrote:


If you haven't done anything yourself, it will be exim4-light.


thanks

--
Key ID4BFEBB31



Re: crc not installed but rsync using it? ...

2020-09-25 Thread mick crane

On 2020-09-25 23:42, Gene Heskett wrote:

On Friday 25 September 2020 18:10:42 Stefan Monnier wrote:


> He may have changed it, but at the time I first started using it on
> a "pc" it had to be registered before it would access the 2nd port.

I don't understand what you're referring to:
- What is the "it" that had to be registered?


That edition of dd-wrt.  You had to get a keyfile from brainslayer.  
You

didn't have to get one to go with a router version.  And it sometimes
took most of a week for him to service your key request.


- With whom/what did it have to be registered?
- What 2nd port of what?


The second ethernet port of the pc you built to run it.


When all this internet kicked off I thought anybody could have a go but 
apparently you need to be with a provider.


mick

--
Key ID4BFEBB31



SSD and HDD

2020-10-11 Thread mick crane
Bearing in mind I rarely do installs and when I do usually let the 
installer do its thing.
Got a PC that has SSD and a HDD. I see that you are supposed to avoid 
writes to SSD for longevity.
Is it a matter of putting entries in fstab for /swap /var /home to 
suitably formatted partitions on HDD ?

Or is there more to  it ?

mick

--
Key ID4BFEBB31



Re: SSD and HDD

2020-10-12 Thread mick crane

On 2020-10-11 19:01, Andy Smith wrote:

Hi Mick,

On Sun, Oct 11, 2020 at 05:45:45PM +0100, mick crane wrote:
Got a PC that has SSD and a HDD. I see that you are supposed to avoid 
writes

to SSD for longevity.


Flash write endurance has come on leaps and bounds over the last
decade to the point where most people don't have to worry about
this.

You can look at "tune2fs -l" output or at SMART attributes to see
how much has been written to your current filesystems / devices over
their life times, to see how your use case matches up against the
write endurance advertised for your SSD.

I wouldn't recommend taking any special measures unless you have
some doubt that the SSD endurance is up to it.

With only a single SSD and a single HDD I'd rate device failure from
other problems as a higher risk than wearing out the SSD.

Is it a matter of putting entries in fstab for /swap /var /home to 
suitably

formatted partitions on HDD ?


If you still think you will have a problem then yes, that is one way
to go. Another is to leave some percentage of the SSD unpartitioned
and never used. That will increase its write endurance.

[ Leaving aside the fact that if I were doing this I'd have an extra
storage device for redundancy… ]

If I were in your position and still had concerns about write
endurance I'd probably put everything in LVM with a volume group on
the SSD and a volume group on the HDD. I'd then use separate logical
volumes for the filesystems that got a lot of writes. The use of LVM
like this would allow me to change my mind later and move LVs
between the SSD and HDD while the machine is online.

Plus any time you are thinking of doing multiple filesystems, LVM is
a good bet.

Plus you might be using LVM anyway for encryption.

But again I can't emphasise enough how you are probably over thinking
write endurance.

Cheers,
Andy


might I ask a favour for information on accepted wisdom for this stuff ?
I being a home user have pfsense on old lenovo between ISP router and 
switch to PCs

another old buster lenovo doing email
another Buster PC I do bits of programming on.
Windows PC I play poker on and some games.
My approach to backup has been to copy files I want to keep to external 
HDs and other disks when I remember. If something goes wrong so long as 
I remember what the config files do it's not such a big deal to start 
again.

I suppose I should try to make it more formal

Tips for understood accepted wisdom appreciated, like is it better if 
want to use a windows program have this Virtualization or reboot and 
change boot order or just have it on another PC. And also practical 
method for backup hardware as consumer hardware only seem to have room 
for 2 disks at most.


mick


--
Key ID4BFEBB31



Re: backups Was: SSD and HDD

2020-10-13 Thread mick crane

On 2020-10-13 00:46, Dan Ritter wrote:

mick crane wrote:


might I ask a favour for information on accepted wisdom for this stuff 
?
I being a home user have pfsense on old lenovo between ISP router and 
switch

to PCs
another old buster lenovo doing email
another Buster PC I do bits of programming on.
Windows PC I play poker on and some games.
My approach to backup has been to copy files I want to keep to 
external HDs

and other disks when I remember. If something goes wrong so long as I
remember what the config files do it's not such a big deal to start 
again.

I suppose I should try to make it more formal


Only if you care about the data...

Tips for understood accepted wisdom appreciated, like is it better if 
want
to use a windows program have this Virtualization or reboot and change 
boot

order or just have it on another PC.


That would depend. Is it a bother to reboot? Do you have a spare
PC? Both of those are easier and potentially faster than
virtualizing an existing system.



And also practical method for backup
hardware as consumer hardware only seem to have room for 2 disks at 
most.


So you have four or more PCs around, and don't mind having
another. Get an older machine and put two shiny new spinning
disks in it. Have the Debian installer set it up as MDADM RAID-1
-- mirrors. Use backupninja on the three Linux machines and have
them store their data on the backup machine.


This looks like good advice, thanks Dan and all.
One thing I wonder about if I reboot and change boot order to start 
windows is if I might create some confusion on the network as pfsense PC 
does DHCP and that will think there are 2 PCs with the same MAC address 
?


mick

--
Key ID4BFEBB31



Re: Linux not seeing all SATA drives

2020-10-13 Thread mick crane

On 2020-10-13 16:39, Dennis Wicks wrote:

David Christensen wrote on 10/12/20 10:01 PM:

On 2020-10-12 19:19, Dennis Wicks wrote:
I have 3 SATA drives on my system. I replaced all my red cables with 
new black cables. The BIOS sees all of them but when linux finishes 
booting it only sees two of them. Do I have to do something to linux 
so it sees the third drive?


FYI, I have the system disk in sata-1, the drive on sata2 is not 
seen, but the drive on sata3 is seen and in use. The CD/DVD drive is 
on sata6 and is also seen.


Thanks for any and all help!
Dennis


Run the following commands as root.  If you need help interpreting the 
results, post your console session:


# lsblk

# fdisk -l

# mount | grep sd


David


Thanks for the tip, but none of those commands show the third disk, 
just two.

What might be /dev/sdc doesn't show up with any command I have tried.

Thanks!
Dennis


I'd look in dmesg for anything and swap the cables about from sata2 and 
sata3

mick
--
Key ID4BFEBB31



Re: PATH nfg after su

2020-10-23 Thread mick crane

On 2020-10-23 19:01, Dan Ritter wrote:


I first used Linux in 1992, 13 or 14 months after Linus started
writing it. sudo was already 12 years old.


"Where do you want to go today" did it for me but I had such a lot of 
trouble shifting head into gear. Never really managed.


--
Key ID4BFEBB31



Re: Replacement Email Client

2020-10-25 Thread mick crane

On 2020-10-26 00:07, Patrick Bartek wrote:
 I have Dillo configured NOT to show images initially. Do that for

security. Reloading page usually brings them up. It will follow some
links to other pages, but for viewing purposes only. One cannot
interact and transmit data as I need to.  I have to use a real browser
for that. And that means logging in through the browser to that
particular email account.


I think this is what is confusing people ( having to logon to gmail to 
see the HTML)
The email you receive has the text and the HTML stored as a file on your 
computer.

You organise the mail reader to process the HTML or not.
I don't know why everybody doesn't use Dovecot/Dovecot-sieve/roundcube 
=o)


mick

--
Key ID4BFEBB31



Re: getmail, getmail6, testing, unstable, python-is-python3

2020-10-27 Thread mick crane

On 2020-10-27 13:08, songbird wrote:

well, yesterday finally became the day when i tried to
see if i could get the old getmail to be left alone, but
nope, none of the options worked.

  the good news, is that getmail6 is in unstable and was
a drop in replacement for getmail.  there's a bit of an
odd message coming out of it but that's not an error and
everything is ending up where it should.

  during all of this fiddling i was wondering if the
python2 to python3 transition was complete enough that
i could run all my programs that i use and it all works
just fine.  so i installed python-is-python3 and the
system rebooted and none of things i use the most have
failed.  that's all i need from a system (browswer, e-mail,
usenet, gimp, go, libreoffice).  i've never done much
with python2 and the game i wrote was python3 so that's
all to the good.

  this was just a quick heads-up for those who are stuck
on getmail like i am (and quite happy with it).  :)



as far as getmail goes maintainer thinks is an unnecessary panic.

""getmail goes out of official support by my distro" may be a 
theoretical
problem, or a philosophical one, but it it certainly is not a 
significant
practical problem.  Keep a Python 2 binary around, download getmail, 
untar it,
and run it right out of the directory - that's literally all that's 
required."


what exactly the python 2 binary is I haven't had need to look as yet.

mick

--
Key ID4BFEBB31



Re: La Comisión Europea aprueba la nueva Estrategia de Software de Código Abierto 2020-2023

2020-10-27 Thread mick crane

On 2020-10-27 14:35, Kenneth Parker wrote:

Good article, about the European Commission embracing a "new Open 
Source
Software Strategy".  Being the European Union is awesome, simply 
because of

how big it is, of course.  I like their principle, "Think Open".


If the European Union say they want to "embrace" you I would run.

mick

--
Key ID4BFEBB31



Re: Replacement Email Client

2020-10-28 Thread mick crane

On 2020-10-28 08:35, to...@tuxteam.de wrote:


How did we end here? How did we end up paying for the ad
industry's infrastrutcture, paying with our privacy, but
also with our real money, having to buy RAM and CPU power
just for their sake?

How do we get out of here?


Good point.
Ad agencies have always pushed for doing more "clever" things.
The innovations in cinema were first made in the TV commercials.
But in that case the product manufacturer was paying.

mick
--
Key ID4BFEBB31



working with mp3 files

2020-10-29 Thread mick crane

hello,
I am totally clueless about audio files.
Have for example librivox recordings of "1984" split into a dozen files.
Would like to combine them together into one file with
ffmpeg join_together "files" some_options) out_file
presumably each file has meta data that I only need once ?
Anybody point to a book or resource for a numpty to discover how it 
works?


mick


--
Key ID4BFEBB31



Re: working with mp3 files

2020-10-29 Thread mick crane

On 2020-10-29 16:40, Nicolas George wrote:

ghe2001 (12020-10-29):
Yeah, but he's starting with mp3, so I don't know of a better way to 
do it.


The better way to do it is to avoid decoding then re-encoding.

How do you get rid of the metadata noise?  I've tried 'cating mp3s, 
and it didn't work very well at all.


You can just cut the file with any binary tool.

Or you can use the concat demuxer in ffmpeg.


Is it correct that the concat works with the file but the demux streams 
it first through audio device and records?
So that would be in the real time or does it speed it up or something 
for the recording ?


mick

--
Key ID4BFEBB31



Re: working with mp3 files

2020-10-30 Thread mick crane

On 2020-10-29 23:30, Nicolas George wrote:

mick crane (12020-10-29):
Is it correct that the concat works with the file but the demux 
streams it

first through audio device and records?


No, absolutely not. What on Earth could make you think that?!?


I'd so far only skimmed the documentation. I'm probably confused with 
what a "stream" is and also what is a "packet".


Thanks to all for the tips.


The concat demuxer works through each file, outputting packets in them
in order, while taking care of shifting the timestamps of the later
files according to the duration of the earlier. Nothing more.

Regards,



mick
--
Key ID4BFEBB31



Re: working with mp3 files

2020-10-30 Thread mick crane

On 2020-10-29 23:30, Nicolas George wrote:

mick crane (12020-10-29):
Is it correct that the concat works with the file but the demux 
streams it

first through audio device and records?


No, absolutely not. What on Earth could make you think that?!?

The concat demuxer works through each file, outputting packets in them
in order, while taking care of shifting the timestamps of the later
files according to the duration of the earlier. Nothing more.


I may be a little intoxicated so there may be irregularities in my 
posting but is it possible you could help me out understanding how a 
static file gets to be a stream ( of packets ) ?


mick
--
Key ID4BFEBB31



Re: Feasibility of speech recognition for note taking on dedicated laptop?

2020-11-06 Thread mick crane

On 2020-11-06 07:25, deloptes wrote:

Let me comment here my impressions. I studied speech processing and 
wrote my
thesis on dialog systems in 2007. Until about 2005 there were still 
some
open source tools like ViaVoice by IBM. Basically all of this was 
dropped
by 2010 - no idea why - might be something related to Google/Amazon, 
costs,

patents or whatever else.

In like 1980 or something noticed voice recognition chip in radio shack 
for not very much money.
Although curious at that time was, and still is, way, way beyond my 
understanding of what you might do with it.


mick
--
Key ID4BFEBB31



HDD for CCTV

2020-11-12 Thread mick crane

regarding earlier post with do not reply request.
There's loads of HDDs advertised as "for CCTV, like a PC disk"
Is there some difference between HDDs for video recording and regular PC 
HDDs ?


mick
--
Key ID4BFEBB31



Re: HDD for CCTV

2020-11-13 Thread mick crane

On 2020-11-13 08:11, Reco wrote:

Hi.

On Fri, Nov 13, 2020 at 07:56:24AM +, mick crane wrote:

regarding earlier post with do not reply request.
There's loads of HDDs advertised as "for CCTV, like a PC disk"
Is there some difference between HDDs for video recording and regular 
PC HDDs ?


Yup, a critical one.
Conventional HDD (aka CMR) it the thing that allows you to use it any
way you want.
New wave HDD (aka SMR) are OK if you use them to write a single
append-only file, and dangerously bad at anything else.

Stay away from those CCTV HDDs, things will eat your data - [1], [2],
[3].

Reco

[1] https://en.wikipedia.org/wiki/Shingled_magnetic_recording
[2] 
https://www.truenas.com/community/resources/list-of-known-smr-drives.141/
[3] 
https://www.tomshardware.com/news/wd-lists-all-drives-slower-smr-techNOLOGY



Cheers, likely saved me some grief there.
mick
--
Key ID4BFEBB31



Re: An old box running Debian 8

2020-11-13 Thread mick crane

On 2020-11-13 17:09, Dan Ritter wrote:
 On Fri, Nov 13, 2020, 9:20 AM Dan Ritter  wrote:


Something ate it. Weird. d...@randomstring.org is correct.


was sent to d...@randomstring.org
--
Key ID4BFEBB31



Re: color border in image, drop everything outside of it

2020-11-15 Thread mick crane

On 2020-11-15 09:38, to...@tuxteam.de wrote:

On Sun, Nov 15, 2020 at 12:31:22AM +0100, Emanuel Berg wrote:

Hello, is there a tool/command/script anywhere that can overwrite
with a single color (or make transparent) every pixel to the left,
above, right, and below a certain other color?

e.g., if one draws a loop of black, tell the program black is the
border, the result would be only what is within the loop?


Your request is a bit... unspecific.

Are you (a) after a tool which you use interactively, where you
actually see the image you described above, and where you can
click into that loop to start the operation?

Or is it (b) rather some kind or "batch mode", where you give the
program the image file *plus* the coordinates of that point inside
the loop where to start?

For ease of search, the operation you're describing is usually
called "flood fill". If you are after (a), your friend is The Gimp;
I guess Krita will fill that bill as well. If it's (b), the usual
standard is "mogrify", from the ImageMagick suite. Look at [1] for
the details on flood fill.

Getting warm with the ImageMagick programs takes a bit of practice,
but it's worth it. Come back if you get stuck.

Cheers
[1] https://imagemagick.org/script/command-line-options.php#floodfill
 - t


I needs to be scripted tho' if want the (x-1, x+1, y-1, y+1)s to be 
wants to be a particular value ?

mick


--
Key ID4BFEBB31



UEFI and legacy MBR

2020-11-21 Thread mick crane

hello,
I'm having a bit of bother trying to install windows and Bullseye on PC.
have 2x HDD and 1 SSD
PC bios has option UEFI or legacy menus
Only seemed to work if selected USB from legacy menu to install windows 
from USB stick on only connected HDD.
So then I connect the other drives and install bullseye on SSD from 
bullseye DVD 1, wanting to use other HDD for data.
Installer won't install desktop environment if I just select XFCE but is 
probably another matter.

Grub was complaining about mixing EFI with MBR disk.
I try to start again but if selecting UEFI menu in PC bios PC boots from 
windows installer USB stick but refuses to install on HDD that already 
has windows on it because it has MBR partition table.

How do I erase MBR from disk ?
I've done all this before but forgotten.
I guess boot from something linuxy and erase the partition table of 
offending disk with fdisk?
I'm concerned that there seems to be another layer of control ( MBR or 
EFI ) between OS and PC that's in the BIOS.


mick


--
Key ID4BFEBB31



Re: UEFI and legacy MBR

2020-11-21 Thread mick crane

On 2020-11-21 11:29, mick crane wrote:

hello,
I'm having a bit of bother trying to install windows and Bullseye on 
PC.


never mind it all seems to be working
mick

--
Key ID4BFEBB31



Re: Why use an email client AND sendmail/popa3d - Does this avoid the hijack?

2020-11-24 Thread mick crane

On 2020-11-23 12:19, Andrei POPESCU wrote:

On Lu, 23 nov 20, 14:27:36, Keith Bainbridge wrote:

So does htis get a new subject in the list?

Good afternon All

I was interested to read that Flo, the OP, uses separate mail
collection, sendmail and thunderbird. Some of the replies sound like
this is a common practice.

What are the advantages of this set of processes over letting tbird do
it all? - or any other client for that matter?


It makes it easier to switch between different e-mail clients if the
sending and/or receiving is handled externally, e.g. one might use a
graphical e-mail client in general and a text mode client occasionally.

Such a setup also typically uses standard locations for the storage (as
opposed to e-mail client specific), which makes it easier to add more
functionality (e.g. serve local e-mail via IMAP) or replace individual
components.


As I can make out if you try to do the useful stuff on your home network
like having Dovecot doing your mail it is really a bodge if you are not 
advertising those services on the internet.
I am I suppose in the domain of Sky who provide my wired connection so I 
use sky/yahoo SMTP server as part of service but they add to outgoing 
email "Reply-Path" being my Sky user account in the headers which seems 
to be confusing exim email lists and results in rejected or bounced 
emails recently.
I'd like to sort it out to avoid that if I knew what they were doing. I 
like things as they are when it is working and really, really don't want 
to go the whole hog of advertising email services. I think it is some 
relatively new thing where they are double authenticating or something 
but ideally I don't know why SMTP server does just pass message along 
and not add items to the header except they received it and passed it 
along to the recipient.


mick
--
Key ID4BFEBB31



Re: Why use an email client AND sendmail/popa3d - Does this avoid the hijack?

2020-11-26 Thread mick crane

On 2020-11-26 03:57, David Wright wrote:


What sort of rejections and/or bounces have you had?


It showed up that mails to getmail list that uses Exim were refused as 
unsubscribed whereas before was OK.
I "think" I then subscribed with noctiluc...@sky.com which worked for a 
bit but then from list to me bounced.

"Remote host said: 554 5.7.9 Message not accepted for policy reasons"
using Sky/Yahoo SMTP it seems to add "Return-Path:" as being 
noctiluc...@sky.com.
Then subscribed to getmail list "from" gmail and other hosted domain 
address

and welcomed as subscribed as "noctiluc...@sky.com".

I only know enough about this stuff to get it working and then promptly 
forget.

Unsure of the etiquette of using other SMTP servers.
This is all using local, not the newest, roundcube for reading/sending.

cheers mick
--
Key ID4BFEBB31



Re: Sharing files LINUX-LINUX / LINUX-WINDOWS / WINDOWS-WINDOWS

2020-11-28 Thread mick crane

On 2020-11-28 03:08, Kanito 73 wrote:

Hello

I have up and running two dual boot LINUX (Debian 10) and WINDOWS 10
machines and want to connect them to be able to work without spending
time copying files from/to on a usb device, have multiple copies of a
same file, etc.


You can use WinSCP to to and fro from the windows side using ssh with 
keys.

Can probably have a ssh server on Windows but never fancied that.

mick
--
Key ID4BFEBB31



exporting display like

2020-12-17 Thread mick crane

please bear in mind I don't know what I'm doing.
It is convenient to have the one display and keyboard/mouse
I sometimes if on windows use putty/Xming to start GUI program on other 
Debian PC.
Think I used screen before so can attach/detach from running terminal 
program but with X display program is it possible to first export to 
other machine then detach and come back to it later on other machine ?

There was VNC, is that the way to do that ?

mick
--
Key ID4BFEBB31



Re: exporting display like

2020-12-18 Thread mick crane

On 2020-12-17 23:11, Nicolas George wrote:

mick crane (12020-12-17):

please bear in mind I don't know what I'm doing.
It is convenient to have the one display and keyboard/mouse
I sometimes if on windows use putty/Xming to start GUI program on 
other

Debian PC.
Think I used screen before so can attach/detach from running terminal
program but with X display program is it possible to first export to 
other

machine then detach and come back to it later on other machine ?
There was VNC, is that the way to do that ?


xpra is probably the program you are looking for.


looks ideal, thanks

--
Key ID4BFEBB31



Re: Debian 10 64bit

2020-12-20 Thread mick crane

On 2020-12-19 20:04, David Wright wrote:
<...>

saying because I noticed that if you add yourself to sudo group in 
/etc/group you have to logout and log back in for it to be noticed.


mick
--
Key ID4BFEBB31



adding a disk to a Volume group

2020-12-20 Thread mick crane

hello,
It's a more or less new bullseye installation.
The installer kindly set up a Volume Group and added Logical Volumes of 
a couple of the partitions on the disk with the OS on it.

I want to add another disk to use for data.
Not had anything to do with LVM.
I'll want to make an extended partition of the whole disk first with 
fdisk.

but not sure the order I need to do things in after that.
Can see what VG is called with "vgdisplay"
will "vgextend my_VG /dev/sdx1"
sort out making the Physical Volume and the Logical Volume ?
I don't want to end up making 2 Volume Groups or something daft.
Is there any difference making the ext4 filesystem on the /dev/VG/LV or 
/dev/sdx1 ?


mick

--
Key ID4BFEBB31



Re: adding a disk to a Volume group

2020-12-20 Thread mick crane

On 2020-12-20 20:38, Charles Curley wrote:

On Sun, 20 Dec 2020 19:05:45 +
mick crane  wrote:


It's a more or less new bullseye installation.
The installer kindly set up a Volume Group and added Logical Volumes
of a couple of the partitions on the disk with the OS on it.
I want to add another disk to use for data.


A couple of thoughts here.

* Are you adding the new disk permanently or as removable media?

  If the latter, put a separate VG on it. Or don't bother. The reason I
  suggest this is if the new disk is removable, having the same VG span
  both disks may make the permanent disk unusable if the removable one
  is gone.

  If it is permanent, consider redoing both of them as a RAID level
  1, with encryption and LVM on top of that. Be sure to leave a boot
  partition on at least one of them.

* You said nothing about encryption. That may impact the order in which
  you do things.


From what I can gather there's not much point adding new disk to the LVM 
if I'm going to use the whole disk as one partition so I formatted it 
ext4 and mount it somewhere in my home directory.


The default netinstaller doesn't seem to make the boot partition big 
enough as with the vmlinux off the install media then vmlinux.old and 
new vmlinux the device was out of space if upgrade so had to remove the 
original kernel gubbins from the install media. At least that seems to 
be what happened.
I'll have to understand LVM at some point to see if I can make boot LV 
bigger.


mick

--
Key ID4BFEBB31



Re: adding a disk to a Volume group

2020-12-22 Thread mick crane

On 2020-12-22 21:04, Michael wrote:

On Tuesday, December 22, 2020 1:26:36 PM CET, elvis wrote:

The LVM howto is your friend


there are also plenty of man pages!

greetings...


You mean like RTFM or something ?
The man pages generally assume you know why you are reading them.
I've noticed a lot of documentation misses out the " You'll want to use 
this because.."


mick
--
Key ID4BFEBB31



Re: adding a disk to a Volume group

2020-12-22 Thread mick crane

On 2020-12-22 22:19, Michael wrote:

On Tuesday, December 22, 2020 10:58:14 PM CET, mick crane wrote:

You mean like RTFM or something ?


indeed, i had something like this in mind... ;)

agreed, the quality of man pages is not, what it used to be back in
the day, when i was young, but lvm is old, and hence the man pages
provide more useful information than some new wannabe fancy software.

just take some time to read all relevant man pages, and even if they
turn out not to be relevant: you might learn a thing or two.

learn! that's my advice to everyone, not just you. copy and paste is
NOT the answer! at least not, if you want to understand what you're
doing.

a quick look at the man pages got me this:
- pvcreate  to add a partition to a pool of physical volumes
- vgextend   to add a physical device
to a volume group
- lvextend [options]  [] to extend the
size of a logical volume

that was not so hard.


I have only skimmed reading the fine manual and other things but I'm 
guessing that if the partition is full I'll either need to make it 
bigger or make another one before invoking LVM?


greetings...


--
Key ID4BFEBB31



transfer speed data

2020-12-22 Thread mick crane

hello,
I have a buster PC and a bullseye PC which are both supposed to have 
gigabyte network cards connected via a little Gigabyte switch box.
Transferring files between them, I forget which shows the transfer speed 
per file, either scp or rsync the maximum is 50 Mbs per file.

Would you expect that to be quicker ?

mick

--
Key ID4BFEBB31



Re: adding a disk to a Volume group

2020-12-22 Thread mick crane

On 2020-12-23 03:37, Andy Smith wrote:
<..>

e.g. if you install a drive and it shows up in your OS as /dev/foo
of size 1TB, then:

# pvcreate /dev/foo
# vgcreate myvg /dev/foo

Now you have a volume group called "myvg" with ~1TB (some space
reserved for metadata) available for allocation.


This might be where I have gotten confused as online tutorial indicates 
to fdisk the disk first in partitions.
Make physical volumes of the partitions then create a volume group of 
the partitions.

You are saying that there is no need to use fdisk to make partitions ?
Can make Volume Group of raw device eg /dev/sdc after first saying it is 
a Physical Volume ?


mick

--
Key ID4BFEBB31



Re: mdadm usage

2020-12-29 Thread mick crane

On 2020-12-29 13:10, Andy Smith wrote:
<..>

The default metadata format (v1.2) for mdadm is at the beginning of
the device. If you've put a filesystem directly on the md device
then the presence of the metadata will prevent it being recognised
as a simple filesystem. What you can do is force mdadm to import it
as a degraded RAID-1.

<..>
I've puzzled about this. Are you supposed to have 3 disks ?
One for the OS and the other 2 for the raid1 ?

mick


--
Key ID4BFEBB31



Re: mdadm usage

2020-12-30 Thread mick crane

On 2020-12-30 13:38, Andy Smith wrote:

Hi Mick,

On Tue, Dec 29, 2020 at 03:32:07PM +, mick crane wrote:

On 2020-12-29 13:10, Andy Smith wrote:
>The default metadata format (v1.2) for mdadm is at the beginning of
>the device. If you've put a filesystem directly on the md device
>then the presence of the metadata will prevent it being recognised
>as a simple filesystem. What you can do is force mdadm to import it
>as a degraded RAID-1.
<..>
I've puzzled about this. Are you supposed to have 3 disks ?
One for the OS and the other 2 for the raid1 ?


It's unclear to me how what you have quoted relates to your
subsequent question. Can you elaborate on what the location of mdadm
metadata has to do with whether one puts the operating system on a
RAID-1 device or not?

I expect that most people using RAID put their OS into the RAID as
well. I certainly do. I don't understand your mental separation of
"OS" and "RAID-1" or why it might mandate 3 devices. It is perfectly
straightforward to put a single partition¹ on each of two devices,
RAID-1 them together and use it as root filesystem and that's it.

Probably we are just misunderstanding each other and there is a
question here that I haven't understood.


I just confused myself. Initially I read somewhere that to make the raid 
first copy the OS from one disk to another.
Just struggling to get a picture of what happens, if what's on one disk 
gets copied to the other or if they are written to simultaneously.
I always understood that you can't duplicate one disk to another with 
itself being the OS.

It'll be the way the software raid does it. I should probably read more.

mick

--
Key ID4BFEBB31



Totally on topic

2020-12-31 Thread mick crane
Happy New Year to all concerned and thanks for the handy tips and 
information on Debian users in 2020


mick
--
Key ID4BFEBB31



Re: sharing a network connection from debian to non-debian

2021-01-15 Thread mick crane

On 2021-01-16 05:02, Dan Hitt wrote:
In 2016, i had a computer with mint on it (which is a form of ubuntu), 
and
it was connected to an internet modem.  There was a super simple gui on 
it

that i could use to share that connection with some older hardware that
were not directly connected to the internet modem.  (They were not
connected to the internet modem because for whatever reason, directly
connecting them made them very unstable and prone to crash.)  But,
nevertheless, the old hardware could use the mint box with no 
configuration

on my part, and get out to the internet through it.

Now, as it happens, i'm planning on upgrading that mint box to debian.

In preparation for that, i'm trying to share the internet with them 
using
another box, which has debian on it, and which is connected to the 
internet
modem.  The debian box has some address like 192.168.*.* on the 
internet
modem network, and an address like 10.*.*.* connected to the old 
hardware,
and the two networks have no direct connection, they just both hook up 
to

my debian machine (one on the motherboard's ethernet, and one on a
usb/ethernet device).

For the old hardware, i can specify the address, a gateway, and a host 
for
dns (all done by ip).  I would choose the ip of the debian box for both 
the

gateway and the dns, and i'd take the ip address of the old hardware to
just be something unused (no need to run dhcpd on the debian box, i 
think).


So i just need to know what to do on the debian box so that it can 
field
requests to get ips from host names on the internet, and forward 
packets to

the internet modem.  Hopefully, it will be some simple tool like
nm-connection-editor, but maybe it has to be a series of commands.  If 
it

is a series of commands, what are they?

TIA for any info!

dan


Bearing in mind I know little of what I speak I'd advise anybody to get 
a dedicated firewall/router between the local network and the internet. 
You can get a smallish PC for £20 which seems suitable with a minimum of 
2 network cards or 4
I like pfsense which works with not much configuration and has lots of 
services and logging available if you want them.


red -> ISP router
green -> local network
blue -> wireless can access internet but not local network
orange -> demilitarized zone

mick
--
Key ID4BFEBB31



One network card many rj45 sockets

2021-01-19 Thread mick crane

hello,
I see that you can get a single network card with 2, 3, 4 connections.
Can you happily make each one on a separate private address block ?
10.0.0.0, 172.16.0.0, 192.168.0.0

mick

--
Key ID4BFEBB31



Re: One network card many rj45 sockets

2021-01-19 Thread mick crane

On 2021-01-19 14:22, Dan Ritter wrote:

mick crane wrote:

hello,
I see that you can get a single network card with 2, 3, 4 connections.
Can you happily make each one on a separate private address block ?
10.0.0.0, 172.16.0.0, 192.168.0.0


My firewall (yes, it runs Debian) has an Intel 4x 1gig ethernet
card in it, as well as the 1 gig port on the motherboard. Each
is completely independent, so I have:

- one connection to the public Internet
- one connection to my switched network of wifi access points
- one connection to my general wired network switch
- one connection to my remote power switch
- and a free connection for the future.

Each of these has one or more different IP addresses, including
IPv6 on three ports, and packets are routed between them and
blocked by the firewall.

-dsr-


What is the purpose of remote power switch ?

mick

--
Key ID4BFEBB31



Re: One network card many rj45 sockets

2021-01-19 Thread mick crane

On 2021-01-19 15:06, Andy Smith wrote:

Hi Mick,

On Tue, Jan 19, 2021 at 12:47:34PM +, mick crane wrote:

I see that you can get a single network card with 2, 3, 4 connections.
Can you happily make each one on a separate private address block ?
10.0.0.0, 172.16.0.0, 192.168.0.0


There is no strong connection between the concept of a physical port
and the logical addresses you put on an interface associated with.
You can create a virtual network interface in a machine with no
network hardware at all, and put a billion different IPv6 networks
on it if you like!

Cheers,
Andy


But presumably at the end it would have to go to one addressable thing ?
Which would be the only point doing networking ?

mick
--
Key ID4BFEBB31



Re: Too many levels of symbolic links

2021-01-20 Thread mick crane

On 2021-01-20 08:40, steve wrote:

Question. What does the following mean?

# find /dev -follow -printf ""
find: '/dev/fd/4': No such file or directory


I don't know but they look to be symlinks that get created to pseudo 
terminals /dev/pts/0 by eg ssh, telnet.

Maybe a session crashed and left the symlink in place ?
https://unix.stackexchange.com/questions/93531/what-is-stored-in-dev-pts-files-and-can-we-open-them

mick


--
Key ID4BFEBB31



Raid 1

2021-01-22 Thread mick crane

hello,
I want to tidy things up as suggested.
Have one old PC that I'll put 2 disks in and tidy everything up so 
what's scattered about is on the running disks and this new/old one is 
just backup for them.
Can I assume that Debian installer in some expert mode will sort out the 
raid or do I need to install to one disk and then mirror it manually 
before invoking the raid thing ?


mick

--
Key ID4BFEBB31



Re: Raid 1

2021-01-23 Thread mick crane

On 2021-01-23 12:20, Andrei POPESCU wrote:

On Vi, 22 ian 21, 22:26:46, mick crane wrote:

hello,
I want to tidy things up as suggested.
Have one old PC that I'll put 2 disks in and tidy everything up so 
what's
scattered about is on the running disks and this new/old one is just 
backup

for them.
Can I assume that Debian installer in some expert mode will sort out 
the
raid or do I need to install to one disk and then mirror it manually 
before

invoking the raid thing ?


The "raid thing" is a separate layer below the partitions and file
systems.

Technically it is possible to create the mirror with just one device (I
believe mdadm calls this "degraded"), partition the md mirror device,
install, copy data to it, etc., add the second device later and let md
synchronize the two drives.

Because Linux RAID is a separate layer with no knowledge of the data
"above" it has to copy every single bit to the other drive as well
(similar to a dd device-to-device copy), regardless if actually needed
or not.

If you are really strapped for space and must do this ZFS can do it 
much

more efficiently, because it controls the entire "stack" and knows
exactly which blocks to copy (besides many other advantages over Linux
RAID).

Unfortunately ZFS is slightly more complicated from the packaging side,
and installing Debian on a ZFS root is difficult.

It still makes an excelent choice to manage your storage drives,
especially on a stable system, where there is less hassle with the dkms
module and it's amazingly simple to use once you familiarise yourself
with the basics.

Kind regards,
Andrei


Sigh, OK I take advice and have a go.
Really I just want to get on and do some drawings or something but I 
think I'll thank myself later if I get proper backup in place.

If after having a quick look am I understanding anything?
Partition and install minimal Debian with no X or anything on just one 
disk.

install headers and zfs-utils.
Add other disk and then what ? To make it a mirror pool (like raid1) 
does zfs take care of the partitions.
Do I want to delete all partitions on other disk first or make like for 
like partitions?


If that's done and I've made a zpool called  "backup" from then on the 
ZFS is nothing to do with the kernel ?

I ask kernel make a directory "my_pc1"
then
"zfs create -o mountpoint=/my_pc1 backup/my_pc1"

I ask kernel make a directory "my_pc2"
then
"zfs create -o mountpoint=/my_pc2 backup/my_pc2"

So then I can copy files from other PC (pc1) to 
"my_backup_pc/backup/my_pc1" and ZFS mirrors the data to other disk in 
pool ?


If that's how it works I'll just need something on the backup_pc and the 
other PCs to automate the backing up.

Is that backup Ninja or something ?

mick


--
Key ID4BFEBB31



Re: Raid 1

2021-01-23 Thread mick crane

On 2021-01-23 17:11, Linux-Fan wrote:

mick crane writes:


On 2021-01-23 12:20, Andrei POPESCU wrote:

On Vi, 22 ian 21, 22:26:46, mick crane wrote:

hello,
I want to tidy things up as suggested.
Have one old PC that I'll put 2 disks in and tidy everything up so 
what's
scattered about is on the running disks and this new/old one is just 
backup

for them.
Can I assume that Debian installer in some expert mode will sort out 
the
raid or do I need to install to one disk and then mirror it manually 
before

invoking the raid thing ?


[...]


Sigh, OK I take advice and have a go.
Really I just want to get on and do some drawings or something but I 
think I'll thank myself later if I get proper backup in place.

If after having a quick look am I understanding anything?
Partition and install minimal Debian with no X or anything on just one 
disk.

install headers and zfs-utils.
Add other disk and then what ? To make it a mirror pool (like raid1) 
does zfs take care of the partitions.
Do I want to delete all partitions on other disk first or make like 
for like partitions?


If I get your scenario correctly you want to install Debian (without
ZFS i.e. not "root on ZFS") and then create a ZFS mirror?

If yes, then as a preparation you need either (a) two entire devices
of ~ same size to use with ZFS or (b) two partitions to use with ZFS.

Say you install as follows:

* sda1: OS
* sda2: Swap
* sda : XX GiB free

* sdb: XX+ Gib free

Then prepare two unformatted partitions:

* sda3: XX GiB "for ZFS"
* sdb1: XX GiB "for ZFS"

and use these devices for ZFS.

If that's done and I've made a zpool called  "backup" from then on the 
ZFS is nothing to do with the kernel ?

I ask kernel make a directory "my_pc1"
then
"zfs create -o mountpoint=/my_pc1 backup/my_pc1"


You can specifiy a mountpoint and it will be created automatically. No
need to pre-create the Directory as with other file systems.


I ask kernel make a directory "my_pc2"
then
"zfs create -o mountpoint=/my_pc2 backup/my_pc2"

So then I can copy files from other PC (pc1) to 
"my_backup_pc/backup/my_pc1" and ZFS mirrors the data to other disk in 
pool ?


Yes. In case you are unsure check the output of `zpool status` to see
the structure as understood by ZFS.

If that's how it works I'll just need something on the backup_pc and 
the other PCs to automate the backing up.

Is that backup Ninja or something ?


I have never used backup Ninja. Depending on your use case anything
from simple rsync to borgbackup may serve :)

Please note that "root on ZFS" is possible but quite complicated:
https://openzfs.github.io/openzfs-docs/Getting%20Started/Debian/Debian%20Buster%20Root%20on%20ZFS.html

For my current system I actually used mdadm RAID 1 for OS+Swap and ZFS
mirrors for the actual data. This way, I can use the Debian Installer
for installation purposes and benefit from the bit rot protection for
the acutally important data while maintaining basic redundancy for the
OS installation. YMMV.

Here are my notes on essential ZFS commands (in case they might be of 
help):

https://masysma.lima-city.de/37/zfs_commands_shortref.xhtml

HTH
Linux-Fan

öö


link is not currently available.
what you seem to be doing there is backing up the data with ZFS but not 
backing up the OS, so I guess your raid is the backup for the OS ?

mick


--
Key ID4BFEBB31



Re: Raid 1

2021-01-24 Thread mick crane

On 2021-01-23 22:01, David Christensen wrote:

On 2021-01-23 07:01, mick crane wrote:

On 2021-01-23 12:20, Andrei POPESCU wrote:

On Vi, 22 ian 21, 22:26:46, mick crane wrote:

hello,
I want to tidy things up as suggested.
Have one old PC that I'll put 2 disks in and tidy everything up so 
what's
scattered about is on the running disks and this new/old one is just 
backup

for them.
Can I assume that Debian installer in some expert mode will sort out 
the
raid or do I need to install to one disk and then mirror it manually 
before

invoking the raid thing ?


The "raid thing" is a separate layer below the partitions and file
systems.

Technically it is possible to create the mirror with just one device 
(I

believe mdadm calls this "degraded"), partition the md mirror device,
install, copy data to it, etc., add the second device later and let 
md

synchronize the two drives.

Because Linux RAID is a separate layer with no knowledge of the data
"above" it has to copy every single bit to the other drive as well
(similar to a dd device-to-device copy), regardless if actually 
needed

or not.

If you are really strapped for space and must do this ZFS can do it 
much

more efficiently, because it controls the entire "stack" and knows
exactly which blocks to copy (besides many other advantages over 
Linux

RAID).

Unfortunately ZFS is slightly more complicated from the packaging 
side,

and installing Debian on a ZFS root is difficult.

It still makes an excelent choice to manage your storage drives,
especially on a stable system, where there is less hassle with the 
dkms

module and it's amazingly simple to use once you familiarise yourself
with the basics.

Kind regards,
Andrei


Sigh, OK I take advice and have a go.
Really I just want to get on and do some drawings or something but I 
think I'll thank myself later if I get proper backup in place.

If after having a quick look am I understanding anything?
Partition and install minimal Debian with no X or anything on just one 
disk.

install headers and zfs-utils.
Add other disk and then what ? To make it a mirror pool (like raid1) 
does zfs take care of the partitions.
Do I want to delete all partitions on other disk first or make like 
for like partitions?


If that's done and I've made a zpool called  "backup" from then on the 
ZFS is nothing to do with the kernel ?

I ask kernel make a directory "my_pc1"
then
"zfs create -o mountpoint=/my_pc1 backup/my_pc1"

I ask kernel make a directory "my_pc2"
then
"zfs create -o mountpoint=/my_pc2 backup/my_pc2"

So then I can copy files from other PC (pc1) to 
"my_backup_pc/backup/my_pc1" and ZFS mirrors the data to other disk in 
pool ?


If that's how it works I'll just need something on the backup_pc and 
the other PCs to automate the backing up.

Is that backup Ninja or something ?



RAID protects against storage device sectors going bad and against
entire storage devices going bad -- e.g. hard disk drives, solid state
drives, etc..


Backups protect against filesystem contents going bad -- e.g. files,
directories, metadata, etc..


While putting an operating system and backups within a single RAID can
be done, this will complicate creation of a ZFS pool and will
complicate disaster preparedness/ recovery procedures.  The following
instructions assume your OS is on one device and that you will
dedicate two HDD's to ZFS.


See "Creating a Mirrored Storage Pool":

https://docs.oracle.com/cd/E19253-01/819-5461/gaynr/index.html


The above URL is good for concepts, but the virtual device names
('c1d0', 'c2d0') are for Solaris.  For Debian, you will want to
zero-fill both HDD's with dd(1) and then create the pool with zpool(8)
using device identity nodes:

/dev/disk/by-id/ata-...


Be extremely careful that you specify the correct devices!


ZFS will mark the drives and create a ZFS pool named 'tank' mounted at
'/tank'.  Note the parallel namespaces -- 'tank'is ZFS namespace and
has no leading slash, while '/tank' is a Unix absolute path.


'/tank' is a ZFS filesystem that can do everything a normal Unix
directory can do.  So, you could create a directory for backups and
create directories for specific machines:

# mkdir /tank/backup

# mkdir /tank/backup/pc1

# mkdir /tank/backup/pc2


Or, you could create a ZFS filesystem for backups and create ZFS
filesystems for specific machines:

# zfs create tank/backup

# zfs create tank/backup/pc1

# zfs create tank/backup/pc2


Both will give you directories that you can put your backups into
using whatever tools you choose, but the latter will give you
additional ZFS capabilities.


David


I know I'm a bit thick about these things, what I'm blocked about is 
where is the OS.

Let's say I have one PC and 2 unpartitioned disk

Re: Raid 1

2021-01-24 Thread mick crane

On 2021-01-24 17:37, Andrei POPESCU wrote:

On Du, 24 ian 21, 11:36:09, mick crane wrote:


I know I'm a bit thick about these things, what I'm blocked about is 
where

is the OS.
Let's say I have one PC and 2 unpartitioned disks.
Put one disk in PC and install Debian on it.


Ok


Install headers and ZFS-utils.
I put other disk in PC, PC boots from first disk.


Ok.


"zpool create tank mirror disk1 disk2"


This will destroy all data already existing on disk1 and disk2 (though 
I
strongly suspect zpool will simply refuse to use disk1). Same with 
Linux

RAID.

Creating the RAID (Linux or ZFS) will overwrite any data already
existing on the disks / partitions used for the RAID.

If you want to have the OS on RAID it's probably easiest to let the
installer configure that for you. This implies *both* disks are
available during install (unless the installer can create a "degraded"
RAID).

Installing Debian on ZFS involves manual steps anyway, so it's 
basically
create the pool with just one disk, install Debian and then 'attach' 
the

other disk to the first one.

If you want to combine Linux RAID and ZFS on just two drives you could
partition the drives (e.g. two partitions on each drive), use the first
partition on each drive for Linux RAID, install Debian (others will 
have
to confirm whether the installer supports creating RAID from 
partitions)

and then use the other partitions for the ZFS pool.

You might want to experiment with this in a VM first. For testing
purposes you can also experiment with ZFS on files instead of real
devices / partitions (probably with Linux RAID as well).

Kind regards,
Andrei


This is my problem "where is the OS to be running the ZFS to put Debian 
on ?"
All I want to do is back up PCs to another and have that have redundancy 
with 2 disks so if one gets borked I can still use the other and put 
things back together.

How do I do that ?
mick
--
Key ID4BFEBB31



Re: Raid 1

2021-01-24 Thread mick crane

On 2021-01-24 20:10, David Christensen wrote:

On 2021-01-24 03:36, mick crane wrote:


Let's say I have one PC and 2 unpartitioned disks.


Please tell us why you must put the OS and the backup images on the
same RAID mirror of two HDD's, and why you cannot add one (or two?)
more devices for the OS.


David


I think I'll go with the first and last suggestion to just have 2 disks 
in raid1.
It seems that properly you'd want 2 disks in raid for the OS, 2 at least 
for the pool and maybe 1 for the cache.

Don't have anything big enough I could put 5 disks in.
I could probably get 3 disks in. Install the OS on one and then dd that 
to another and put that in a drawer and have another 2 disks as the zfs 
pool. I might have a fiddle about and see what goes on.


mick
--
Key ID4BFEBB31



rsync to NAS for backup

2021-02-13 Thread mick crane

I made a mistake and instead of getting a PC for backup I got a NAS.
I'm struggling to get to grips with it.
If rsync from PC to NAS NAS changes the owner/group of files to me/users 
which is probably no good for backing up.

There's that problem then another that it won't let me login as root.
I asked on Synology forum but not getting a lot of joy.
https://community.synology.com/enu/forum/1/post/141137
Anybody used these things can advise ?

mick

--
Key ID4BFEBB31



Re: rsync to NAS for backup

2021-02-15 Thread mick crane

On 2021-02-13 19:20, David Christensen wrote:

On 2021-02-13 01:27, mick crane wrote:

I made a mistake and instead of getting a PC for backup I got a NAS.
I'm struggling to get to grips with it.
If rsync from PC to NAS NAS changes the owner/group of files to 
me/users which is probably no good for backing up.

There's that problem then another that it won't let me login as root.
I asked on Synology forum but not getting a lot of joy.
https://community.synology.com/enu/forum/1/post/141137
Anybody used these things can advise ?


What is the model of the Synology NAS?  What options -- CPU, memory,
disks, bays, interfaces, PSU, whatever?  Support page URL?


Reading the forum post, it sounds like you damaged the sudoers file.
The fix would appear to be doing a Mode 2 reset per Synology's
instructions:

https://www.synology.com/en-global/knowledgebase/DSM/tutorial/General_Setup/How_to_reset_my_Synology_NAS


Once the NAS has been reset, figure out how to meet your needs within
the framework provided by Synology.  Follow the User Guide.  Follow
the Admin Guide.  Do not mess around "under the hood" with a terminal
and sudo.  Make Synology earn your money.


But if you want complete control, buy or build an x86_64/amd64 server,
install Debian, and have at it.




thanks for advices folks.
It was indeed user error with being in a rush and blurred eyesight 
mistook "%" for "#"

We are making progress.
Appears that to retain permissions need root at both ends of rsync.
Have keys working with ssh for users to NAS ( not helped by default 
permissions for .ssh files being wrong) and can su to root so now need 
to get ssh working with keys with no passphrase for root and all should 
be good.


mick


--
Key ID4BFEBB31



Re: awstats, how to see in a browser?

2021-02-16 Thread mick crane

On 2021-02-16 09:28, Gene Heskett wrote:

Greetings all;

I finally got around to changing awstats.conf to look at the httpd logs
since the apache2 logs haven't been used in a while, but 2 changes in
browsers has lost the localhost link to see what it is spitting out.

Does anyone recall the address to send a browser to?


nmap to see what port is listening on ?

mick

--
Key ID4BFEBB31



Re: identifying my LInux machine on my LAN

2021-02-16 Thread mick crane

On 2021-02-16 16:49, Paul Scott wrote:

My LAN used to have 1 or two computers and/or debices and my Debian
Linux machine on it.  I used to be able to log in either on the LAN
from my wife's Windows computer or from outside the LAN with my Debian
laptop with ssh or Windows machines on which I had installed putty or
Bitvise.

I have dynamic DNS hosted by Dyn and I use ddclient.

I currently use DHCP for my Debian machine and have also attempted to
connect with its local IP from the Windows machine on the LAN.

Now all methods fail.

I don't remember if attachments are allowed but I will attach one
example of a failure as I possible clue.

TIA for any help,



vaugely related windows' hosts file is.
C:\Windows\System32\drivers\etc\hosts
mick

--
Key ID4BFEBB31



Re: rsync to NAS for backup

2021-02-18 Thread mick crane

On 2021-02-15 12:39, mick crane wrote:

On 2021-02-13 19:20, David Christensen wrote:

On 2021-02-13 01:27, mick crane wrote:

I made a mistake and instead of getting a PC for backup I got a NAS.
I'm struggling to get to grips with it.
If rsync from PC to NAS NAS changes the owner/group of files to 
me/users which is probably no good for backing up.

There's that problem then another that it won't let me login as root.
I asked on Synology forum but not getting a lot of joy.
https://community.synology.com/enu/forum/1/post/141137
Anybody used these things can advise ?


What is the model of the Synology NAS?  What options -- CPU, memory,
disks, bays, interfaces, PSU, whatever?  Support page URL?


Reading the forum post, it sounds like you damaged the sudoers file.
The fix would appear to be doing a Mode 2 reset per Synology's
instructions:

https://www.synology.com/en-global/knowledgebase/DSM/tutorial/General_Setup/How_to_reset_my_Synology_NAS


Once the NAS has been reset, figure out how to meet your needs within
the framework provided by Synology.  Follow the User Guide.  Follow
the Admin Guide.  Do not mess around "under the hood" with a terminal
and sudo.  Make Synology earn your money.


But if you want complete control, buy or build an x86_64/amd64 server,
install Debian, and have at it.




thanks for advices folks.
It was indeed user error with being in a rush and blurred eyesight
mistook "%" for "#"
We are making progress.
Appears that to retain permissions need root at both ends of rsync.
Have keys working with ssh for users to NAS ( not helped by default
permissions for .ssh files being wrong) and can su to root so now need
to get ssh working with keys with no passphrase for root and all
should be good.


further to this if it helps anybody can start sshd with -d switch and at 
same time do client with -vv switch then can see where is falling down. 
Having telnet available helps if break sshd_config can still telnet and 
mend it.

mick

--
Key ID4BFEBB31



Re: rsync to NAS for backup

2021-02-18 Thread mick crane

On 2021-02-18 16:13, Gary Dale wrote:

On 2021-02-18 10:57, mick crane wrote:

On 2021-02-15 12:39, mick crane wrote:

On 2021-02-13 19:20, David Christensen wrote:

On 2021-02-13 01:27, mick crane wrote:
I made a mistake and instead of getting a PC for backup I got a 
NAS.

I'm struggling to get to grips with it.
If rsync from PC to NAS NAS changes the owner/group of files to 
me/users which is probably no good for backing up.
There's that problem then another that it won't let me login as 
root.

I asked on Synology forum but not getting a lot of joy.
https://community.synology.com/enu/forum/1/post/141137
Anybody used these things can advise ?


What is the model of the Synology NAS?  What options -- CPU, memory,
disks, bays, interfaces, PSU, whatever?  Support page URL?


Reading the forum post, it sounds like you damaged the sudoers file.
The fix would appear to be doing a Mode 2 reset per Synology's
instructions:

https://www.synology.com/en-global/knowledgebase/DSM/tutorial/General_Setup/How_to_reset_my_Synology_NAS 
Once the NAS has been reset, figure out how to meet your needs 
within

the framework provided by Synology.  Follow the User Guide. Follow
the Admin Guide.  Do not mess around "under the hood" with a 
terminal

and sudo.  Make Synology earn your money.


But if you want complete control, buy or build an x86_64/amd64 
server,

install Debian, and have at it.




thanks for advices folks.
It was indeed user error with being in a rush and blurred eyesight
mistook "%" for "#"
We are making progress.
Appears that to retain permissions need root at both ends of rsync.
Have keys working with ssh for users to NAS ( not helped by default
permissions for .ssh files being wrong) and can su to root so now 
need

to get ssh working with keys with no passphrase for root and all
should be good.


further to this if it helps anybody can start sshd with -d switch and 
at same time do client with -vv switch then can see where is falling 
down. Having telnet available helps if break sshd_config can still 
telnet and mend it.

mick


rsync is a quick & dirty backup tactic but it's got limitations.

1) files may stay around forever in the backup even if you've deleted
them from your main computer because you don't need them.

2) you only have one copy of a file and that only lasts until the next
rsync. This limits your ability to restore from a backup before it is
overwritten.


Using a real backup program, which can run on you main computer to
backup to the NAS, lets you define a retention policy so files no
longer needed can be purged while you have multiple backups of files
you are currently working on.

rsync is not a good substitute for backups.


OK, I didn't do this before.
Am I right in thinking that BackupNinja keeps a local directory with 
list of files that need to be backed up and then rsyncs those files to 
remote directory ?

mick

--
Key ID4BFEBB31



Re: need to run the windows version of cura for amd64

2021-02-25 Thread mick crane

On 2021-02-25 19:50, Gene Heskett wrote:

Greetings all;

I may have made a mistake, but I bought a dremel digilab 3d45 FDM
printer, aka a 3d printer. A better printer in the medium priced
category at a bit over $1800 from Amazon.

I have the appimage of cura but that version has no knowledge of this
printer, so it abuses it very noisily. The two major diffs are that the
dremel apparently considers the right rear of the plate as home, 
whereas

the ender3 I also have uses the left front corner as home.

They have an adapted version of cura for a free download, but only in
Win64 and mac os versions, no appimages in sight.

So, what is the best winderz emulator we have, to run this:

Dremel3DSlicer-1.2.3-win64.exe

Which file says is a:

Dremel3DSlicer-1.2.3-win64.exe: PE32 executable (GUI) Intel 80386, for 
MS

Windows, Nullsoft Installer self-extracting archive

I have no experience wrangling wine or whatever.



If it were me I'd get a Dell with a win10 pro licence sticker, and 
download the windows installer.
You can select not to install the "helpful" stuff and there's 
destructions on the net for disabling Cortina and the like with Group 
Policy editor or something. Might be simplest in the long run.


mick



--
Key ID4BFEBB31



Re: need to reinstall pulseaudio every day

2021-02-28 Thread mick crane

On 2021-02-28 11:31, Pierre Frenkiel wrote:

On Tue, 23 Feb 2021, David Wright wrote:


Is this buster?

  yes


Are you running any applications, particularly those involving sound,
as root, particularly in response to some previous problem?

  no


Is it just that binary that goes missing, or does apt/dpkg actually
show that the entire package is uninstalled?

The pulseaudio package contains about 216 files. Have they all gone,
or just the one binary? (Run   $ dpkg -L pulseaudio   to list them.)


  I can answer today, as /usr/bin/pulseaudio was not there this 
morning:
  It's the only missing files. All  other files of the package are 
still there.
  I'll enable again my monitoring every minute, hoping that observing a 
process

  will not modify it, as in quantum physics.

best regards,


That is a bit weird. Is it an actual file and not a link ?
mick
--
Key ID4BFEBB31



Re: Non-free firmware [was: Debian install Question]

2021-03-02 Thread mick crane

On 2021-03-02 23:29, Brian wrote:

On Tue 02 Mar 2021 at 16:19:45 -0500, rhkra...@gmail.com wrote:


On Tuesday, March 02, 2021 02:55:08 PM Brian wrote:
> On Mon 01 Mar 2021 at 08:13:13 -0500, rhkra...@gmail.com wrote:
> > On Sunday, February 28, 2021 12:03:31 PM Celejar wrote:
> > > "Many wireless network cards (and even some wired ones) require
> > > non-free firmware to function properly. This firmware is not included
> > > in the standard installation images, due to Debian's free software
> > > ideals. If the network hardware your installation will rely upon
> > > requires such firmware, you may consider using the alternate non-free
> > > installation images available here."
> >
> > +1
>
> "+1" for what? Advertising each and every non-Debian installer that
> comes along and is uploaded to unofficial?

No.  Providing a reasonable explanatory text about why some other 
installer

may be required and a link to a place where you can find one or more.


My installer is aimed at users with an adapter that uses the p54usb
driver. It requires firmware that needs to be extracted from the device
and there aren't any such files in the non-free archive. I imagine 
there

are other similar devices.

I can easlily provide explanatory text about why my installer is needed
and why it would benefit users. Would it be ok to have it in unofficial
as a non-Debian installer?

Just a thought!


The suggestion somebody made of having a tethered phone plugged into USB 
in case non-free drivers are required for network after installation 
seemed like a good one.


mick

--
Key ID4BFEBB31



Re: Trusting trust [was: PARTIAL DIAGNOSIS of Installation problems]

2021-03-04 Thread mick crane

On 2021-03-04 09:41, Joe wrote:


Of course. Any externally-supplied network device is inherently
untrusted. It is unwise to give any IoT device access to your network,
it is fail-safe to assume that every such device reports back as much
as possible to some Chinese company.


Most certainly. The Wifi for the CCTV I purchased would only function 
through a far eastern server.

Why would they do that ?

mick

--
Key ID4BFEBB31



using git locally

2019-05-17 Thread mick crane

hello,
Because I am always making mistakes I thought, if it's not too hard, to 
see about using git locally.

I made a git repository for project following destructions
https://www.digitalocean.com/community/tutorials/how-to-use-git-effectively
but I'm having bother accessing it remotely.
I can ssh from one pc to another using keys with key phrase.
"ssh mick@server"
but
"git remote add origin ssh://mick@server/home/mick/git/camera"
and many variations I get.
fatal: not a git repository (or any of the parent directories): .git
I'm not really understanding the difference between "ssh" and "ssh://" 
except "ssh" works in terminal and "ssh://" doesn't.
Is it ssh:// that is wrong or I've failed to get the syntax right for 
git ?

mick
--
Key ID4BFEBB31



Re: using git locally

2019-05-17 Thread mick crane

On 2019-05-17 14:56, Greg Wooledge wrote:



If you really *did* create a git repository on a remote server, and
you want to clone it onto your local PC, you use a "git clone" command.

Something like:  git clone my.server:/whatever.git


well that seems to work
"git clone myserver:/path_to_git_repository"
whereas
"git remote add origin myserver:/path_to_git_repository"
fatal: not a git repository (or any of the parent directories): .git

probably I can worry about that later at least I know now I can talk to 
it.


mick
--
Key ID4BFEBB31



Re: using git locally

2019-05-17 Thread mick crane

On 2019-05-17 15:05, Brad Rogers wrote:

On Fri, 17 May 2019 14:36:36 +0100



thanks
--
Key ID4BFEBB31



Re: using git locally

2019-05-17 Thread mick crane

On 2019-05-17 15:59, Eduardo M KALINOWSKI wrote:

On 17/05/2019 11:31, mick crane wrote:

well that seems to work
"git clone myserver:/path_to_git_repository"
whereas
"git remote add origin myserver:/path_to_git_repository"
fatal: not a git repository (or any of the parent directories): .git



That's because git remote add is meant to add a remote to an existing
git (local) repository. You're probably running it on an empty
directory, so it complains (correctly) that you're not in a repository.


Oh I see, thought message was about the other end.
thanks
--
Key ID4BFEBB31



Re: major email problems

2019-05-18 Thread mick crane

On 2019-05-18 23:58, Glenn English wrote:


I couldn't find anything in the Dovecot config files that addressed
that, except a commented out line: "#disable_plaintext_auth = yes."
But Dovecot seems to be tossing PLAINTEXT anyway. I didn't try
deleting the line.



Dunno why it suddenly stopped working.
The commented out lines in the config file normally show the default.
https://wiki.dovecot.org/TestInstallation

Is the place to start.

good luck

mick
--
Key ID4BFEBB31



Re: major email problems

2019-05-18 Thread mick crane

On 2019-05-19 00:58, Glenn English wrote:
On Sat, May 18, 2019 at 11:39 PM mick crane  
wrote:



https://wiki.dovecot.org/TestInstallation


That looks great -- first thing in the morning :-)


which file are you editing ?
I think how it works is that apt puts its files in /usr/share/dovecot
and update overwrites those, whereas "your" files are in /etc/dovecot.

mick
--
Key ID4BFEBB31



Re: Gene you poor soul

2019-05-21 Thread mick crane

On 2019-05-22 04:40, Gene Heskett wrote:

Its working now, and I have other irons in the fire, like how do I 
print

to a printer shared by cups, from a win 10 Home edition.


I've only ever done it with networked printers.
You may get lucky with cupsd on linux box that can print if you let 
windows search for a printer.
Otherwise the printer to select will be, I forget exactly, may be "local 
printer"


http://ipaddress_of_pc_running_cupsd:631/exact_name_cups_identifies_printer_with.

good luck

mick

--
Key ID4BFEBB31



Re: Gene you poor soul

2019-05-21 Thread mick crane

On 2019-05-22 07:52, mick crane wrote:


http://ipaddress_of_pc_running_cupsd:631/exact_name_cups_identifies_printer_with.

sorry, seem to remember that's.
http://ipaddress_of_pc_running_cupsd:631/printers/exact_name_cups_identifies_printer_with

probably need the driver on windows as well.
mick


--
Key ID4BFEBB31



Re: Gene you poor soul

2019-05-22 Thread mick crane

On 2019-05-22 10:34, Gene Heskett wrote:
 Wally has some really cheap

$40 ones, but I suspect that I'd have to buy one per job because the
heads would dry up and clog between uses. Back when I was a fan of
epsons, the cost of the inks was $250/year just to print the nightly
amanda reports to exercise the printer. That worked out to about $1 a
sheet and it still got clogged.


I had one of those xerox phaser printers with solid colour blocks that 
worked really well until I dropped it.
seemed like a way to stop the heads getting blocked but don't know if 
caught on.

Not very small tho'

mick

--
Key ID4BFEBB31



Re: No Books in print on Systemd?

2019-05-22 Thread mick crane

On 2019-05-19 13:51, Boyan Penkov wrote:

--
Boyan Penkov
www.boyanpenkov.com


On May 18, 2019, at 17:19, Kenneth Parker  wrote:

I know there are controversies on Systemd (including in Debian  --  
for example, Devuan), but I want to learn enough about it to 
(Horrors!)  become an expert.


And yes, I have found several online resources, including on the 
Debian Wiki.  (I'm also reading 
https://www.freedesktop.org/wiki/Software/systemd/ 
 ).


My problem?  My best times for reading are times where a "Paper Book" 
is best.  Unfortunately, I haven't found any.


+1 for the implicit sentiment that it may be time for a book-length
elucidation of the system, as I was looking around the the same thing
??? even if it???s http://0pointer.net/blog/ posts cleaned up and laid out
in a systematic (not temporally linear..) way, I??? be interested???.



If I'm missing something, please tell me.  Otherwise, do any of you 
know if someone's working on a Book?






I did buy the "windows 98 administrator's guide" to try to get to grips 
with it but left me more annoyed.

"I just want to know what is happening, it is my PC"
So it was a relief to find Linux books and an OS that does what it says 
it should do.

Now I dunno what goes on.
But really I guess now I don't care so much as I feel the guys are 
giving me this software are trustworthy

It would be nice to have it laid out in print exactly what goes on.

mick

--
Key ID4BFEBB31



Re: Debian Programming languages

2019-05-24 Thread mick crane

On 2019-05-24 17:14, ghe wrote:

On 5/24/19 9:08 AM, Paul Sutton wrote:


As I am trying to promote contributing to Debian,  what programming
languages are mostly used?


C, perl, java, ruby, python, bash, that I know of. And probably several
others. I don't recall seeing any COBOL, though :-)



Perl is happily off on it's own.


What goes on with Perl ?
There is Perl6 but development is stalled ?

mick


--
Key ID4BFEBB31



Re: [DNG] Linux system can be brought down by sending SIGILL to Systemd

2019-05-25 Thread mick crane

On 2019-05-25 08:25, Reco wrote:


again no problem here.


Stretch's systemd:

# kill -ILL 1
Message from syslogd@xxx at May 25 10:19:09 ...
 systemd[1]: Caught , dumped core as pid 822.
...
systemd[1]: Freezing execution.


The userspace and the kernel will work after this, but anything that's
related to systemd (including poweroff and shutdown) just hangs.

Seems harmless to me as one needs to be root to send signals to PID 1.


If you are going to kill off processes as root I'd expect things to be 
unhappy.
I once accidentally removed everything from / down and that stopped it 
working as well.


mick

--
Key ID4BFEBB31



Re: How to set access permissions to protect a database file?

2019-05-25 Thread mick crane

On 2019-05-26 00:49, Markos wrote:

Hi,

I made a program (reading_room.tcl), with Sqlite running on Debian 9,
to control the books of a reading room.

I implemented an authentication system for common users and
administrator users in the reading_room program.

Now I want that any user logged in the Linux be able to run the
program reading_room.tcl, which will access the database (books.db)

But I want to protect the file books.db so that only the the program
reading_room.tcl can access the books.db file. But that no user could
delete or write to the file books.db (only the program
reading_room.tcl)

Please, how can I configure the system to do that?

How to define the permissions?


I'll have a go, sure I'll get pulled up if off.

read 4, write 2, execute 1  add these together for permissions
owner, group, anybody

I never did anything on a PC with other people having access so I never 
made a file only executable by anybody but I don't see why not.

As you wrote reading_room.tcl presume that belongs to you.
I don't know anything about tcl as yet but assume it's executable as it 
is and does something.
You may have a group librarians that want to have read/write access to 
reading_room.tcl

Assume you have backups of the files.
guess books.db wants to be 644
"su -"
"chmod 644 books.db"
 or if the librarians want write access to it.
"chown you.librarians books.db"
"chmod 664 books.db"

"chown you.librarians reading_room.tcl"
"chmod 771 reading_room.tcl"

mick


--
Key ID4BFEBB31



Re: How to set access permissions to protect a database file?

2019-05-25 Thread mick crane

On 2019-05-26 05:32, David Christensen wrote:

On 5/25/19 8:12 PM, mick crane wrote:

On 2019-05-26 00:49, Markos wrote:

Hi,

I made a program (reading_room.tcl), with Sqlite running on Debian 9,
to control the books of a reading room.

I implemented an authentication system for common users and
administrator users in the reading_room program.

Now I want that any user logged in the Linux be able to run the
program reading_room.tcl, which will access the database (books.db)

But I want to protect the file books.db so that only the the program
reading_room.tcl can access the books.db file. But that no user could
delete or write to the file books.db (only the program
reading_room.tcl)

Please, how can I configure the system to do that?

How to define the permissions?


I'll have a go, sure I'll get pulled up if off.

read 4, write 2, execute 1?? add these together for permissions
owner, group, anybody

I never did anything on a PC with other people having access so I 
never made a file only executable by anybody but I don't see why not.

As you wrote reading_room.tcl presume that belongs to you.
I don't know anything about tcl as yet but assume it's executable as 
it is and does something.
You may have a group librarians that want to have read/write access to 
reading_room.tcl

Assume you have backups of the files.
guess books.db wants to be 644
"su -"
"chmod 644 books.db"
 ??or if the librarians want write access to it.
"chown you.librarians books.db"
"chmod 664 books.db"

"chown you.librarians reading_room.tcl"
"chmod 771 reading_room.tcl"

mick



I don't believe there is a solution using just read, write, and mode
bits and group membership.  (Perhaps, there is a solution if you also
use access control lists?)


Suppose I have a Perl script "shared-program.pl" (sorry, I don't know
TCL) that reads a line from the terminal, lower cases the line, and
then writes the line to the terminal.  If the line contains the word
"write', the line is also written to a data file "shared-program.dat":

2019-05-25 20:31:43 dpchrist@tinkywinky ~
$ ll sandbox/perl5/shared-program.pl
-rwxr-xr-x 1 dpchrist dpchrist 267 2019-05-25 20:31:35
sandbox/perl5/shared-program.pl*

2019-05-25 20:31:49 dpchrist@tinkywinky ~
$ cat sandbox/perl5/shared-program.pl
#!/usr/bin/env perl
use strict;
use warnings;
use FindBin qw( $Bin );
use File::Slurp;
use constant DATAFILE => "$Bin/shared-program.dat";
print "$0 >";
my $line = <>;
$line = lc $line;
write_file(DATAFILE, {append => 1}, $line)
if $line =~ /write/;
print $line;


If I run the program as the owner, it works as expected:

2019-05-25 20:34:01 dpchrist@tinkywinky ~
$ sandbox/perl5/shared-program.pl
sandbox/perl5/shared-program.pl >Hi, Dave!
hi, dave!

2019-05-25 20:34:15 dpchrist@tinkywinky ~
$ sandbox/perl5/shared-program.pl
sandbox/perl5/shared-program.pl >write Bye, Dave!
write bye, dave!

2019-05-25 20:35:09 dpchrist@tinkywinky ~
$ ll sandbox/perl5/shared-program.dat
-rw-r--r-- 1 dpchrist dpchrist 17 2019-05-25 20:35:09
sandbox/perl5/shared-program.dat

2019-05-25 20:35:22 dpchrist@tinkywinky ~
$ cat sandbox/perl5/shared-program.dat
write bye, dave!


The mode of 755 on the script allows other group members and all other
users to run the script:

tinkywinky@tinkywinky:~$ /home/dpchrist/sandbox/perl5/shared-program.pl
/home/dpchrist/sandbox/perl5/shared-program.pl >Hello, Tinky Winky!
hello, tinky winky!


But, if I clear the world read bit on the script:

2019-05-25 20:35:24 dpchrist@tinkywinky ~
$ chmod o-r sandbox/perl5/shared-program.pl

2019-05-25 20:38:08 dpchrist@tinkywinky ~
$ ll sandbox/perl5/shared-program.pl
-rwxr-x--x 1 dpchrist dpchrist 267 2019-05-25 20:31:35
sandbox/perl5/shared-program.pl*


Other users are not able to run the script because the Perl
interpreter cannot read the script:

tinkywinky@tinkywinky:~$ /home/dpchrist/sandbox/perl5/shared-program.pl
Can't open perl script
"/home/dpchrist/sandbox/perl5/shared-program.pl": Permission denied


(It might be possible for other users to run binary programs with just
the world execute bit set?)


So, the world mode needs to be read+execute for other users to run
scripts they do not own:

2019-05-25 20:59:32 dpchrist@tinkywinky ~
$ chmod o=rx sandbox/perl5/shared-program.pl

2019-05-25 21:05:53 dpchrist@tinkywinky ~
$ ll sandbox/perl5/shared-program.pl
-rwxr-xr-x 1 dpchrist dpchrist 267 2019-05-25 20:31:35
sandbox/perl5/shared-program.pl*

tinkywinky@tinkywinky:~$ /home/dpchrist/sandbox/perl5/shared-program.pl
/home/dpchrist/sandbox/perl5/shared-program.pl >Blah Blah Blab
blah blah blab


Focusing on the data file, let's add the other user to the file's 
group:


2019-05-25 20:49:08 root@tinkywinky ~
# usermod -a -G dpchrist tinkywinky

2019-05-25 20:50:33 root@tinkywinky ~
# grep dpchrist /etc/group | grep t

Re: network installer will not boot

2019-05-26 Thread mick crane

On 2019-05-26 14:29, Blair, Charles E III wrote:

Thank you.  I seem to have another
problem.

   I used F2 to shut off "secure boot".
Now, there are noises that suggest the
CD is being read, but nothing displays
on the monitor--- no warnings, no diagnostics,
just a blinking cursor in the upper-left
corner.


I seem to remember that this install of Buster if I booted from a 
pendrive it would start the install process but stalled not finding the 
files and if I booted from the DVD same thing but booting from the 
pendrive with the DVD (accidentally) in the drive then it completed the 
install.


mick

--
Key ID4BFEBB31



Re: That time IPv6 farted in Gene's church (Was Re: forcedeth?)

2019-05-27 Thread mick crane

On 2019-05-27 22:22, Gene Heskett wrote:


Then what was I looking at 3 hours ago, looked like a login form to me,
wanted my username, my real name and my email address. That popped up
and denied me access when I clicked on add bug in the upper right 
corner

of the screen? It flat refused to let me proceed without a valid login.
Yet you're telling me it should sail right on by just by clicking on 
the

add button?



This might be an issue with your browser.

mick

--
Key ID4BFEBB31



Re: WRITING to NTFS drives

2019-05-28 Thread mick crane

On 2019-03-11 18:13, deb wrote:


Someone asked what the status of WRITING to NTFS drives was.


I move files windows -> Debian with WinScp.
You can move files Debian -> Debian with mc and a ssh connection in the 
other window.
Interested to see that there is a ssh server available on windows so it 
should be possible Debian -> Windows with mc.


mick


--
Key ID4BFEBB31



Re: WRITING to NTFS drives

2019-05-29 Thread mick crane

On 2019-05-29 07:28, deloptes wrote:

mick crane wrote:


I move files windows -> Debian with WinScp.
You can move files Debian -> Debian with mc and a ssh connection in 
the

other window.
Interested to see that there is a ssh server available on windows so 
it

should be possible Debian -> Windows with mc.


I've been writing directly to ntfs with ntfs-3g for many years now. Not 
on

daily bases, but doing backup and restore couple of times on different
notebooks, PCs etc.


Thing is you don't know what windows is going to do next.
Was an update a few days ago that I assume was why PC just started 
crashing ( which hasn't happened for years ) and couldn't decide if it 
wanted to boot or not.
Then an hour later there was another update and all started playing 
nicely again.


mick
--
Key ID4BFEBB31



Re: reboot stuff doesn't start

2019-05-29 Thread mick crane

On 2019-05-29 16:00, Gene Heskett wrote:

On Wednesday 29 May 2019 08:20:02 am Brian wrote:


On Tue 28 May 2019 at 21:47:06 -0400, Gene Heskett wrote:
> On Tuesday 28 May 2019 03:37:55 pm Brian wrote:
> > Why do think cron was calling hpfax? Did you set up the job?
> > (Using fax isn't exactly common these day).


yeah, like going back to the cretatious. I've actually sent one fax in
the last nearly 40 years and I think that was from an amiga. Retired 
the

last one in 98 after I'd put RH5 on an x86 tower I'd built.


legal people still use fax.


--
Key ID4BFEBB31



Re: WRITING to NTFS drives

2019-05-29 Thread mick crane

On 2019-05-29 11:18, deloptes wrote:

mick crane wrote:


Thing is you don't know what windows is going to do next.
Was an update a few days ago that I assume was why PC just started
crashing ( which hasn't happened for years ) and couldn't decide if it
wanted to boot or not.
Then an hour later there was another update and all started playing
nicely again.


But this has nothing to do with the original question. We even do not 
know

what linux or debian developers will do next ;-)

The point is that OP should know that ntfs-3g works well under linux. I
guess there should be additional thought which user does the writes, 
but it

does not change the fact that it works fine.

regards


You understand I just make the point.
In the past it was considered dangerous to write to NTFS
That seems to work now but you don't know what might change
If this open-ssh implementation is on windows then it is part of their 
thing so should be likely to not wreck anything.


mick

--
Key ID4BFEBB31



Re: Gmail problems (was Re: Ping as normal user)

2019-05-31 Thread mick crane

On 2019-05-31 14:01, rhkra...@gmail.com wrote:

I guess I have to learn more about google
mail, maybe either disabling their spam filter, or deciding to switch 
to an
email provider (ideally free or cheap) who doesn't filter email for me. 
 (I
guess when others mark something as spam, at least sometimes it affects 
me or

everybody -- very annoying.)

posteo.de has been mentioned if you don't mind using 100% green 
electricity


mick
--
Key ID4BFEBB31



Re: Using ISO image of installer DVD as repository - How?

2019-06-01 Thread mick crane

On 2019-05-31 13:20, Richard Owlett wrote:

With the first DVD of Debian 9.8.0 I did:
   dd if=/dev/cdrom of=dvd.iso bs=4M
I edited sources.list to read
   deb file:///home/richard/dvd.iso stretch main contrib trusted=yes

When running Synaptic's
Edit->Reload Package Information
I receive an error message:

The repository 'file:/home/richard/dvd.iso stretch Release'
does not have a Release file.


What is the problem?
TIA


I'm going to get in trouble for this but if I could offer advice.
You seem more interested in the actual install process than getting it 
running and doing something with it.

Fair enough, it is like a hobby,
When came across this stuff I was the same, installed whatever 
distribution on awkward hardware just to see.

But I had no idea what I was doing.
There is so much to know and if you have a memory like a sieve like me 
it is really hard to grasp how it all works.
These days I accept the default installation and that which is needed to 
do bits of image manipulation and I really like having the email and 
webserver software and that's it.


cheers

mick


--
Key ID4BFEBB31



Re: Using ISO image of installer DVD as repository - How?

2019-06-02 Thread mick crane

On 2019-06-02 12:47, Richard Owlett wrote:

On 06/01/2019 07:08 PM, mick crane wrote:

On 2019-05-31 13:20, Richard Owlett wrote:

With the first DVD of Debian 9.8.0 I did:
 dd if=/dev/cdrom of=dvd.iso bs=4M
I edited sources.list to read
 deb file:///home/richard/dvd.iso stretch main contrib trusted=yes

When running Synaptic's
?? Edit->Reload Package Information
I receive an error message:

The repository 'file:/home/richard/dvd.iso stretch Release'
does not have a Release file.


What is the problem?
TIA


On one installation the installer requested if I would like to use the 
CDROM as a repository and put this line in sources.list which I later 
commented out because I didn't want to have to keep searching for the 
CD.


# deb cdrom:[Debian GNU/Linux testing _Buster_ - Official Snapshot amd64 
DVD Binary-1 20180326-04:08]/ buster contrib main


--
Key ID4BFEBB31



Re: How to set access permissions to protect a database file?

2019-06-09 Thread mick crane

On 2019-06-09 22:32, Markos wrote:


reading_room.db rw-r--rw- (owner markos)

why give world write access to the database ?
--
Key ID4BFEBB31



Re: web page problem

2019-06-15 Thread mick crane

On 2019-06-13 20:33, Gene Heskett wrote:

Greetings all;

And it's my web page.




Or do I have to copy them across to a local dir I can share and chown
them to match the apache2 sandboxes names?


Don't know if supposed to but can put a soft link in /var/www/html 
pointing to directory anywhere readable by group www-data.




--
Key ID4BFEBB31



IPv4 v IPv6

2019-06-17 Thread mick crane

hello,
I know nothing about IPv6.
Can somebody point to a good explanation ?
Without knowing anything about it I'm wondering if I should request an 
IPv6 range from my ISP to use locally.
A network card have IPv4 and IPv6 addresses that are different, not the 
same address in different notation ?

Then with firewalling do you need to specify both IPv4 and IPv6 ranges ?

mick

--
Key ID4BFEBB31



Re: [solved]Re: Converting text subtitles to vobsub

2019-06-24 Thread mick crane

On 2019-06-23 15:31, Michael Lange wrote:

Hi,

On Sat, 22 Jun 2019 12:54:30 +0200
Nicolas George  wrote:


Michael Lange (12019-06-22):
> I did investigate some more, now as far as I can see this is actually
> not true. spumux only creates a .sub file but the .idx file is
> missing. This seems to be no good except with DVDs. Besides, there
> seems only to be the choice between 25.0 and 29,97 fps framerates
> (PAL/NTSC) which is too bad if the video is 23.976 fps :(

Indeed, because vobsub is a bastard format built on top of a crappy
format. You need spumux to produce spu packets and mux them into a
MPEG-PS stream, and then you need a DVD ripping tool to butcher the
MPEG-PS stream and chop the pair of final files.


I was finally able to find an app which does what I want
(https://www.nikse.dk/subtitleedit/)

It's a windows program, too, but it is GPL and can be run on debian 
with

mono (the latest version 359 did not work perfectly here with Stretch
for some reason, maybe Stretch's mono is too old or maybe it's 
something
else; so I followed someone's suggestion and tried an older version 
(343)

which seems to work well here).
The feature set this app offers looks rather impressive, obviously it's
far superior to similar programs that come with debian. And it can 
create

good looking vobsub subtitles in less than one minute.

Just in case someone comes here looking for help:
you can download the zip file with the portable version, unpack it and
then run
# mono SubtitleEdit.exe
which should launch the application window.
To create vobsub files you can (once the original subtitles are opened)
go to File -> Export -> VobSub (sub/idx)... which should open a dialog 
box

where the properties of the vobsub file can be configured and finally
press the "Export all lines..." button which will start the procedure.

Regards

Michael


That seems quick.
Any idea what this software does to "burn" text over video ?
extracting frames then combining with text for duration in .srt file and 
putting them back would take ages I would imagine.


mick

--
Key ID4BFEBB31



Re: [solved]Re: Converting text subtitles to vobsub

2019-06-24 Thread mick crane

On 2019-06-24 11:32, Michael Lange wrote:

Hi,

On Mon, 24 Jun 2019 09:23:15 +0100
mick crane  wrote:

(...)

> which seems to work well here).
> The feature set this app offers looks rather impressive, obviously
> it's far superior to similar programs that come with debian. And it
> can create
> good looking vobsub subtitles in less than one minute.

(...)


That seems quick.
Any idea what this software does to "burn" text over video ?
extracting frames then combining with text for duration in .srt file
and putting them back would take ages I would imagine.


it does not "burn" them, but creates separate vobsub subtitles (a .sub
plus an .idx file), that's the point :)
I can add these to an .mkv file along with an .srt or .ass subtitle
track, so I can pick which one to use depending on the player. Or I can
even turn them off.



So it sort of merges the streams.
I thought you were supposed never to cross the streams.




Regards

Michael

P.S.:
for the archives, in case someone looks here:
I tried other versions of SubtitleEdit, v. 353 seems to be the latest 
one

that works properly with Stretch.
When exporting to vobsub, on linux for some reason the "Simple 
rendering"

option in the dialog box needs to be checked (seems to be the case with
any version).


.-.. .. ...- .   .-.. --- -. --.   .- -. -..   .--. .-. --- ... .--. . 
.-.


"That unit is a woman."
"A mass of conflicting impulses."
-- Spock and Nomad, "The Changeling", stardate 3541.9


--
Key ID4BFEBB31



Re: Giving remaja (teens) group full administrator privileges through sudo - dangerous?

2019-06-25 Thread mick crane

On 2019-06-25 04:38, Bagas Sanjaya wrote:

On 24/06/19 06.27, Aidan Gauland wrote:

I can't really offer an opinion on whether it is dangerous without a 
more detailed hypothetical scenario, but I would say that is 
overbroad, and this rule should be narrowed down to only allow running 
certain commands via sudo as required for this group to perform their 
work.


In this hypothetical scenario, the sudoers rule is applied to ALL
systems, including production ones, and sysadmins doesn't have proper
backups.


I've concluded that you are asking for assistance with some artistic 
idea applying anarchist political theory to TV film production but are 
confusing production method with production tools.
When film/ tape was flammable an editor wouldn't let a random person 
with a flame thrower into his editing room likewise a computer whose 
function might be video editing is a tool of many delicate parts and if 
some part of it is broken then it likely will stop working.


mick
--
Key ID4BFEBB31



OT:hardware query

2019-06-28 Thread mick crane
The first concern if getting a new PC is that it can play the steam 
games and they are getting really pushy what they need to work.
I never have proper available funds for this stuff these days and 
generally buy used..
The idea is each year or so get something else and move the last one 
down to doing more useful work.
That would mean it should have facility to attach 2 or more internal 
drives and slots for network cards.

If that makes sense what advise something used for 200 UKP ?
mick

--
Key ID4BFEBB31



<    1   2   3   4   5   6   7   >