Re: USB M-Audio as default audio output
On Fri, Jan 24, 2020 at 04:04:40PM +0100, Thomas de Grivel wrote: > Hello misc, > > I have a USB M-Audio card which is very well supported by OpenBSD 6.6 amd64 > > My question is : how do I setup an USB audio card as the default audio > device whenever it is plugged in ? > > Also I did not manage to get audio output with environment variables > only, I had to swap /dev/audio0 and /dev/audio1 and then it worked. > Could it have something to do with sndiod not running for /dev/audio1 > ? > > In all cases I really like sndio, it is really easy to work with. Hi, You could define the internal device the main one (-f option) and add the usb device as alternate device (-F option). In this case sndiod will use the usb one perferably and switch to the internal one when the usb one is disconnected. For instance set: sndiod_flags=-f rsnd/0 -F rsnd/1 in /etc/rc.conf.local and restart sndiod. There's no way to detect when the usb device is connected again. sndiod will start using it the next time it needs to open a device. As programs tend to keep the device open, you could force sndiod to reopen the devices (and thus switch to the usb one) by sending it a HUP signal. On 6.6 you have to "pkill -1 -x sndiod", on -current the rcctl script does it for you: rcctl reload sndiod HTH, -- Alexandre
Re: OpenBSD 6.0: PPPOE with vlan configure problem
Dear Tom, I had tried with different authentication protocol like pap and chap but not successful. On top of that, should i set mtu to bigger size like 1510 bytes. Regards, -- Peter Wong 016-396 3326 On Sat, Jan 25, 2020 at 10:26 AM Tom Smyth wrote: > Peter > > I would check the authentication protocol and cycle > through various authentication protocols to see if the isp > has only one type of authentication protocol enabled > im not certain the "\" is required, I havent had to use > that on hostname.if files (in my experience) > I see it in the manual page example but that may be > try without that ... > also keep an eye on the MTU of the PPPoE .. > > if the parent interface has an MTU of 1500 Bytes... > unencrypted pppoe would have an MTU of 1492 > PPPoE with encryption would need an MTU of 1488 > Hope this helps > > > > > > On Sat, 25 Jan 2020 at 02:16, Peter Wong wrote: > >> Dear All, >> I'm trying to setup openbsd as router but could not get any internet >> connection. >> I need to set my external interface to vnetid 500. Below is my >> configuration: >> >> /etc/hostname.vlan500 >> -inet vnetid 500 parent fxp0 up >> >> /etc/hostname.pppoe0 >> inet 0.0.0.0.0 255.255.255.255 NONE pppoedev *vlan500 *authproto chap \ >> authname "username" authkey "pass" up >> dest 0.0.0.1 >> !/sbin/route add default -ifp pppoe0 0.0.0.1 >> >> Questions: >> 1. How to diagnose pppoe connection, any log file? >> 2. Should the vlan interface name follow vlan or vnetid? >> 3. Does it need to change the pppoedev interface to fxp0 or vlan500 or >> something else? >> >> Please advise. Thank you. >> >> Regards, >> -- >> Peter Wong >> 016-396 3326 >> > > > -- > Kindest regards, > Tom Smyth. >
Re: OpenBSD 6.0: PPPOE with vlan configure problem
On Fri, Jan 24, 2020, at 18:03, Peter Wong wrote: > Dear All, > I'm trying to setup openbsd as router but could not get any internet > connection. > I need to set my external interface to vnetid 500. Below is my > configuration: > > /etc/hostname.vlan500 > -inet vnetid 500 parent fxp0 up > > /etc/hostname.pppoe0 > inet 0.0.0.0.0 255.255.255.255 NONE pppoedev *vlan500 *authproto chap \ > authname "username" authkey "pass" up > dest 0.0.0.1 > !/sbin/route add default -ifp pppoe0 0.0.0.1 > > Questions: > 1. How to diagnose pppoe connection, any log file? > 2. Should the vlan interface name follow vlan or vnetid? > 3. Does it need to change the pppoedev interface to fxp0 or vlan500 or > something else? > > Please advise. Thank you. > > Regards, > -- > Peter Wong > 016-396 3326 >
Re: OpenBSD 6.0: PPPOE with vlan configure problem
Peter I would check the authentication protocol and cycle through various authentication protocols to see if the isp has only one type of authentication protocol enabled im not certain the "\" is required, I havent had to use that on hostname.if files (in my experience) I see it in the manual page example but that may be try without that ... also keep an eye on the MTU of the PPPoE .. if the parent interface has an MTU of 1500 Bytes... unencrypted pppoe would have an MTU of 1492 PPPoE with encryption would need an MTU of 1488 Hope this helps On Sat, 25 Jan 2020 at 02:16, Peter Wong wrote: > Dear All, > I'm trying to setup openbsd as router but could not get any internet > connection. > I need to set my external interface to vnetid 500. Below is my > configuration: > > /etc/hostname.vlan500 > -inet vnetid 500 parent fxp0 up > > /etc/hostname.pppoe0 > inet 0.0.0.0.0 255.255.255.255 NONE pppoedev *vlan500 *authproto chap \ > authname "username" authkey "pass" up > dest 0.0.0.1 > !/sbin/route add default -ifp pppoe0 0.0.0.1 > > Questions: > 1. How to diagnose pppoe connection, any log file? > 2. Should the vlan interface name follow vlan or vnetid? > 3. Does it need to change the pppoedev interface to fxp0 or vlan500 or > something else? > > Please advise. Thank you. > > Regards, > -- > Peter Wong > 016-396 3326 > -- Kindest regards, Tom Smyth.
OpenBSD 6.0: PPPOE with vlan configure problem
Dear All, I'm trying to setup openbsd as router but could not get any internet connection. I need to set my external interface to vnetid 500. Below is my configuration: /etc/hostname.vlan500 -inet vnetid 500 parent fxp0 up /etc/hostname.pppoe0 inet 0.0.0.0.0 255.255.255.255 NONE pppoedev *vlan500 *authproto chap \ authname "username" authkey "pass" up dest 0.0.0.1 !/sbin/route add default -ifp pppoe0 0.0.0.1 Questions: 1. How to diagnose pppoe connection, any log file? 2. Should the vlan interface name follow vlan or vnetid? 3. Does it need to change the pppoedev interface to fxp0 or vlan500 or something else? Please advise. Thank you. Regards, -- Peter Wong 016-396 3326
Re: pkg_info(1) man page possible error
Hi Andrew, Andrew Easton wrote on Fri, Jan 24, 2020 at 11:17:20PM +0100: > I am running OpenBSD in a virtualbox because I am taking a deeper look > into it. > > I was looking for a list of ports packages Depending what you really need, try $ doas pkg_add portslist $ less /usr/local/share/ports-INDEX $ doas pkg_add sqlports $ sqlite3 /usr/local/share/sqlports https://cvsweb.openbsd.org/ports/ > and read the man page pkg_info(1). > > That man page it states, > "When browsing through uninstalled packages, running pkg_info -I *.tgz > will report a summary line for each package [...]" > > Note the capital eye 'I'. > > It says so in the VMs man page as well as at > https://man.openbsd.org/pkg_info > (All Sections ; All Architectures ; OpenBSD-current) > (Timestamp: approx. Fri 24 Jan 2020 10:05:00 PM UTC) > > > When I run the command > > # pkg_info -I *.tgz > > I get the result > > Invalid spec: *.tgz > Invalid spec: *.tgz > # > Well, that's less a question about pkg_info(1) but more about the sh(1). In the https://man.openbsd.org/sh.1#Expansion section, look for the paragraph beginning with After field splitting, the shell matches filename patterns. So the above command only makes sense in a directory where you do actually have some packages with file names that match the glob(7) pattern "*.tgz", for example: schwarze@isnote $ cd /usr/ports/packages/amd64/all/ schwarze@isnote $ ls groff* groff-1.22.3p9.tgz groff-1.22.4p2.tgz groff-git-1.22.4p3.tgz groff-1.22.4.tgzgroff-1.22.4p3.tgz schwarze@isnote $ pkg_info -D unsigned -I *.tgz | grep groff gpresent-2.3p0.tgz make presentations with groff and PDF gpresent-2.5.tgzmake presentations with groff and PDF groff-1.22.3p9.tgz GNU troff typesetter groff-1.22.4.tgzGNU troff typesetter groff-1.22.4p2.tgz GNU troff typesetter groff-1.22.4p3.tgz GNU troff typesetter groff-git-1.22.4p3.tgz GNU troff typesetter ja-groff-1.10_0.99p2.tgz japanese groff > If I run > # pkg_info -l *.tgz # NOTE the little ell instead of capital eye Using -l in this way doesn't really make sense. Look at $ man -O tag=l pkg_info # or https://man.openbsd.org/pkg_info.1#l for what -l does. You don't want to give "*.tgz" as an option argument to -l. > If I run > # pkg_info -I > > I get the result > pkg_info: Missing package name(s) > Usage: <...> Yes. It pays off to read manual pages and error messages closely, at least on OpenBSD. pkg_info(1) says: -I Show the index entry for each package. So with -I, you need to say for which package(s) you want to see index entries. > Searching for "openbsd pkg_info -I" with duckduckgo Don't search the web for OpenBSD documentation that way. Yes, for Linux, it's sometimes hard to get any help without searching the web indiscriminately. But for OpenBSD, everything is supposed to be explained in the manual page of the program you are trying to use, so look there. Random stuff from the web is likely to just confuse you even more. > What other information can I provide to clarify where the problem lies? > (It may be the man page, pkg_info, "layer 8" or a combination of these > three factors.) The information you provided was pretty good, i hope i could help. Yours, Ingo
pkg_info(1) man page possible error
Hello, I am running OpenBSD in a virtualbox because I am taking a deeper look into it. I was looking for a list of ports packages and read the man page pkg_info(1). That man page it states, "When browsing through uninstalled packages, running pkg_info -I *.tgz will report a summary line for each package [...]" Note the capital eye 'I'. It says so in the VMs man page as well as at https://man.openbsd.org/pkg_info (All Sections ; All Architectures ; OpenBSD-current) (Timestamp: approx. Fri 24 Jan 2020 10:05:00 PM UTC) When I run the command # pkg_info -I *.tgz I get the result Invalid spec: *.tgz Invalid spec: *.tgz # If I run # pkg_info -l *.tgz # NOTE the little ell instead of capital eye I get something that looks like the list the man page describes. Two columns, first being package name and second being a short one line description. If I run # pkg_info -I I get the result pkg_info: Missing package name(s) Usage: <...> Searching for "openbsd pkg_info -I" with duckduckgo just presented the OpenBSD FAQ and Manual Pages and something about a pkg_info -Q bug. I read the man page's descriptions for options -I and -l and it seems to me that -I (capital eye) *should* work the way the man page exemplifies its use or maybe even without an argument. Maybe I am misinterpreting the descriptions. I do not quite understand why requesting the list of packages including a short description works with -l (small ell), which takes a string as an argument. What other information can I provide to clarify where the problem lies? (It may be the man page, pkg_info, "layer 8" or a combination of these three factors.) # uname -a OpenBSD 6.6 GENERIC#4 amd64 Thank you for your time, Andrew Easton
Error: Can't open display: ssvnc-viewer (vncviewer) local connection to QEMU host with -vnc option enabled
Trying to connect to QEMU 4.1.0 with VNC server enabled by $ doas vncviewer -rawlocal 127.0.0.1:0 All the time receive 'Error: Can't open display' by vncviewer (ssvnc-viewer package installed on OpenBSD 6.6) when connect to QEMU machine which run on the same localhost and QEMU VNC server listens on $ doas netstat -an | grep 5900 tcp 0 0 127.0.0.1.5900 *.* LISTEN $ doas qemu-system-x86_64 -vnc 127.0.0.1:0 -k en-us -monitor pty \ -m 2048 -object memory-backend-file,id=mem,size=2048M,\ mem-path=/tmp/qemu-mem,share=on \ -numa node,memdev=mem -cdrom linux.iso \ -boot -d -name linux linux.qcow2 But I can connect by telnet localhost 5900 successfully. Anyway there is no any TCP connection to 127.0.0.1:5900 from vncviewer unfortunately.
Re: Fan spinning constantly on Lenovo X1C and 6.6
I'm running an X220 myself, and I noticed that the fan was constantly running since upgrading from 6.5 to 6.6. I figured it was just Firefox being a hog, but it does it even when Firefox isn't running, but after seeing this thread, I'm thinking there must be some other reason. -- Jay Williams
USB M-Audio as default audio output
Hello misc, I have a USB M-Audio card which is very well supported by OpenBSD 6.6 amd64 My question is : how do I setup an USB audio card as the default audio device whenever it is plugged in ? Also I did not manage to get audio output with environment variables only, I had to swap /dev/audio0 and /dev/audio1 and then it worked. Could it have something to do with sndiod not running for /dev/audio1 ? In all cases I really like sndio, it is really easy to work with. Cheers, -- Thomas de Grivel kmx.io
Re: Assigning multiple IPv6 addresses to loopback
Hello Tom, > Hi Aham, > > what I do is I add multiple loopback interfaces (it is useful in an ISP > context > so that when I add a loopback interface to ospf (to advertise the address > as an > intra area route ) (but I don't want to advertise the standard loopback > addresses > 127.0.0.1) > > eg > echo inet a.b.c.d/32 >/etc/hostname.lo2 > echo inet alias w.x.y.z/32 >>/etc/hostname.lo2 > > and just keep adding additional addresses using "inet alias" > > Hope this helps > > > > > > > > On Thu, 23 Jan 2020 at 11:04, Aham Brahmasmi wrote: > > > Namaste misc, > > > > In IPv6, what address prefix/range is recommended for use when > > assigning multiple addresses to the loopback interface? > > > > The use case is running multiple servers (nsd and unbound) on the same > > port but different loopback addresses. It is similar to what popped up > > on the other thread about dig. > > > > If I am not wrong, 127.0.0.1/8 is the loopback range in IPv4. On the > > other hand, in IPv6, there is only one loopback address - ::1/128 [1]. > > > > And because there is only one loopback address, I do not know whether: > > 1) ::2/128, ::3/128 et al are RFC compliant IPv6 loopback addresses. > > 2) the very idea of running multiple servers on the same port but > > different loopback addresses is redundant in IPv6. > > > > Searching the internet throws up different mechanisms, but no definitive > > solution. In fact, someone went throught the entire trouble of writing > > up a draft RFC [3] to assign an address range. But for reasons that I do > > not know, the draft was allowed to expire. > > > > Dhanyavaad, > > ab > > [1] - https://www.iana.org/assignments/ipv6-address-space/ > > [2] - https://www.iana.org/assignments/ipv6-multicast-addresses/ > > [3] - > > https://tools.ietf.org/html/draft-smith-v6ops-larger-ipv6-loopback-prefix-04 > > -|-|-|-|-|-|-|-- > > > > > > -- > Kindest regards, > Tom Smyth. > Thank you Tom for your response. >From what I understand from your response, you add an IPv4 address to a new loopback interface (lo2) and continue to add additional addresses via "inet alias" to lo2. In the context of IPv6, let us assume that I create an lo2 interface and assign it ::1/128 - because it is a loopback interface. $ cat /etc/hostname.lo2 inet6 ::1/128 My query is, which addresses/prefixes can I use to assign additional IPv6 addresses to the lo2 loopback interface, such that unbound/nsd/ other daemons can bind on them? Also, from what I understand, using the zone/interface identifier format of IPv6 addresses is not allowed for loopback address as per RFC 4007 [1]. In other words, ::1/128%lo2 is not a valid IPv6 address. In order to solve this, I searched some more, and encountered another Internet Draft, which also wanted to allocate an IPv6 address range for loopback purposes [2]. However, that Internet Draft has also expired. I continue to search. Dhanyavaad, ab [1] - https://tools.ietf.org/html/rfc4007#section-11.1 [2] - https://tools.ietf.org/html/draft-ipversion6-loopback-prefix-00 -|-|-|-|-|-|-|--
Re: pfctl -T expire
On 2020-01-24, myml...@gmx.com wrote: > Hi All, > > Thanks to Jesper and Stuart, i'm using max-pkt-rate not! > > I'm also using max-src-conn-rate and overload in conjunction with authpf > and I'm worried that potentially valid traffic may get blocked. > > I'm wondering if it's a condoned/accepted/best practice to use cron with > pfctl to expire table entries that are over a certain age. Yes, that is often required, "pfctl -T expire [number]" is for exactly this.
Re: Brand new server - bad adventures
Ozgur, AFAIK with hyperthreading on side channel attacks and other CPU vulnerabilities are much easier to achieve. also under certain workloads Hyperthreading actually reduces performance, (where you have High packet rate Network I/O for instance) if you are using OpenBSD Current or Stable smt is off by default you can enable it by finding the sysctl containing "smt" and setting it to 1 but I would benchmark to see if you get a positive performance effect by enabling smt for your particular workload. smt increases security risk considerably (in instances where you are running browsers on your system virtual machines running for third parties on your system (untrusted code running on your machine) then SMT should probably be left off Im sure there have been some discussions about it in the past and you can check the archives, Colin Percival gave a talk about CPU Vulnerabilities at the eurobsdcon it will help paint the picture for you . On Fri, 24 Jan 2020 at 06:36, Özgür Kazancci wrote: > Hi Aaron, > > Considering heavy traffic load&requests through web/sql server on the > system, wouldn't that decrease performance? HT might not be too safe - > OpenBSD is. :) > I do know and am aware of that OpenBSD team suggest turning it of, but.. > Other than that, have you read anything else *specifically* regarding > the security implementation of these CPUs? > > Many thanks. > Best, > Ozgur Kazancci > > > > > On 24/01/2020 03:06, Aaron Mason wrote: > > After reviewing your dmesg and googling the model of your CPU, might I > > suggest/recommend turning off hyperthreading if you can. Bad security > > juju. > > > > > > > > > > On Thu, Jan 23, 2020 at 6:29 PM Andreas Kusalananda Kähäri > > wrote: > >> > >> On Wed, Jan 22, 2020 at 11:30:51PM +0300, Özgür Kazancci wrote: > >> > Hello everyone! Greetings to misc people! > >> > > >> > Got a brand new dedicated server with a hardware: Intel Xeon-E 2274G > - 64GB > >> > DDR4 ECC 2666MHz - 2x SSD NVMe 960GB > >> > and installed "brand new" OpenBSD 6.6 on it. (I'm managing it > remotely via > >> > KVM/IPMI) > >> > > >> > After the first boot, dmesg is outputting sequentally between few > seconds > >> > delays: > >> > "wsdisplay0 at inteldrm0 mux 1 > >> > init: can't open /dev/console: Device not configured" and the system > doesn't > >> > boot at all. > >> > >> Is it possible that it does actually boot but that you just don't see > >> the > >> messages. Did you try pinging the machine or accessing it through > >> SSH? > >> > >> > >> > > >> > Please refer to the screenshot attached: https://ibb.co/sQbt7F7 > >> > > >> > And after few hours of forums/IRC-logs readings, I tried to try the > >> > suggestion of lots of similar-people: "disable inteldrm" > >> > > >> > To do that, during the boot I typed "boot -c", then got a brand new > error > >> > (IPMI/KVM freezes, no more keyboard input): > >> > "kbc: cmd word write error" (with a weird cursor) > >> > Please refer to the screenshot attached: https://ibb.co/QchqhtY > >> > > >> > Anyways, wanted to skip that -for now-, rebooted the server again, and > >> > booted into bsd.rd, mounted the / and /usr on the harddisk, chrooted > into > >> > there and did; > >> > "config -ef /bsd", then "disable inteldrm" and "quit" to save the > changes. > >> > Finally rebooted. > >> > > >> > The system booted up fine! Got the login prompt shell, logged in, > well, with > >> > -an another- brand new error :) > >> > > >> > "reorder_kernel: failed - see /usr/...GENERIC.MP/relink.log" > >> > >> This sometimes indicates that the previous boot got to the kernel > >> re-linking stage but that it got interrupted there. I see this on VMs > >> if I forcefully reboot them as soon as the login prompt appears. > >> > >> > >> > > >> > I guess that was because I modified the kernel, anyway, wanted to > skip that > >> > too -for now-. Did what I always do the first: syspatch > >> > > >> > installed the patches, rebooted the system, aand...Tada! "inteldrm0 > is back, > >> > b1tch3z!" :) > >> > > >> > Dmesg has again: "init: can't open /dev/console: Device not > configured" and > >> > delays there. No boot, again. > >> > > >> > My questions are: > >> > > >> > How can I get the rid of the error "init: can't open /dev/console: > Device > >> > not configured" to be able to boot into the system? > >> > > >> > if that was the only way (disabling inteldrm), would I repeat it each > time I > >> > issue syspatch? > >> > > >> > And each time syspatch (re)installs the kernel, should I get the error > >> > "reorder_kernel: failed", because I modified (disabled inteldrm) > kernel? > >> > > >> > Any words on "kbc: cmd word write error" when I tried the 'boot -c'? > >> > > >> > I thank you for your time in reading all these, > >> > And many thanks for your suggestions, in advance! > >> > > >> > Best, > >> > Özgür Kazancci > >> > >> -- > >> Andreas (Kusalananda) Kähäri > >> SciLifeLab, NBIS, ICM > >> Uppsala University, Sweden > >> > >> . > >> > > -- Kindes