Re: USB peripherals hang, nothing in messages
On Wed, Mar 13, 2024 at 05:12:29PM +0500, ofthecentury wrote: > My USB mouse and keyboard hang intermittently. > > Very weird things happen, i.e. my mouse's red LED > light begins to flicker in a very weird fashion, or my > keyboard stops responding and my sound output > is suddenly muted by itself (I don't even touch sound). > > This was in the /var/log/messages regarding sound: > wrapper-2.0: vfprintf %s NULL in "[xfce-mixer-plugin. > c:374 xfce_mixer_plugin_set_property]: could not > set sound-card to '%s', trying the default card instead" > wrapper-2.0: vfprintf %s NULL in "%s: muted" > > Nothing else to show up in /var/log/messages. Is there > a more detailed log? This sounds to me like it might be due to USB stack performance problems, though you'll at least want to give `dmesg` output so that those who better understand this have a chance of helping. FWIW, there seem to be notable differences in USB performance on nominally similar hardware with OpenBSD. On an AMD 7900x w/MSI motherboard, I had very few USB performance problems (though there were other non-USB issues). On an Intel 13900k w/Asus motherboard I have frequent, significant, USB performance problems. Every USB peripheral suffers from random disconnects, particularly under load. This is most notable with USB sound and USB webcam, which disconnect several times per hour, but the USB keyboard and USB mouse are also sometimes affected (perhaps once a week, mostly the mouse). I have absolutely no idea what the cause for this difference might be. The CPU and motherboard differences might be significant or not, I don't know. And it may, or may not, have any relation to the symptoms you're seeing. Laurie
Re: xscreensaver-settings keeps on crashing
On Wed, Oct 18, 2023 at 03:46:51AM -0500, Luke Small wrote: Hello Luke, > I discovered that if I run xfce desktop that I have on here for thunar > file manager, that it works. I don’t know why. > > I can’t run xscreensaver-settings under fvwm. The screensavers work > though. > > Any suggestions? It said something about conflicting with > xfce4-screensaver or something too. I'm not totally certain if this is relevant but, at least in the past (I haven't checked recently), xfce4-screensaver fiddles with X's screen saver settings. There's some details spread throughout this thread: https://marc.info/?l=openbsd-ports=168355214625929=2 Laurie
Ryzen 9 (7x000) users: do you experience hangs?
A small number of us with AMD Ryzen 9 (i.e. chips in the 7x000 range) machines have been experiencing regular (often daily), or semi-regular hangs, but without any obvious cause. What we don't know is if we're the unlucky few, or whether this might be a wider issue. So, to see if there is some sort of pattern going on (e.g. are certain motherboards / BIOSes correlated with hangs or not?), I'd like to poll Ryzen 9 OpenBSD users. At a minimum we'd need to know: CPU model (e.g. "7900x") Motherboard (e.g. "MSI PRO670-X") Have you experienced crashes? (Yes/No) If "Yes": what frequency (e.g. "daily/weekly/no obvious pattern")? are there are obvious causes (e.g. "happens when I run program X")? have you found any mitigations (e.g. "updated BIOS")? Ideally a dmesg too We're as interested in Ryzen 9 users who aren't experiencing hangs as who are! Please feel free to reply to the list, or to me individually, and I'll collate the information and see if there are any patterns or not. Laurie -- Personalhttps://tratt.net/laurie/ Software Development Team https://soft-dev.org/ https://github.com/ltratt https://twitter.com/laurencetratt
Re: All my Rust programs stop working on OpenBSD 7.3
On Mon, Apr 10, 2023 at 08:53:55PM +0200, Theo Buehler wrote: Hello Theo, > with something like this in Cargo.toml: > > [dependencies.ring] > version = "^0.16" > path = "/usr/local/share/ring-0.16.20" In case it's useful to anyone else, one can set this globally in ~/.cargo/config.toml (and avoid tweaking multiple Cargo.toml's, which can be a pain with dependencies) with: [patch.crates-io] ring = { path = "/usr/local/share/ring-0.16.20" } However, there is one gotcha: this will cause your Cargo.lock to be altered, so if you're working on a project with a checked-in Cargo.lock, you need to be careful. Laurie
Re: Hardware for OpenBSD based access point
On Mon, Mar 14, 2022 at 01:52:15AM +0100, Nicolas Goy wrote: Hello Nicolas, > I use OpenBSD for all my network gears except wireless access points. > > My current access points are getting old and I'd like to replace them. I was also in the same place a year or so ago. After seeing many recommendations I bought a Ubiquiti device, but I would not recommend it: it is poorly documented, with two separate incomplete UIs, and buggy (including, but not only, dropping connections), even before one considers things like "phoning home" etc. Not one of my better purchases, and I'm surprised how often they're recommended -- I was happy to be rid of it. I then bought a cheap Celeron box as an OpenBSD router and a Ruckus access point (an R510 in my case, though I suspect most of their models would suit my purposes) with the "unleashed" firmware. The Ruckus is an absolute joy -- the UI is simple and well thought through, so I had it 95% configured to do what I wanted in under 10 minutes, and the (clear! fairly complete!) documentation helped me do the rest soon after. It has been rock solid for 6 months, without once dropping a connection. The only problem is price -- they are prohibitively expensive new for a typical consumer, but on ebay you can pick them up for a reasonable price. Laurie -- Personalhttps://tratt.net/laurie/ Software Development Team https://soft-dev.org/ https://github.com/ltratt https://twitter.com/laurencetratt
Re: USB Camera
On Fri, Sep 25, 2020 at 03:42:36PM +0200, Jan Stary wrote: Hello Jan, >> *However*, uvideo currently doesn't support the ability to set things like >> zoom, pan, and, exposure. That latter is a problem for cameras (like my >> Logitech C920) that do auto-exposure: no matter what framerate you ask >> for, they continually adjust it to match what they think the exposure >> should be. > I have a similar problem with some Logitechs using auto*focus*: the moving > figure in front of a whiteboard, for example, makes the camera refocus > constantly, producing an unwatchable video. The best advice I've seen is to turn off all auto features in cameras when recording videos, for just that reason! However, most of those auto-features (including auto-focus) are part of the UVC camera terminal control request (4.2.2.1 in the 1.5 version of the UVC spec). It's probably not rocket science to add support for that part of the spec to uvideo for someone who's familiar with those general parts of the kernel, but it is work, and I'm not aware that anyone's currently looking into it (but I would love to be wrong about that!). Laurie
Re: video(1) -s size default overrides -r rate
On Mon, Sep 21, 2020 at 05:44:17PM +0200, Jan Stary wrote: Hello Jan, > Presumably, as the default -s size is picked, and the camera cannot do 30 > fps in that size, -r 20 is chosen instead. > > If that's correct, the default size in effect overrides a specified rate. > Is that intended? > > It doesn't seem to be the least surprise: the command line specifies the > rate, and doesn't care about the size. > > Would it be preferable if video(1) chose -s 640x360 in that case, at 30 > fps, obeying the command line option? IMHO, there's no way to not surprise users: users (naively, if reasonably) want both big sizes and high frame rates, but that's generally impractical for (uncompressed) YUY2. It *might* be more reasonable to throw an error if everything specified can't be delivered. However, there's a probably deeper point here. IMHO, video(1) isn't really a sensible tool for viewing or recording video as it can't access a camera's MJPEG mode (assuming the camera has one!) without ld tricks. In general, I suggest that people use ffplay/ffmpeg (or something similar). Stefan Hagen has been trying to put together an FAQ entry explaining webcam use on OpenBSD [1]. Laurie [1] https://marc.info/?l=openbsd-tech=160053691513681=2
Re: USB Camera
On Thu, Sep 17, 2020 at 03:46:25PM +0200, Jan Stary wrote: Hello Jan, > Can people please recommend an USB camera that is known to work well with > OpenBSD? Since Marcus fixed MJPEG support in uvideo recently, most USB cameras will probably work pretty well with uvideo. *However*, uvideo currently doesn't support the ability to set things like zoom, pan, and, exposure. That latter is a problem for cameras (like my Logitech C920) that do auto-exposure: no matter what framerate you ask for, they continually adjust it to match what they think the exposure should be. In practise, this means that you end up with duplicated frames (even in well lit situations) which is tolerable for a video chat but more annoying for recorded videos. Some cameras don't have an automatic exposure setting and so, I presume, are immune to this problem, though I have yet to acquire such a camera to test. Laurie
webcam fixes and changes in -current
Lots of us have to use webcams more than we used to. There have been some recent changes in OpenBSD support for webcams that some might find useful. Most of the hard work was done by Marcus Glocker, with input from Ingo Feinerer, sc.dying, and myself. The first change is that MJPEG in cameras now works reliably. In essence, most webcams can deliver uncompressed video at a low frame rate or compressed (MJPEG) at a high frame rate. The latter tickled a limitation in the USB stack, which led to the picture breaking up -- and which is now fixed! If you want to know what your camera is capable of, my suggestion is to install ffmpeg and then run: $ ffplay -f v4l2 -list_formats all -i /dev/video0 which will output lots of stuff, but at the end has the important bits: [video4linux2,v4l2 @ 0x914fbbb6000] Raw : yuyv422 : YUYV : 640x480 160x90 160x120 176x144 320x180 320x240 352x288 432x240 640x360 800x448 800x600 864x480 960x720 1024x576 1280x720 1600x896 1920x1080 2304x1296 2304x1536 [video4linux2,v4l2 @ 0x914fbbb6000] Compressed: mjpeg : MJPEG : 640x480 160x90 160x120 176x144 320x180 320x240 352x288 432x240 640x360 800x448 800x600 864x480 960x720 1024x576 1280x720 1600x896 1920x1080 This shows that my C920s webcam has a maximum MJPEG resolution of 1920x1080. The "raw" options (yuyv422) might look tempting as they have a max resolution of 2304x1536, but "video -q" shows they can only achieve low frame rates: $ video -q video device /dev/video: encodings: yuy2 frame sizes (width x height, in pixels) and rates (in frames per second): 160x90: 30, 24, 20, 15, 10, 7, 5 160x120: 30, 24, 20, 15, 10, 7, 5 176x144: 30, 24, 20, 15, 10, 7, 5 320x180: 30, 24, 20, 15, 10, 7, 5 320x240: 30, 24, 20, 15, 10, 7, 5 352x288: 30, 24, 20, 15, 10, 7, 5 432x240: 30, 24, 20, 15, 10, 7, 5 640x360: 30, 24, 20, 15, 10, 7, 5 640x480: 30, 24, 20, 15, 10, 7, 5 800x448: 30, 24, 20, 15, 10, 7, 5 800x600: 24, 20, 15, 10, 7, 5 864x480: 24, 20, 15, 10, 7, 5 960x720: 15, 10, 7, 5 1024x576: 15, 10, 7, 5 1280x720: 10, 7, 5 1600x896: 7, 5 1920x1080: 5 2304x1296: 2 2304x1536: 2 controls: brightness, contrast, saturation, gain, sharpness, white_balance_temperature As that suggests, video(1) only easily supports YUY2/YUYV422. The easiest way to see higher frame rates I know of is to use ffmpeg. Most cameras can sustain 30fps (or sometimes 60fps) at high resolutions as can be seen with: $ ffplay -f v4l2 -input_format mjpeg -video_size 1920x1080 -i /dev/video0 If you use video chat in a browser, you should find that it can now reliably support higher resolutions without problems. video(1) has also been extended to allow altering webcam controls from the command-line. In order to do this, nothing else can be using the webcam; however, the settings are "sticky" so they effect subsequent programs which use the webcam. I can see the current settings with: $ video -c brightness=128 contrast=128 saturation=128 gain=0 sharpness=128 white_balance_temperature=auto and I can reset things back to a known state with: $ video -d I can change e.g. brightness with: $ video brightness=200 brightness: 128 -> 200 Some, though not all, controls have automatic adjustment. If your webcam has the white_balance_temperature control, it probably defaults to "auto", meaning that it tries to adjust based on how yellow/white it thinks the light is. In my experience, the automatic adjustment ends up making everything look like a Smurfs homage (i.e. too blue). video(1) allows us to override the automatic setting and specify a temperature manually (in Kelvin). During the day I might use: $ video white_balance_temperature=5000 white_balance_temperature: auto -> 5000 If you really want, you can use "auto" as a value for such controls instead of a numeric value. Note further that if you're used to other operating systems webcam support, you might expect there to be two white balance temperature controls (one for the manual temperature and a separate auto boolean): video(1) unifies them. You can specify multiple controls at once e.g.: $ video brightness=50 white_balance_temperature=3000 brightness: 128 -> 50 white_balance_temperature: auto -> 3000 Be aware that uvideo doesn't yet support the "camera terminal control requests" part of the UVC spec so some controls (e.g. zoom, pan, and exposure) cannot be altered. If and when uvideo gains such support, the necessary changes to video(1) will be trivial. Overall, I think this makes webcams much more usable under OpenBSD, and thanks again to Marcus, because none of this would have happened without him! Laurie
Re: vesa vs. wsfb?
On Wed, Jul 05, 2017 at 05:20:14PM -, Christian Weisgerber wrote: Hello Christian, > Between the vesa(4) and wsfb(4) X11 video driver, are there any advantages > one has over the other? > > I have a brand new laptop (Kaby Lake) whose integrated graphics chipset > isn't yet supported by inteldrm(4)/intel(4). On a Skylake machine from last year, I found a couple of odd things happening with vesa. The one I remember is that if my phone was charging from the machine at boot, the BIOS reported incorrect vesa details that meant I couldn't run X (I have no idea why; presumably the BIOS developers no longer test non-UEFI code paths properly). vesa was also, ISTR, too slow to play video sensibly, although I might be wrong about that. wsfb worked flawlessly as soon as I switched. I'm not pretending that my experience is anything other than a single anecdote though. Laurie -- Personal http://tratt.net/laurie/ Software Development Teamhttp://soft-dev.org/ https://github.com/ltratt http://twitter.com/laurencetratt
Re: Computer hangup : scsi_xfer pool exhausted!
On Wed, Jan 27, 2016 at 10:31:28AM +, Sébastien Morand wrote: Hello Sébastien, > I have a computer hanging up every 4/5 days. It's no more accessible by > network and keyboard is not responding. The only message displayed in > console log is "scsi_xfer pool exhausted!" which is documented by : I see this too, though less frequently, perhaps every couple of weeks or so. There appears to be no clear pattern about when the machine suddenly locks like this (X shuts down, I'm dumped in the console, and see the above message; though the keyboard sort-of works, in the sense that key presses are echoed back, no commands can be executed nor can I login; I can't power the machine off in any nice way; instead I have to hard power the machine off), which makes filing a bug report hard. Laurie -- Personal http://tratt.net/laurie/ Software Development Teamhttp://soft-dev.org/ https://github.com/ltratt http://twitter.com/laurencetratt OpenBSD 5.9-beta (GENERIC.MP) #1864: Mon Jan 25 19:11:29 MST 2016 dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP real mem = 8476475392 (8083MB) avail mem = 8215384064 (7834MB) mpath0 at root scsibus0 at mpath0: 256 targets mainbus0 at root bios0 at mainbus0: SMBIOS rev. 2.7 @ 0xeb170 (52 entries) bios0: vendor Intel Corp. version "BLH6710H.86A.0160.2012.1204.1156" date 12/04/2012 bios0: TranquilPC IXL acpi0 at bios0: rev 2 acpi0: sleep states S0 S3 S4 S5 acpi0: tables DSDT FACP APIC SSDT MCFG HPET acpi0: wakeup devices PS2K(S3) PS2M(S3) UAR1(S3) P0P1(S4) P0P2(S4) P0P3(S4) P0P4(S4) GBE_(S4) BR20(S3) EUSB(S3) USBE(S3) PEX0(S4) BR21(S4) PEX1(S4) PEX2(S4) PEX3(S4) [...] acpitimer0 at acpi0: 3579545 Hz, 24 bits acpimadt0 at acpi0 addr 0xfee0: PC-AT compat cpu0 at mainbus0: apid 0 (boot processor) cpu0: Intel(R) Core(TM) i7-2600S CPU @ 2.80GHz, 2794.12 MHz cpu0: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS H,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX ,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,A ES,XSAVE,AVX,NXE,LONG,LAHF,PERF,ITSC,SENSOR,ARAT cpu0: 256KB 64b/line 8-way L2 cache cpu0: smt 0, core 0, package 0 mtrr: Pentium Pro MTRR support, 10 var ranges, 88 fixed ranges cpu0: apic clock running at 99MHz cpu0: mwait min=64, max=64, C-substates=0.2.1.1, IBE cpu1 at mainbus0: apid 2 (application processor) cpu1: Intel(R) Core(TM) i7-2600S CPU @ 2.80GHz, 2793.65 MHz cpu1: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS H,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX ,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,A ES,XSAVE,AVX,NXE,LONG,LAHF,PERF,ITSC,SENSOR,ARAT cpu1: 256KB 64b/line 8-way L2 cache cpu1: smt 0, core 1, package 0 cpu2 at mainbus0: apid 1 (application processor) cpu2: Intel(R) Core(TM) i7-2600S CPU @ 2.80GHz, 2793.65 MHz cpu2: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS H,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX ,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,A ES,XSAVE,AVX,NXE,LONG,LAHF,PERF,ITSC,SENSOR,ARAT cpu2: 256KB 64b/line 8-way L2 cache cpu2: smt 1, core 0, package 0 cpu3 at mainbus0: apid 3 (application processor) cpu3: Intel(R) Core(TM) i7-2600S CPU @ 2.80GHz, 2793.65 MHz cpu3: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS H,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX ,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,DEADLINE,A ES,XSAVE,AVX,NXE,LONG,LAHF,PERF,ITSC,SENSOR,ARAT cpu3: 256KB 64b/line 8-way L2 cache cpu3: smt 1, core 1, package 0 ioapic0 at mainbus0: apid 0 pa 0xfec0, version 20, 24 pins acpimcfg0 at acpi0 addr 0xf800, bus 0-63 acpihpet0 at acpi0: 14318179 Hz acpiprt0 at acpi0: bus 0 (PCI0) acpiprt1 at acpi0: bus -1 (P0P1) acpiprt2 at acpi0: bus -1 (P0P2) acpiprt3 at acpi0: bus -1 (P0P3) acpiprt4 at acpi0: bus -1 (P0P4) acpiprt5 at acpi0: bus 1 (PEX0) acpiprt6 at acpi0: bus -1 (BR21) acpiprt7 at acpi0: bus 2 (PEX1) acpiprt8 at acpi0: bus -1 (PEX2) acpiprt9 at acpi0: bus -1 (PEX3) acpiprt10 at acpi0: bus -1 (PEX4) acpiprt11 at acpi0: bus -1 (PEX5) acpiprt12 at acpi0: bus -1 (PEX6) acpiprt13 at acpi0: bus -1 (PEX7) acpicpu0 at acpi0 0x800a4008 cnt:01 stk:00 package: 06 0x800a3a88 cnt:01 stk:00 integer: 6 0x8009fc08 cnt:01 stk:00 integer: 0 0x800a4d88 cnt:01 stk:00 integer: 0 0x800a4d08 cnt:01 stk:00 integer: fe 0x800a1508 cnt:01 stk:00 integer: 2 0x800a1308 cnt:01 stk:00 integer: 2 CSD r=0 d=0 c=fe n=2 i=2 : C3(350@104 mwait.3@0x20), C2(500@80 mwait.3@0x10), C1(1000@1 mwait.1), PSS acpicpu1 at acpi0 0x8009f188 cnt:01 stk:00 package: 06 0x8009f308 cnt:01 stk:00 integer: 6 0x800a1a08
Re: iwm0: could not initiate 2 GHz scan
On Mon, Jan 11, 2016 at 11:13:03AM -0700, Chris Wojo wrote: Hello Chris, > Currently, I'm running a snapshot 5.9-beta # 1800. > > I'm trying to connect to a wireless access point but receive "iwm0: could > not initiate 2 GHz scan" from dmesg. > > dhclient comes back with no link. I saw this yesterday on a recent snapshot, although in an odd way. Despite the "could not initiate 2GHz scan" message, I could connect to a 2GHz network, but not a 5GHz one (with the same symptoms you saw: dhclient saying there was no link). Laurie -- Personal http://tratt.net/laurie/ Software Development Teamhttp://soft-dev.org/ https://github.com/ltratt http://twitter.com/laurencetratt
Re: Thinkpad X1 Carbon Suspend issue
On Mon, May 25, 2015 at 08:21:19PM +0100, Bojan Nastic wrote: Anyone having much luck with 5.7 or -current on Thinkpad X1 Carbon 2nd gen (Haswell chip)? It works pretty well (including wireless), although on my machine the lack of a specific video driver means that things in X can be painfully slow (forget about watching a video!). Everything seems to be working fine, except for waking from suspend. Suspend works fine, either via 'zzz' or closing the lid, but waking it up doesn't work -- hardware seems unresponsive, the sleep light stays on regardless of what I do to it (pressing buttons, opening the lid...) When I do this, the OS is still working, but the screen doesn't wake back up (whether this is related to X running in the background or not, I don't know -- I never run without X). I can see this happening as follows. Log in as root on console 1. Suspend with zzz (I don't use suspend-with-lid). Resume by pressing the power button. [At this point the screen is blank.] Type reboot. Wait a little while and the machine will reboot. I appreciate that's not hugely useful, but it does mean that, if I want to test suspend/resume support ever so often, I don't have to fsck afterwards... Laurie -- Personal http://tratt.net/laurie/ Software Development Teamhttp://soft-dev.org/ https://github.com/ltratt http://twitter.com/laurencetratt
Re: offline mail setup for road warrior
On Sat, Mar 09, 2013 at 12:18:50AM +0100, frantisek holop wrote: i have my own mail server, that i can setup as i want. i am travelling with my notebook. my preferred setup would be something that downloads my mails when i am connected, then i can write answers locally even when being offline, and these would be sent automatically (through my server) when i come online again. my mail client is mutt. any road warriors living like this with a rock solid well tested setup? I use unison to sync my maildirs (much faster than POP/IMAP) and extsmail [1] to send my e-mail via ssh whenever a connection is found. This is a very simple setup, but it has the advantage that it requires no more config than is needed for normal ssh. I find it much easier than e.g. setting up SMTP/TLS on various machines. It also means that synchronising things across multiple machines works well. I spend huge chunks of time offline (e.g. I'm writing this on a train), and this setup has worked well for me for several years. Yours, Laurie [1] http://tratt.net/laurie/src/extsmail/ in ports as mail/extsmail -- Personal http://tratt.net/laurie/ Software Development Teamhttp://soft-dev.org/ https://github.com/ltratt http://twitter.com/laurencetratt
Re: several X servers on one host
On Sun, Dec 02, 2012 at 11:53:44PM +0400, Alexei Malinin wrote: Indeed, I ran two X servers at the same time a long time ago. But from time to time I have a need to do so (that is, to run one more X session on behalf of another person, without destroyingmy active X session)... I sometimes have to do this too, and similarly realised that running two X servers on the same machine was rather difficult to get working. Based on a program called xsandbox, I created a little script xcage: http://tratt.net/laurie/src/xcage/ Nested X sessions can be a little buggy -- at least on the machines I've used them on -- but they're often better than the alternatives (e.g. VNC to localhost). Laurie -- Personal http://tratt.net/laurie/ The Converge programming language http://convergepl.org/ https://github.com/ltratt http://twitter.com/laurencetratt
Re: Soekris equivalent
On Wed, Dec 17, 2008 at 02:38:43PM -0500, Christopher Sean Hilton wrote: Is anyone aware of an equivalent for the Soekris Net 5501-70. I'm looking to prototype an OpenBSD border gateway that offers web proxy capabilities through squid cache but squid is a bit of a memory hog and I'd like to have something with a Gig of RAM. Power footprint is a consideration which is why the Soekris is at the top of the list. I started off looking at Soekris but, to be honest, thought they were expensive given their lack of horsepower. After a lot of hunting, I ended up with a Tranquil (http://www.tranquilpc.co.uk/) T7, which is a passively cooled Intel Atom solution. Depending on where you site it, you might want to fiddle with its positioning to maximise its ability to cool itself (I found that if I floor mounted it, raising it half an inch above the floor meant it ran much cooler; I suspect the available wall mount would have a similar beneficial effect), It works fine with OpenBSD, draws very little power, can be ordered in a bare bones version (sans OS etc.), and is very well engineered. As with most Atom machines, it's a little sparse on the peripherals, but adding a USB NIC or two would probably do the trick for most gateway purposes. Laurie -- http://tratt.net/laurie/ -- Personal http://fetegeo.org/ -- Free text geocoding http://convergepl.org/ -- The Converge programming language
Re: Archiving pkg's added by pkg_add -u
On Sat, Jan 26, 2008 at 12:00:22PM +0100, Marc Espie wrote: As a possibly complimentary idea to PKG_CACHE, I wrote a simple script a while back which bulk downloads packages: You don't need this script to minimize service down time. The normal way to slurp down packages of on an installed machine is to run pkg_add -uin with PKG_CACHE set (in fact, I had to tweak pkg_add -n behavior right after implementing PKG_CACHE to make sure it would download the whole package). Then, once your full set is downloaded, you can pkg_add them. Even better - I can drop that script (it's quite old, and predates pkg_add -u IIRC)! I am a huge fan of the pkg_* tools, and their improvement over the time I have used OpenBSD has been nothing short of incredible. The only issue I have with pkg_add is that I find the options overwhelming (e.g. -r and -u confuse me every time, as a quick read of the man page suggests they do virtually the same thing). When you say the normal way I expect most people had no idea that -uin and PKG_CACHE in combination do the right thing. Perhaps this could be added to the man page or the FAQ so it can become the normal way? I'm sure you know a number of useful tricks with the pkg_* tools that the rest of us remain sadly ignorant of, and it would be great if such things became more widely known. Of course, it's entirely possible that I'm the only person who didn't realise that the above was possible, in which case please pretend I never said anything :) Laurie -- http://tratt.net/laurie/ -- Personal http://convergepl.org/ -- The Converge programming language
Re: Archiving pkg's added by pkg_add -u
On Fri, Jan 25, 2008 at 10:20:50AM +, Edd Barrett wrote: I was wondering if there is a way that pkg_add -u can save packages that it installs into a specified directory. I think I could save a lot of bandwidth if this were possible, as I have several machines to update with snapshots every 2 weeks or so. As a possibly complimentary idea to PKG_CACHE, I wrote a simple script a while back which bulk downloads packages: http://tratt.net/laurie/computing/obsd/packagesbootstrap/ I use this to download packages onto a local machine before doing a pkg_add, which helps minimise any service down time (if you're upgrading from one OS version to another, I recommend still using PKG_PATH with an ftp server as the second location in the path, as package dependencies can change and the script doesn't check that sort of thing). It automatically slurps in the output from pkg_info, so it's quite easy to use. Laurie -- http://tratt.net/laurie/ -- Personal http://convergepl.org/ -- The Converge programming language
Re: Machine will not recover from 'deep sleep' state [ IBM Thinkpad T41 ]
On Sat, Dec 01, 2007 at 03:54:42PM +0100, Ted Unangst wrote: [Mark Thomas] If I close the lid on this laptop ( Thinkpad T41 ) the machine goes into a deep sleep but will not recover with OpenBSD 4.2. With 4.1 this worked flawlessly. xorg is not running during these tests. it will often come back if you cycle through another suspend/resume with fn-f4. For what it's worth, this is also the case with hibernation. Occasionally my T43 doesn't come out of hibernation properly. Re-hibernating and then switching the machine back on has worked every time so far (though once I had to do this twice I think). Laurie -- http://tratt.net/laurie/ -- Personal http://convergepl.org/ -- The Converge programming language
ACPI slowness on amd64 bsd.mp
The latest amd64 snapshots have ACPI enabled. On my Shuttle SN25P, with an AMD dual core processor, this leads to a significant decrease in performance. For example, given the same bsd.mp kernel on an unloaded system, here's a time'd compile of an application with ACPI disabled: gmake 50.99s user 7.26s system 92% cpu 1:03.29 total and with ACPI enabled: gmake 53.05s user 10.81s system 73% cpu 1:26.57 total As you can see, enabling ACPI leads to a more-or-less 50% slowdown. I did file an informal report about this same issue in January, so I don't think this is a new problem. With ACPI enabled, even when the machine is idle top shows that one processor is fairly continuously spending 60-70% of its time processing interrupts. In use, the machine feels really sluggish, as if using a machine from several years back. Disabling ACPI at UKC is all that is needed to restore performance. Here's the dmesg with ACPI disabled: OpenBSD 4.1-current (GENERIC.MP) #1286: Thu Jun 7 00:52:32 MDT 2007 [EMAIL PROTECTED]:/usr/src/sys/arch/amd64/compile/GENERIC.MP real mem = 1073278976 (1023MB) avail mem = 1025142784 (977MB) User Kernel Config UKC disable acpi 263 acpi0 disabled UKC quit Continuing... mainbus0 at root bios0 at mainbus0: SMBIOS rev. 2.2 @ 0xf (32 entries) bios0: Shuttle Inc SN25V10 acpi at mainbus0 not configured mainbus0: Intel MP Specification (Version 1.1) cpu0 at mainbus0: apid 0 (boot processor) cpu0: AMD Athlon(tm) 64 X2 Dual Core Processor 4200+, 2210.47 MHz cpu0: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,NXE,MMXX,FFXSR,LONG,3DNOW2,3DNOW cpu0: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB 64b/line 16-way L2 cache cpu0: ITLB 32 4KB entries fully associative, 8 4MB entries fully associative cpu0: DTLB 32 4KB entries fully associative, 8 4MB entries fully associative cpu0: apic clock running at 200MHz cpu1 at mainbus0: apid 1 (application processor) cpu1: AMD Athlon(tm) 64 X2 Dual Core Processor 4200+, 2210.19 MHz cpu1: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,NXE,MMXX,FFXSR,LONG,3DNOW2,3DNOW cpu1: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB 64b/line 16-way L2 cache cpu1: ITLB 32 4KB entries fully associative, 8 4MB entries fully associative cpu1: DTLB 32 4KB entries fully associative, 8 4MB entries fully associative mpbios: bus 0 is type PCI mpbios: bus 1 is type PCI mpbios: bus 2 is type PCI mpbios: bus 3 is type PCI mpbios: bus 4 is type PCI mpbios: bus 5 is type PCI mpbios: bus 6 is type ISA ioapic0 at mainbus0 apid 2 pa 0xfec0, version 11, 24 pins ioapic0: misconfigured as apic 0, remapped to apid 2 pci0 at mainbus0 bus 0: configuration mode 1 NVIDIA nForce4 DDR rev 0xa3 at pci0 dev 0 function 0 not configured pcib0 at pci0 dev 1 function 0 NVIDIA nForce4 ISA rev 0xa3 nviic0 at pci0 dev 1 function 1 NVIDIA nForce4 SMBus rev 0xa2 iic0 at nviic0 iic1 at nviic0 adt0 at iic1 addr 0x2e: adm1027 rev 0x6a iic1: addr 0x4e 03=08 04=08 12=fd 13=0f 28=83 29=12 2a=12 2b=28 ohci0 at pci0 dev 2 function 0 NVIDIA nForce4 USB rev 0xa2: apic 2 int 11 (irq 11), version 1.0, legacy support pciide0 at pci0 dev 6 function 0 NVIDIA nForce4 IDE rev 0xf2: DMA, channel 0 configured to compatibility, channel 1 configured to compatibility atapiscsi0 at pciide0 channel 0 drive 0 scsibus0 at atapiscsi0: 2 targets cd0 at scsibus0 targ 0 lun 0: SONY, CD-RW CRX320EE, RYK3 SCSI0 5/cdrom removable cd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2 pciide0: channel 1 ignored (disabled) pciide1 at pci0 dev 7 function 0 NVIDIA nForce4 SATA rev 0xf3: DMA pciide1: using apic 2 int 10 (irq 10) for native-PCI interrupt wd0 at pciide1 channel 0 drive 0: WDC WD1500ADFD-00NLR0 wd0: 16-sector PIO, LBA48, 143089MB, 293046768 sectors wd0(pciide1:0:0): using PIO mode 4, Ultra-DMA mode 5 pciide2 at pci0 dev 8 function 0 NVIDIA nForce4 SATA rev 0xf3: DMA pciide2: using apic 2 int 11 (irq 11) for native-PCI interrupt ppb0 at pci0 dev 9 function 0 NVIDIA nForce4 PCI-PCI rev 0xa2 pci1 at ppb0 bus 5 IC Ensemble Envy24PT/HT Audio rev 0x01 at pci1 dev 6 function 0 not configured VIA VT6306 FireWire rev 0x80 at pci1 dev 7 function 0 not configured nfe0 at pci0 dev 10 function 0 NVIDIA CK804 LAN rev 0xa3: apic 2 int 5 (irq 5), address 00:30:1b:b9:05:6c eephy0 at nfe0 phy 1: Marvell 88E Gigabit PHY, rev. 2 ppb1 at pci0 dev 11 function 0 NVIDIA nForce4 PCIE rev 0xa3 pci2 at ppb1 bus 4 ppb2 at pci0 dev 12 function 0 NVIDIA nForce4 PCIE rev 0xa3 pci3 at ppb2 bus 3 ppb3 at pci0 dev 13 function 0 NVIDIA nForce4 PCIE rev 0xa3 pci4 at ppb3 bus 2 ppb4 at pci0 dev 14 function 0 NVIDIA nForce4 PCIE rev 0xa3 pci5 at ppb4 bus 1 vga1 at pci5 dev 0 function 0 NVIDIA GeForce 6600 rev 0xa2 wsdisplay0 at
Re: keyboard lockup, KVM, dual-boot
On Sun, Feb 25, 2007 at 06:10:43PM +0100, Stefan Kell wrote: I want to use this machine as a dual-boot system together with windows. It is connected to a standard PS2-KVM, no USB-mouse or keyboard. Installation of both Windows and OpenBSD 4.0 from CDs worked without any problems. But now if I boot OpenBSD from harddisk the keyboard is locked at the login prompt. But I can use the keyboard in the BIOS, for the boot-manager, with the standard boot-prompt of OpenBSD and within UKC. So something later in the bootprocess is locking the keyboard. I tried to use X-Windows but there is the problem that the mouse is not responding. Maybe this is related? Any sugestions? On perhaps 10-20% of the times I boot my KVM'd OpenBSD setup, a similar thing happens. The keyboard works well at UKC and while the console is booting. As soon as X is launched (with kdm running) the keyboard sometimes is totally dead. Rebooting usually cures the problem and this is easily done via the mouse (which still works) with kdm. So in my case, it's irritating, but not a serious enough problem to really worry about. Have you tried rebooting when the keyboard locks? Every once in a while, I have to reboot 3 or 4 times to get things working so some persistence might pay off. Laurie -- http://tratt.net/laurie/ -- Personal http://convergepl.org/ -- The Converge programming language
Re: Lenovo Thinkpad T43p won't do external VGA output properly
On Wed, Jan 10, 2007 at 03:46:59PM +0100, Jonathan Thornburg wrote: The built-in LCD display works fine at 1600x1200. My problem is that I can't get external video output properly. There seem to be two cases (neither one of which fits my definition of properly): * If, in the BIOS setup, I set Boot Display Device to LCD, then I can get 1600x1200 VGA output when booting and before I start X, but I get no external video output at all once I start X. * If, in the BIOS setup, I set Boot Display Device to VGA+LCD or VGA+DVI+LCD, then I get no external video output when booting and before I start X, but when I start X I get only 640x480 resolution (and matching external video output). I'm not sure exactly when, but at some point something appears to have changed, presumably in X, since X now seems to use 640x480 whenever it's unsure about the output device (previously I'm fairly sure it always used whatever resolution you told it to). That seems to be coupled with the fact that my T43 (which I know has a different graphics card from your T43p, but there again you seem to be having the same problems) plays funny buggers with the external output. On a handful of data projectors, I've got the correct 1024x768; on most I get 640x480; and I get occasional oddities like clipped 1024x768 (missing 20-30 pixels on all edges). Nothing I've tried thus far has persuaded X to use a sensible resolution in such cases. Laurie -- http://tratt.net/laurie/-- Personal http://convergepl.org/ -- The Converge programming language http://sosym.dcs.kcl.ac.uk/ -- Software and Systems Modelling Team
Re: Weird behaviour of KDM
On Wed, Nov 22, 2006 at 08:19:33AM +0100, Dr. Harry Knitter wrote: sometimes I get the right resolution (1280x1024) sometimes only standard vga (600x480). How can I tweak my system to get a reliable KDM with a resolution of 1280x1024? I'm not sure exactly when, but at some point something appears to have changed. These days I find I generally have to have my monitor plugged into my OpenBSD boxes while they're booting if I want to get the correct resolution otherwise I get 640x480 (previously I'm reasonably sure that X used to respect my preferred resolution no matter what). This works across the board: on my KVM switch I have to ensure the monitor focus is on the booting box; on my laptops I have to boot the machine plugged into the data projector etc. I use KDM as well, but I've tried turning that off and the same thing (unsurprisingly) has happend - I don't think it has anything to do with KDM in my case at least. Laurie -- http://tratt.net/laurie/-- Personal http://convergepl.org/ -- The Converge programming language http://sosym.dcs.kcl.ac.uk/ -- Software and Systems Modelling Team
Re: Lenovo notebooks
On Sun, Oct 29, 2006 at 11:44:41AM +0100, Jonathan Thornburg wrote: The main thing I've found which doesn't work at all well is sending video to the external video connector to drive a projector for conference presentations. The usual tricks like changing the X resolution (with 'xrandr') and toggling Fn-F7 have no effect whatsoever -- so far as I can tell there's no signal at all going to the external video connector. The only way I have found to make this work is to reboot, enter the IBM BIOS setup, and set the 'boot video device' to 'LCD + VGA' (instead of the default 'Thinkpad LCD'). The machine then boots normally (with the console display), but when I start X the builtin display is blank and 1280x1024 video is sent to the external connector. My usual 'xterm -fn 7x14 -fg white -bg black' is really ugly in this video mode, but 'xpdf -fullscreen' looks fine. On a T43 I also have to have output set to LCD+VGA, and to reboot with a connector in the VGA port if I want video out to actually work; annoying but not unbearable. The thing that I have not yet conquered is the almost total randomness as to what resolution X will use. On a handful of data projectors, I've got the correct 1024x768; on most I get 640x480; and I get occasional oddities like clipped 1024x768 (missing 20-30 pixels on all edges). Nothing I've tried thus far has persuaded X to use a sensible resolution in such cases. My guess would be that the T43p - which I believe uses a completely different video card to the T43 - may be immune to such problems. Laurie -- http://tratt.net/laurie/-- Personal http://convergepl.org/ -- The Converge programming language http://sosym.dcs.kcl.ac.uk/ -- Software and Systems Modelling Team
Re: Thinkpad hibernation
On Mon, Jul 10, 2006 at 03:46:16AM -0400, Philippe Meunier wrote: I have a Thinkpad laptop (T43) and I'm about to install OpenBSD on it. I have a few questions regarding hibernation though. I've read various documents online so I'm fairly confident with regard to the how but out of curiosity I have some questions below regarding the why, plus a few comments. Hibernation works OK on my T43 (not perfectly, but well enough). tphdisk is in ports/sysutils, so that's one thing less to worry about. As I remember it (and I could be wrong here), in order for hibernation to work the 16 partition has to be the first on the disk. The best tip I can give is do the minimum possible work to create the hibernation partition and install a minimal OpenBSD and test whether hibernation works. There's nothing worse than installing and configuring everything, only to press Fn-F12 and be greeted with a tiny beep which means that the ThinkPad isn't going to hibernate. A couple of caveats though: both my T43 (and my old T40) refuse to hibernate 9 times out of 10 with certain PCMCIA cards (i.e. pressing Fn-F12 does nothing). Taking the cards out rarely effects this - it's like the ThinkPad BIOS has thrown a strop, and I have no idea why this happens. On my T43 (can't remember about the T40), the machine also consumes notably more power when it comes out of hibernation (this doesn't seem to be related to SpeedStep, but I'm not entirely sure). Again, I have no idea why this happens, and there have been several power related commits in the past 3 or 4 weeks, so I have some hope that this might have been fixed. Laurie -- http://tratt.net/laurie/ -- Personal http://convergepl.org/ -- The Converge programming language http://sosym.dcs.kcl.ac.uk/ -- Software and Systems Modelling Team http://modelsconference.org/ -- MoDELS/UML 2006 conference
Re: Anyone using a Asus K8N-VM or A8V-VM?
On Fri, Jun 23, 2006 at 06:03:22PM -0500, Emilio Perea wrote: I have been using an Asus A8V since February. Had lots of problems at first, which seem to have been due to the use of the multiprocessor kernel with a PS/2 keyboard and mouse. Had no problems with the plain bsd kernel, but it would freeze frequently with bsd.mp. Changed memory, disk drives, video card and NIC, finally motherboard. Nothing helped. Although I don't have an Asus motherboard, I had similar problems a few months back on AMD 64 bsd.mp. Brad and Mark Kettenis (and possibly others that I don't know of) found a problem related to processing interrupts. I filed bug report #4914 if you're interested, and the eventual patch was against sys/arch/amd64/isa/isa_machdep.c. That solved the problem for me in -current; I suspect you probably changed keyboards at the point the patch made it into -current! Laurie -- http://tratt.net/laurie/ -- Personal http://convergepl.org/ -- The Converge programming language http://sosym.dcs.kcl.ac.uk/ -- Software and Systems Modelling Team http://modelsconference.org/ -- MoDELS/UML 2006 conference
Re: Sun X2100
On Tue, Apr 18, 2006 at 07:19:07PM -0400, stan wrote: I'm considering purchasing a Sun X2100 to use a an OpenBSD based firewall. Any hardware issues I should be aware of? What have been peoples experince with these (or similar) machines? Although it's not directly OpenBSD related, you'll probably want to flash the BIOS with the latest version, as Sun still seem to be shipping machines with the comically broken first version of the BIOS. Just to give you an idea of how bad it is: USB keyboards don't work reliably (and this is a machine without a PS/2 slot don't forget), and at least one BIOS screen says something like press Shift-F1 but misses the f in shift. Quality control were probably having an off day. Mercifully the BIOS update you can get from SUN is installable in an OS independent fashion, and after that the machine (and OpenBSD) seem to run fine. Laurie -- http://tratt.net/laurie/ -- Personal http://convergepl.org/ -- The Converge programming language http://sosym.dcs.kcl.ac.uk/ -- Software and Systems Modelling Team http://modelsconference.org/ -- MoDELS/UML 2006 conference