firefor memory usage (Was Re: swapctl question)

2018-04-14 Thread Otto Moerbeek
On Sun, Apr 15, 2018 at 12:42:10AM -0500, Z Ero wrote:

> Also, why is Firefox 58 taking up about 2 gb of ram when I have 8
> (non-multimedia) tabs open?

Isn't confusing toi ask a new qustion with the same Subject.

Show the numbers and how you retrieved them. This is system using
virtual memory, not all numbers report actial physical memory usage.

That said, most web browsers are blaoted beyond believe.

-Otto

> 
> On Sun, Apr 15, 2018 at 12:37 AM, Z Ero  wrote:
> > amd64, 6.2
> >
> > I have my swap partition set to priority 9 in fstab.
> >
> > Why does swapctl report priority 0?
> >
> > # swapctl
> > Device  512-blocks UsedAvail Capacity  Priority
> > /dev/sd0b 11874624  1266232 1060839211%0
> > # cat /etc/fstab
> > 14d16d0d42a89629.a / ffs rw,softdep 1 1
> > 14d16d0d42a89629.k /home ffs rw,softdep,nodev,nosuid 1 2
> > 14d16d0d42a89629.d /tmp ffs rw,nodev,nosuid 1 2
> > 14d16d0d42a89629.f /usr ffs rw,softdep,nodev 1 2
> > 14d16d0d42a89629.g /usr/X11R6 ffs rw,softdep,nodev 1 2
> > 14d16d0d42a89629.h /usr/local ffs rw,softdep,wxallowed,nodev 1 2
> > 14d16d0d42a89629.b none swap sw,priority=9
> > 14d16d0d42a89629.e /var ffs rw,softdep,nodev,nosuid 1 2
> >
> > I want to minimize swapping since I am using a mechanical hard disk
> > and thus swap slows things down.
> >
> > I can disable swap if I want with swapctl -d but I would rather not.
> >
> > Thanks



Fwd: swapctl question

2018-04-14 Thread Philip Guenther
Whoops, meant to send this to the list too:

-- Forwarded message --
From: Philip Guenther 
Date: Sat, Apr 14, 2018 at 11:13 PM
Subject: Re: swapctl question
To: Z Ero 


On Sat, Apr 14, 2018 at 10:37 PM, Z Ero  wrote:

> amd64, 6.2
>
> I have my swap partition set to priority 9 in fstab.
>

> Why does swapctl report priority 0?
>

The compiled in default swap location (normally the 'b' partition of the
boot disk) is added as swap at priority zero in kernel startup as part of
uvm_swap_init(), before any userspace processes are started or /etc/fstab
is read.


# swapctl
> Device  512-blocks UsedAvail Capacity  Priority
> /dev/sd0b 11874624  1266232 1060839211%0
> # cat /etc/fstab
>

You only have one swap device so the priority doesn't matter: priority is
for selection _among_ swap devices and has no effect on the kernel's
decision of _whether_ to swap out a page.


I want to minimize swapping since I am using a mechanical hard disk
> and thus swap slows things down.
>

Slows things down relative to _what_?  Which statistics have you been
examining when under the workload you're interested in?


Philip Guenther


Re: OpenBSD 6.3 kernel panic

2018-04-14 Thread Mike Larkin
On Sat, Apr 14, 2018 at 11:32:00PM -0500, Juan Morado wrote:
> Here's the text as best I can see it.
> 
> uvm_fault (0xc1afca80, 0x808ca000, 0, 1) -> e
> kernel: page fault trap, code=0
> Stopped atihidev_intr+0x18a:  movzbl   0(%rsi,%rax,1),%eax
> ddb{0}>
> 
> On the same hardware, I did occasionally get some errors logged to the
> console running 6.2, IIRC something about an invalid value from ihiddev,
> but it didn't crash or hang.
> 

Can you show the output of "show reg" at ddb?

PS, this bug report leaves a lot to be desired...

-ml

> On Sat, Apr 14, 2018 at 8:06 PM, Mike Larkin  wrote:
> 
> > On Sat, Apr 14, 2018 at 04:47:32PM -0500, Juan Morado wrote:
> > > On Fri, Apr 13, 2018 at 1:18 PM, Mike Larkin 
> > wrote:
> > >
> > > > On Thu, Apr 12, 2018 at 10:19:23PM -0500, Juan Morado wrote:
> > > > > Hi all,
> > > > >
> > > > > I searched the mail archives briefly but couldn't find a related
> > issue.
> > > > > Apologies if this is a duplicate.
> > > > >
> > > > > Since upgrading to OpenBSD 6.3 on my amd64 laptop, it has been
> > crashing
> > > > > whenever I touch the track pad.
> > > > >
> > > > > Touching the track pad after X starts generally causes the machine to
> > > > just
> > > > > hang, however, it also crashes during boot if the track pad is
> > touched
> > > > so I
> > > > > was able to get a dump from ddb.
> > > > >
> > > > > Output from dmesg follows. I also have bsd.0.core, bsd.0, bounds,
> > minfree
> > > > > files from the crash dump. If there is any interest in looking at
> > these,
> > > > > please advise the best way to share them.
> > > > >
> > > > > - JM
> > > > >
> > > > > ---
> > > >
> > > > Where's the panic string?
> > > >
> > >
> > > Hell if I know.
> > >
> > > Maybe kernel panic isn't the correct terminology? ddb is invoked anytime
> > I
> >
> > So what does it say on the screen when you are in ddb?
> >
> > > touch the track pad while booting. Touching the track pad once X starts
> > > causes the machine to become unresponsive. I don't recall if the dmesg
> > was
> > > taken immediately following the crash or not. As I mentioned I was able
> > to
> > > generate a dump and I can share those dump files.
> >
> >
> >



Re: swapctl question

2018-04-14 Thread Z Ero
Also, why is Firefox 58 taking up about 2 gb of ram when I have 8
(non-multimedia) tabs open?

On Sun, Apr 15, 2018 at 12:37 AM, Z Ero  wrote:
> amd64, 6.2
>
> I have my swap partition set to priority 9 in fstab.
>
> Why does swapctl report priority 0?
>
> # swapctl
> Device  512-blocks UsedAvail Capacity  Priority
> /dev/sd0b 11874624  1266232 1060839211%0
> # cat /etc/fstab
> 14d16d0d42a89629.a / ffs rw,softdep 1 1
> 14d16d0d42a89629.k /home ffs rw,softdep,nodev,nosuid 1 2
> 14d16d0d42a89629.d /tmp ffs rw,nodev,nosuid 1 2
> 14d16d0d42a89629.f /usr ffs rw,softdep,nodev 1 2
> 14d16d0d42a89629.g /usr/X11R6 ffs rw,softdep,nodev 1 2
> 14d16d0d42a89629.h /usr/local ffs rw,softdep,wxallowed,nodev 1 2
> 14d16d0d42a89629.b none swap sw,priority=9
> 14d16d0d42a89629.e /var ffs rw,softdep,nodev,nosuid 1 2
>
> I want to minimize swapping since I am using a mechanical hard disk
> and thus swap slows things down.
>
> I can disable swap if I want with swapctl -d but I would rather not.
>
> Thanks



swapctl question

2018-04-14 Thread Z Ero
amd64, 6.2

I have my swap partition set to priority 9 in fstab.

Why does swapctl report priority 0?

# swapctl
Device  512-blocks UsedAvail Capacity  Priority
/dev/sd0b 11874624  1266232 1060839211%0
# cat /etc/fstab
14d16d0d42a89629.a / ffs rw,softdep 1 1
14d16d0d42a89629.k /home ffs rw,softdep,nodev,nosuid 1 2
14d16d0d42a89629.d /tmp ffs rw,nodev,nosuid 1 2
14d16d0d42a89629.f /usr ffs rw,softdep,nodev 1 2
14d16d0d42a89629.g /usr/X11R6 ffs rw,softdep,nodev 1 2
14d16d0d42a89629.h /usr/local ffs rw,softdep,wxallowed,nodev 1 2
14d16d0d42a89629.b none swap sw,priority=9
14d16d0d42a89629.e /var ffs rw,softdep,nodev,nosuid 1 2

I want to minimize swapping since I am using a mechanical hard disk
and thus swap slows things down.

I can disable swap if I want with swapctl -d but I would rather not.

Thanks



Re: OpenBSD 6.3 kernel panic

2018-04-14 Thread Juan Morado
Here's the text as best I can see it.

uvm_fault (0xc1afca80, 0x808ca000, 0, 1) -> e
kernel: page fault trap, code=0
Stopped atihidev_intr+0x18a:  movzbl   0(%rsi,%rax,1),%eax
ddb{0}>

On the same hardware, I did occasionally get some errors logged to the
console running 6.2, IIRC something about an invalid value from ihiddev,
but it didn't crash or hang.

On Sat, Apr 14, 2018 at 8:06 PM, Mike Larkin  wrote:

> On Sat, Apr 14, 2018 at 04:47:32PM -0500, Juan Morado wrote:
> > On Fri, Apr 13, 2018 at 1:18 PM, Mike Larkin 
> wrote:
> >
> > > On Thu, Apr 12, 2018 at 10:19:23PM -0500, Juan Morado wrote:
> > > > Hi all,
> > > >
> > > > I searched the mail archives briefly but couldn't find a related
> issue.
> > > > Apologies if this is a duplicate.
> > > >
> > > > Since upgrading to OpenBSD 6.3 on my amd64 laptop, it has been
> crashing
> > > > whenever I touch the track pad.
> > > >
> > > > Touching the track pad after X starts generally causes the machine to
> > > just
> > > > hang, however, it also crashes during boot if the track pad is
> touched
> > > so I
> > > > was able to get a dump from ddb.
> > > >
> > > > Output from dmesg follows. I also have bsd.0.core, bsd.0, bounds,
> minfree
> > > > files from the crash dump. If there is any interest in looking at
> these,
> > > > please advise the best way to share them.
> > > >
> > > > - JM
> > > >
> > > > ---
> > >
> > > Where's the panic string?
> > >
> >
> > Hell if I know.
> >
> > Maybe kernel panic isn't the correct terminology? ddb is invoked anytime
> I
>
> So what does it say on the screen when you are in ddb?
>
> > touch the track pad while booting. Touching the track pad once X starts
> > causes the machine to become unresponsive. I don't recall if the dmesg
> was
> > taken immediately following the crash or not. As I mentioned I was able
> to
> > generate a dump and I can share those dump files.
>
>
>


bioctl "intermitently" reports RAID 1 array as degraded

2018-04-14 Thread Theodore Wynnychenko
Hello

I am trying to understand what I may be missing (I have been noticing this issue
for a year or so).

I have a machine running -current that is setup with 2 SSD hard drives.

The SSD's are fdisk'ed with 1 openbsd partition:

# fdisk sd0
Disk: sd0   geometry: 19457/255/63 [312581808 Sectors]
Offset: 0   Signature: 0xAA55
Starting Ending LBA Info:
 #: id  C   H   S -  C   H   S [   start:size ]
---
 0: 00  0   0   0 -  0   0   0 [   0:   0 ] unused
 1: 00  0   0   0 -  0   0   0 [   0:   0 ] unused
 2: 00  0   0   0 -  0   0   0 [   0:   0 ] unused
*3: A6  0   1   2 -  19456 254  63 [  64:   312576641 ] OpenBSD

The disklabels on each disk have an "a" 4.2BSD partition, a "b" swap partition,
and then a "m" RAID partition:

# disklabel sd0
# /dev/rsd0c:
type: SCSI
disk: SCSI disk
label: INTEL SSDSA2BW16
duid: 43d094716532e926
flags:
bytes/sector: 512
sectors/track: 63
tracks/cylinder: 255
sectors/cylinder: 16065
cylinders: 19457
total sectors: 312581808
boundstart: 64
boundend: 312576705
drivedata: 0

16 partitions:
#size   offset  fstype [fsize bsize   cpg]
  a:  2104448   64  4.2BSD   2048 16384 1 # /
  b: 18860313  2104512swap# none
  c:3125818080  unused
  m:291611880 20964825RAID

Most of the time, everything is fine:

# bioctl -i sd2
Volume  Status   Size Device
softraid0 0 Online   149305012224 sd2 RAID1
  0 Online   149305012224 0:0.0   noencl 
  1 Online   149305012224 0:1.0   noencl 


BUT, every once in a while (let's say, a couple of weeks, then a couple of
months), all of sudden the array will report as being degraded.

However, other than the notice that the array is degraded and that a mirror is
offline, I can find nothing in any log, or any changes in the dmesg to suggest
what may have happened.

I have changed the hard drive cables.  I have changed out the SSD drives.

But, it still happens every so often.

When the array is degraded, I can still fdisk/disklabel the "offline" disk
without a problem.  I can rebuild the degraded array with the "offline" disk (#
bioctl -R /dev/sd1m sd2), and the rebuild completes without a problem, and the
array is stable for weeks/months until, randomly, it happens again.

I am wondering if there is anything I should be looking at/for to help figure
out what the issue is?

As I said, I have already swapped out hardware (at least) once.  If it is a
hardware issue, I can keep swapping out hardware, but (at this point) it seems
that the probability is really low that I would have multiple drives that have
the same intermittent problem (but, obviously, not zero).

I would appreciate any advice on how to track down what the problem may be the
next time it happens.

Thanks
Ted




Re: pkg_info -Q fails [OpenBSD 6.3 amd64/virtualbox]

2018-04-14 Thread Edgar Pettijohn



On 04/14/18 19:34, Jeffrey Joshua Rollin wrote:



Sent from Blue 
On 15 Apr 2018, at 00:31, Edgar Pettijohn > wrote:



On 04/14/18 15:08, Jeffrey Joshua Rollin wrote:

Hi, I've installed OpenBSD 6.3-release for amd64 on
virtualbox, and updated it with syspatch as of 20:40 UTC.
pkg_info -Q seems to be failing. Specifically, I tried $
pkg_info -Q mate ...and also as root, to remind myself what
the metapackage is [I have a feeling it's just "mate" anyway]
[EDIT: Metapackages? maybe I'm thinking of FreeBSD]; but:
pkg_info -Q firefox also fails, despite the fact I just
successfully installed Firefox. The relevant error is as
follows: Redirected to
https://cloudflare.cdn.openbsd/org/pub/OpenBSD/6.3/packages-stable/amd64



^^
Your PKG_PATH appears to have a couple of errors.

https://cloudflare.cdn.openbsd.org/pub/OpenBSD/6.3/packages/amd64

and I can't remember but it may need to end with a `/'


Can't locate object method "syslog" via package
"OpenBSD::PkgInfo::State" at
/usr/libdata/perl5/OpenBSD/PackageRepository.pm
 line 302, <$fh> line 3. Thanks,
Jeff. 


edgar:7$ pkg_info -Q mate
checkmate-0.21
libmatekbd-1.20.0
libmatemixer-1.20.0
libmateweather-1.20.0
mate-calc-1.20.0
mate-control-center-1.20.0
mate-desktop-1.20.0
mate-icon-theme-1.20.0
mate-media-1.20.0
mate-menus-1.20.0
mate-notification-daemon-1.20.0
mate-panel-1.20.0
mate-power-manager-1.20.0
mate-screensaver-1.20.0
mate-session-manager-1.20.0
mate-settings-daemon-1.20.0
mate-terminal-1.20.0
mate-themes-3.22.15
mate-utils-1.20.0
sslmate-1.5.1p1
tmate-2.2.1p0

I suspect its because

https://cloudflare.cdn.openbsd/org/pub/OpenBSD/6.3/packages-stable/amd64

doesn't exist or is down.

It exists, and is unlikely to be a transient error,

because I tried it several times, and as I said,  was able

to download software even though I couldn't query it.

(I subsequently found a YouTube tutorial which listed

most of the packages in your message.)

I will try again, and/or with a different mirror in

the morning.

Jeff





Re: OpenBSD 6.3 kernel panic

2018-04-14 Thread Mike Larkin
On Sat, Apr 14, 2018 at 04:47:32PM -0500, Juan Morado wrote:
> On Fri, Apr 13, 2018 at 1:18 PM, Mike Larkin  wrote:
> 
> > On Thu, Apr 12, 2018 at 10:19:23PM -0500, Juan Morado wrote:
> > > Hi all,
> > >
> > > I searched the mail archives briefly but couldn't find a related issue.
> > > Apologies if this is a duplicate.
> > >
> > > Since upgrading to OpenBSD 6.3 on my amd64 laptop, it has been crashing
> > > whenever I touch the track pad.
> > >
> > > Touching the track pad after X starts generally causes the machine to
> > just
> > > hang, however, it also crashes during boot if the track pad is touched
> > so I
> > > was able to get a dump from ddb.
> > >
> > > Output from dmesg follows. I also have bsd.0.core, bsd.0, bounds, minfree
> > > files from the crash dump. If there is any interest in looking at these,
> > > please advise the best way to share them.
> > >
> > > - JM
> > >
> > > ---
> >
> > Where's the panic string?
> >
> 
> Hell if I know.
> 
> Maybe kernel panic isn't the correct terminology? ddb is invoked anytime I

So what does it say on the screen when you are in ddb?

> touch the track pad while booting. Touching the track pad once X starts
> causes the machine to become unresponsive. I don't recall if the dmesg was
> taken immediately following the crash or not. As I mentioned I was able to
> generate a dump and I can share those dump files.




puri.sm What is the quality of this work?

2018-04-14 Thread worik
https://puri.sm/learn/freedom-roadmap/

I stumbled on this today.

I am interested in the criticisms of it.  They seem quite pleased with
themselves.

I have seen https://marc.info/?l=openbsd-misc&m=142242615002878&w=2 from
three years ago. 

Purism claim is that they are still having problems removing FSP.  But
is this comment (from the linked email from Theo) still applicable:
"Don't waste your money on a false ideal by someone who misunderstands
modern hardware and the market forces."  Of course, but does that
description fit these folks?

Worik

-- 
  If not me then who?  If not now then when?  If not here then where?
So, here I stand, I can do no other
  r...@worik.org 021-1680650, (03) 4821804 Aotearoa (New Zealand)



tmux split-windows from external shell appears to apply the split mixed up

2018-04-14 Thread Kevin Chadwick
tmux new-session -d -s cgdb
tmux select-window -t cgdb
tmux select-pane -t cgdb:.0
# -h here seems to do vertical!?
tmux split-window -h -d -t cgdb

The last line of this appears to split vertically, while -v does
horizontal. Does that represent intended behaviour?



Re: Status of X i386 openbsd 6.2 on x200

2018-04-14 Thread Markus Lude
On Mon, Apr 02, 2018 at 09:26:58PM +0200, Markus Lude wrote:
> On Sun, Apr 01, 2018 at 09:41:07PM +, flipchan wrote:
> > Hello all,
> > 
> > I have tried to installed 6.1 and 6.2 on a thinkpad x200 it works but X 
> > does work ...
> > 
> > Its works great with 6.0 but then i dont get the good 6.2 packages and 
> > features such as syspatch. 
> > 
> > 
> > It seems lika well known problem:
> > https://marc.info/?l=openbsd-bugs&m=150506076421862&w=2
> > 
> > 
> > Does anyone know the status of this/ if anyone is working on this ?
>  
> The problem still exists. The drm diff back then was quite huge and I am
> unable to break it down in smaller chunks to see where the cause therein
> is.
> The T61 is quite old and still runs with 6.1.
> It is new for me that newer Thinkpads do have the same problem. Could
> you please post a trace of your crash?

I now moved from i386 to amd64 on the T61. I didn't saw the drm related
crash since then. Upgrade through 6.2 to 6.3 worked.

Regards,
Markus




Re: vgafb manpage is in wrong place, should I report it?

2018-04-14 Thread IL Ka
 > When a manual page applies to more than 1 arch, we place it a level up.

Thank you, but should not we add comment like the one we have for "man pci"

SYNOPSIS
   # macppc, sparc64
   vgafb* at pci?

Btw, I found some more things to improve in mans like:

options(4) APERTURE section should have "See xf86(4)"
remark (it is done for almost all options except aperture)

Installation process asked me if I want my X11 to be "started by xdm(1)"
and it should be rephrased to "started by display manager xenodm(1) (xdm
clone)"
since there is no xdm(1)

Experienced user will never ever notice these small things, but they could
help newbies like me:)

I can fix it and send diff to tech@ (or where should I send it?) but I am
not sure about quality for my English.

Ilya.


Re: Community-driven OpenBSD tutorials wiki?

2018-04-14 Thread Mehma Sarja
I think what Jan is saying is sometimes we go to the hardware store for a
particular task, like weather proofing the home. And sometimes we go to the
store just to see what they have and you might want without a particular
project in mind.

Man pages, as opposed to woman pages, help one accomplish a task. A wiki
might give you ideas that did not occur to you.

Yudhvir


Re: OpenBSD 6.3 kernel panic

2018-04-14 Thread IL Ka
>
> Maybe kernel panic isn't the correct terminology? ddb is invoked anytime I
> touch the track pad while booting.

 You are right: it is kernel panic.

Accroding to ddb(4):
"ddb is invoked upon a kernel panic when the sysctl(8) ddb.panic is set to
1."

I am not sure, but I believe you can disable it and get kernel panic
message on console instead of ddb by disabling this option in
"/etc/sysctl.conf" and reboot
But even with ddb you can get some useful information to report to bugs@.
See https://www.openbsd.org/ddb.html
I think "traceback" and "show panic" could be useful


pkg_info -Q fails [OpenBSD 6.3 amd64/virtualbox]

2018-04-14 Thread Jeffrey Joshua Rollin
Hi,

I've installed OpenBSD 6.3-release for amd64 on virtualbox, and updated it
with syspatch as of 20:40 UTC. pkg_info -Q seems to be failing.
Specifically, I tried

$ pkg_info -Q mate

...and also as root, to remind myself what the metapackage is [I have a
feeling it's just "mate" anyway] [EDIT: Metapackages? maybe I'm thinking of
FreeBSD]; but:

pkg_info -Q firefox also fails, despite the fact I just successfully
installed Firefox.

The relevant error is as follows:

Redirected to
https://cloudflare.cdn.openbsd/org/pub/OpenBSD/6.3/packages-stable/amd64
Can't locate object method "syslog" via package "OpenBSD::PkgInfo::State"
at /usr/libdata/perl5/OpenBSD/PackageRepository.pm line 302, <$fh> line 3.

Thanks,

Jeff.


Re: vgafb manpage is in wrong place, should I report it?

2018-04-14 Thread Theo de Raadt
> Hello,
> I am pretty new to OpenBSD and not sure if I should report minor issue to
> bugs@, but I just found that vgafb(4) device is supported only on macppc
> and sparc64 (according to src/sys). It has nothing to do with i386 nor with
> amd64.
> 
> But for some reason it's man page sits directly in /usr/share/man/man4
> While other platform-specific mans live in  /usr/share/man/man4/${machine}
> (lcd(4) is good example).

When a manual page applies to more than 1 arch, we place it a level up.



Re: OpenBSD 6.3 kernel panic

2018-04-14 Thread Juan Morado
On Fri, Apr 13, 2018 at 1:18 PM, Mike Larkin  wrote:

> On Thu, Apr 12, 2018 at 10:19:23PM -0500, Juan Morado wrote:
> > Hi all,
> >
> > I searched the mail archives briefly but couldn't find a related issue.
> > Apologies if this is a duplicate.
> >
> > Since upgrading to OpenBSD 6.3 on my amd64 laptop, it has been crashing
> > whenever I touch the track pad.
> >
> > Touching the track pad after X starts generally causes the machine to
> just
> > hang, however, it also crashes during boot if the track pad is touched
> so I
> > was able to get a dump from ddb.
> >
> > Output from dmesg follows. I also have bsd.0.core, bsd.0, bounds, minfree
> > files from the crash dump. If there is any interest in looking at these,
> > please advise the best way to share them.
> >
> > - JM
> >
> > ---
>
> Where's the panic string?
>

Hell if I know.

Maybe kernel panic isn't the correct terminology? ddb is invoked anytime I
touch the track pad while booting. Touching the track pad once X starts
causes the machine to become unresponsive. I don't recall if the dmesg was
taken immediately following the crash or not. As I mentioned I was able to
generate a dump and I can share those dump files.


The bsdly.net traplist dumps are now served https only (forced redirect)

2018-04-14 Thread Peter N. M. Hansteen
While looking for something else entirely in my webserver logs I notice
that there are several hosts that try to fetch the hourly traplist dumps
https://www.bsdly.net/~peter/bsdly.net.traplist but via http and ignore
the redirect to https.

Both sites (https://www.bsdly.net/~peter/bsdly.net.traplist and the
slightly better connected
https://home.nuug.no/~peter/bsdly.net.traplist) now force https, so if
you are running some kind of out of date fetching setup, please update
to something modern.

I also notice that there are fetches from other operating systems, but
hopefully anyone interested in OpenBSD spamd(8) will check here
occasionally.

All the best,
Peter
-- 
Peter N. M. Hansteen, member of the first RFC 1149 implementation team
http://bsdly.blogspot.com/ http://www.bsdly.net/ http://www.nuug.no/
"Remember to set the evil bit on all malicious network traffic"
delilah spamd[29949]: 85.152.224.147: disconnected after 42673 seconds.



Re: Audio stuttering on media playback with sndiod

2018-04-14 Thread Alexandre Ratchov
On Tue, Apr 10, 2018 at 03:20:33PM +0200, Robert Klein wrote:
> Hi Daniel,
> 
> On Wed, 4 Apr 2018 03:22:04 -0300
> Daniel Bolgheroni  wrote:
> 
> > Hi,
> > 
> > audio is stuttering on media playback when run through sndiod. It's OK
> > without it.
> 
> Maybe related.  Yesterday I disabled webcam and microphone in BIOS on
> my X250.  Then Video playback (audio and video) was stuttering. I
> didn't investigate further, as: reverting BIOS settings made it Ok
> again.

Thanks. Few notes for the mailing-list archives:

Certains laptops have a "disable microphone" knob in the BIOS which
makes the device operate play-only, but it still reports full-duplex
capability. This confuses any full-duplex program, including sndiod,
and makes sound stutter. I've found no way to detect this situation.

Until we manage to properly detect it in the azalia driver, I'd
suggest not using the BIOS knob (ie keep your microphone enabled). To
disable it, run as root:

chmod 600 /dev/audio[0-9]

and restart audio programs (or reboot if unsure). This is reliable
because sndiod has no root privileges; even if it is compromised, the
attacker won't be able to record. And this works for everyone, even
for those without the BIOS "feature" :-)

HTH