Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Andrei POPESCU
On Vi, 15 mai 20, 11:27:40, Greg Wooledge wrote:
> 
> As the programmer, you need to know which commands can be invoked in
> which way(s).  Usually a quick glance at the man page will suffice.
> 
> Now, in the case of msgfmt(1), I don't actually know the right answer
> for you -- it's not a tool I'm really familiar with.  I will note,
> though, that its manual explicitly says it should be able to handle
> multiple input files:
> 
> SYNOPSIS
>msgfmt [OPTION] filename.po ...
> [...]
>Input file location:
>filename.po ...
>   input files

It complains about the empty 'msgid' at the start of each file. As far 
as I understand there's nothing wrong with it, so this could be a 
documentation bug. The rest of the manpage and GNU docs for 'msgfmt' 
only talk about singular files.
 
> There's something about *your* particular input files that it doesn't
> seem to like.  It seems to be complaining about duplicates.  Maybe
> you've defined something multiple times across multiple files, and it
> doesn't like that?

These are from debian-installer and I have no reason to believe they are 
wrong. 'msgfmt' itself has several --check options that confirm it for 
single files.
 
> Anyway, that's why there are several different tools available.  You
> can choose the right one for your task.

Which is why I've come to appreciate the flexibility of 'find' a lot 
and, FWIW, I strongly recommend it for any advanced linux user.

Kind regards,
Andrei
-- 
http://wiki.debian.org/FAQsFromDebianUser


signature.asc
Description: PGP signature


Re: qemu/kvm reboot problem

2020-05-15 Thread Thomas Schmitt
Hi,

Gary L. Roach wrote:
> I burned a CD off of the .iso file and used it to install the
> system.

I wonder why you need to burn a real CD (or DVD ?) for a virtual machine.
Virtualization can work with the .iso file directly and make it appear
in the guest as CD-ROM drive with medium.


> Dummy me overlooked the screen icon that said install to hard disk. That
> fixed the boot problem.

This explains a lot.


> Now if I can figure out which hard drive I am
> installed in I will be a happy camper.

This is probably not a qemu/kvm question but one of libvirt.


Have a nice day :)

Thomas



Re: Server goes to sleep

2020-05-15 Thread mett
On 2020年5月16日 4:20:50 JST, Dan Ritter  wrote:
>Chris Rhodin wrote: 
>> Hi,
>> 
>> I've installed Debian Buster on a desktop system I use as a server. 
>I also
>> occasionally use this as a regular desktop system so it has a
>monitor,
>> keyboard, and GUI.  During installation I selected the ssh server in
>> tasksel (so during installation there was some indication this was a
>> server).
>> 
>> The problem I have is that when the console screen goes black and
>locks,
>> the system becomes unresponsive to network activity.  If I have an
>ssh
>> session running when this occurs it stops responding.  It doesn't
>kick me
>> off, the ssh connection is still there.  If I then go to the console
>and
>> shake the mouse the screen lights up and the ssh session starts
>responding
>> like nothings wrong, until the console goes to sleep again.
>> 
>> Searching online I found this command which seems to solve the
>problem:
>> 
>> sudo systemctl mask sleep.target suspend.target hibernate.target
>> hybrid-sleep.target
>> 
>> So my question is what is the correct way to manage this?  Is there a
>> document that goes over the various power states and how they impact
>> running services?
>
>All modern processors have power-reduction features that operate
>pretty much automatically when the system isn't being asked to
>do anything. There are lots of tunables for more aggressive
>savings. The powertop package can help you out there.
>
>You don't have to worry much about those, but they won't
>interfere with running a server.
>
>Laptops, and most desktops, have sleep functions:
>
>- sleep to RAM  
>- sleep to disk and power-off
>- hybrid sleep (first to RAM, then change to disk later)
>
>You can't realistically run a server with those sleep states
>activated.
>
>Your desktop environment probably decided that it was OK to
>sleep when you weren't active. It will have a control to turn
>that behavior off.
>
>-dsr-

Hi

last time I stopped it with
"console blank"
in grub

vi /etc/default/grub

GRUB_CMDLINE_LINUX_DEFAULT="quiet consoleblank=0"

dont forget to update grub after

i think u ll need reboot as well.

10minutes is the mark to be sure.

Not sure about the correct way...

hth


[SOLVED] Re: vlc and access modules

2020-05-15 Thread moelmoel2714

On Fri, 15 May 2020, Celejar wrote:


On Fri, 15 May 2020 01:41:21 -0400 (EDT)
moelmoel2714  wrote:

[...]


vlc worked fine before I did something I know not what. and it works
fine on the other computer. but, to repeat, the working system has a
ton of modules listed but this one has four or so.


Debian's vlc plugins seem to be in packages vlc-plugin-base and
vlc-plugin-video-output, but there's no point in trying to figure out
what's wrong with your system until you install official versions.


probably due to your advice, not sure, but I have gotten a resolution. 
thanks are owed to you in any case and also to Jude DaShiell, tomas 
and Roberto for useful tips and information.


here's what happened: I removed the deb-multimedia and did a purge of 
vlc.


apt-upgrade yielded the dreaded 'unmet dependencies' message and a 
list of vlc-related files. some of the usual countermeasures didn't 
have any effect; I won't detail them.


I stumbled on the advice to do

sudo aptitude install vlc

this worked wonders, offering various scenarios for removing or 
retaining files. choosing prudently was easy.


now vlc has a large list of 'access modules' available and the problem 
which led me to suspecting the lack of these modules was at fault is 
also gone.


(4qos is just another DE over Debian, like Mint and so on (based on 
Trinity Desktop, derived from KDE3). nothing exotic.)


the 'aptitude' thing is interesting. I had used 'apt-get', then 'apt' 
and 'synaptic' but 'aptitude' did the trick.


thank you again.

f.

--
Felmon Davis



Re: I'd like to use private snippets with UltiSnips.

2020-05-15 Thread Yukiharu YABUKI
Hi, there.

I had posted the last article. I found a way how I do.

let g:UltiSnipsUsePythonVersion = 3
let g:UltiSnipsExpandTrigger=""
let g:UltiSnipsJumpForwardTrigger=""
let g:UltiSnipsJumpBackwardTrigger=""
let g:UltiSnipsSnippetDirectories=[$HOME.'/myUltiSnips/']

These snippets that I made make me be more productive.

Best, Yukiharu.

On Thu, 14 May 2020 23:48:44 +0900
Yukiharu YABUKI  wrote:


> I am confusing that I wasn't able to achieve to use private snippets
> with UltiSnips.

--
++++++++++++++
Yukiharu Yabuki (矢吹幸治)  I use Debian GNU/Linux
mail: yab...@netfort.gr.jp
クレクレタコラは好き / クレクレタコだはイヤ
++++++++++++++



Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread David Christensen

On 2020-05-15 15:58, Greg Wooledge wrote:

On Fri, May 15, 2020 at 03:34:53PM -0700, David Christensen wrote:

Another consideration is concurrency.  If you have a multi-core processor
and implement a solution that puts two or more cores to work at the same
time, a concurrent program should finish sooner than a sequential program.
Again, benchmarking.


One of the main reasons why people still suggest learning the xargs -0
variant is because GNU xargs has a lovely little -P option that runs
tasks in parallel.

It's super easy to go from

find ... -print0 | xargs -0 sha256sum

to something like

find ... -print0 | xargs -0 -P 4 sha256sum

This is one of the main advantages of the xargs -0 approach over the
find -exec + approach.  If you don't need any of GNU xargs's fancy
features, you can just stick with the standard -exec +.



Thanks for the tip.  :-)


David



Re: Installing Buster on a Fit-PC: Can't find the network.

2020-05-15 Thread David Wright
On Fri 15 May 2020 at 16:03:12 (-0600), Charles Curley wrote:
> I have several fit-PC 1s.
> https://en.wikipedia.org/wiki/Fit-PC#fit-PC_1.0 I have done fresh
> installs of Buster on two, so it should work. But recently the net
> install ISO (debian-10.0.0-i386-netinst.iso) did not find the two
> Ethernet adapters.

I don't know why—mine did. It's a Pentium III (with pae). The only
firmware it "requires" is for the Yamaha sound, but because my 386
laptop needs a couple of bits, I always download the firmware version.
But the kernel package(s) contained within should be identical.

> root@chaffee:~# lspci -vs 00:0d.0
> 00:0d.0 Ethernet controller: Realtek Semiconductor Co., Ltd. 
> RTL-8100/8101L/8139 PCI Fast Ethernet Adapter (rev 10)
>   Subsystem: Realtek Semiconductor Co., Ltd. RTL-8100/8101L/8139 PCI Fast 
> Ethernet Adapter
>   Flags: bus master, medium devsel, latency 64, IRQ 10
>   I/O ports at f800 [size=256]
>   Memory at e1014000 (32-bit, non-prefetchable) [size=256]
>   Capabilities: [50] Power Management version 2
>   Kernel driver in use: 8139too
>   Kernel modules: 8139cp, 8139too
> 
> root@chaffee:~# lsmod | grep 8139
> 8139too32768  0
> 8139cp 28672  0
> mii16384  2 8139cp,8139too
> root@chaffee:~# 
> 
> These adapters do not require firmware.
> 
> Two questions:
> 
> * The netinst installer has supported these in the past, including, I
>   believe, 10.0. Or am I mistaken, these are no longer supported.

These are the 10.0 kernels from

 488636416 Jul  6  2019 firmware-10.0.0-i386-netinst.iso

in iso9660://pool/main/l/linux-signed-i386/

  41860120 Jun 20  2019 linux-image-4.19.0-5-686-pae_4.19.37-5_i386.deb
  41548424 Jun 20  2019 linux-image-4.19.0-5-686_4.19.37-5_i386.deb

which contain

CONTENTS/lib/modules/4.19.0-5-686-pae/kernel/drivers/net/

 11344 Jun 19  2019  mii.ko

CONTENTS/lib/modules/4.19.0-5-686-pae/kernel/drivers/net/ethernet/realtek/

 39868 Jun 19  2019 8139cp.ko
 49180 Jun 19  2019 8139too.ko

CONTENTS/lib/modules/4.19.0-5-686/kernel/drivers/net/

 11344 Jun 19  2019  mii.ko

CONTENTS/lib/modules/4.19.0-5-686/kernel/drivers/net/ethernet/realtek/

 39476 Jun 19  2019 8139cp.ko
 49052 Jun 19  2019 8139too.ko

> * I tried supplying the kernel modules from a working installation. The
>   installer looked only at the device itself (/dev/sdb) and not at any
>   partitions (/dev/sdb1, /dev/sdb2, etc). Even when I provided the
>   drivers on a partitionless device (a USB floppy disk drive), it
>   failed to find the modules. How do I set up the media so the
>   installer can find the modules?

I didn't know the installer would find modules, only firmware.
I would try:

modprobe [--dump-modversions] [filename]

or

insmod [filename]

if modprobe can't load them from any old path (untested—
I've never had to do this).

Cheers,
David.



Re: qemu/kvm reboot problem

2020-05-15 Thread Gary L. Roach


On 5/15/20 3:19 AM, Thomas Schmitt wrote:

Hi,

Gary L. Roach wrote:

I load the software from an .iso file in my Download directory.

I wonder what this means in detail.

The normal procedure with an .iso image file and a qemu VM is
to start qemu with the .iso file as -cdrom and the (empty) virtual
hard disk image file as -hda.
Then one would let the system that comes up from the .iso image
install its payload as bootable operating system on the virtual
hard disk.



If I run fdisk p on the Hard Disk I am using I get:
Device Boot Start   End   Sectors  Size Id Type
/dev/sda1  * 2048 283117567 283115520  135G 83 Linux
/dev/sda2   283117568 312581807  29464240 14.1G 82 Linux swap / Solaris

Is this the view from the host operating system ?cfdisk /dev/sda

Did you submit /dev/sda to qemu as -hda ?



The drive is obviously marked as bootable.

As tomas already stated, this does not guarantee bootability.

Background:
The boot flag is a mark for generic MBR code which tells from where
to load a Volume Boot Record as next step of booting. One often can see
boot flag sensitive MBRs on freshly purchased USB sticks.

The usual boot loaders of Linux systems have other ways in their MBRs
to run the further boot stages up to the display of a boot menu.



Do you need more information?

What .iso image did you use ?
Can it be downloaded for free somewhere ?

What qemu command lines did you use and why ?
Did you do anything else as preparation outside qemu (and why) ?

What did you do when qemu was running ?


Have a nice day :)

Thomas


Thank you all for your replies.

I am using Virtual Machine Manager 2.0.0 powered by libvirt to set up 
the guest system. I burned a CD off of the .iso file and used it to 
install the system. The installation went fine but reboot failed again. 
I did detect an error that the 'v/lib/libvirt/images file was not 
active. I had to create the images file and then run |"virsh pool-start 
default" followed by "visrsh pool-autostart default". This fixed that 
problem.

|

|The .iso file is caelinux2018.iso and is available free of charge at 
caelinux.com. If you are not familiar with the package, it is a 
compendium of scientific and engineering packages that - if your good 
enough - could allow you to design and build your next airplane, 
automobile, particle accelerator, etc. The CAE stands for Computer Aided 
Engineering.|


|I think I have fix the major problem. More careful reading of the 
installation instructions indicated that the installation is in two 
parts. The loading of the disk image actually is a temporary install for 
tryout. Dummy me overlooked the screen icon that said install to hard 
disk. That fixed the boot problem. Now if I can figure out which hard 
drive I am installed in I will be a happy camper.|


|Thank you all for you help.|

|Gary R.
|



Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Greg Wooledge
On Fri, May 15, 2020 at 03:34:53PM -0700, David Christensen wrote:
> Another consideration is concurrency.  If you have a multi-core processor
> and implement a solution that puts two or more cores to work at the same
> time, a concurrent program should finish sooner than a sequential program.
> Again, benchmarking.

One of the main reasons why people still suggest learning the xargs -0
variant is because GNU xargs has a lovely little -P option that runs
tasks in parallel.

It's super easy to go from

find ... -print0 | xargs -0 sha256sum

to something like

find ... -print0 | xargs -0 -P 4 sha256sum

This is one of the main advantages of the xargs -0 approach over the
find -exec + approach.  If you don't need any of GNU xargs's fancy
features, you can just stick with the standard -exec +.



Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread David Christensen

On 2020-05-14 03:47, Albretch Mueller wrote:

  The thing is that I have to call, say sha256sum, on millions of files

  Probably debian admin people dealing with packaging have to deal with
the same kinds of issues.

  lbrtchx



The need to checksum files is common; it is a good test case for trying 
out different computing paradigms and/or programming languages.



As other people have mentioned, using find(1) or xargs(1) from the 
command line to invoke sha256sum(1) is one possibility.  All of these 
tools are mature and should produce predictable results.  When used 
correctly, their performance is good.  For ad-hoc tasks, this is how its 
done.



If you find that you need to parameterize the invocation, such as to use 
one set of arguments and/or options for one set of files and another set 
for other files, you can cut and paste an example invocation into a text 
file, parameterize it with variables, and add code to make the file into 
a script.  I would start with a Bourne shell script.  Of course, there 
are many other scripting languages to choose from; pick your favorite.



Even if you do not need parameterization, typing './myscript' requires 
fewer keystrokes and less mental effort than recalling a find(1) 
incantation over and over again.  And, it provides consistency.  These 
considerations are important when you are brain fried and heading for 
log off, or crawling through the files months later.



As you plan to perform the SHA256 computation a great many times, you 
should consider the cost of Unix process creation and tear-down -- e.g. 
CPU cycles (time) and memory usage.  If you write a program that 
computes many checksums per process, it will have less overhead and 
should finish in less time than a program that creates one process per 
input file.  Benchmarking will tell.



The above is related to the desired output format.  Obvious choices 
include one checksum file for all input files vs. one checksum file per 
input file.  The plus sign in the '-exec command {} +' option to find(1) 
facilitates the former, and should be efficient.



Also, where to put the output file(s) -- in the current working 
directory, within the input tree, within a parallel tree, or someplace 
else?  One output file for everything is easiest, but my archive and 
image scripts checksum the input files individually and touch(1) the 
checksum file modification times to match.



Another consideration is concurrency.  If you have a multi-core 
processor and implement a solution that puts two or more cores to work 
at the same time, a concurrent program should finish sooner than a 
sequential program.  Again, benchmarking.



I find that Bourne shell scripts are comfortable only up to a certain 
level of complexity.  Above that, I use Perl.  That said, Go would be 
well suited to this task and should be faster.  Then there is C, 
assembly, and/or hardware acceleration.



David



Installing Buster on a Fit-PC: Can't find the network.

2020-05-15 Thread Charles Curley
I have several fit-PC 1s.
https://en.wikipedia.org/wiki/Fit-PC#fit-PC_1.0 I have done fresh
installs of Buster on two, so it should work. But recently the net
install ISO (debian-10.0.0-i386-netinst.iso) did not find the two
Ethernet adapters.

root@chaffee:~# lspci -vs 00:0d.0
00:0d.0 Ethernet controller: Realtek Semiconductor Co., Ltd. 
RTL-8100/8101L/8139 PCI Fast Ethernet Adapter (rev 10)
Subsystem: Realtek Semiconductor Co., Ltd. RTL-8100/8101L/8139 PCI Fast 
Ethernet Adapter
Flags: bus master, medium devsel, latency 64, IRQ 10
I/O ports at f800 [size=256]
Memory at e1014000 (32-bit, non-prefetchable) [size=256]
Capabilities: [50] Power Management version 2
Kernel driver in use: 8139too
Kernel modules: 8139cp, 8139too

root@chaffee:~# lsmod | grep 8139
8139too32768  0
8139cp 28672  0
mii16384  2 8139cp,8139too
root@chaffee:~# 

These adapters do not require firmware.

Two questions:

* The netinst installer has supported these in the past, including, I
  believe, 10.0. Or am I mistaken, these are no longer supported.

* I tried supplying the kernel modules from a working installation. The
  installer looked only at the device itself (/dev/sdb) and not at any
  partitions (/dev/sdb1, /dev/sdb2, etc). Even when I provided the
  drivers on a partitionless device (a USB floppy disk drive), it
  failed to find the modules. How do I set up the media so the
  installer can find the modules?

-- 
Does anybody read signatures any more?

https://charlescurley.com
https://charlescurley.com/blog/



Re: Server goes to sleep

2020-05-15 Thread Dan Ritter
Chris Rhodin wrote: 
> Hi,
> 
> I've installed Debian Buster on a desktop system I use as a server.  I also
> occasionally use this as a regular desktop system so it has a monitor,
> keyboard, and GUI.  During installation I selected the ssh server in
> tasksel (so during installation there was some indication this was a
> server).
> 
> The problem I have is that when the console screen goes black and locks,
> the system becomes unresponsive to network activity.  If I have an ssh
> session running when this occurs it stops responding.  It doesn't kick me
> off, the ssh connection is still there.  If I then go to the console and
> shake the mouse the screen lights up and the ssh session starts responding
> like nothings wrong, until the console goes to sleep again.
> 
> Searching online I found this command which seems to solve the problem:
> 
> sudo systemctl mask sleep.target suspend.target hibernate.target
> hybrid-sleep.target
> 
> So my question is what is the correct way to manage this?  Is there a
> document that goes over the various power states and how they impact
> running services?

All modern processors have power-reduction features that operate
pretty much automatically when the system isn't being asked to
do anything. There are lots of tunables for more aggressive
savings. The powertop package can help you out there.

You don't have to worry much about those, but they won't
interfere with running a server.

Laptops, and most desktops, have sleep functions:

- sleep to RAM  
- sleep to disk and power-off
- hybrid sleep (first to RAM, then change to disk later)

You can't realistically run a server with those sleep states
activated.

Your desktop environment probably decided that it was OK to
sleep when you weren't active. It will have a control to turn
that behavior off.

-dsr-



Server goes to sleep

2020-05-15 Thread Chris Rhodin
Hi,

I've installed Debian Buster on a desktop system I use as a server.  I also
occasionally use this as a regular desktop system so it has a monitor,
keyboard, and GUI.  During installation I selected the ssh server in
tasksel (so during installation there was some indication this was a
server).

The problem I have is that when the console screen goes black and locks,
the system becomes unresponsive to network activity.  If I have an ssh
session running when this occurs it stops responding.  It doesn't kick me
off, the ssh connection is still there.  If I then go to the console and
shake the mouse the screen lights up and the ssh session starts responding
like nothings wrong, until the console goes to sleep again.

Searching online I found this command which seems to solve the problem:

sudo systemctl mask sleep.target suspend.target hibernate.target
hybrid-sleep.target

So my question is what is the correct way to manage this?  Is there a
document that goes over the various power states and how they impact
running services?


ChrisR


Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Greg Wooledge
On Fri, May 15, 2020 at 05:48:23PM +0300, Andrei POPESCU wrote:
> I just stumbled upon an interesting case:
> 
> $ find po -name ro.po -exec msgfmt --statistics {} \;
> 66 translated messages.
> 705 translated messages, 14 fuzzy translations.
> 52 translated messages.
> 485 translated messages.
> 527 translated messages, 22 fuzzy translations, 1 untranslated message.
> 
> but
> 
> $ find po -name ro.po -exec msgfmt --statistics {} +
> po/sublevel3/ro.po:21: duplicate message definition...
> po/sublevel4/ro.po:19: ...this is the location of the first definition
> msgfmt: found 1 fatal error
> 
> In this particular case it is actually necessary to issue a separate 
> 'msgfmt' command for each .po file, while in most other cases the '{} +' 
> form is better (and shorter to write ;).

Yes.  There are many commands that *can't* handle multiple input files,
and have to be fed one file at a time.

As the programmer, you need to know which commands can be invoked in
which way(s).  Usually a quick glance at the man page will suffice.

Now, in the case of msgfmt(1), I don't actually know the right answer
for you -- it's not a tool I'm really familiar with.  I will note,
though, that its manual explicitly says it should be able to handle
multiple input files:

SYNOPSIS
   msgfmt [OPTION] filename.po ...
[...]
   Input file location:
   filename.po ...
  input files

There's something about *your* particular input files that it doesn't
seem to like.  It seems to be complaining about duplicates.  Maybe
you've defined something multiple times across multiple files, and it
doesn't like that?

> po/sublevel3/ro.po:21: duplicate message definition...
> po/sublevel4/ro.po:19: ...this is the location of the first definition

I would start by comparing line 21 of po/sublevel3/ro.po with
line 19 of po/sublevel4/ro.po.

Anyway, that's why there are several different tools available.  You
can choose the right one for your task.



Re: vlc and access modules

2020-05-15 Thread Celejar
On Fri, 15 May 2020 01:41:21 -0400 (EDT)
moelmoel2714  wrote:

> On Fri, 15 May 2020, Celejar wrote:
> 
> > On Thu, 14 May 2020 22:05:41 -0400 (EDT)
> > moelmoel2714  wrote:
> >
> >> Greets!
> >>
> >> not sure how I got into this bind but I seem to have lost the 'access
> >> modules' that allow vlc to view video files (and likely do many other
> >> things; I know I cannot convert video).
> >>
> >> when I try to look at an mp4, I get
> >>
> >> Your input can't be opened:
> >> VLC is unable to open the MRL
> >> 'file:///home/davisf/dwhelper/video.mp4'. Check the log for details.

...

> >> vlc is installed from deb-multimedia. it's 3.0.10 Vetinari.
> >
> > Why deb-multimedia? Buster has 3.0.10 in the official repos:
> 
> no longer recall; pulled it over from a former install.

If you're trying to troubleshoot, first get rid of the deb-multimedia
version and install from Debian's repos. If you still have trouble, we
can troubleshoot further, but otherwise, we're wasting time.

> > https://packages.debian.org/bullseye/vlc
> 
> recent discussions here about 'buster' and 'bullseye'. my systems have 
> 'buster'; 'bullseye' is for the cutting edge?

https://www.debian.org/releases/

Which version is best for particular situations is something that has
been discussed endlessly on this list - search the archives. [It's been
explained far better than I can do in one email, and you can find
multiple perspectives.]

> vlc worked fine before I did something I know not what. and it works 
> fine on the other computer. but, to repeat, the working system has a 
> ton of modules listed but this one has four or so.

Debian's vlc plugins seem to be in packages vlc-plugin-base and
vlc-plugin-video-output, but there's no point in trying to figure out
what's wrong with your system until you install official versions.

> really appreciate your advice!

Sure - good luck!

Celejar



Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Andrei POPESCU
On Vi, 15 mai 20, 07:48:54, Greg Wooledge wrote:
> 
> Compare and contrast these commands:
> 
>  find . -type f -exec ls -l {} \;
> 
>  find . -type f -exec ls -l {} +
> 
> How do they differ?
> 
> The first one issues one "ls -l" command for each file found.
> 
> The second one gathers up multiple filenames into a list, and when it
> thinks the list is the right size, it issues one "ls -l" command with
> that entire list as arguments.  Then it repeats, until all the filenames
> have been handled.

I just stumbled upon an interesting case:

$ find po -name ro.po -exec msgfmt --statistics {} \;
66 translated messages.
705 translated messages, 14 fuzzy translations.
52 translated messages.
485 translated messages.
527 translated messages, 22 fuzzy translations, 1 untranslated message.

but

$ find po -name ro.po -exec msgfmt --statistics {} +
po/sublevel3/ro.po:21: duplicate message definition...
po/sublevel4/ro.po:19: ...this is the location of the first definition
msgfmt: found 1 fatal error

In this particular case it is actually necessary to issue a separate 
'msgfmt' command for each .po file, while in most other cases the '{} +' 
form is better (and shorter to write ;).

Kind reegards,
Andrei
-- 
http://wiki.debian.org/FAQsFromDebianUser


signature.asc
Description: PGP signature


Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Roberto C . Sánchez
On Fri, May 15, 2020 at 11:39:08AM +0200, Nicolas George wrote:
> Jonathan Dowland (12020-05-15):
> > The ultimate answer that Dan provided was to use find with xargs, which
> > is fine. And if you are going to use -print0, it is often a good idea to
> > trial that you've got the pattern right (especially if you are more used
> > to expressing file patterns in shell globs or regexes), so there was
> > value in Dan providing that too.
> 
> There was value, but not as an answer to the question.
> 
I wrote a lengthier reply to another of your messages in this thread,
then deleted it without sending.

However, you appear to still be hung up on something, though I cannot
tell what it is.

You may not have liked how someone else answered the question, but all
the answers so far have been utile.  That said, your insistence that the
other answers are somehow inadequate or inappropriate has not at all
helped the discussion.

Let me make a friendly suggestion that you discontinue your
participation in this thread.  It will benefit all concerned.

Regards,

-Roberto

-- 
Roberto C. Sánchez



Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Carl Fink

On 5/15/20 7:48 AM, Greg Wooledge wrote:

Unix is not taught in "videos".  This isn't freaking Microsoft here.
Unix and its toolset are built around TEXT.


You seriously aren't aware of the thousands of videos that
"teach Unix"? Or you are just a purist who refused to
admit they have any value?

I prefer text myself, but I don't go into denial about the
existence of alternatives. I just wish search engines had
a "stop showing me videos!" setting.

--
Carl Fink   nitpick...@nitpicking.com

Read my blog at blog.nitpicking.com.  Reviews!  Observations!



Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Greg Wooledge
On Fri, May 15, 2020 at 12:41:07PM +0200, Albretch Mueller wrote:
>  What documentation, books, videos, ... would you suggest for me to
> read up if I were to investigate what exactly is "find" 's magic to
> hook other processes and keep a running instance for multiple "found"
> files?

You're overthinking this.  find(1) does NOT communicate with a coproc.
It launches multiple instances of the desired command as needed to work
around the fact that there is a finite limit on the number of arguments
that it can pass to each instance of the desired command.

 might be of some help here, but
if you've already refused to read the man pages, I'm not sure how much
benefit there is in offering you additional reading material.

Unix is not taught in "videos".  This isn't freaking Microsoft here.
Unix and its toolset are built around TEXT.

Books are a legitimate request, but I don't know of any great Unix books
at the moment.  Most of the books that include any kind of Unix shell
tools or scripting have massive flaws and are to be avoided.

Compare and contrast these commands:

 find . -type f -exec ls -l {} \;

 find . -type f -exec ls -l {} +

How do they differ?

The first one issues one "ls -l" command for each file found.

The second one gathers up multiple filenames into a list, and when it
thinks the list is the right size, it issues one "ls -l" command with
that entire list as arguments.  Then it repeats, until all the filenames
have been handled.

If you want to write your own tool set that launches a coprocess and
communicates the list of files to it over a socket (or whatever),
you're free to do that.  For most of the world, however, the standard
find(1) with -exec + is good enough.



Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Andrei POPESCU
On Vi, 15 mai 20, 12:38:12, Albretch Mueller wrote:
> On 5/14/20, Nicolas George  wrote:
> 
> > The question was not how to find the files, the formulation of the
> > question indicates that Albretch has that covered.
> 
>  Yeah, my problem is not finding the files per se. I have them or
> could have them easily listed.

If your filenames contain "strange" characters you can avoid a lot of 
headaches by using 'find -exec  {} +' instead of using xargs 
directly.

The man page claims the '-exec {} +' is similar to xargs. Since you have 
these many files you could test ;)

Using 'xargs' directly (or combined with 'find -print0' to avoid issues 
with strange filenames) allows for some additional tuning.

>  The thing is that when you work on copora research you have to get
> fairly complicated answers from millions of text "as fast as possible"
> and you have to make sure that your baseline hasn't been changed.
> 
>  I will have to play (again) with the options that you have given me
> and by the way I said sha256sum as an example in the typical case you
> would run "file" and two hashes on each file and that would take
> forever a user's machine.

Are you sure the bottleneck is in execution? With so many files it could 
be many other things (storage, RAM, etc.).

Kind regards,
Andrei
-- 
http://wiki.debian.org/FAQsFromDebianUser


signature.asc
Description: PGP signature


Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Andrei POPESCU
On Vi, 15 mai 20, 12:41:07, Albretch Mueller wrote:
>  What documentation, books, videos, ... would you suggest for me to
> read up if I were to investigate what exactly is "find" 's magic to
> hook other processes and keep a running instance for multiple "found"
> files?

The man page is a good start, the section for the -exec command.

As this is GNU software there might be an 'info' file with more details 
(didn't bother to check if this is the case here).

'find' and 'xargs' are part of the same package (findutils).

Kind regards,
Andrei
-- 
http://wiki.debian.org/FAQsFromDebianUser


signature.asc
Description: PGP signature


Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Albretch Mueller
 What documentation, books, videos, ... would you suggest for me to
read up if I were to investigate what exactly is "find" 's magic to
hook other processes and keep a running instance for multiple "found"
files?

 lbrtchx



general protection fault on vif50.1-q1-guest (Debian 8/Xen)

2020-05-15 Thread John Naggets
Hello,

I had recently a general protection fault on a Debian 8 server with
Xen (debian pacakge: 4.4.4lts4-0+deb8u1) on the vif50.1-q1-guest
kernel proces. I have copied the kernel log below in this mail for
reference. After this GPF the system was still responding but one domU
lost network connectivity and all the others where still working
properly. I decided to power-off and power-on the system as a soft GPF
renders the system in an unstable state.

Now I am trying to find out what is most likely the cause of this
general protection fault in order to avoid that again in the future
and would like your opinion on that:

- is this maybe a bug in the Debian kernel I am using?
- a bug in the Xen package used by Debian 8?
- a hardware issue?
- if it is a hardware issue, what is most likely? RAM? CPU?
- anything else I am missing?

Note that the hardware is enterprise grade hardware and that the BIOS
has been updated to the latest available version.The CPUs (dual CPU)
are Intel Xeon E5-2640 v3 @ 2.60GHz.

Thank you for your input.

Best regards,
John

[Wed May  6 14:48:02 2020] general protection fault:  [#1] SMP
[Wed May  6 14:48:02 2020] Modules linked in: xt_physdev
iptable_filter ip_tables x_tables xen_netback xen_blkback hmac
binfmt_misc xen_gntdev xen_evtchn xenfs xen_privcmd nfsd auth_rpcgss
oid_registry nfs_acl nfs lockd fscache sunrpc bridge bonding iTCO_wdt
iTCO_vendor_support mxm_wmi zfs(PO) zunicode(PO) x86_pkg_temp_thermal
intel_powerclamp zcommon(PO) intel_rapl znvpair(PO) spl(O) coretemp
crc32_pclmul zavl(PO) aesni_intel pcspkr aes_x86_64 lrw gf128mul
glue_helper ablk_helper cryptd ast ttm drm_kms_helper evdev joydev drm
lpc_ich mfd_core i2c_algo_bit mei_me mei shpchp tpm_tis tpm ipmi_si
ipmi_msghandler wmi acpi_power_meter processor thermal_sys button
8021q garp stp mrp llc drbd lru_cache libcrc32c crc32c_generic autofs4
ext4 crc16 mbcache jbd2 dm_mod raid1 md_mod mlx4_en vxlan xen_blkfront
ptp pps_core
[Wed May  6 14:48:02 2020]  hid_generic usbhid hid sg sd_mod
crc_t10dif crct10dif_generic ahci libahci crct10dif_pclmul
crct10dif_common crc32c_intel ehci_pci ehci_hcd mlx4_core libata
i2c_i801 i2c_core usbcore usb_common scsi_mod nvme
[Wed May  6 14:48:02 2020] CPU: 0 PID: 8305 Comm: vif50.1-q1-gues
Tainted: P   O  3.16.0-10-amd64 #1 Debian 3.16.72-1
[Wed May  6 14:48:02 2020] Hardware name: Quanta Computer Inc
QuantaPlex T41S-2U/S2S-MB, BIOS S2S_3B12 05/30/2019
[Wed May  6 14:48:02 2020] task: 88003c9f95d0 ti: 88004a3ac000
task.ti: 88004a3ac000
[Wed May  6 14:48:02 2020] RIP: e030:[]
[] xenvif_gop_frag_copy+0x22/0x3b0 [xen_netback]
[Wed May  6 14:48:02 2020] RSP: e02b:88004a3afd98  EFLAGS: 00010282
[Wed May  6 14:48:02 2020] RAX: 1000 RBX: 8802e0841800
RCX: 7aec7d18f3f45689
[Wed May  6 14:48:02 2020] RDX: 88004a3afe80 RSI: 8802e0841800
RDI: 000111f703b7
[Wed May  6 14:48:02 2020] RBP: c9002332c258 R08: 5ff8d9a9
R09: b1fe2a0e
[Wed May  6 14:48:02 2020] R10: 8800 R11: 0002
R12: 7aec7d18f3f45689
[Wed May  6 14:48:02 2020] R13: c9002332c258 R14: 88004a3afe54
R15: 0001
[Wed May  6 14:48:02 2020] FS:  ()
GS:88048400() knlGS:88048400
[Wed May  6 14:48:02 2020] CS:  e033 DS:  ES:  CR0: 80050033
[Wed May  6 14:48:02 2020] CR2: 7f49c8679000 CR3: 74855000
CR4: 00042660
[Wed May  6 14:48:02 2020] Stack:
[Wed May  6 14:48:02 2020]  58f6d400 c90023336c08
02c0 8802e0841800
[Wed May  6 14:48:02 2020]  88004a3afe80 0080
8802e0841800 c9002332c258
[Wed May  6 14:48:02 2020]  79eb3472cad61644 0028
88004a3afe54 0001
[Wed May  6 14:48:02 2020] Call Trace:
[Wed May  6 14:48:02 2020]  [] ?
xenvif_kthread_guest_rx+0x549/0xce0 [xen_netback]
[Wed May  6 14:48:02 2020]  [] ?
xenvif_map_frontend_rings+0xd0/0xd0 [xen_netback]
[Wed May  6 14:48:02 2020]  [] ? kthread+0xd1/0xf0
[Wed May  6 14:48:02 2020]  [] ? __schedule+0x22f/0x750
[Wed May  6 14:48:02 2020]  [] ?
kthread_create_on_node+0x1b0/0x1b0
[Wed May  6 14:48:02 2020]  [] ? ret_from_fork+0x6e/0xa0
[Wed May  6 14:48:02 2020]  [] ?
kthread_create_on_node+0x1b0/0x1b0
[Wed May  6 14:48:02 2020] Code: 2e 0f 1f 84 00 00 00 00 00 0f 1f 44
00 00 41 57 41 56 b8 00 10 00 00 41 55 41 54 49 89 cc 55 53 49 89 fd
4b 8d 3c 08 48 83 ec 30 <48> 8b 09 4c 8b 74 24 68 4c 8b 7c 24 70 80 e5
40 74 08 49 8b 4c
[Wed May  6 14:48:02 2020] RIP  []
xenvif_gop_frag_copy+0x22/0x3b0 [xen_netback]
[Wed May  6 14:48:02 2020]  RSP 
[Wed May  6 14:48:33 2020] ---[ end trace 4fb039a0de2de66f ]---



Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Albretch Mueller
On 5/14/20, Nicolas George  wrote:

> The question was not how to find the files, the formulation of the
> question indicates that Albretch has that covered.

 Yeah, my problem is not finding the files per se. I have them or
could have them easily listed.

 The thing is that when you work on copora research you have to get
fairly complicated answers from millions of text "as fast as possible"
and you have to make sure that your baseline hasn't been changed.

 I will have to play (again) with the options that you have given me
and by the way I said sha256sum as an example in the typical case you
would run "file" and two hashes on each file and that would take
forever a user's machine.

 lbrtchx



Re: qemu/kvm reboot problem

2020-05-15 Thread Thomas Schmitt
Hi,

Gary L. Roach wrote:
> I load the software from an .iso file in my Download directory.

I wonder what this means in detail.

The normal procedure with an .iso image file and a qemu VM is
to start qemu with the .iso file as -cdrom and the (empty) virtual
hard disk image file as -hda.
Then one would let the system that comes up from the .iso image
install its payload as bootable operating system on the virtual
hard disk.


> If I run fdisk p on the Hard Disk I am using I get:
> Device Boot Start   End   Sectors  Size Id Type
> /dev/sda1  * 2048 283117567 283115520  135G 83 Linux
> /dev/sda2   283117568 312581807  29464240 14.1G 82 Linux swap / Solaris

Is this the view from the host operating system ?
Did you submit /dev/sda to qemu as -hda ?


> The drive is obviously marked as bootable.

As tomas already stated, this does not guarantee bootability.

Background:
The boot flag is a mark for generic MBR code which tells from where
to load a Volume Boot Record as next step of booting. One often can see
boot flag sensitive MBRs on freshly purchased USB sticks.

The usual boot loaders of Linux systems have other ways in their MBRs
to run the further boot stages up to the display of a boot menu.


> Do you need more information?

What .iso image did you use ?
Can it be downloaded for free somewhere ?

What qemu command lines did you use and why ?
Did you do anything else as preparation outside qemu (and why) ?

What did you do when qemu was running ?


Have a nice day :)

Thomas



Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Nicolas George
Jonathan Dowland (12020-05-15):
> The ultimate answer that Dan provided was to use find with xargs, which
> is fine. And if you are going to use -print0, it is often a good idea to
> trial that you've got the pattern right (especially if you are more used
> to expressing file patterns in shell globs or regexes), so there was
> value in Dan providing that too.

There was value, but not as an answer to the question.

Regards,

-- 
  Nicolas George


signature.asc
Description: PGP signature


Re: How could you load only once a Linux ultility without a batch --input-files kind of option and repeatedly use it on many files? . . .

2020-05-15 Thread Jonathan Dowland

On Thu, May 14, 2020 at 01:28:19PM +0200, Nicolas George wrote:

Dan Ritter (12020-05-14):

find . -name "*foo" -print


I have not not noticed where Albretch told us that the millions of files
where all together and could be selected by a simplistic pattern on
their name.

The question was not how to find the files, the formulation of the
question indicates that Albretch has that covered.


The ultimate answer that Dan provided was to use find with xargs, which
is fine. And if you are going to use -print0, it is often a good idea to
trial that you've got the pattern right (especially if you are more used
to expressing file patterns in shell globs or regexes), so there was
value in Dan providing that too.



--
👱🏻  Jonathan Dowland
✎   j...@dow.land
🔗   https://jmtd.net



Re: vlc and access modules

2020-05-15 Thread tomas
On Fri, May 15, 2020 at 02:47:55AM -0400, moelmoel2714 wrote:

[...]

No idea who or what Q4OS is (and not sure I want to know).

> Q4OS puts everything in /etc/apt/sources.list.d/; always makes me a
> tad nervous. anyway, one of the files there, '20_debian.list' has
> non-free on all the active lines.

The Debian "non-free" repo isn't bad per se. It's just a heads-up
"those packages don't match our Debian Free Software Guidelines,
so check for yourself whether theey match yours". You might find
the Emacs documentation there (because the GNU free documentation
license collides with DFSG), but also straight closed-source vendor
drivers.

> will quote it for good measure (some line wrapping):
> 
> # Q4OS essential repository
> #  !!! NEVER touch this CRITICAL system file  !!!

...actually, such a comment would challenge me to do the
opposite, or perhaps to get whatever put that into my box
kicked out :-)

Follow the relevant lines:
> deb http://ftp.debian.org/debian/ buster main contrib non-free
> deb http://security.debian.org/debian-security/ buster/updates main contrib 
> non-free
> deb http://ftp.debian.org/debian/ buster-updates main contrib non-free

This looks rather harmless -- unless you want to avoid non-free.
The rest is prefixed with #, i.e. commented out.

Cheers
-- t


signature.asc
Description: Digital signature


Re: qemu/kvm reboot problem

2020-05-15 Thread tomas
On Thu, May 14, 2020 at 01:13:10PM -0700, Gary L. Roach wrote:
> Hi all,
> 
> System: Debian Buster host
> 
>           qemu/kvm virtual machine
> 
>           CAELinux Guest
> 
> I load the software from an .iso file in my Download directory. The
> guest files seem to be loading and working fine until I try to
> reboot the Guest. Then I get the following:
> 
> Booting from Hard Disk...
> Boot failed: not a bootable disk
> No bootable device.
> 
> If I run fdisk p on the Hard Disk I am using I get:
> 
> Device Boot Start   End   Sectors  Size Id Type
> /dev/sda1  * 2048 283117567 283115520  135G 83 Linux
> /dev/sda2   283117568 312581807  29464240 14.1G 82 Linux swap / Solaris
> 
> The drive is obviously marked as bootable.

The mark on the tin doesn't necessarily corresponds with the tin's
content...

> [...] This drive is an extra
> one that was left over when I put two 1TB drives in the system. I
> reformated the drive , marked it as bootable and added a swap
> partition before loading the qemu/kvm software. Does anyone have an
> idea as to what I am doing wrong? Do you need more information?

I don't know under which conditions qemu issues the error message
above, but it could well be that it's missing a boot sector in the
/dev/sda1 partition. Something e.g. grub sould do for you (there
are other possibilities, though).

If all you did was partition, (possibly, depending on what "reformat"
means to you) make file systems and mark one partition as bootable,
the boot sector is most certainly missing.

AFAIK, the "bootable mark" is a reminiscence of bad old DOS times and
most software ignores it these days, anyway.

Cheers
-- t


signature.asc
Description: Digital signature