Re: counting commas

2024-01-19 Thread Thomas Schmitt
Hi,

fxkl4...@protonmail.com wrote:
> why doesn't grep count 2 commas
> echo 'Kích thước máy xay cỏ, giá máy thế nào , phụ tùng máy mua ở đâu' |
> grep -c ,
> 1

Happens with much simpler text too:
  $ echo ',,,' | grep -c ','
  1

The man page explains it:

 -c, --count
Suppress  normal output; instead print a count of matching lines
for each input file.  With the -v,  --invert-match  option  (see
below), count non-matching lines.  (-c is specified by POSIX.)

Note that it counts lines, not characters.

Counting characters by grep seems somewhat tricky:
  
https://www.unix.com/shell-programming-and-scripting/128033-grep-command-count-characters.html

An answer to this question
  
https://stackoverflow.com/questions/16679369/count-occurrences-of-a-char-in-a-string-using-bash
proposes
echo "referee" | tr -cd 'e' | wc -c

  $ echo ',,,' | tr -cd ',' | wc -c
  3
  $ echo 'Kích thước máy xay cỏ, giá máy thế nào , phụ tùng máy mua ở đâu' | tr 
-cd ',' | wc -c
  2

(I hope i did not quote something that's against the code of conduct. :))


Have a nice day :)

Thomas



Mariadb error

2024-01-19 Thread Gift Rain
Good day,

I'm running Debian 11 and getting error "Failed to start MariaDB 10.5.12
database server.

My emails are not working. Another error on my logs is :

"warning:proxy:mysql:/etc/postfix/mysql/sender_bcc_maps_user.cf lookup
error for"

Please help,

Gift


Re: Mariadb error

2024-01-19 Thread Alexander V. Makartsev

On 19.01.2024 13:46, Gift Rain wrote:

Good day,

I'm running Debian 11 and getting error "Failed to start MariaDB 
10.5.12 database server.


Your MySQL database server doesn't start for some reason. Is there 
anything helpful in the output?


   $ sudo journalctl --no-pager -x --unit mariadb.service

You can use Debian "pastebin" site [1] to send the output if it is long.

What happened before failure? Was it system crash? System upgrade 
attempt? Anything else?




My emails are not working. Another error on my logs is :

"warning:proxy:mysql:/etc/postfix/mysql/sender_bcc_maps_user.cf 
 lookup error for"


Postfix uses mysql database to lookup necessary information and since it 
is not running so does postfix.



[1] https://paste.debian.net/
--
With kindest regards, Alexander.

⢀⣴⠾⠻⢶⣦⠀
⣾⠁⢠⠒⠀⣿⡁ Debian - The universal operating system
⢿⡄⠘⠷⠚⠋⠀ https://www.debian.org
⠈⠳⣄

Re: normally start new xterms

2024-01-19 Thread tomas
On Fri, Jan 19, 2024 at 10:16:56AM +0100, Thomas Schmitt wrote:
> Hi,

[...]

> to...@tuxteam.de wrote:
> > It's Modifier (that Flying Window thing), aka "4" and the regular "t"
> > (my mnemonics: "terminal").
> 
> Ah. You use it as modifier for other keys, i use it as plain key.

Yes, I was avid for keys (small laptop here :)

> The quotation marks around "t" are only ornamental ?

Most probably yes. Most probably also cargo cult :-)

Cheers
-- 
t


signature.asc
Description: PGP signature


Re: no sound

2024-01-19 Thread Gareth Evans


> On 19 Jan 2024, at 05:56, Maureen L Thomas  wrote:
> 
> … I used Lucky Backup but I cannot figure out how to restore.  I read the 
> book and it is confusing …

Do you mean this?

https://luckybackup.sourceforge.net/manual.html#restore

If not, is it helpful?

Best wishes,
Gareth


Re: Libreoffice hangs at start

2024-01-19 Thread Hans
Hi David,

> It sounds rather like a computer that doesn't know its hostname, or
> its IP address. So can you elaborate on how you "fix" the address.
> 
> For example, my /etc/hosts file on ahost contains at a minimum:
> 
>   127.0.0.1   localhost
>   127.0.1.1   ahost.corp  ahost   # 192.168.1.123
> 
>   ::1 localhost ip6-localhost ip6-loopback
> 
>   ff02::1 ip6-allnodes
>   ff02::2 ip6-allrouters
> 
> and the router's DHCP server issues 192.168.1.123 when asked by
> a PC with ahost's MAC. (All other hosts' /etc/hosts files contain
>   192.168.1.123   ahost.corp  ahost)
> 
I had the same idea and so I checked for /etc/hosts. It looked like:

--- snip 

127.0.0.1   localhost debian
192.168.2.11localhost debian  
192.168.2.101   localhost debian  


# The following lines are desirable for IPv6 capable hosts 
::1 ip6-localhost ip6-loopback 
fe00::0 ip6-localnet 
ff00::0 ip6-mcastprefix 
ff02::1 ip6-allnodes 
ff02::2 ip6-allrouters 
ff02::3 ip6-allhosts

--- snap 

However, I found nothing suspicous in it. It is structured as mine, where it is 
working well.

192.168.2.11 is the IP of the wired network card (not used)
192.168.2.101 is the IP of the wireless card (connected with)

As I said before: I am using network manager and fixed IP, NO DHCP.

Do you see any strange thing in this file?

Thanks for the help!

Best regards

Hans


Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread Anssi Saari
gene heskett  writes:

> The OOM death of the system was the xfce4 terminal apparently being
> set for unlimited scrollback and that was eating the memory. Switching
> to Konsole with has the ability to control the scrollback to 200
> lines, and its taken all 32G's as .cache and 1536 1k blocks of swap,
> and its working w/o any OOM actions I've detected.

It does seem strange to me, even in MS-DOS era I was able to set a
terminal scrollback to 5000 lines without issue, when RAM was maybe 4 MB
and a DOS terminal program probably had access to way less than that. So
does rsync really generate gigabytes of verbose output? Or is
xfce-terminal storing the scrollback in a very inefficient way?



Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread Anssi Saari
Franco Martelli  writes:

> I don't know if it is a good idea, in fact it exists a special
> partition type for RAID array listed in fdisk, I used that for my
> RAID:

One case against using partitions on mdraid: if your array gets messed
up, you get to recreate those partition tables yourself and that's just
hilarious if you don't have a backup. Happened to a friend of mine,
reason was a UPS brownout. I think he scanned his disks for copies of
the superblock but didn't find any and then somehow with a lot of hassle
eventually figured out what the partition tables were.

So in a catastrophe, partition tables are one more obstacle to cross
before you can start actually recovering your data.

My only mdraid was on raw partitions but that never had any issues. I
think zfs effectively does the same, no partitions.



Re: normally start new xterms

2024-01-19 Thread tomas
On Fri, Jan 19, 2024 at 09:06:05AM +0100, Thomas Schmitt wrote:
> Hi,
> 
> to...@tuxteam.de wrote:
> > I coopted the otherwise useless "Windows" key (aka "Left Super" for
> > WM things: Super-L makes an xterm:
> >  # Terminal
> >  Key   "t"   A   4  Exec exec xterm
> 
> For me the Flying Windows keys pop up or push down the affected window:
> 
>   Key Super_L A N RaiseLower
>   Key Super_R A N RaiseLower
> 
> What i don't understand in your example is the Keyname "t".
> man fvwm points me to /usr/include/X11/keysymdef.h or
> /usr/X11R6/lib/X11/XKeysymDB (which seems not exist in Debian except
> a file "XKeysymDB" of ipackage "xemacs21-support").
> 
> Do you know documentation which describes your "t" ?

It's Modifier (that Flying Window thing), aka "4" and the regular "t"
(my mnemonics: "terminal").

What I forgot to say is that I set up that key Whose Name Won't Be
Mentioned to act as a modifier:

  setxkbmap -model pc105 \
-layout "de,el" \
-variant "deadtilde," \
-option "compose:caps" \
-option "altwin:alt_super_win" \
-option "terminate:ctrl_alt_bksp" \
-option "grp:shifts_toggle"

(the fifth line -- the others do other funny things ;-) This is
in my ~/.xinitrc, but could possibly go to /etc/default/keyboard;
too lazy to try out at the moment.

Cheers
-- 
t


signature.asc
Description: PGP signature


Re: No Release file for Security Update

2024-01-19 Thread debian-user
Tixy  wrote:
> On Thu, 2024-01-18 at 12:06 -0600, John Hasler wrote:
> > Tixy writes:  
> > > Where could your machine be getting this IP address from?  It's
> > > the same IP address shown in your output when you used the
> > > incorrect address 'ftp.security.debian.org' and for me that
> > > doesn't resolve to any IP address.  
> >   
> > > From here both security.debian.org and
> > > ftp.security.debian.org resolve  
> > to 57.128.81.193.  Happens both with Unbound and with 8.8.8.8.
> > 
> > toncho/~ 22 dig  ftp.security-debian.org  
> 
> That's a different address (you're using a '-') and works for me too.
> 
> I was using the address that George _said_ he used in his email,
> obviously he was wrong and just mis-typing emails rather than copy and
> pasting in what he was actually using :-(

Another example of why posting the prompt and command as well as the
output is useful :)



Re: normally start new xterms

2024-01-19 Thread Thomas Schmitt
Hi,

to...@tuxteam.de wrote:
> I coopted the otherwise useless "Windows" key (aka "Left Super" for
> WM things: Super-L makes an xterm:
>  # Terminal
>  Key   "t"   A   4  Exec exec xterm

For me the Flying Windows keys pop up or push down the affected window:

  Key Super_L A N RaiseLower
  Key Super_R A N RaiseLower

What i don't understand in your example is the Keyname "t".
man fvwm points me to /usr/include/X11/keysymdef.h or
/usr/X11R6/lib/X11/XKeysymDB (which seems not exist in Debian except
a file "XKeysymDB" of ipackage "xemacs21-support").

Do you know documentation which describes your "t" ?

(I see in my configuration that in the past i bound a pseudo-key F34 to
keycodes 115 and 116 by xmodmap(1) and used the Keyname F34 with fvwm
command "Key". After some system change i had to google and learned that
"Super_L" and "Super_R" work without help of xmodmap.)


Have a nice day :)

Thomas



Re: counting commas

2024-01-19 Thread tomas
On Fri, Jan 19, 2024 at 07:10:51AM +, fxkl4...@protonmail.com wrote:
> why doesn't grep count 2 commas
> 
> 
> echo 'Kích thước máy xay cỏ, giá máy thế nào , phụ tùng máy mua ở đâu' | grep 
> -c ,
> 1
> 
> echo 'Kích thước máy xay cỏ, giá máy thế nào , phụ tùng máy mua ở đâu' | cut 
> -d, -f1
> Kích thước máy xay cỏ
> 
> echo 'Kích thước máy xay cỏ, giá máy thế nào , phụ tùng máy mua ở đâu' | cut 
> -d, -f2
>   giá máy thế nào
> 
> echo 'Kích thước máy xay cỏ, giá máy thế nào , phụ tùng máy mua ở đâu' | cut 
> -d, -f3
>   phụ tùng máy mua ở đâu

It is in the man page:

   -c, --count
 Suppress  normal output; instead print a count of matching lines
 for each input file.  With the -v,  --invert-match  option  (see
 below), count non-matching lines.

It counts matching lines. You gave it one line.

If you want to go character-wise, tr might fit the bill (e.g. do a tr -c
to remove everything except comma, then measure the resulting string's
length).

Of course, if you have something else than shell+utils there might be
more efficient ways.

Cheers
-- 
t


signature.asc
Description: PGP signature


Re: normally start new xterms

2024-01-19 Thread Thomas Schmitt
Hi,

to...@tuxteam.de wrote:
> > > I coopted the otherwise useless "Windows" key (aka "Left Super" for
> > > WM things: Super-L makes an xterm:
> > >  # Terminal
> > >  Key   "t"   A   4  Exec exec xterm

i wrote:
> > For me the Flying Windows keys pop up or push down the affected window:
> >   Key Super_L A N RaiseLower
> >   Key Super_R A N RaiseLower
> > What i don't understand in your example is the Keyname "t".

to...@tuxteam.de wrote:
> It's Modifier (that Flying Window thing), aka "4" and the regular "t"
> (my mnemonics: "terminal").

Ah. You use it as modifier for other keys, i use it as plain key.
The quotation marks around "t" are only ornamental ?


Have a nice day :)

Thomas



Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread Thomas Schmitt
Hi,

Anssi Saari
> It does seem strange to me, even in MS-DOS era I was able to set a
> terminal scrollback to 5000 lines without issue, when RAM was maybe 4 MB
> and a DOS terminal program probably had access to way less than that.

I have no problems with 130 xterms of 10,000 lines each.


> So does rsync really generate gigabytes of verbose output?

rsync can be extremely verbose when the number of transferred files is
very high.


> Or is xfce-terminal storing the scrollback in a very inefficient way?

I would not be astonished to learn that the luxury ornamented terminals
of the various desktops waste many extra bytes when memorizing plain text.
But the real bug is the fact that the scroll back memory is unlimited and
can summon the OOM killer. (I imagine it like the Discworld Death of Rats.)

If i were a user of Xfce i would report this as bug to its Debian
maintainer. Bug title "xfce-terminal: A landmine on the kids' playground".


Have a nice day :)

Thomas



Re: Re: Como hacer una partición no destructiva?

2024-01-19 Thread Jorge Abel Secreto
Hola, buen día!

El jue, 18 ene 2024 a la(s) 3:22 p.m., Camaleón (noela...@gmail.com) escribió:
>
> El 2024-01-18 a las 08:36 -0500, Jude_xiomi Sago escribió:
>
> > El jue, 18 ene 2024 a las 8:32, Jude_xiomi Sago
> > () escribió:
> > >
> > > El 2024-01-17 a las 14:44 -0500, Jude_xiomi Sago escribió:
> > > Identificador del disco: 0xcbe73cf0
> > > > 
> > > > Disposit.  Inicio  Comienzo Final  Sectores Tamaño Id Tipo
> > > > /dev/sda1  *   2046 107438079 107436034  51,2G  5 Extendida
> > > > /dev/sda2 107438080 976773167 869335088 414,5G  7 
> > > > HPFS/NTFS/exFAT
> > > > /dev/sda5  2048  20269055  20267008   9,7G 83 Linux
> > > > /dev/sda6  20271104  27674623   7403520   3,5G 83 Linux
> > > > /dev/sda7  27676672  31848447   4171776 2G 82 Linux swap / 
> > > > Solaris
> > > > /dev/sda8  31850496  33257471   1406976   687M 83 Linux
> > > > /dev/sda9  33259520 107438079  74178560  35,4G 83 Linux
> > > >
> >
> > sda1 es partición extendida y ahí no hay nada
>
> Lo que me desconcierta es que ocupa 51,2 GiB :-?

Da la impresión de que la partición sda1 es la extendida donde están
sda5 a sda9 que son las lógicas.
Si te fijas la suma de sus tamaños es igual a tamaño de sda1.

> ...
> Saludos,
>
> --
> Camaleón
>

Saludos
-- 
Jorge A Secreto
Analista de Sistemas
MP 361



Re: File has unexpected size (x != y). Mirror sync in progress? [IP: ...] ...

2024-01-19 Thread Albretch Mueller
On 1/19/24, Max Nikulin  wrote:
> Precise steps
> depend on degree of your paranoia.

 ... and mine is of the totally irrevocable, even joyful kind; so,
where are the steps?

 I have always believe that Debian’s basic assumptions about using the
Internet as a relatively secure, “private” venue are definitely more
worryingly irrational than my paranoia.

 I think at some point I will have to learn more about Debian’s apt
utility. Any documentation you would suggest explaining it all from
the protocoled structure of deb packages to the various installation
procedures depending on degree of paranoia? When I learn something I
like to learn all of it.

 I tend to only mind what I am working on. I would just use an
unexposed computer and/or do things by hand/on paper if possible, but
you can’t do algorithmic simulations and tests by hand.

 lbrtchx

On 1/19/24, Max Nikulin  wrote:
> On 18/01/2024 12:45, Albretch Mueller wrote:
>> On 1/14/24, Max Nikulin wrote:
>>> Generally just pay attention that GPG keys for repositories are obtained
>>> through trusted channels.
>>
>>   How do you functionally (that is, give me the step-by-step command
>> line statements, ... in order to) do that?
>
> Verify installation (or live) image to have initial keyring
>
> https://lists.debian.org/msgid-search/uobl6l$i21$1...@ciao.gmane.io
> Re: Correction to last message for Debian 11 and Debian 12. Thu, 18 Jan
> 2024 23:55:48 +0700.
>
> Optionally install necessary keyring packages.
>
> When adding a third-party repository, evaluate that GPG key you are
> going to add really belongs to repository maintainers. Precise steps
> depend on degree of your paranoia.



Re: File has unexpected size (x != y). Mirror sync in progress? [IP: ...] ...

2024-01-19 Thread Andrew M.A. Cater
On Fri, Jan 19, 2024 at 03:22:52PM +, Albretch Mueller wrote:
> On 1/19/24, Max Nikulin  wrote:
> > Precise steps
> > depend on degree of your paranoia.
> 
>  ... and mine is of the totally irrevocable, even joyful kind; so,
> where are the steps?
> 
>  I have always believe that Debian’s basic assumptions about using the
> Internet as a relatively secure, “private” venue are definitely more
> worryingly irrational than my paranoia.
> 
>  I think at some point I will have to learn more about Debian’s apt
> utility. Any documentation you would suggest explaining it all from
> the protocoled structure of deb packages to the various installation
> procedures depending on degree of paranoia? When I learn something I
> like to learn all of it.
> 

What aspect? apt sits on top of package dependencies, package signing,
package validation ...

And apt succeeds / parallels aptitude and apt-get. Apt-get succeeded dselect
which superseded dpkg commands. The base is still dpkg and keeping track
of package dependencies in some sense.

All the very best,

Andy
(amaca...@debian.org)
Where do you _actually_ want to start

>  I tend to only mind what I am working on. I would just use an
> unexposed computer and/or do things by hand/on paper if possible, but
> you can’t do algorithmic simulations and tests by hand.
> 
>  lbrtchx
> 
> On 1/19/24, Max Nikulin  wrote:
> > On 18/01/2024 12:45, Albretch Mueller wrote:
> >> On 1/14/24, Max Nikulin wrote:
> >>> Generally just pay attention that GPG keys for repositories are obtained
> >>> through trusted channels.
> >>
> >>   How do you functionally (that is, give me the step-by-step command
> >> line statements, ... in order to) do that?
> >
> > Verify installation (or live) image to have initial keyring
> >
> > https://lists.debian.org/msgid-search/uobl6l$i21$1...@ciao.gmane.io
> > Re: Correction to last message for Debian 11 and Debian 12. Thu, 18 Jan
> > 2024 23:55:48 +0700.
> >
> > Optionally install necessary keyring packages.
> >
> > When adding a third-party repository, evaluate that GPG key you are
> > going to add really belongs to repository maintainers. Precise steps
> > depend on degree of your paranoia.
> 



Re: File has unexpected size (x != y). Mirror sync in progress? [IP: ...] ...

2024-01-19 Thread Max Nikulin

On 18/01/2024 12:45, Albretch Mueller wrote:

On 1/14/24, Max Nikulin wrote:

Generally just pay attention that GPG keys for repositories are obtained
through trusted channels.


  How do you functionally (that is, give me the step-by-step command
line statements, ... in order to) do that?


Verify installation (or live) image to have initial keyring

https://lists.debian.org/msgid-search/uobl6l$i21$1...@ciao.gmane.io
Re: Correction to last message for Debian 11 and Debian 12. Thu, 18 Jan 
2024 23:55:48 +0700.


Optionally install necessary keyring packages.

When adding a third-party repository, evaluate that GPG key you are 
going to add really belongs to repository maintainers. Precise steps 
depend on degree of your paranoia.




Re: top bar the way I want it

2024-01-19 Thread Joe
 On 1/18/24 1:17 AM, Beyond Insulted wrote:
> > On Wed, Jan 17, 2024 at 08:40:30PM -0500, Maureen L Thomas wrote:  
> >> I now have a system that works but I cannot find any
> >> utility to fix the top bar the way I want it.  Any hints?  
> > Try to understand the audience that is being asked.
> >
> > Imaging that they were willing to help and stopped doing so
> > because the "the way I want it" is a way too poor description.
> >
> > 
> >> Moe  
> >
> > Groeten
> > Geert Stappers  

On Thu, 18 Jan 2024 23:02:21 -0500
Maureen L Thomas  wrote:

> I am sorry for the way I said that.  What I want is the very top bar, 
> before I re-installed it had three topics on the very top left hand
> that allowed me to click on one of them and get a menu of all the
> software installed and in order according to the topic.  Like under
> internet would list all the internet software. Right now I have to
> use that dot thing to see what is installed. It is a pain.  I cannot
> find the utility to change the settings for the top bar or the bottom
> bar or the sidebar I used daily with a list of the browsers, and
> special software that is used daily. Again I apologize for the
> previous, I was very uptight over my inability to remember what I
> need to do.
> 
We cannot all recollect all that has gone before.

There is very large flexibility as to the Linux display. There are four
major desktop environments and several derivatives of them. Some people
don't use a DE at all, just a window manager.

I use Xfce4 and its own panels, with one panel to the top left and one
panel top right, with a third tiny panel just containing an analogue
clock.

Most configuration can be achieved by right-clicking on a panel then
Panel-> Panel Preferences. The size, position and number of panels can
be controlled in that way. Launchers can be added to panels, and
applications can be added to launchers. Mostly one launcher contains
one application.

I don't know what display configuration you have, but a good start is
to right-click on whatever bars you have, and explore the menus. 

The main application menu can pretty much always be opened by
right-clicking on an empty part of the desktop and choosing
Applications. This set of menus, grouped as you say be approximate
function, can be edited by a couple of applications, one of which is the
Gnome alacarte, which I use. This is not normally installed by default
on Debian, but can be installed in the usual way. If you don't already
have Gnome or some of its applications, it will probably bring in a
distressing list of dependencies.

Let us know more about what desktop environment you use, and we can
probably give better advice. Unfortunately, while reinstalling can fix
many problems fairly easily, it does bring with it the need to rebuild
the configurations of many things.

-- 
Joe



Re: Re: Como hacer una partición no destructiva?

2024-01-19 Thread Camaleón
El 2024-01-19 a las 08:20 -0300, Jorge Abel Secreto escribió:

> Hola, buen día!
> 
> El jue, 18 ene 2024 a la(s) 3:22 p.m., Camaleón (noela...@gmail.com) escribió:
> >
> > El 2024-01-18 a las 08:36 -0500, Jude_xiomi Sago escribió:
> >
> > > El jue, 18 ene 2024 a las 8:32, Jude_xiomi Sago
> > > () escribió:
> > > >
> > > > El 2024-01-17 a las 14:44 -0500, Jude_xiomi Sago escribió:
> > > > Identificador del disco: 0xcbe73cf0
> > > > > 
> > > > > Disposit.  Inicio  Comienzo Final  Sectores Tamaño Id Tipo
> > > > > /dev/sda1  *   2046 107438079 107436034  51,2G  5 Extendida
> > > > > /dev/sda2 107438080 976773167 869335088 414,5G  7 
> > > > > HPFS/NTFS/exFAT
> > > > > /dev/sda5  2048  20269055  20267008   9,7G 83 Linux
> > > > > /dev/sda6  20271104  27674623   7403520   3,5G 83 Linux
> > > > > /dev/sda7  27676672  31848447   4171776 2G 82 Linux swap 
> > > > > / Solaris
> > > > > /dev/sda8  31850496  33257471   1406976   687M 83 Linux
> > > > > /dev/sda9  33259520 107438079  74178560  35,4G 83 Linux
> > > > >
> > >
> > > sda1 es partición extendida y ahí no hay nada
> >
> > Lo que me desconcierta es que ocupa 51,2 GiB :-?
> 
> Da la impresión de que la partición sda1 es la extendida donde están
> sda5 a sda9 que son las lógicas.
> Si te fijas la suma de sus tamaños es igual a tamaño de sda1.

Cierto... parece que las particiones no están en orden.

Efectivamente, la partición extendida inicia en el sector 2046 y la sda5 
en el 2048, por lo que entiendo que el orden «real» es:

(extendida)
sda1 
↓
sda5
sda6
sda7
sda8
sda9

(primaria)
sda2

Se me hace raro ver una partición extendida al principio del disco y 
marcada como «arracable» :-?

Saludos,

-- 
Camaleón 



Re: normally start new xterms

2024-01-19 Thread Henning Follmann
On Fri, Jan 19, 2024 at 06:43:31AM +0100, to...@tuxteam.de wrote:
> On Thu, Jan 18, 2024 at 08:06:24PM +0100, Thomas Schmitt wrote:
> 
> [...]
> 
> > I have it in ~/.fvwm2rc as:
> > 
> > *FvwmButtons xterm_ts5 linuxterm.xpm Exec xterm -ls -geometry 80x24 -bg 
> > wheat -fg black -sl 1 +sb
> > 
> > This causes a button in the button box which creates a new xterm when
> > clicked.
> 
> I coopted the otherwise useless "Windows" key (aka "Left Super" for
> WM things: Super-L makes an xterm:
> 
>   # Terminal
>   Key   "t"   A   4  Exec exec xterm
> 
Interesting,
I always thought of you as an emacs guy, wouldn't that interfere with it? I
always used the left super as the Meta key (and if I am not wrong, that is
the default)

-H


-- 
Henning Follmann   | hfollm...@itcfollmann.com



Re: counting commas

2024-01-19 Thread fxkl47BF
On Fri, 19 Jan 2024, Thomas Schmitt wrote:

> Hi,
>
> Greg Wooledge wrote:
>> unicorn:~$ string="apple,banana,cherry,date"
>> unicorn:~$ commas=${string//[!,]/}
>> unicorn:~$ echo "${#commas}"
>> 3
>
> Always astonishing what a good bashism can do.
>
>
>> But at this point, we have to wonder what the *actual* goal is.

to exclude phrases with commas for seperate examination

>
> Up to now we only know about the astonishment of fxkl4...@protonmail.com
> that grep -c does not count characters.

i DID know that
that brain cell was offline at the moment
it needed a reminder to refresh the connection

>
> For a more complicated use case i would write a little C program where
> i'd be in control of every single bit of throughput.
> (Ok, C causes scars on the programmer's self esteem. But what does not
> kill me makes me just stronger. I'm a vim user.)

vi is the only way to go
i programmed c on hp/ux for 20+ years
had a room full of k200's
that was a lifetime ago



Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread gene heskett

On 1/19/24 04:50, Thomas Schmitt wrote:

Hi,

Anssi Saari

It does seem strange to me, even in MS-DOS era I was able to set a
terminal scrollback to 5000 lines without issue, when RAM was maybe 4 MB
and a DOS terminal program probably had access to way less than that.


I have no problems with 130 xterms of 10,000 lines each.



So does rsync really generate gigabytes of verbose output?


rsync can be extremely verbose when the number of transferred files is
very high.



Or is xfce-terminal storing the scrollback in a very inefficient way?


I would not be astonished to learn that the luxury ornamented terminals
of the various desktops waste many extra bytes when memorizing plain text.
But the real bug is the fact that the scroll back memory is unlimited and
can summon the OOM killer. (I imagine it like the Discworld Death of Rats.)

If i were a user of Xfce i would report this as bug to its Debian
maintainer. Bug title "xfce-terminal: A landmine on the kids' playground".


Have a nice day :)

Thomas

.

Excellent description Thomas. Love it.
Cheers, Gene Heskett.
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author, 1940)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis



Re: normally start new xterms

2024-01-19 Thread tomas
On Fri, Jan 19, 2024 at 09:11:21AM -0500, Henning Follmann wrote:
> On Fri, Jan 19, 2024 at 06:43:31AM +0100, to...@tuxteam.de wrote:
> > On Thu, Jan 18, 2024 at 08:06:24PM +0100, Thomas Schmitt wrote:
> > 
> > [...]
> > 
> > > I have it in ~/.fvwm2rc as:
> > > 
> > > *FvwmButtons xterm_ts5 linuxterm.xpm Exec xterm -ls -geometry 80x24 -bg 
> > > wheat -fg black -sl 1 +sb
> > > 
> > > This causes a button in the button box which creates a new xterm when
> > > clicked.
> > 
> > I coopted the otherwise useless "Windows" key (aka "Left Super" for
> > WM things: Super-L makes an xterm:
> > 
> >   # Terminal
> >   Key   "t"   A   4  Exec exec xterm
> > 
> Interesting,
> I always thought of you as an emacs guy,

This honours me :)

> wouldn't that interfere with it? I
> always used the left super as the Meta key (and if I am not wrong, that is
> the default)

No, no. On my keyboard, there's that "Windows" key courtesy of Microsoft,
and to its right is Alt, wich is my Emacs Meta. I could switch them, but
having a key with a window on it as "window manager key" seemed kind of
appropriate :)

Cheers
-- 
t


signature.asc
Description: PGP signature


Re: counting commas

2024-01-19 Thread Michael Grant
On Fri, Jan 19, 2024 at 09:25:14AM +0100, Thomas Schmitt wrote:
> fxkl4...@protonmail.com wrote:
> > why doesn't grep count 2 commas
> > echo 'Kích thước máy xay cỏ, giá máy thế nào , phụ tùng máy mua ở đâu' |
> > grep -c ,
> > 1

Here's my way:

$ echo 'Kích thước máy xay cỏ, giá máy thế nào , phụ tùng máy mua ở đâu' |  
fold -w1 | grep -c ,
2




signature.asc
Description: PGP signature


Re: counting commas

2024-01-19 Thread Thomas Schmitt
Hi,

Greg Wooledge wrote:
> unicorn:~$ string="apple,banana,cherry,date"
> unicorn:~$ commas=${string//[!,]/}
> unicorn:~$ echo "${#commas}"
> 3

Always astonishing what a good bashism can do.


> But at this point, we have to wonder what the *actual* goal is.

Up to now we only know about the astonishment of fxkl4...@protonmail.com
that grep -c does not count characters.

For a more complicated use case i would write a little C program where
i'd be in control of every single bit of throughput.
(Ok, C causes scars on the programmer's self esteem. But what does not
kill me makes me just stronger. I'm a vim user.)


Have a nice day :)

Thomas



Re: Request for translation of "Back In Time"

2024-01-19 Thread Daniel Venturini
Hey
I'm in

On Thu, Jan 18, 2024, 5:28 PM Joao Mandl  wrote:

> I will help as well.
> Thanks
>
>
>
> On Thu, Jan 18, 2024 at 5:22 PM Atenágoras Silva 
> wrote:
>
>> I'd like to help, too.
>>
>> Sincerely yours,
>> Atenágoras
>>
>> Em qui., 18 de jan. de 2024 às 13:01, Yuri Musachio <
>> yuri.musac...@gmail.com> escreveu:
>>
>>> Christian, hi!
>>>
>>> I will do.
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> Best,
>>>
>>> On Jan 18 2024, at 8:37 am, c.bu...@posteo.jp wrote:
>>>
>>> Hello,
>>>
>>> I am upstream maintainer of "Back In Time" [1] [2] a GUI backup tool
>>> using rsync in the back.
>>>
>>> I would like to kindly ask if someone want to contribute to the
>>> Portuguese translation of that application. The current state of
>>> translation is 23%.
>>>
>>> We offer a web-based front-end on our translation platform based on
>>> Weblate and hostet at Codeberg.org.
>>>
>>> 
>>>
>>> Thanks in advance
>>> Christian Buhtz
>>>
>>> [1] -- 
>>> [2] -- 
>>>
>>>


Re: counting commas

2024-01-19 Thread fxkl47BF
On Fri, 19 Jan 2024, Greg Wooledge wrote:

> On Fri, Jan 19, 2024 at 03:30:17PM +, fxkl4...@protonmail.com wrote:
 But at this point, we have to wonder what the *actual* goal is.
>>
>> to exclude phrases with commas for seperate examination
>
> Parsing natural language text is going to be tricky.  I can only talk
> about English, and not about whatever language your text is actually
> written in.
>
> Let's look at a few example English sentences:
>
>Good morning, John.
>
>I went to the store with Mary, Paul, Susan and Ralph.
>
>I won, and you lost.
>
>The bear, who was hungry, looked for food.
>
>Oh, that's interesting.
>
> These are five different examples of comma usage in English.  Do you
> happen to know in advance that your text will *only* contain samples
> that use the fourth style above?  Let's assume this.  Let's then form
> a template:
>
>STUFF, ASIDE, MORE STUFF, ASIDE, STILL MORE STUFF.
>
> I.e. given a sentence which conforms to expectation, we should see
> an even number of commas (is *THIS* why you were counting them??) and
> we should extract the ASIDEs from in between the first and second, then
> the third and fourth, and so on.
>
> So... uh, I guess my next question is: are you *pre-filtering* the
> sentences and keeping only the ones which have an even number of
> commas?  Or have you already *done* that, and now you're asking how
> to extract the ASIDEs?
>
> I really don't think I'd try this with shell scripts.  The tools just
> aren't designed for this.  You really want tools that are custom built
> for natural language processing, or a language that lets you run
> through a large string character by character in a fast, efficient
> way (C comes to mind) if you're trying to build your tools from the
> ground up.
>
> The "obvious" algorithm for extracting the ASIDEs would be use a
> simple finite state machine, and march through the sentence
> character by character.  When you encounter a comma, change state.
> Otherwise, if you're in the "ASIDE" state, copy the character to your
> output buffer.  When you leave the "ASIDE" state, terminate the current
> output buffer and move to the next one.  That's how I'd do it in C.
> Add whitespace trimming and so on.
>
> Also note that breaking a piece of natural language text *into*
> sentences in the first place is extraordinarily difficult.  If you
> haven't already got a way to do that, you're probably screwed.
> Seriously, asking the debian-user list how to count the number of
> commas in a text file is *not* a good sign if you're dealing with a
> masters-degree-level problem in natural language analysis.
>


certain characters give the interpreter a hard time
i'll just process what is easy for the interpreter
then work on the rest



Re: Re: Re: Como hacer una partición no destructiva?

2024-01-19 Thread Jude_xiomi Sago
El vie, 19 ene 2024 a las 13:50, Jude_xiomi Sago
() escribió:
>
> Hola, buen día!
>
> El jue, 18 ene 2024 a la(s) 3:22 p.m., Camaleón (noela...@gmail.com) escribió:
> >
> > El 2024-01-18 a las 08:36 -0500, Jude_xiomi Sago escribió:
> >
> > > El jue, 18 ene 2024 a las 8:32, Jude_xiomi Sago
> > > () escribió:
> > > >
> > > > El 2024-01-17 a las 14:44 -0500, Jude_xiomi Sago escribió:
> > > > Identificador del disco: 0xcbe73cf0
> > > > > 
> > > > > Disposit.  Inicio  Comienzo Final  Sectores Tamaño Id Tipo
> > > > > /dev/sda1  *   2046 107438079 107436034  51,2G  5 Extendida
> > > > > /dev/sda2 107438080 976773167 869335088 414,5G  7 
> > > > > HPFS/NTFS/exFAT
> > > > > /dev/sda5  2048  20269055  20267008   9,7G 83 Linux
> > > > > /dev/sda6  20271104  27674623   7403520   3,5G 83 Linux
> > > > > /dev/sda7  27676672  31848447   4171776 2G 82 Linux swap 
> > > > > / Solaris
> > > > > /dev/sda8  31850496  33257471   1406976   687M 83 Linux
> > > > > /dev/sda9  33259520 107438079  74178560  35,4G 83 Linux
> > > > >
> > >
> > > sda1 es partición extendida y ahí no hay nada
> >
> > Lo que me desconcierta es que ocupa 51,2 GiB :-?

Si!. Es desconcertante, pero esa fué la opción automática que me
propuso el instalador cuando se instaló bullseye en instalación limpia
(disco nuevo).
Lo cierto es debo actualizarme a la versión 12 y voy a intentar
solucionar el inconveniente de poco espacio para la raíz / .
Gracias por el interés...
>
> Da la impresión de que la partición sda1 es la extendida donde están
> sda5 a sda9 que son las lógicas.
> Si te fijas la suma de sus tamaños es igual a tamaño de sda1.
>
> > ...
> > Saludos,
> >
> > --
> > Camaleón
> >
>
> Saludos
> --
> Jorge A Secreto
> Analista de Sistemas
> MP 361
Gracias por el interés...



Re: counting commas

2024-01-19 Thread Greg Wooledge
On Fri, Jan 19, 2024 at 03:30:17PM +, fxkl4...@protonmail.com wrote:
> >> But at this point, we have to wonder what the *actual* goal is.
> 
> to exclude phrases with commas for seperate examination

Parsing natural language text is going to be tricky.  I can only talk
about English, and not about whatever language your text is actually
written in.

Let's look at a few example English sentences:

Good morning, John.

I went to the store with Mary, Paul, Susan and Ralph.

I won, and you lost.

The bear, who was hungry, looked for food.

Oh, that's interesting.

These are five different examples of comma usage in English.  Do you
happen to know in advance that your text will *only* contain samples
that use the fourth style above?  Let's assume this.  Let's then form
a template:

STUFF, ASIDE, MORE STUFF, ASIDE, STILL MORE STUFF.

I.e. given a sentence which conforms to expectation, we should see
an even number of commas (is *THIS* why you were counting them??) and
we should extract the ASIDEs from in between the first and second, then
the third and fourth, and so on.

So... uh, I guess my next question is: are you *pre-filtering* the
sentences and keeping only the ones which have an even number of
commas?  Or have you already *done* that, and now you're asking how
to extract the ASIDEs?

I really don't think I'd try this with shell scripts.  The tools just
aren't designed for this.  You really want tools that are custom built
for natural language processing, or a language that lets you run
through a large string character by character in a fast, efficient
way (C comes to mind) if you're trying to build your tools from the
ground up.

The "obvious" algorithm for extracting the ASIDEs would be use a
simple finite state machine, and march through the sentence
character by character.  When you encounter a comma, change state.
Otherwise, if you're in the "ASIDE" state, copy the character to your
output buffer.  When you leave the "ASIDE" state, terminate the current
output buffer and move to the next one.  That's how I'd do it in C.
Add whitespace trimming and so on.

Also note that breaking a piece of natural language text *into*
sentences in the first place is extraordinarily difficult.  If you
haven't already got a way to do that, you're probably screwed.
Seriously, asking the debian-user list how to count the number of
commas in a text file is *not* a good sign if you're dealing with a
masters-degree-level problem in natural language analysis.



Re: To partition or not to partition MD arrays (Was Re: smartctl cannotaccess my storage, need syntax help)

2024-01-19 Thread Franco Martelli

On 19/01/24 at 09:03, Anssi Saari wrote:

One case against using partitions on mdraid: if your array gets messed
up, you get to recreate those partition tables yourself and that's just
hilarious if you don't have a backup. Happened to a friend of mine,
reason was a UPS brownout.


How can I get a backup of mdadm RAID partition? And which tool to backup 
the whole disks of an array? The only tool that it comes in mind it is 
"dd" that it isn't a viable solution for me.
I think is useless to backup the raw data stored in a partition or the 
whole disk. I backup files and directories stored in the filesystem not 
raw data. If an error occurs in the RAID, mdadm takes care to warn me 
via email... I hope!



I think he scanned his disks for copies of
the superblock but didn't find any and then somehow with a lot of hassle
eventually figured out what the partition tables were.

So in a catastrophe, partition tables are one more obstacle to cross
before you can start actually recovering your data.


Me too ran into a catastrophe scenario, I had lost /dev/md0, the reason 
was using hibernate (suspend to disk) in a logical volume placed inside 
the RAID. I think it was damaged the RAID metadata.
I got rid of this using Debian-installer, I thought that I had loosed 
everything and I prepared for reinstall, when Debian-installer asked me 
to create the new RAID I specify all the four partitions, I saved, and 
magically the logical device and all my logical volumes, embedded in the 
old RAID, reappeared. To partition was not a trouble in those circumstances.




My only mdraid was on raw partitions but that never had any issues. I
think zfs effectively does the same, no partitions.


Which raw partitions? Maybe did you mean without partitions? I never 
used zfs it's full featured, I prefer to keep the things simple: RAID -> 
LVM -> ext4


Cheers,
--
Franco Martelli



Re: File has unexpected size (x != y). Mirror sync in progress? [IP: ...] ...

2024-01-19 Thread Max Nikulin

On 1/19/24, Max Nikulin wrote:

When adding a third-party repository, evaluate that GPG key you are
going to add really belongs to repository maintainers.


The sentence above is important to get the next phrase right.

On 19/01/2024 22:22, Albretch Mueller wrote:

On 1/19/24, Max Nikulin wrote:

Precise steps
depend on degree of your paranoia.

[...]

  I have always believe that Debian’s basic assumptions about using the
Internet as a relatively secure, “private” venue are definitely more
worryingly irrational than my paranoia.


Debian does not control 3rd party repositories. It is up to users to 
decide if they trust such repositories and if they trust web pages 
containing an identifiers of GPG public keys.


Actually even in the case of official Debian images you need to get 
identifiers of GPG keys. Do you trust https://debian.org/? Are you sure 
that browser's certificate storage doesn't contain an extra certificate? 
Are you sure that you are not visiting an alternative site and some 
certification authority from "official" ones has not issued an 
alternative debian.org certificate? A particular WiFi hotspot might have 
malicious DNS and might direct you to a site looking like debian.org, 
but containing another set of GPG keys and pointing to specially crafted 
download links.


APT is secure even for HTTP, but it needs proper GPG keys. APT might be 
insecure even for HTTPS if the user adds a malicious repository and GPG 
keys for it (or if the user disables GPG signatures checks).




Re: To partition or not to partition MD arrays (Was Re: smartctl cannotaccess my storage, need syntax help)

2024-01-19 Thread Nicolas George
Franco Martelli (12024-01-19):
> > One case against using partitions on mdraid: if your array gets messed
> > up, you get to recreate those partition tables yourself and that's just
> > hilarious if you don't have a backup. Happened to a friend of mine,
> > reason was a UPS brownout.
> How can I get a backup of mdadm RAID partition?

You do not need a backup of the RAID partitions, that would be terribly
inefficient. You need a backup of the partition table.

Which, if you are organized, you already have in
$notes_dir/$hostname/install.md as something that looks like this:

```
sudo sfdisk /dev/sdX <

signature.asc
Description: PGP signature


Re: normally start new xterms

2024-01-19 Thread David Wright
On Fri 19 Jan 2024 at 09:06:05 (+0100), Thomas Schmitt wrote:
> to...@tuxteam.de wrote:
> > I coopted the otherwise useless "Windows" key (aka "Left Super" for
> > WM things: Super-L makes an xterm:
> >  # Terminal
> >  Key   "t"   A   4  Exec exec xterm
> 
> For me the Flying Windows keys pop up or push down the affected window:
> 
>   Key Super_L A N RaiseLower
>   Key Super_R A N RaiseLower
> 
> What i don't understand in your example is the Keyname "t".
> man fvwm points me to /usr/include/X11/keysymdef.h or
> /usr/X11R6/lib/X11/XKeysymDB (which seems not exist in Debian except
> a file "XKeysymDB" of ipackage "xemacs21-support").
> 
> Do you know documentation which describes your "t" ?
> 
> (I see in my configuration that in the past i bound a pseudo-key F34 to
> keycodes 115 and 116 by xmodmap(1) and used the Keyname F34 with fvwm
> command "Key". After some system change i had to google and learned that
> "Super_L" and "Super_R" work without help of xmodmap.)

For my layout, I think these basic querty symbols come from:
/usr/share/X11/xkb/symbols/us, specifically:

key  {[ t,T   ]   };

with the gb file added for some of my keyboards. For you, perhaps,
I think /usr/share/X11/xkb/symbols/de is complete on its own.

An interactive method of finding the appropriate keysym is to run
xev and look at the keysym in the third line:

  KeyPress event, serial 36, synthetic NO, window 0x461,
root 0x6ab, subw 0x0, time 5446542, (2,170), root:(1324,199),
state 0x0, keycode 28 (keysym 0x74, t), same_screen YES,
XLookupString gives 1 bytes: (74) "t"
XmbLookupString gives 1 bytes: (74) "t"
XFilterEvent returns: False

  KeyRelease event, serial 36, synthetic NO, window 0x461,
root 0x6ab, subw 0x0, time 5446622, (2,170), root:(1324,199),
state 0x0, keycode 28 (keysym 0x74, t), same_screen YES,
XLookupString gives 1 bytes: (74) "t"
XFilterEvent returns: False

This is useful for finding out what all those keys with weird labels
send, like XF86AudioLowerVolume, XF86WakeUp, XF86TouchpadOff/On
and so on.

From the examples in man FvwmProxy, it would appear the quotes round
"t" are unnecessary:

   Undo and redo can be easily mapped to any keys.

   Key Z A 3 SendToModule FvwmProxy Undo
   Key R A 3 SendToModule FvwmProxy Redo

The only ordinary key I've modified is "/", which has the name slash,
and must be named as such. I substituted "m" without quotes, and that
worked correctly:

Key  slash  A  CMS  Exec exec xinput-xsession #quiet
 ↓
Key  m  A  CMS  Exec exec xinput-xsession #quiet

Cheers,
David.



Re: counting commas

2024-01-19 Thread debian-user
Greg Wooledge  wrote:

> I won, and you lost

There shouldn't be a comma in that sentence, in English. There is in
the closely related expression "I won, you lost."

> I really don't think I'd try this with shell scripts.  The tools just
> aren't designed for this.  You really want tools that are custom built
> for natural language processing, or a language that lets you run
> through a large string character by character in a fast, efficient
> way (C comes to mind) if you're trying to build your tools from the
> ground up.

At the risk of being seen as old-fashioned, but as a user of both
languages, I think Perl is a much better choice than C for string
processing. But whatever the OP knows is likely the best choice in the
short term.



Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread gene heskett

On 1/19/24 03:12, Anssi Saari wrote:

gene heskett  writes:


The OOM death of the system was the xfce4 terminal apparently being
set for unlimited scrollback and that was eating the memory. Switching
to Konsole with has the ability to control the scrollback to 200
lines, and its taken all 32G's as .cache and 1536 1k blocks of swap,
and its working w/o any OOM actions I've detected.


It does seem strange to me, even in MS-DOS era I was able to set a
terminal scrollback to 5000 lines without issue, when RAM was maybe 4 MB
and a DOS terminal program probably had access to way less than that. So
does rsync really generate gigabytes of verbose output? Or is
xfce-terminal storing the scrollback in a very inefficient way?

That I can't answer, other than -v outputs a full from / pathlist to 
everyfile it touchs, and if storing that in ram, I can sure see it 
eating 32G very quickly when it is moving 335G, it only got around 13G 
moved before OOM struck and killed the system, on each of probably 15 
attempts. Knowing that the tech of an SSD and the common micro-sd has a 
relatively limited actual write speed after in has used up its input 
cache of fast ram, I took the v off the -av, and them limited it to 
10megs a second, it took around 9 hours and the system acted normally, 
no OOM problens. I have edited the /etc/stab and am now running on that 
copy for /home.  The raid is now automounted to /raid10 and says its 
valid, despite the 4th drives log being a mess. My thoughts are to 
reverse the copy and put it in crontab to keep an uptodate backup of 
/home until I can re-invent my wrappers for amanda. /home is by far the 
biggest glop of data, and none of my printers or cnc machines will use 
more that 10G reach, so I'm inclinded to think of the other 8T of drives 
as an lvm managed 8T, which should give me room enough to keep 30 days 
worth of amanda's way of doing things.


But I'm hibernating for the nonce, I woke up at 6 with 6" of new snow on 
the deck, and the weather fabricators are promising another 24 hours of 
that, might wind up with 3 or 4 feet of it. I've got coffee, the 
freezers are well stocked.  Boring but safe.


All the messy logs were at hour 21027 so that was a single actual event, 
probably caused by OOM.


Take care Anssi, stay warm, dry and well where ever you are.

Cheers, Gene Heskett.
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author, 1940)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis



Re: counting commas

2024-01-19 Thread Greg Wooledge
On Fri, Jan 19, 2024 at 09:25:14AM +0100, Thomas Schmitt wrote:
> An answer to this question
>   
> https://stackoverflow.com/questions/16679369/count-occurrences-of-a-char-in-a-string-using-bash
> proposes
> echo "referee" | tr -cd 'e' | wc -c
> 
>   $ echo ',,,' | tr -cd ',' | wc -c
>   3

That's one way, and it's sh-compatible.

If you actually want to do it in *bash* as the URL suggests, you can
take advantages of bash's extra features, to avoid forking two new
programs plus a subshell.

unicorn:~$ string="apple,banana,cherry,date"
unicorn:~$ commas=${string//[!,]/}
unicorn:~$ echo "${#commas}"
3

In this case, I'm using the ${varname//old/new} expansion to remove
everything that isn't a comma.

But at this point, we have to wonder what the *actual* goal is.  They
wanted to count the number of commas... why, exactly?  Are they going
to split the input string into a list of substrings?  If so, just do
that in the first place.

unicorn:~$ IFS=, read -ra list <<< "$string,"
unicorn:~$ declare -p list
declare -a list=([0]="apple" [1]="banana" [2]="cherry" [3]="date")

To understand why I added an extra comma at the end of the input
string, see .

This approach needs adjustment if the input string may contain
newlines.  So, please state the actual goal up front, in full, and
include a worst-case-scenario example.

Finally, if the input is actually a CSV (Comma-Separated Values)
file, which may contain fields with commas *inside* them, then none
of these approaches work.  You need an actual CSV parser to handle
these files properly.



Re: Re: Re: Como hacer una partición no destructiva?

2024-01-19 Thread Jude_xiomi Sago
<

Cierto... parece que las particiones no están en orden.
Efectivamente, la partición extendida inicia en el sector 2046 y la sda5
en el 2048, por lo que entiendo que el orden «real» es:
(extendida)
sda1
↓
sda5
sda6
sda7
sda8
sda9
(primaria)
sda2
Se me hace raro ver una partición extendida al principio del disco y
marcada como «arracable» :-?
Saludos,

-- 
Camaleón
>

Y esa fué la opción automática que me propuso el instalador cuando se
instaló bullseye en instalación limpia (disco nuevo).
Pienso salvar lo que hay en /dev/sda2 en otro disco y volver a particionar
al estilo Windows: Hasta 4 particiones primarias y una extendida para /tmp,
/var y Swap.


Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread David Christensen

On 1/18/24 23:23, gene heskett wrote:

On 1/19/24 00:55, David Christensen wrote:
I am unclear if those errors are inside the SSD or if they are the 
SATA communications link between the SSD and the motherbaord or HBA 
port and/or main memory (?).  Does dmesg(1) show anything?


I'm not sure what I should be looking for, and I don't see anything that 
is looping to correct an error.  Suggested grep targets?



Here is a dmesg(1) excerpt from 2014 -- Debian 7, good SSD, bad SATA cable:

[2.086360] ata3.00: ATA-9: INTEL SSDSC2CW060A3, 400i, max UDMA/133
[2.086365] ata3.00: 117231408 sectors, multi 16: LBA48 NCQ (depth 
31/32), AA

[2.096265] ata3.00: configured for UDMA/133
[   14.718054] EXT4-fs (dm-0): mounted filesystem with ordered data 
mode. Opts: (null)
[   18.449227] EXT4-fs (sda1): mounted filesystem with ordered data 
mode. Opts: (null)
[   20.157693] ata3.00: exception Emask 0x10 SAct 0x40 SErr 0xc1 
action 0x6 frozen

[   20.157699] ata3.00: irq_stat 0x0800, interface fatal error
[   20.157703] ata3: SError: { RecovData Handshk LinkSeq }
[   20.157709] ata3.00: failed command: WRITE FPDMA QUEUED
[   20.157716] ata3.00: cmd 61/08:b0:a0:e0:61/00:00:00:00:00/40 tag 22 
ncq 4096 out

[   20.157721] ata3.00: status: { DRDY }
[   20.157727] ata3: hard resetting link
[   20.473489] ata3: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
[   20.484835] ata3.00: configured for UDMA/133
[   20.484847] ata3: EH complete
[   21.059825] ata3.00: exception Emask 0x10 SAct 0x4000 SErr 0x400100 
action 0x6 frozen

[   21.059831] ata3.00: irq_stat 0x0800, interface fatal error
[   21.059835] ata3: SError: { UnrecovData Handshk }
[   21.059840] ata3.00: failed command: WRITE FPDMA QUEUED
[   21.059848] ata3.00: cmd 61/08:70:50:e2:61/00:00:00:00:00/40 tag 14 
ncq 4096 out

[   21.059853] ata3.00: status: { DRDY }
[   21.059859] ata3: hard resetting link
[   21.376135] ata3: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
[   21.397234] ata3.00: configured for UDMA/133
[   21.397246] ata3: EH complete
[   22.590805] ata3.00: exception Emask 0x10 SAct 0x600 SErr 0x400100 
action 0x6 frozen

[   22.590811] ata3.00: irq_stat 0x0800, interface fatal error
[   22.590815] ata3: SError: { UnrecovData Handshk }
[   22.590819] ata3.00: failed command: WRITE FPDMA QUEUED
[   22.590826] ata3.00: cmd 61/08:48:f0:ee:1d/00:00:00:00:00/40 tag 9 
ncq 4096 out

[   22.590831] ata3.00: status: { DRDY }
[   22.590834] ata3.00: failed command: WRITE FPDMA QUEUED
[   22.590840] ata3.00: cmd 61/08:50:70:ef:1d/00:00:00:00:00/40 tag 10 
ncq 4096 out

[   22.590844] ata3.00: status: { DRDY }
[   22.590851] ata3: hard resetting link
[   22.909955] ata3: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
[   22.921525] ata3.00: configured for UDMA/133
[   22.937878] ata3: EH complete
[   22.938635] ata3: limiting SATA link speed to 3.0 Gbps
[   22.938638] ata3.00: exception Emask 0x10 SAct 0x40 SErr 0x400100 
action 0x6 frozen

[   22.938640] ata3.00: irq_stat 0x0800, interface fatal error
[   22.938642] ata3: SError: { UnrecovData Handshk }
[   22.938645] ata3.00: failed command: WRITE FPDMA QUEUED
[   22.938648] ata3.00: cmd 61/60:b0:20:28:66/00:00:00:00:00/40 tag 22 
ncq 49152 out

[   22.938650] ata3.00: status: { DRDY }
[   22.938652] ata3: hard resetting link
[   23.257418] ata3: SATA link up 3.0 Gbps (SStatus 123 SControl 320)
[   23.269251] ata3.00: configured for UDMA/133
[   23.285387] ata3: EH complete


In any case, make sure that you are using SATA III 6 Gbps cables with 
locking connectors for your drives and that all the connections are good.


That's hard to verify once the cables are removed from the packing. all 
are black, with locking clips  There is a cable maker under every tree 
in china so I'n not swearing any are up to specs, I've had cable problem 
in the past but usually a magenta colored on that is over 2 years old, 
If you have a known good src on straight on cables, please share.  You 
would be doing everyone a favor. 



https://www.cablematters.com/pc-187-156-3-pack-straight-60-gbps-sata-iii-cable.aspx

https://www.cablematters.com/pc-188-156-cable-matters-3-pack-90-degree-right-angle-60-gbps-sata-iii-cable-18-inches.aspx


Test what you have by taking a wooden stick and moving each one a 
centimeter or so, if the log blows up with sata resets, bingo, bad 
cable. replace it asap.



I call that the "wiggle" test.


David



Re: File has unexpected size (x != y). Mirror sync in progress? [IP: ...] ...

2024-01-19 Thread Albretch Mueller
On 1/19/24, Andrew M.A. Cater  wrote:
> On Fri, Jan 19, 2024 at 03:22:52PM +, Albretch Mueller wrote:
>> On 1/19/24, Max Nikulin  wrote:
>> > Precise steps
>> > depend on degree of your paranoia.
>>  ... and mine is of the totally irrevocable, even joyful kind; so,
>> where are the steps?
>>  I have always believe that Debian’s basic assumptions about using the
>> Internet as a relatively secure, “private” venue are definitely more
>> worryingly irrational than my paranoia.
>>  I think at some point I will have to learn more about Debian’s apt
>> utility. Any documentation you would suggest explaining it all from
>> the protocoled structure of deb packages to the various installation
>> procedures depending on degree of paranoia? When I learn something I
>> like to learn all of it.
> What aspect? apt sits on top of package dependencies, package signing,
> package validation ...

 Well, "my mind" has been partially trained, partially conditioned to
be kind of mix of poetic/artistic, scientific (mostly Math and
Physics, but anything empirical I find fascinating and technical
things somewhat, but I can’t be abused by all that AI cr@p you find
everywhere these days) and downright paranoid and proudly, joyfully so
;-)

 To me saying that you can ensure security, that thing they used to
call "privacy", ... with software would be like saying that you could
invent some sort of esperanto which would not allow for people to lie.

 Package dependencies to me are just DAGs, what I am mostly interested
in is how the various hard-, soft- and "mind"-ware "techne" aspects
related to one another and for that kind of semiotic study you need to
look into the grammar established by the different processes that go
on a computer. The nodes of the DAGs (the "characters" of that
grammar) conditioning the different kinds of transformations offered
by the packages’ utilities when programs run. So, to start I would
like to study the Debian packages and how dpkg establishes and keeps
those dependencies. What happens on the hire and on the repositories
with certificates ... I haven’t found a book yet, explaining it all.
At times I have found great explanations about single aspects.

 lbrtchx



Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread David Christensen

On 1/19/24 00:03, Anssi Saari wrote:

My only mdraid was on raw partitions but that never had any issues. I
think zfs effectively does the same, no partitions.



You can do it either way on ZFS.


David




Re: iscrizioni lista

2024-01-19 Thread Andrew M.A. Cater
Esiste una lista debian-italian. Vedi anche 
https://www.debian.org/MailingLists/index.it.html

Buon anno anche a te

[There is also a Debian-italian list. See also MailingLists page]

Andy
(amaca...@debian.org



Re: To partition or not to partition MD arrays (Was Re: smartctl cannotaccess my storage, need syntax help)

2024-01-19 Thread Franco Martelli

On 19/01/24 at 20:14, Nicolas George wrote:

Franco Martelli (12024-01-19):

One case against using partitions on mdraid: if your array gets messed
up, you get to recreate those partition tables yourself and that's just
hilarious if you don't have a backup. Happened to a friend of mine,
reason was a UPS brownout.

How can I get a backup of mdadm RAID partition?


You do not need a backup of the RAID partitions, that would be terribly
inefficient. You need a backup of the partition table.


Yes, I agree of course. I was asking this to Anssi because it looks like 
strange to me to have the backup of the partitions, as he pointed (for 
my understanding)




Which, if you are organized, you already have in
$notes_dir/$hostname/install.md as something that looks like this:

```
sudo sfdisk /dev/sdX <

The partitions table of my HDD is part of my backup.

Cheers,

--
Franco Martelli



Re: counting commas

2024-01-19 Thread John Hasler
 debian-u...@howorth.org.uk writes:
> There shouldn't be a comma in that sentence, in English. There is in
> the closely related expression "I won, you lost."

The program has to be able to deal with bad writing.

> At the risk of being seen as old-fashioned, but as a user of both
> languages, I think Perl is a much better choice than C for string
> processing.

Use SPITBOL.
-- 
John Hasler 
j...@sugarbit.com
Elmwood, WI USA



Re: Request for translation of "Back In Time"

2024-01-19 Thread Rogerio R. Silva
Hi Christian,

I could help if there are not enough people working on this.
Please, let me know.

Best regards,
Rogério

Em sex., 19 de jan. de 2024 às 17:12, Daniel Venturini <
danielventurini...@gmail.com> escreveu:

> Hey
> I'm in
>
> On Thu, Jan 18, 2024, 5:28 PM Joao Mandl  wrote:
>
>> I will help as well.
>> Thanks
>>
>>
>>
>> On Thu, Jan 18, 2024 at 5:22 PM Atenágoras Silva 
>> wrote:
>>
>>> I'd like to help, too.
>>>
>>> Sincerely yours,
>>> Atenágoras
>>>
>>> Em qui., 18 de jan. de 2024 às 13:01, Yuri Musachio <
>>> yuri.musac...@gmail.com> escreveu:
>>>
 Christian, hi!

 I will do.







 Best,

 On Jan 18 2024, at 8:37 am, c.bu...@posteo.jp wrote:

 Hello,

 I am upstream maintainer of "Back In Time" [1] [2] a GUI backup tool
 using rsync in the back.

 I would like to kindly ask if someone want to contribute to the
 Portuguese translation of that application. The current state of
 translation is 23%.

 We offer a web-based front-end on our translation platform based on
 Weblate and hostet at Codeberg.org.

 

 Thanks in advance
 Christian Buhtz

 [1] -- 
 [2] -- 



-- 
Rogério R. Silva | SCIANTS 
Museu Paraense Emílio Goeldi - MPEG
Depto. Ciências da Terra e Ecologia
Av. Perimetral, 1901 - Terra Firme
66077-830, Belém, PA, Brasil
Fone: +55 91 3221-6446


Re: File has unexpected size (x != y). Mirror sync in progress? [IP: ...] ...

2024-01-19 Thread David Wright
On Fri 19 Jan 2024 at 22:19:21 (+), Albretch Mueller wrote:

>  Package dependencies to me are just DAGs,

Are they? No circular dependencies?

> [ … ] I haven’t found a book yet, explaining it all.
> At times I have found great explanations about single aspects.

What sales figures would you expect to see with such a book?

Cheers,
David.



phpmyadmin en panne

2024-01-19 Thread ajh-valmer
Depuis peu, je lance phpmyadmin normalement sous Debian bookworm,
mais lorsque je tape une commande SQL, je reçois ceci :

"Erreur dans le traitement de la requête,
Code d'erreur : 403.
Texte de l'erreur : Forbidden (rejected)
Il semble que la connexion au serveur aie été perdue. 
Merci de vérifier la connectivité réseau et l'état du serveur".

# dpkg-reconfigure phpmyadmin :
dbconfig-common: writing config to /etc/dbconfig-common/phpmyadmin.conf
dbconfig-common: flushing administrative password

# service mysql restart
mysql: unrecognized service

Je ne sais comment réparer...

Bonne fin de soirée,

A. Valmer






Re: standardize uid:gid?

2024-01-19 Thread David Wright
On Thu 18 Jan 2024 at 07:31:05 (-0500), Greg Wooledge wrote:
> On Thu, Jan 18, 2024 at 05:38:37AM -, David Chmelik wrote:
> > Couldn't Debian standardize uid:gid numbers for daemons?
> 
> The thing is, Debian has tens of thousands of packages, and any one
> of these packages is capable of creating new UIDs and/or GIDs if it
> feels like doing so.  There is no centralized place where all of the
> possible UIDs and GIDs are registered.  It's all ad hoc.
> 
> If a centralized UID/GID registry were to be created, the following
> results would occur:

Debian does have four very small ID registries, two are in
base-passwd: /usr/share/base-passwd/{passwd,group}.master.¹
At a purely local level, what would be the consequences of
extending those files to cover all the expected UID/GIDs on
a network of pet PCs (as opposed to cattle). Obviously this
would have to be done at the earliest opportunity.

>  * Every package that creates one would have to be updated in a
>non-trivial manner.  By its maintainer.  Thousands of separate
>maintainers.  A cat-herd of Debian developers, who do this work
>in their spare time, as they get around to it.

A local sysadmin might try wrapping adduser/useradd, or whatever,
to insert/override choices. Or else new packages would have to be
examined before their installation, and UID/GIDs added manually.

>  * Every obscure, niche package's users and groups would have to be
>added to every Debian system. [ … ]
>  * Did I mention that every Debian system in existence would have to
>have ALL of its users and groups redone? [ … ]
>  * This change would have to be made by a human being running a
>conversion script as root in single-user mode, [ … ]
> 
> This is one of those "the boat has already left the dock" situations.
> If this were going to happen, it would have to have happened in the
> early 1990s.  There is no feasible way to make it happen now.

Agreed, for any sort of Debian or non-local reconfiguration.

¹ There are some reserved high IDs documented in the README, which
  are set when the relevant packages are installed.

Cheers,
David.



Re: counting commas

2024-01-19 Thread David Wright
On Fri 19 Jan 2024 at 17:25:10 (+), debian-u...@howorth.org.uk wrote:
> Greg Wooledge  wrote:
> 
> > I won, and you lost
> 
> There shouldn't be a comma in that sentence, in English. There is in
> the closely related expression "I won, you lost."

That's rather proscriptive. "I won and you lost." and
"I won, and you lost." are two different sentences.

The first is a more neutral statement of fact. The
second carries an implication of triumphalism or
mockery: many speakers would expect a swoop upwards
in intonation on "won", a pause, and a steep drop
between "you" and "lost"; kinda like:

  -⭜   ·¯⭝

if that works in your font.

What you lose (sorry) in "I won, you lost." is the
anacrusis, the ·, which many would pronounce "ən",
as in ənyeeoo. Without it, I'd be inclined to write
"I won. You lost." (similar intonation).

Disclaimer: my choice of intonation was to illustrate
one difference. There are many more ways of saying
all of those sentences.

Cheers,
David.



Re: Probable bug in mc shell link when reading non-ASCII file names

2024-01-19 Thread tomas
On Sat, Jan 20, 2024 at 12:20:55AM +0100, ju...@op.pl wrote:
> I'm not sure if this is actually a bug in the mc package or maybe somewhere 
> in sshd or in some library that uses ssh. That's why I didn't report it via 
> reportbug. Anyway, I noticed the effects only in Shell Link in mc. SSH in the 
> terminal works fine. FTP Link in mc also works properly.
> The bug appeared today and is visible on all computers connecting to remote 
> Debian Testing systems regardless of MC version (I tested it with mc from 
> Ubuntu 18 and from the current Mint). File and directory names on the remote 
> Debian Testing computer containing UTF-8 Non-ASCII characters are displayed 
> incorrectly and the files and directories cannot be read.
> For example, instead of a file with a name containing the Polish letters 
> "AąCćEę", Shell Link mc sees a file named "A304205C304207E304231".
> Can anyone advise me which package this error should be reported for?

Hm. It seems that mc gets confused with the way the "other side" tells
it what encoding it uses.

I'd go for mc, because they know best how it interprets the remote
encoding.

Cheers
-- 
t


signature.asc
Description: PGP signature


Re: top bar the way I want it

2024-01-19 Thread David Christensen

On 1/19/24 21:53, Maureen L Thomas wrote:
I am using Gnome, and I found the stuff I needed to get my desktop the 
way I wanted it.  I am very happy about it.  Now I just have to put 
NordVPN to connect with my browser.  Thank you for the help, it is 
greatly appreciated.



I am glad it worked out for you.  :-)


Part of participating in an Internet mailing list like debian-user is 
posting the solution to your question, so that other people can benefit. 
 Please document your solution.



David



Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread David Christensen

On 1/19/24 21:34, gene heskett wrote:

On 1/19/24 20:29, Felix Miata wrote:

gene heskett composed on 2024-01-19 19:09 (UTC-0500):

On 1/19/24 15:56, David Christensen wrote:

https://www.cablematters.com/pc-187-156-3-pack-straight-60-gbps-sata-iii-cable.aspx



Cheap enough at 18", ordered 4 packs of 3 for service & build stock,
thanks David.


Among the elements of that page, opened in web browser lacking JS 
support, was

absence of a price, and also were the following "features":

Serial ATA/150
and
Fast data transfer rate of up to 150 Mbps

Those describe SATA revision 1.0 (1.5 Gbit/s), not SATA revision 2.0 
(300MB/s, 3.0

Gbit/s), not SATA revision 3.0 (600MB/s, 6.0 Gbit/s).
https://en.wikipedia.org/wiki/SATA

With JS enabled, the page radically changed to show $8.49 for a 3-pack 
of 6.0

Gbit/s cables.


They had 2 lengths, 24" will if everything isn't good, sign on as 
sata-II but the 18" I bought claim sata-III.



I bought black cables, 18" and 24", straight-straight and straight-90. 
The older ones are labeled "Serial ATA 6G".  The newer ones are labeled 
"Serial ATA3.2".



David



Re: Connamon: Desklet "Network usage monitor" fills logfiles

2024-01-19 Thread Chris Jölly

Hello,

that issue was already reported "upstream" and is fixed in the meantime. 
The issue was a compatibility issue with Clutter.


Cheers

On 1/14/24 18:11, Chris Jölly wrote:


Hello,

I try to use the desklet Network usage monitor which I can download 
using the Desklet control.


It downloads and installs without issues, and when I try to activate 
it it is not shown on the desktop. vnstat and vnstati are installed.


Looking into the logs with journalctl, the following error message is 
shown 3 times every 2 seconds:


Jan 14 08:07:58 laptop1 cinnamon[2643]: JS ERROR: TypeError: 
Clutter.Texture is not a constructor

_updateGraph/<@/home/chris/.local/share/cinnamon/desklets/netus...@30yavash.com/4.0/desklet.js:144:29
spawnCommandLineAsync/<@/usr/share/cinnamon/js/misc/util.js:206:17

The code around line 144 in desklet.js is:

   if (this._device != "null") {
   if (!this.useExtendedDisplay) { this.extendedDisplay = 
"-s" };
   let image = 
`${path}/vnstatImage_${this._device}_${this.extendedDisplay}.png`;
   let command = 'vnstati ' + this.extendedDisplay + ' -ne 
-i ' + this._device + ' -o ' + image ;

// GLib.spawn_command_line_async(command);

   Util.spawnCommandLineAsync(command, () => {
    let l = new Clutter.BinLayout();
    let b = new Clutter.Box();
    let c = new Clutter.Texture({keep_aspect_ratio: 
true, filter_quality: 2, filename: image });

    b.set_layout_manager(l);
*    b.add_actor(c);*
    this.imageWidget.destroy_all_children();
    this.imageWidget.set_child(b);
    });
 }


I used Alf+F2 and "lg" to get more insights, but was not successful. I 
can see that Clutter is provided with the package cinnamon-common, but 
I could not find the definition of Clutter.Texture. But I am not a 
Javscript developer, so just tried to grep around a little bit.


I read that whole Clutter is already unmaintained. Does it look like 
those Clutter based Cinnamon stuff is slowly fading out?


BR

Chris


Re: Probable bug in mc shell link when reading non-ASCII file names

2024-01-19 Thread Sven Joachim
On 2024-01-20 00:20 +0100, ju...@op.pl wrote:

> I'm not sure if this is actually a bug in the mc package or maybe
> somewhere in sshd or in some library that uses ssh. That's why I
> didn't report it via reportbug. Anyway, I noticed the effects only in
> Shell Link in mc. SSH in the terminal works fine. FTP Link in mc also
> works properly.
> The bug appeared today and is visible on all computers connecting to
> remote Debian Testing systems regardless of MC version (I tested it
> with mc from Ubuntu 18 and from the current Mint). File and directory
> names on the remote Debian Testing computer containing UTF-8 Non-ASCII
> characters are displayed incorrectly and the files and directories
> cannot be read.
> For example, instead of a file with a name containing the Polish
> letters "AąCćEę", Shell Link mc sees a file named
> "A304205C304207E304231".

Interesting.  I can reproduce that, it has apparently been triggered by
the Perl upgrade from 5.36 to 5.38.

> Can anyone advise me which package this error should be reported for?

The mc package.  You can tag the bug as forwarded to
https://midnight-commander.org/ticket/4507, which has already been
closed.  The fix will be part of mc 4.8.31, if you are lucky the Debian
maintainers cherry-pick it earlier.

Cheers,
   Sven



Re: Request for translation of "Back In Time"

2024-01-19 Thread c.buhtz
Dear Rogerio,

thanks for your offer.

On 2024-01-19 17:16 "Rogerio R. Silva"  wrote:
> I could help if there are not enough people working on this.
> Please, let me know.

Portuguese is still at 34%. But Brazilian is complete.

Beside translating untranslated strings there is also a need to review
the existing translations via using the "Approve" button.

Please let me know if and how you want to be mentioned in the credits
as a translator. It is up to you if you want to use your real name,
your email or something else.

We do have this file:


That names will be used in the about dialog for example.

Kind
Christian



Re: Probable bug in mc shell link when reading non-ASCII file names

2024-01-19 Thread Sven Joachim
On 2024-01-20 08:44 +0100, Sven Joachim wrote:

> On 2024-01-20 00:20 +0100, ju...@op.pl wrote:
>
>> I'm not sure if this is actually a bug in the mc package or maybe
>> somewhere in sshd or in some library that uses ssh. That's why I
>> didn't report it via reportbug. Anyway, I noticed the effects only in
>> Shell Link in mc. SSH in the terminal works fine. FTP Link in mc also
>> works properly.
>> The bug appeared today and is visible on all computers connecting to
>> remote Debian Testing systems regardless of MC version (I tested it
>> with mc from Ubuntu 18 and from the current Mint). File and directory
>> names on the remote Debian Testing computer containing UTF-8 Non-ASCII
>> characters are displayed incorrectly and the files and directories
>> cannot be read.
>> For example, instead of a file with a name containing the Polish
>> letters "AąCćEę", Shell Link mc sees a file named
>> "A304205C304207E304231".
>
> Interesting.  I can reproduce that, it has apparently been triggered by
> the Perl upgrade from 5.36 to 5.38.
>
>> Can anyone advise me which package this error should be reported for?
>
> The mc package.  You can tag the bug as forwarded to
> https://midnight-commander.org/ticket/4507, which has already been
> closed.  The fix will be part of mc 4.8.31, if you are lucky the Debian
> maintainers cherry-pick it earlier.

I have attached the patch which fixes the bug.  You can apply it
directly to /usr/lib/mc/fish/ls, if you do not mind that tools like
debsums and "dpkg --verify" might complain about the changed file.

Cheers,
   Sven

diff --git a/src/vfs/shell/helpers/ls b/src/vfs/shell/helpers/ls
index 4c8ca21137..c7701d644f 100644
--- a/src/vfs/shell/helpers/ls
+++ b/src/vfs/shell/helpers/ls
@@ -122,9 +122,8 @@ SHELL_DIR=$1
 perl -e '
 use strict;
 use POSIX;
-use Fcntl;
-use POSIX ":fcntl_h"; #S_ISLNK was here until 5.6
-import Fcntl ":mode" unless defined _ISLNK; #and is now here
+use Fcntl ":mode";  # S_ISLNK, S_IFMT, S_IMODE are here
+use POSIX ":fcntl_h";   # S_ISLNK might be here as well
 my $dirname = $ARGV[0];
 if (opendir (DIR, $dirname)) {
 while((my $filename = readdir (DIR))){


Probable bug in mc shell link when reading non-ASCII file names

2024-01-19 Thread jureq
I'm not sure if this is actually a bug in the mc package or maybe somewhere in 
sshd or in some library that uses ssh. That's why I didn't report it via 
reportbug. Anyway, I noticed the effects only in Shell Link in mc. SSH in the 
terminal works fine. FTP Link in mc also works properly.
The bug appeared today and is visible on all computers connecting to remote 
Debian Testing systems regardless of MC version (I tested it with mc from 
Ubuntu 18 and from the current Mint). File and directory names on the remote 
Debian Testing computer containing UTF-8 Non-ASCII characters are displayed 
incorrectly and the files and directories cannot be read.
For example, instead of a file with a name containing the Polish letters 
"AąCćEę", Shell Link mc sees a file named "A304205C304207E304231".
Can anyone advise me which package this error should be reported for?
 
Jureq

Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread gene heskett

On 1/19/24 15:56, David Christensen wrote:
No sign of that snipped stuff.


https://www.cablematters.com/pc-187-156-3-pack-straight-60-gbps-sata-iii-cable.aspx


Cheap enough at 18", ordered 4 packs of 3 for service & build stock, 
thanks David.



I call that the "wiggle" test.


So do I but I've had to explain it.  Several times.

Now they'll have to dig me out, got around 16" of white stuff in the 
last 36 hrs. I believe winter has arrived.


Cheers, Gene Heskett.
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author, 1940)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis



Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread Felix Miata
gene heskett composed on 2024-01-19 19:09 (UTC-0500):

> On 1/19/24 15:56, David Christensen wrote:

> No sign of that snipped stuff.
> 
>> https://www.cablematters.com/pc-187-156-3-pack-straight-60-gbps-sata-iii-cable.aspx

> Cheap enough at 18", ordered 4 packs of 3 for service & build stock, 
> thanks David. 

Among the elements of that page, opened in web browser lacking JS support, was
absence of a price, and also were the following "features":

Serial ATA/150
and
Fast data transfer rate of up to 150 Mbps

Those describe SATA revision 1.0 (1.5 Gbit/s), not SATA revision 2.0 (300MB/s, 
3.0
Gbit/s), not SATA revision 3.0 (600MB/s, 6.0 Gbit/s).
https://en.wikipedia.org/wiki/SATA

With JS enabled, the page radically changed to show $8.49 for a 3-pack of 6.0
Gbit/s cables.
-- 
Evolution as taught in public schools is, like religion,
based on faith, not based on science.

 Team OS/2 ** Reg. Linux User #211409 ** a11y rocks!

Felix Miata



Re: counting commas

2024-01-19 Thread Nicholas Geovanis
On Fri, Jan 19, 2024, 6:52 PM John Hasler  wrote:

>  debian-u...@howorth.org.uk writes:
> > The
> > At the risk of being seen as old-fashioned, but as a user of both
> > languages, I think Perl is a much better choice than C for string
> > processing.
>
> Use SPITBOL.
>

Another SPITBOL user lives??!? :-)
It should all be open-source by now
Is it?

John Hasler
> j...@sugarbit.com
> Elmwood, WI USA
>
>


Re: counting commas

2024-01-19 Thread Nicholas Geovanis
On Fri, Jan 19, 2024, 9:24 PM John Hasler  wrote:

> > Another SPITBOL user lives??!? :-)
>
> It's been decades since I used it.
>
> > It should all be open-source by now
> > Is it?
>
> http://www.snobol4.com/
>
> A search finds this:
>

Well thank you so much John. They are giving away for free Spitbol 360/70,
and for the past year I just so happen to have an IBM mainframe laying
around again :-)
One of my CS profs in college was Glenn Manacher who had been a maintainer
of Snobol at Bell labs in New Jersey.


https://github.com/spitbol/x64
>
> I haven't looked at it.  I'm surprised it isn't in Debian.
> --
> John Hasler
> j...@sugarbit.com
> Elmwood, WI USA
>


Re: smartctl cannot access my storage, need syntax help

2024-01-19 Thread gene heskett

On 1/19/24 20:29, Felix Miata wrote:

gene heskett composed on 2024-01-19 19:09 (UTC-0500):


On 1/19/24 15:56, David Christensen wrote:



No sign of that snipped stuff.


https://www.cablematters.com/pc-187-156-3-pack-straight-60-gbps-sata-iii-cable.aspx



Cheap enough at 18", ordered 4 packs of 3 for service & build stock,
thanks David.


Among the elements of that page, opened in web browser lacking JS support, was
absence of a price, and also were the following "features":

Serial ATA/150
and
Fast data transfer rate of up to 150 Mbps

Those describe SATA revision 1.0 (1.5 Gbit/s), not SATA revision 2.0 (300MB/s, 
3.0
Gbit/s), not SATA revision 3.0 (600MB/s, 6.0 Gbit/s).
https://en.wikipedia.org/wiki/SATA

With JS enabled, the page radically changed to show $8.49 for a 3-pack of 6.0
Gbit/s cables.


They had 2 lengths, 24" will if everything isn't good, sign on as 
sata-II but the 18" I bought claim sata-III.


Cheers, Gene Heskett.
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author, 1940)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis



Re: counting commas

2024-01-19 Thread gene heskett

On 1/19/24 21:48, Nicholas Geovanis wrote:
On Fri, Jan 19, 2024, 2:07 PM Thomas Schmitt > wrote:


.

(Ok, C causes scars on the programmer's self esteem. But what does not
kill me makes me just stronger. I'm a vim user.)


OK I'll mention that to my psychiatrist :-)
But the C programmers I knew were either really nice guys if they wrote 
C on unix, or real toads if they wrote C for DOS/Windows. YMMV




Have a nice day :)

Thomas
Back in my Amiga days 25-35 years ago, I did my stuff in SAS-C or ARexx 
and compiled the ARexx too. ARexx actually had wrappers for every call 
Amigados had. Absolutely nothing you could not do in ARexx.  Amigados 
did not have a cron so we wrote one in ARexx and gave it away. Jim Hines 
and I wrote the first tv stations web page ever, dedicated a dialup line 
so folks could read the teleprompter text on their home computers.  It 
was a wild west in those days. Now everybody had a web page but me.



Cheers, Gene Heskett.
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author, 1940)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis



Re: top bar the way I want it

2024-01-19 Thread Maureen L Thomas
I am using Gnome, and I found the stuff I needed to get my desktop the 
way I wanted it.  I am very happy about it.  Now I just have to put 
NordVPN to connect with my browser.  Thank you for the help, it is 
greatly appreciated.


On 1/19/24 7:17 AM, Joe wrote:

  On 1/18/24 1:17 AM, Beyond Insulted wrote:

On Wed, Jan 17, 2024 at 08:40:30PM -0500, Maureen L Thomas wrote:

 I now have a system that works but I cannot find any
utility to fix the top bar the way I want it.  Any hints?

Try to understand the audience that is being asked.

Imaging that they were willing to help and stopped doing so
because the "the way I want it" is a way too poor description.

 

Moe

Groeten
Geert Stappers

On Thu, 18 Jan 2024 23:02:21 -0500
Maureen L Thomas  wrote:


I am sorry for the way I said that.  What I want is the very top bar,
before I re-installed it had three topics on the very top left hand
that allowed me to click on one of them and get a menu of all the
software installed and in order according to the topic.  Like under
internet would list all the internet software. Right now I have to
use that dot thing to see what is installed. It is a pain.  I cannot
find the utility to change the settings for the top bar or the bottom
bar or the sidebar I used daily with a list of the browsers, and
special software that is used daily. Again I apologize for the
previous, I was very uptight over my inability to remember what I
need to do.


We cannot all recollect all that has gone before.

There is very large flexibility as to the Linux display. There are four
major desktop environments and several derivatives of them. Some people
don't use a DE at all, just a window manager.

I use Xfce4 and its own panels, with one panel to the top left and one
panel top right, with a third tiny panel just containing an analogue
clock.

Most configuration can be achieved by right-clicking on a panel then
Panel-> Panel Preferences. The size, position and number of panels can
be controlled in that way. Launchers can be added to panels, and
applications can be added to launchers. Mostly one launcher contains
one application.

I don't know what display configuration you have, but a good start is
to right-click on whatever bars you have, and explore the menus.

The main application menu can pretty much always be opened by
right-clicking on an empty part of the desktop and choosing
Applications. This set of menus, grouped as you say be approximate
function, can be edited by a couple of applications, one of which is the
Gnome alacarte, which I use. This is not normally installed by default
on Debian, but can be installed in the usual way. If you don't already
have Gnome or some of its applications, it will probably bring in a
distressing list of dependencies.

Let us know more about what desktop environment you use, and we can
probably give better advice. Unfortunately, while reinstalling can fix
many problems fairly easily, it does bring with it the need to rebuild
the configurations of many things.


Re: counting commas

2024-01-19 Thread Peter Hillier-Brook

On 19/01/2024 23:02, David Wright wrote:

On Fri 19 Jan 2024 at 17:25:10 (+), debian-u...@howorth.org.uk wrote:

Greg Wooledge  wrote:


I won, and you lost


There shouldn't be a comma in that sentence, in English. There is in
the closely related expression "I won, you lost."


Anything other than this *accurate* statement would have led to a caning 
in my grammar school in the late '40s. :-)


Peter HB


That's rather proscriptive. "I won and you lost." and
"I won, and you lost." are two different sentences.

The first is a more neutral statement of fact. The
second carries an implication of triumphalism or
mockery: many speakers would expect a swoop upwards
in intonation on "won", a pause, and a steep drop
between "you" and "lost"; kinda like:

   -⭜   ·¯⭝

if that works in your font.

What you lose (sorry) in "I won, you lost." is the
anacrusis, the ·, which many would pronounce "ən",
as in ənyeeoo. Without it, I'd be inclined to write
"I won. You lost." (similar intonation).

Disclaimer: my choice of intonation was to illustrate
one difference. There are many more ways of saying
all of those sentences.

Cheers,
David.





Re: counting commas

2024-01-19 Thread Nicholas Geovanis
On Fri, Jan 19, 2024, 2:07 PM Thomas Schmitt  wrote:

> .

(Ok, C causes scars on the programmer's self esteem. But what does not
> kill me makes me just stronger. I'm a vim user.)
>

OK I'll mention that to my psychiatrist :-)
But the C programmers I knew were either really nice guys if they wrote C
on unix, or real toads if they wrote C for DOS/Windows. YMMV

>

Have a nice day :)
>
> Thomas
>
>


Re: counting commas

2024-01-19 Thread gene heskett

On 1/19/24 21:48, Nicholas Geovanis wrote:
On Fri, Jan 19, 2024, 2:07 PM Thomas Schmitt > wrote:


.

(Ok, C causes scars on the programmer's self esteem. But what does not
kill me makes me just stronger. I'm a vim user.)


OK I'll mention that to my psychiatrist :-)
But the C programmers I knew were either really nice guys if they wrote 
C on unix, or real toads if they wrote C for DOS/Windows. YMMV


I took one look at a dos c-compiler and ran for the hills. Never ever 
saw such a busted language interface. Totally, absolutely unusable using 
the K manual for reference.




Have a nice day :)

Thomas



Cheers, Gene Heskett.
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author, 1940)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis



Re: counting commas

2024-01-19 Thread Cindy Sue Causey
On 1/19/24, David Wright  wrote:
> On Fri 19 Jan 2024 at 17:25:10 (+), debian-u...@howorth.org.uk wrote:
>> Greg Wooledge  wrote:
>>
>> > I won, and you lost
>>
>> There shouldn't be a comma in that sentence, in English. There is in
>> the closely related expression "I won, you lost."
>
> That's rather proscriptive. "I won and you lost."


I won and you lost, but we can still be friends.

Cindy :)
-- 
Talking Rock, Pickens County, Georgia, USA
* runs with memories of a North Georgia English teacher saying to me,
"You didn't go to school around here, did you." He'd been standing up
against my desk as I was taking a third or fourth test at the time. He
was apparently trying to figure out if I was cheating on his tests.
Nope. *



Re: NUT and Eaton UPS produce a lot of error messages

2024-01-19 Thread Dan Ritter
Stefan Schumacher wrote: 
> Hello
> 
> I recently bought a small UPS by Eaton in order to prevent my
> btrfs-fileserver (running Debian 12 Bookworm, which is also the source
> of my nut-installation) from shutting down abruptly while writing
> something important during a power loss. I have found very good
> documentation on how to set up the UPS and the services on the server
> connected to it. Unfortunately it's in German
> (https://techbotch.org/blog/ups-setup/index.html) which is not a
> problem for me but possibly for others trying to understand my set-up.

 
> The problem is the dozens of errors the systemctl status messages
> show. I bought the UPS to increase reliability and now I don't know if
> the service is working in case of an emergency. How can I fix this ?
> Should I try to contact the Package Maintainer? Are there alternatives
> I could use or is nut the gold standard?
> 
> ● nut-server.service - Network UPS Tools - power devices information server
> Loaded: loaded (/lib/systemd/system/nut-server.service; enabled;
> preset: enabled)
> Active: active (running) since Fri 2024-01-19 05:17:03 CET; 5s ago
> Main PID: 1303 (upsd)
> Tasks: 1 (limit: 38253)
> Memory: 640.0K
> CPU: 3ms
> CGroup: /system.slice/nut-server.service
> └─1303 /lib/nut/upsd -F
> Jan 19 05:17:03 servername nut-server[1303]: fopen /run/nut/upsd.pid:
> No such file or directory
> Jan 19 05:17:03 servername nut-server[1303]: Could not find PID file
> '/run/nut/upsd.pid' to see if previous upsd instance is already
> running!
> Jan 19 05:17:03 servername nut-server[1303]: listening on 127.0.0.1 port 3493
> Jan 19 05:17:03 servername nut-server[1303]: listening on ::1 port 3493
> Jan 19 05:17:03 servername upsd[1303]: listening on 127.0.0.1 port 3493
> Jan 19 05:17:03 servername upsd[1303]: listening on ::1 port 3493
> Jan 19 05:17:03 servername nut-server[1303]: Connected to UPS [Eaton]:
> usbhid-ups-Eaton
> Jan 19 05:17:03 servername upsd[1303]: Connected to UPS [Eaton]:
> usbhid-ups-Eaton
> Jan 19 05:17:03 servername upsd[1303]: Running as foreground process,
> not saving a PID file
> Jan 19 05:17:03 servername nut-server[1303]: Running as foreground
> process, not saving a PID file


So far, we aren't seeing any errors at all. This is just startup
logging.


> ● nut-monitor.service - Network UPS Tools - power device monitor and
> shutdown controller
> Loaded: loaded (/lib/systemd/system/nut-monitor.service; enabled;
> preset: enabled)
> Active: active (running) since Fri 2024-01-19 03:37:28 CET; 1h 41min ago
> Main PID: 847 (upsmon)
> Tasks: 2 (limit: 38253)
> Memory: 3.4M
> CPU: 338ms
> CGroup: /system.slice/nut-monitor.service
> ├─847 /lib/nut/upsmon -F
> └─849 /lib/nut/upsmon -F
> Jan 19 03:43:08 servername nut-monitor[849]: UPS Eaton@localhost on battery
> Jan 19 03:43:09 servername nut-monitor[916]: Network UPS Tools upsmon 2.8.0
> Jan 19 03:43:33 servername nut-monitor[849]: UPS Eaton@localhost on line power
> Jan 19 03:43:34 servername nut-monitor[920]: Network UPS Tools upsmon 2.8.0

The UPS decided to activate, then decided to go back to the
line. This might be a power fluctuation -- quite possibly an
undervoltage so brief that nothing else in the house noticed.


> Jan 19 05:17:04 servername nut-monitor[849]: Poll UPS
> [Eaton@localhost] failed - Write error: Broken pipe
> Jan 19 05:17:04 servername nut-monitor[849]: Communications with UPS
> Eaton@localhost lost
> Jan 19 05:17:04 servername nut-monitor[1305]: Network UPS Tools upsmon 2.8.0
> Jan 19 05:17:09 servername nut-monitor[849]: Login on UPS
> [Eaton@localhost] failed - got [ERR ACCESS-DENIED]
> Jan 19 05:17:14 servername nut-monitor[849]: Communications with UPS
> Eaton@localhost established
> Jan 19 05:17:14 servername nut-monitor[1312]: Network UPS Tools upsmon 2.8.0

That, however, is lost-and-regained communication with the UPS. It might be
a bad USB cable, a reset of the UPS's controller, a USB
controller issue... 

Does it happen repeatedly?

Does it ever not re-connect?

-dsr-