It's been awhile

2020-06-10 Thread Greg Thomas
Hey all,

Wow, it looks like I haven't run OpenBSD since 2006 according to the misc
archives.  I guess I got too busy with my shit corporate job which I quit
in 2014 to roast coffee full time.  And then I guess I got too busy to move
on from my comfort zone as my old OpenBSD laptops died.  But with the
current lockdown in Los Angeles giving me a little bit of time to explore
tech along with Windows 7 being unsupported I figured I'd try to move back
to my favorite OS.  I bought a pretty much unused Thinkpad X220 on Ebay
(it's in better shape than the last X220 was when I bought that one 6 years
ago, so super score).

So, I'm still refamiliarizing myself with OpenBSD and was wondering what
the biggest changes have been for a regular user since 4.0?  The first
thing I've seen is rcctl.

Also, has anybody ever reprinted the large wireframe Puffy sticker from
around 15 years ago, or still have one for trade/sale?  I still have the
T40 with my last one stuck to it.

https://photos.app.goo.gl/QTPhKrMraZ4m4oPUA

I'm thinking about trying to pull it off to stick it on to this X220
somehow.

I also did a little poking around last night for window managers/desktop
environments.  I used to use WindowMaker but I'm thinking about trying
something more featureful.  So far during my searching I've seen
recommendations for cwm in base, and then stuff like spectrwm and MATE.
I'm pretty sure I'm *not *going to stick with fvwm.  Is there anything I
absolutely have to check out before I add windowmaker (or maybe xfce)?.

The only problem I've had so far is I have no wired Ethernet here, urndis
was failing me with my OnePlus 6t phone and I just couldn't take the time
to troubleshoot, and I just couldn't seem to add the iwn firmware after
copying it to /tmp from my USB stick (I got "file:/tmp/: empty" after
running fw_update -v -p /tmp iwn) so I took my laptop to my neighbor's
ethernet and easily added iwn.  Running fw_update -vn -p /tmp now seems to
work fine, I'm not sure what I was doing wrong previously.

I've added chrome obviously, and am happy to see my label app on Avery.com
works fine which is the only thing other than email and Google Docs that I
really need for the coffee business.

I also just installed Audacity because I started a noise project about a
year ago so I need to do some basic sound editing.  I'll give the GIMP a
try again for my photography but I may hang on to my old X220 to use
Windows 7 and CS4 PS offline.  And now that I'm done with this email I'm
going to watch the end of Charlie Jade with VLC.

Thanks folks!  If this is inappropriate for misc let me know which forums
are best to join, for whatever reasons I'm not a reddit user yet but if
need be I'll start an account there for OpenBSD, coffee, and noise.

Greg


Re: __printflike macro on OpenBSD

2020-06-10 Thread Theo de Raadt
Because we don't.

sensiblehue  wrote:

> Hello,
> I was wondering why OpenBSD doesn't have a `__printflike' macro in
> ? FreeBSD, NetBSD, and DragonflyBSD have it and it's also
> available from libbsd on Linux.
> Personally I think it's cleaner and just as portable if not more
> portable, because some compilers don't support `__attribute__'.
> 



Re: dmesg memory not match spdmem and bios

2020-06-10 Thread man Chan
 Thanks.  I tried to use amd64 which show the correct memory size.
Is there a way to use i386 to show the correct size of memory ?  The bios shows 
8G memory.  Did I miss something to make it ?
Clarence

Stuart Henderson () 在 2020年6月11日星期四 上午12:41:40 
[GMT+8] 寫道:  
 
 On 2020-06-10, man Chan  wrote:
>  You mean the memory limitation of i386 is 4G.  Am I right ?

A 32-bit kernel can only access memory mapped to addresses below 4GB.

The actual amount of memory that you can use depends on where the
BIOS/UEFI maps the memory (it reserves some addresses for device i/o
etc).

That's why you see a lower "available memory" amount than 4GB.

  


__printflike macro on OpenBSD

2020-06-10 Thread sensiblehue
Hello,
I was wondering why OpenBSD doesn't have a `__printflike' macro in
? FreeBSD, NetBSD, and DragonflyBSD have it and it's also
available from libbsd on Linux.
Personally I think it's cleaner and just as portable if not more
portable, because some compilers don't support `__attribute__'.



Re: Protectli FW1 with Intel 82583V - Interfaces errors and latency spike issue

2020-06-10 Thread obsdml
I have a small fleet of protectli firewalls, all of them with em nics.  Only 
the units i’ve upgraded to 6.7 are showing interface errors, where 6.6 is 
definitely not.


> On Jun 8, 2020, at 5:30 PM, Gabri Tofano  wrote:
> 
> Hi all,
> 
> I'm sending this e-mail since I have found other users in this mailing-list 
> using the same device without issues.
> 
> I'm using a "Protectli FW1" with FreeBSD 12.1 amd64 as a firewall which is 
> serving me with great performances and no issues at all. The appliance has 4 
> Intel Gigabit 82583V Ethernet NIC ports which are working very well under 
> FreeBSD 12.1. I have used PFsense as well prior to FreeBSD and it worked 
> without issues too.
> 
> I took the decision to move to OpenBSD 6.7 amd64 in order to benefit of the 
> latest pf (and other) features but unfortunately the OS is giving me an issue 
> which I guess is related to the NIC drivers; When I was connected via ssh I 
> felt some glitches meanwhile I was typing/moving around with the editor, so I 
> started to ping the inside interface from my wired connected pc and found out 
> that time to time the appliance is responding with a 100+/200+ ms response (I 
> have cut some 1ms reply to make it shorter):
> 
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=163ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time<1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=2ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time<1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time<1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=3ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time<1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=43ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time<1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time<1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time<1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time<1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=4ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=1ms TTL=254
> Reply from 172.16.200.1: bytes=32 time=257ms TTL=254
> 
> With FreeBSD 12.1 is steady at <1/1ms all the time and even under load.
> 
> As an online gamer as well, I felt the glitches meanwhile playing few online 
> FPS games using OpenBSD 6.7 on the appliance. Looking at the interface 
> statistics on OpenBSD I found out that inbound/outbound errors are present 
> (this has been taken after few minutes of a reinstall to test it again):
> 
> FRW-FW1# netstat -i
> NameMtu   Network Address  Ipkts   IfailOpkts Ofail 
> Colls
> em0 1500xx:xx:xx:xx:xx:xx1317600  2351   466114 0   
>   0
> em0 1500  74.215.235/ xxx.xxx.xxx.xxx  1317600  2351   466114 0   
>   0
> em1 1500xx:xx:xx:xx:xx:xx39278218   1199871 1   
>   0
> em1 1500  172.16.200. 172.16.200.1 39278218   1199871 1   
>   0
> em2 1500xx:xx:xx:xx:xx:xx156055 1   
>   0
> em2 1500  172.16.103/ 172.16.103.254   156055 1   
>   0
> em3*1500xx:xx:xx:xx:xx:xx 0 0 0 0   
>   0
> enc0*   0 0 0 0 0   
>   0
> pflog0  33136 0 0 0 0   
>   0
> 
> Looking at the Cisco 3560G where the ports are connected there are no errors 
> at all. I have also doublechecked the drivers and the firmware installed by 
> fw_update are the following:
> 
> vmm-firmware-1.11.0p2
> inteldrm-firmware-20181218
> intel-firmware-20200508v0
> 
> I have done multiple reinstall with different OS to make sure that this is 
> related to OpenBSD 6.7 itself and found the following:
> 
> PFsense 2.4.5: no issues at all
> FreeBSD 12.1: no issues at all
> OPNsense: interface errors
> OpenBSD: interface errors and interface latency spikes
> 
> I have also swapped the ethernet cables and contacted Protectli which has 
> confirmed that this appliance has been tested on OpenBSD (it looks like 6.3).
> 
> Here the dmesg output:
> 
> OpenBSD 6.7 (GENERIC.MP) #2: Thu Jun  4 09:55:08 MDT 2020
> 

Re: dmesg memory not match spdmem and bios

2020-06-10 Thread Theo de Raadt
i386 showed the correct amount of memory *it could use*.

man Chan  wrote:

>  Thanks.  I tried to use amd64 which show the correct memory size.
> Is there a way to use i386 to show the correct size of memory ?  The bios 
> shows 8G memory.  Did I miss something to make it ?
> Clarence
> 
> Stuart Henderson () 在 2020年6月11日星期四 上午12:41:40 
> [GMT+8] 寫道:  
>  
>  On 2020-06-10, man Chan  wrote:
> >  You mean the memory limitation of i386 is 4G.  Am I right ?
> 
> A 32-bit kernel can only access memory mapped to addresses below 4GB.
> 
> The actual amount of memory that you can use depends on where the
> BIOS/UEFI maps the memory (it reserves some addresses for device i/o
> etc).
> 
> That's why you see a lower "available memory" amount than 4GB.
> 
>   



Re: Disabling OpenBSD Login Prompt

2020-06-10 Thread Aisha Tammy
On 6/10/20 1:10 PM, Steve Williams wrote:
> On 10/06/2020 10:31 a.m., Aisha Tammy wrote:
>> On 6/10/20 10:46 AM, Steve Williams wrote:
>>> Hi,
>>>
>>> Do you have the proper ioctls to set baud rate, parity, start bits, stop 
>>> bits so that the serial port is configured correctly?
>>>
>>> What about flow control?  rts/cts, xon/xoff.
>>>
>>> Dealing with a serial port is it's own art.
>>>
>> Wow, this is really interesting.
>> I'm curious, do the display managers like gdm/xdm, etc also have
>> to handle this?
>> I'm asking cuz I'm porting a display manager for linux (nothing to
>> do with openbsd,  but this discussion was very related).
>> I'm in a very similar position where the simplest answer would be
>> to disable a getty at one of the tty's and start the login prompt
>> there (its a visual prompt).
>>
>> link to display manager, if my writing wasn't clear
>> https://git.sr.ht/~kennylevinsen/greetd
>>
>> Aisha
> The baud rate, etc is only applicable to things running over serial RS-232 
> (and 422) ports.  The original poster specified it is running on "com0".
> 
> A display manager would not (typically) be talking over a serial port 
> natively.  In the old days, X might be talking over a serial port using SLIP 
> or some such technology, but that has all gone the way of the dodo bird.
> 
Cool, got it.
Thanks a lot!

Aisha

> Cheers,
> Steve W.
> 
> 
> 
>>
>>> Cheers,
>>> Steve W.
>>>
>>> On 10/06/2020 3:03 a.m., Valdrin MUJA wrote:
 Hi Misc,

 I want to disable OpenBSD Login prompt at startup -and also after logging 
 out-. Because I want to run my external program instead of ksh. There is 
 an login prompt also in my program and I want to use it.

 I updated the /etc/ttys ;

 valdrin# cat /etc/ttys
 #
 #   $OpenBSD: ttys,v 1.2 2008/01/09 17:39:42 miod Exp $
 #
 # name  getty   type    status  comments
 #
 console "/usr/libexec/getty std.9600"   vt220   off secure
 ttyC0   "/usr/libexec/getty std.9600"   vt220   on  secure
 ttyC1   "/usr/libexec/getty std.9600"   vt220   on  secure
 ttyC2   "/usr/libexec/getty std.9600"   vt220   on  secure
 ttyC3   "/usr/libexec/getty std.9600"   vt220   on  secure
 ttyC4   "/usr/libexec/getty std.9600"   vt220   off secure
 ttyC5   "/usr/libexec/getty std.9600"   vt220   on  secure
 ttyC6   "/usr/libexec/getty std.9600"   vt220   off secure
 ttyC7   "/usr/libexec/getty std.9600"   vt220   off secure
 ttyC8   "/usr/libexec/getty std.9600"   vt220   off secure
 ttyC9   "/usr/libexec/getty std.9600"   vt220   off secure
 ttyCa   "/usr/libexec/getty std.9600"   vt220   off secure
 ttyCb   "/usr/libexec/getty std.9600"   vt220   off secure
 tty00   "/root/myprogram"   vt220    on secure
 tty01   "/usr/libexec/getty std.9600"   unknown off
 tty02   "/usr/libexec/getty std.9600"   unknown off
 tty03   "/usr/libexec/getty std.9600"   unknown off
 tty04   "/usr/libexec/getty std.9600"   unknown off
 tty05   "/usr/libexec/getty std.9600"   unknown off
 tty06   "/usr/libexec/getty std.9600"   unknown off
 tty07   "/usr/libexec/getty std.9600"   unknown off

 I'm connected the device with com0 port so I updated the tty00 to run my 
 external program. However; system is stucking after date appears on 
 startup.


 starting network
 reordering libraries: done.
 starting early daemons: syslogd ntpd.
 starting RPC daemons:.
 savecore: no core dump
 checking quotas: done.
 clearing /tmp
 kern.securelevel: 0 -> 1
 creating runtime link editor directory cache.
 preserving editor files.
 starting network daemons: sshd.
 starting local daemons: cron.
 Wed Jun 10 10:27:04 +03 2020


 Also, I tried "chsh" and "chpass" , but still OpenBSD login prompt 
 appears.. How can I overcome this issue?

 Thanks..

> 



Re: Disabling OpenBSD Login Prompt

2020-06-10 Thread Aaron Mason
On Wed, Jun 10, 2020 at 5:57 PM Valdrin MUJA  wrote:
>
> Hi Misc,
>
>
>
> I want to disable OpenBSD Login prompt at startup -and also after logging 
> out-. Because I want to run my external program instead of ksh. There is an 
> login prompt also in my program and I want to use it.
>
>
>
> I updated the /etc/ttys ;
>
> valdrin# cat /etc/ttys
> #
> #   $OpenBSD: ttys,v 1.2 2008/01/09 17:39:42 miod Exp $
> #
> # name  getty   typestatus  comments
> #
> console "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC0   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC1   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC2   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC3   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC4   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC5   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC6   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC7   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC8   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC9   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyCa   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyCb   "/usr/libexec/getty std.9600"   vt220   off secure
> tty00   "/root/myprogram"   vt220on secure
> tty01   "/usr/libexec/getty std.9600"   unknown off
> tty02   "/usr/libexec/getty std.9600"   unknown off
> tty03   "/usr/libexec/getty std.9600"   unknown off
> tty04   "/usr/libexec/getty std.9600"   unknown off
> tty05   "/usr/libexec/getty std.9600"   unknown off
> tty06   "/usr/libexec/getty std.9600"   unknown off
> tty07   "/usr/libexec/getty std.9600"   unknown off
>
>
>
> I'm connected the device with com0 port so I updated the tty00 to run my 
> external program. However; system is stucking after date appears on startup.
>
>
>
> starting network
> reordering libraries: done.
> starting early daemons: syslogd ntpd.
> starting RPC daemons:.
> savecore: no core dump
> checking quotas: done.
> clearing /tmp
> kern.securelevel: 0 -> 1
> creating runtime link editor directory cache.
> preserving editor files.
> starting network daemons: sshd.
> starting local daemons: cron.
> Wed Jun 10 10:27:04 +03 2020
>
>
>
>
>
> Also, I tried "chsh" and "chpass" , but still OpenBSD login prompt appears.. 
> How can I overcome this issue?
>
>
>
> Thanks..

Are you able to access other terminals after boot (i.e. Ctrl+Alt+F2)?

-- 
Aaron Mason - Programmer, open source addict
I've taken my software vows - for beta or for worse



Re: late pppoe address

2020-06-10 Thread Jan Stary
On Jun 06 11:30:46, mill...@openbsd.org wrote:
> On Sat, 06 Jun 2020 19:14:28 +0200, Jan Stary wrote:
> 
> > Is the aim to let the ISP know that the iface is down,
> > so that it gets set up afresh on boot, as opposed to
> > waiting for some PPP keep-alive timeout?
> 
> Basically.  It is to work around an issue where the pppoe ethernet
> interface goes down during reboot before the pppoe disconnect message
> can be sent to the ISP.
> 
> I'm not sure it is needed anymore, though I still have it in my own
> rc.shutdown file.

After a few reboots with and without that, I can confirm
that having 'ifconfig pppoe0 down' in rc.shutdown
noticeably speeds up getting an address assigned
on the next boot. With my ISP, it's seconds
as opposed to a minute or two.

Thank you.

Jan




Re: Disabling OpenBSD Login Prompt

2020-06-10 Thread Aisha Tammy
On 6/10/20 10:46 AM, Steve Williams wrote:
> Hi,
> 
> Do you have the proper ioctls to set baud rate, parity, start bits, stop bits 
> so that the serial port is configured correctly?
> 
> What about flow control?  rts/cts, xon/xoff.
> 
> Dealing with a serial port is it's own art.
> 
Wow, this is really interesting.
I'm curious, do the display managers like gdm/xdm, etc also have 
to handle this?
I'm asking cuz I'm porting a display manager for linux (nothing to 
do with openbsd,  but this discussion was very related).
I'm in a very similar position where the simplest answer would be 
to disable a getty at one of the tty's and start the login prompt 
there (its a visual prompt).

link to display manager, if my writing wasn't clear
https://git.sr.ht/~kennylevinsen/greetd

Aisha


> Cheers,
> Steve W.
> 
> On 10/06/2020 3:03 a.m., Valdrin MUJA wrote:
>> Hi Misc,
>>
>> I want to disable OpenBSD Login prompt at startup -and also after logging 
>> out-. Because I want to run my external program instead of ksh. There is an 
>> login prompt also in my program and I want to use it.
>>
>> I updated the /etc/ttys ;
>>
>> valdrin# cat /etc/ttys
>> #
>> #   $OpenBSD: ttys,v 1.2 2008/01/09 17:39:42 miod Exp $
>> #
>> # name  getty   type    status  comments
>> #
>> console "/usr/libexec/getty std.9600"   vt220   off secure
>> ttyC0   "/usr/libexec/getty std.9600"   vt220   on  secure
>> ttyC1   "/usr/libexec/getty std.9600"   vt220   on  secure
>> ttyC2   "/usr/libexec/getty std.9600"   vt220   on  secure
>> ttyC3   "/usr/libexec/getty std.9600"   vt220   on  secure
>> ttyC4   "/usr/libexec/getty std.9600"   vt220   off secure
>> ttyC5   "/usr/libexec/getty std.9600"   vt220   on  secure
>> ttyC6   "/usr/libexec/getty std.9600"   vt220   off secure
>> ttyC7   "/usr/libexec/getty std.9600"   vt220   off secure
>> ttyC8   "/usr/libexec/getty std.9600"   vt220   off secure
>> ttyC9   "/usr/libexec/getty std.9600"   vt220   off secure
>> ttyCa   "/usr/libexec/getty std.9600"   vt220   off secure
>> ttyCb   "/usr/libexec/getty std.9600"   vt220   off secure
>> tty00   "/root/myprogram"   vt220    on secure
>> tty01   "/usr/libexec/getty std.9600"   unknown off
>> tty02   "/usr/libexec/getty std.9600"   unknown off
>> tty03   "/usr/libexec/getty std.9600"   unknown off
>> tty04   "/usr/libexec/getty std.9600"   unknown off
>> tty05   "/usr/libexec/getty std.9600"   unknown off
>> tty06   "/usr/libexec/getty std.9600"   unknown off
>> tty07   "/usr/libexec/getty std.9600"   unknown off
>>
>> I'm connected the device with com0 port so I updated the tty00 to run my 
>> external program. However; system is stucking after date appears on startup.
>>
>>
>> starting network
>> reordering libraries: done.
>> starting early daemons: syslogd ntpd.
>> starting RPC daemons:.
>> savecore: no core dump
>> checking quotas: done.
>> clearing /tmp
>> kern.securelevel: 0 -> 1
>> creating runtime link editor directory cache.
>> preserving editor files.
>> starting network daemons: sshd.
>> starting local daemons: cron.
>> Wed Jun 10 10:27:04 +03 2020
>>
>>
>> Also, I tried "chsh" and "chpass" , but still OpenBSD login prompt appears.. 
>> How can I overcome this issue?
>>
>> Thanks..
>>
> 



Re: VMM Debian guest serial setup help needed

2020-06-10 Thread Tom Smyth
Hi George,
a reboot on a serial console is probably due to the serial console speeds
miss matching, between your
console client and the console on the guest.

make sure you are setting the console speed / parity, etc also

this issue happens frequently also when booting the  PC Engines board where
the bios runs at 115200 baud , N 8 1
and then the OpenBSD Console changes to 9600 N 8 1 during boot (defaults on
installxx.fs / installxx.img

hope this helps
Tom Smyth

On Wed, 10 Jun 2020 at 21:01, George  wrote:

> Hi guys,
>
> I apologize if this maybe out of topic even though it is truly related
> to VMM than Debian.
>
> I am trying to setup a VMM Debian based guest but I'm not able to get it
> to work. I found some description on the web about which settings to
> edit in grub.cfg to enable the serial console and created a VM with 10.3
> in qcow2 disk format in KVM. Now I am trying to start the same on
> OpenBSD 6.7 but keep getting the connected message and then just
> "Rebooting " after I hit some keyboard keys seems like baud rate issue
> but not sure.
>
> After messing with it for a while now I am getting a new error:
>
> vmctl: could not open disk image(s)
>
> even thought the disk is there and readable to the user I have setup in
> vm.conf in fact I have another VM with the same configuration and disk
> with the same permissions and in the same location that works (it is
> OpenBSD based).
>
> I would greatly appreciate it if someone has gone this path and can
> share some config info with me.
>
> Cheers and thanks in advance,
>
> George
>
>
>
>

-- 
Kindest regards,
Tom Smyth.


Re: VMM Debian guest serial setup help needed

2020-06-10 Thread Dave Voutila


George writes:

> Hi guys,
>
> I apologize if this maybe out of topic even though it is truly related
> to VMM than Debian.
>
> I am trying to setup a VMM Debian based guest but I'm not able to get
> it to work. I found some description on the web about which settings
> to edit in grub.cfg to enable the serial console and created a VM with
> 10.3 in qcow2 disk format in KVM. Now I am trying to start the same on
> OpenBSD 6.7 but keep getting the connected message and then just
> "Rebooting " after I hit some keyboard keys seems like baud rate issue
> but not sure.

Not baudrate related, but there are some known issues in OpenBSD 6.7
related to the emulated uart device in vmd(8). (I have a patch if you
follow -current[1] that fixes stability issues.)

My advice is to install using vmm(4)/vmd(8) and not migrate an image
from KVM. I believe Debian started including the virtio cdrom drivers
finally...but, if not, google for some guides on adding those to the
iso.

Make sure you install OpenSSH and rely on ssh(1) connections to the guest.

As soon as you can, modify the grub defaults in /etc/default/grub and
set the GRUB_CMDLINE_LINUX_DEFAULT to include:

  tsc=reliable tsc=noirqtime console=ttyS0,115200

Make sure to run update-grub afterwards.

You'll probably have a bad time with your clock, though Debian use a 4.x
kernel, so it won't be too bad and may manage using tsc as a
clocksource. Otherwise expect refined-jiffies as the clocksource and it
may run at a rate of 50% of host time.

I recommend you also build and install my Linux clone of vmmci(4)[2]
within the Debian guest if you want safe guest shutdowns.

>
> After messing with it for a while now I am getting a new error:
>
> vmctl: could not open disk image(s)
>
> even thought the disk is there and readable to the user I have setup
> in vm.conf in fact I have another VM with the same configuration and
> disk with the same permissions and in the same location that works (it
> is OpenBSD based).

Use top(1) showing threads and command line args: top -C -g vmd

Chances are you have a lingering vmd(8) process for the Debian guest
using the disk. Kill -9 the one with the vm name.

>
> I would greatly appreciate it if someone has gone this path and can
> share some config info with me.
>
> Cheers and thanks in advance,
>
> George

[1] https://sisu.io/patches/vmd-thread-safety-07062020-v1.patch
[2] https://github.com/voutilad/virtio_vmmci

-Dave



Re: dmesg memory not match spdmem and bios

2020-06-10 Thread man Chan
 thanks you .  will amd64 on my i5 machine
clarence

() 在 2020年6月10日星期三 下午10:17:51 [GMT+8] 寫道:  
 
 Haai,

"man Chan"  wrote:
> Hello,
> I just got a second Gaga-H97N-wifi motherbroad and installed openbsd6.6 
> Stable. The  dmesg shows real and avail memory does not  match with the 
> spdmem.  Anyone know how to solve this problem ?  Please help.
> Thanks
> Clarence
> OpenBSD 6.6-stable (GENERIC.MP) #1: Sun Jun  7 14:00:04 HKT 2020
>    r...@dell.my.domain:/usr/src/sys/arch/i386/compile/GENERIC.MP

i386 is limited to 4G of memory. Try amd64.

(In theory, there's PAE, but the developers appear to find it more
trouble than it's worth.) 

> real mem  = 3634733056 (3466MB)    
> avail mem = 3552747520 (3388MB)    
>[snip]
> spdmem0 at iic0 addr 0x50: 8GB DDR3 SDRAM PC3-12800  
> 

Good luck,

        --zeurkous.

-- 
Friggin' Machines!
  


Re: VMM Debian guest serial setup help needed

2020-06-10 Thread Benjamin Baier
On Wed, 10 Jun 2020 14:36:46 -0400
George  wrote:

> Hi guys,
> 
> I apologize if this maybe out of topic even though it is truly related 
> to VMM than Debian.
> 
> I am trying to setup a VMM Debian based guest but I'm not able to get it 
> to work. I found some description on the web about which settings to 
> edit in grub.cfg to enable the serial console and created a VM with 10.3 
> in qcow2 disk format in KVM. Now I am trying to start the same on 
> OpenBSD 6.7 but keep getting the connected message and then just 
> "Rebooting " after I hit some keyboard keys seems like baud rate issue 
> but not sure.
Don't need the KVM/qemu step.

> After messing with it for a while now I am getting a new error:
> 
> vmctl: could not open disk image(s)
Better start over.

> even thought the disk is there and readable to the user I have setup in 
> vm.conf in fact I have another VM with the same configuration and disk 
> with the same permissions and in the same location that works (it is 
> OpenBSD based).
> 
> I would greatly appreciate it if someone has gone this path and can 
> share some config info with me.

Here is how I got debian 9 (stretch) installed.
http://www.netzbasis.de/openbsd/vmd-debian/index.html
I think the virtio-modules are now included in the debian 10 (buster)
installer, but not tested. 



VMM Debian guest serial setup help needed

2020-06-10 Thread George

Hi guys,

I apologize if this maybe out of topic even though it is truly related 
to VMM than Debian.


I am trying to setup a VMM Debian based guest but I'm not able to get it 
to work. I found some description on the web about which settings to 
edit in grub.cfg to enable the serial console and created a VM with 10.3 
in qcow2 disk format in KVM. Now I am trying to start the same on 
OpenBSD 6.7 but keep getting the connected message and then just 
"Rebooting " after I hit some keyboard keys seems like baud rate issue 
but not sure.


After messing with it for a while now I am getting a new error:

vmctl: could not open disk image(s)

even thought the disk is there and readable to the user I have setup in 
vm.conf in fact I have another VM with the same configuration and disk 
with the same permissions and in the same location that works (it is 
OpenBSD based).


I would greatly appreciate it if someone has gone this path and can 
share some config info with me.


Cheers and thanks in advance,

George





FU: RE: dmesg memory not match spdmem and bios

2020-06-10 Thread zeurkous
[before someone starts shooting me...]

me wrote:
> i386 is limited to 4G of memory.

In reality, of course, it's 4G of address space... which is not
exclusively devoted to main memory. But, while that observation does
suggest a theoretical, partial work-around (reducing the amount of
address space taken up by other devices), it likely won't help OP much.

  --zeurkous.

-- 
Friggin' Machines!



RE: dmesg memory not match spdmem and bios

2020-06-10 Thread zeurkous
Haai,

"man Chan"  wrote:
> Hello,
> I just got a second Gaga-H97N-wifi motherbroad and installed openbsd6.6 
> Stable. The  dmesg shows real and avail memory does not  match with the 
> spdmem.  Anyone know how to solve this problem ?  Please help.
> Thanks
> Clarence
> OpenBSD 6.6-stable (GENERIC.MP) #1: Sun Jun  7 14:00:04 HKT 2020
> r...@dell.my.domain:/usr/src/sys/arch/i386/compile/GENERIC.MP

i386 is limited to 4G of memory. Try amd64.

(In theory, there's PAE, but the developers appear to find it more
trouble than it's worth.) 

> real mem  = 3634733056 (3466MB)
> avail mem = 3552747520 (3388MB)
>[snip]
> spdmem0 at iic0 addr 0x50: 8GB DDR3 SDRAM PC3-12800  
> 

Good luck,

--zeurkous.

-- 
Friggin' Machines!



Re: dmesg memory not match spdmem and bios

2020-06-10 Thread man Chan
 You mean the memory limitation of i386 is 4G.  Am I right ?
clarence


Zé Loff () 在 2020年6月10日星期三 下午10:08:24 [GMT+8] 寫道:  
 
 

Wrong architecture.  You should be running amd64, not i386

On Wed, Jun 10, 2020 at 02:02:32PM +, man Chan wrote:
> Hello,
> I just got a second Gaga-H97N-wifi motherbroad and installed
> openbsd6.6 Stable. The  dmesg shows real and avail memory does not 
> match with the spdmem.  Anyone know how to solve this problem ? 
> Please help.
> Thanks
> Clarence
> OpenBSD 6.6-stable (GENERIC.MP) #1: Sun Jun  7 14:00:04 HKT 2020
>     r...@dell.my.domain:/usr/src/sys/arch/i386/compile/GENERIC.MP
                                            

-- 
 
  


dmesg memory not match spdmem and bios

2020-06-10 Thread man Chan
Hello,
I just got a second Gaga-H97N-wifi motherbroad and installed openbsd6.6 Stable. 
The  dmesg shows real and avail memory does not  match with the spdmem.  Anyone 
know how to solve this problem ?  Please help.
Thanks
Clarence
OpenBSD 6.6-stable (GENERIC.MP) #1: Sun Jun  7 14:00:04 HKT 2020
    r...@dell.my.domain:/usr/src/sys/arch/i386/compile/GENERIC.MP
real mem  = 3634733056 (3466MB)    
avail mem = 3552747520 (3388MB)    
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: date 04/13/12, SMBIOS rev. 2.7 @ 0xecf50 (76 entries)
bios0: vendor American Megatrends Inc. version "F6" date 02/02/2015
bios0: Gigabyte Technology Co., Ltd. H97N-WIFI
acpi0 at bios0: ACPI 5.0
acpi0: sleep states S0 S3 S4 S5
acpi0: tables DSDT FACP APIC FPDT SSDT SSDT SSDT MCFG HPET SSDT SSDT DMAR
acpi0: wakeup devices PEG0(S4) PEGP(S4) PEG1(S4) PEGP(S4) PEG2(S4) PEGP(S4) 
RP01(S4) PXSX(S4) PXSX(S4) PXSX(S4) RP04(S4) PXSX(S4) RP05(S4) PXSX(S4) 
PXSX(S4) PXSX(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) i5-4590 CPU @ 3.30GHz ("GenuineIntel" 686-class) 3.71 
GHz, 06-3c-03
cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,SDBG,FMA3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,MOVBE,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,PAGE1GB,RDTSCP,LONG,LAHF,ABM,PERF,ITSC,FSGSBASE,TSC_ADJUST,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID,IBRS,IBPB,STIBP,L1DF,SSBD,SENSOR,ARAT,XSAVEOPT,MELTDOWN
mtrr: Pentium Pro MTRR support, 10 var ranges, 88 fixed ranges
cpu0: apic clock running at 100MHz
cpu0: mwait min=64, max=64, C-substates=0.2.1.2.4, IBE
cpu1 at mainbus0: apid 2 (application processor)
cpu1: Intel(R) Core(TM) i5-4590 CPU @ 3.30GHz ("GenuineIntel" 686-class) 3.31 
GHz, 06-3c-03
cpu1: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,SDBG,FMA3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,MOVBE,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,PAGE1GB,RDTSCP,LONG,LAHF,ABM,PERF,ITSC,FSGSBASE,TSC_ADJUST,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID,IBRS,IBPB,STIBP,L1DF,SSBD,SENSOR,ARAT,XSAVEOPT,MELTDOWN
cpu2 at mainbus0: apid 4 (application processor)
cpu2: Intel(R) Core(TM) i5-4590 CPU @ 3.30GHz ("GenuineIntel" 686-class) 3.31 
GHz, 06-3c-03
cpu2: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,SDBG,FMA3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,MOVBE,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,PAGE1GB,RDTSCP,LONG,LAHF,ABM,PERF,ITSC,FSGSBASE,TSC_ADJUST,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID,IBRS,IBPB,STIBP,L1DF,SSBD,SENSOR,ARAT,XSAVEOPT,MELTDOWN
cpu3 at mainbus0: apid 6 (application processor)
cpu3: Intel(R) Core(TM) i5-4590 CPU @ 3.30GHz ("GenuineIntel" 686-class) 3.31 
GHz, 06-3c-03
cpu3: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,SDBG,FMA3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,MOVBE,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,PAGE1GB,RDTSCP,LONG,LAHF,ABM,PERF,ITSC,FSGSBASE,TSC_ADJUST,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID,IBRS,IBPB,STIBP,L1DF,SSBD,SENSOR,ARAT,XSAVEOPT,MELTDOWN
ioapic0 at mainbus0: apid 8 pa 0xfec0, version 20, 24 pins
acpimcfg0 at acpi0
acpimcfg0: addr 0xf800, bus 0-63
acpihpet0 at acpi0: 14318179 Hz
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus -1 (PEG0)
acpiprt2 at acpi0: bus -1 (PEG1)
acpiprt3 at acpi0: bus -1 (PEG2)
acpiprt4 at acpi0: bus 1 (RP01)
acpiprt5 at acpi0: bus 2 (RP04)
acpiprt6 at acpi0: bus 3 (RP05)
acpiec0 at acpi0: not present
acpicpu0 at acpi0: C2(200@117 mwait.1@0x30), C1(1000@1 mwait.1), PSS
acpicpu1 at acpi0: C2(200@117 mwait.1@0x30), C1(1000@1 mwait.1), PSS
acpicpu2 at acpi0: C2(200@117 mwait.1@0x30), C1(1000@1 mwait.1), PSS
acpicpu3 at acpi0: C2(200@117 mwait.1@0x30), C1(1000@1 mwait.1), PSS
acpipwrres0 at acpi0: PG00, resource for PEG0
acpipwrres1 at acpi0: PG01, resource for PEG1
acpipwrres2 at acpi0: PG02, resource for PEG2
acpipwrres3 at acpi0: FN00, resource for FAN0
acpipwrres4 at acpi0: FN01, resource for FAN1
acpipwrres5 at acpi0: FN02, resource for FAN2
acpipwrres6 at acpi0: FN03, resource for FAN3
acpipwrres7 at acpi0: FN04, resource for FAN4
acpitz0 at acpi0: critical temperature is 105 degC
acpitz1 at acpi0: critical temperature is 105 degC
"PNP0A08" at acpi0 not configured
acpicmos0 at acpi0
"INT33CA" at acpi0 not configured
acpibtn0 at acpi0: PWRB
acpibtn1 at acpi0: SLPB
"PNP0C0B" at acpi0 not configured
"PNP0C0B" at acpi0 not configured
"PNP0C0B" at acpi0 not configured
"PNP0C0B" at acpi0 not configured

Re: Disabling OpenBSD Login Prompt

2020-06-10 Thread Steve Williams

On 10/06/2020 10:31 a.m., Aisha Tammy wrote:

On 6/10/20 10:46 AM, Steve Williams wrote:

Hi,

Do you have the proper ioctls to set baud rate, parity, start bits, stop bits 
so that the serial port is configured correctly?

What about flow control?  rts/cts, xon/xoff.

Dealing with a serial port is it's own art.


Wow, this is really interesting.
I'm curious, do the display managers like gdm/xdm, etc also have
to handle this?
I'm asking cuz I'm porting a display manager for linux (nothing to
do with openbsd,  but this discussion was very related).
I'm in a very similar position where the simplest answer would be
to disable a getty at one of the tty's and start the login prompt
there (its a visual prompt).

link to display manager, if my writing wasn't clear
https://git.sr.ht/~kennylevinsen/greetd

Aisha
The baud rate, etc is only applicable to things running over serial 
RS-232 (and 422) ports.  The original poster specified it is running on 
"com0".


A display manager would not (typically) be talking over a serial port 
natively.  In the old days, X might be talking over a serial port using 
SLIP or some such technology, but that has all gone the way of the dodo 
bird.


Cheers,
Steve W.






Cheers,
Steve W.

On 10/06/2020 3:03 a.m., Valdrin MUJA wrote:

Hi Misc,

I want to disable OpenBSD Login prompt at startup -and also after logging out-. 
Because I want to run my external program instead of ksh. There is an login 
prompt also in my program and I want to use it.

I updated the /etc/ttys ;

valdrin# cat /etc/ttys
#
#   $OpenBSD: ttys,v 1.2 2008/01/09 17:39:42 miod Exp $
#
# name  getty   type    status  comments
#
console "/usr/libexec/getty std.9600"   vt220   off secure
ttyC0   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC1   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC2   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC3   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC4   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC5   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC6   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC7   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC8   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC9   "/usr/libexec/getty std.9600"   vt220   off secure
ttyCa   "/usr/libexec/getty std.9600"   vt220   off secure
ttyCb   "/usr/libexec/getty std.9600"   vt220   off secure
tty00   "/root/myprogram"   vt220    on secure
tty01   "/usr/libexec/getty std.9600"   unknown off
tty02   "/usr/libexec/getty std.9600"   unknown off
tty03   "/usr/libexec/getty std.9600"   unknown off
tty04   "/usr/libexec/getty std.9600"   unknown off
tty05   "/usr/libexec/getty std.9600"   unknown off
tty06   "/usr/libexec/getty std.9600"   unknown off
tty07   "/usr/libexec/getty std.9600"   unknown off

I'm connected the device with com0 port so I updated the tty00 to run my 
external program. However; system is stucking after date appears on startup.


starting network
reordering libraries: done.
starting early daemons: syslogd ntpd.
starting RPC daemons:.
savecore: no core dump
checking quotas: done.
clearing /tmp
kern.securelevel: 0 -> 1
creating runtime link editor directory cache.
preserving editor files.
starting network daemons: sshd.
starting local daemons: cron.
Wed Jun 10 10:27:04 +03 2020


Also, I tried "chsh" and "chpass" , but still OpenBSD login prompt appears.. 
How can I overcome this issue?

Thanks..





Re: Filling a 4TB Disk with Random Data

2020-06-10 Thread STeve Andre'
Even easier,  have stty status set to ^T, and run dd .

When you want to know where you are in the process hit ^T.  Lots (most?)
of programs will respond to a SIGINFO request.

--STeve Andre' ​

On Jun 10, 2020, 12:48, at 12:48, Luke Small  wrote:
>if you have access to packages, you could "pkg_add pv"
>
>and:
>
>"dd if=/dev/random | pv | dd of=/dev/rsdXc bs=1m"
>
>It will show you in real time how much random
>
>data has been written to disk.
>
>-Luke
>
>
>On Wed, Jun 10, 2020 at 11:43 AM Luke Small 
>wrote:
>
>> I mean: "dd if=/dev/random | pv | dd of=/dev/rsdXc bs=1m"
>>
>> -Luke
>>
>>
>> On Wed, Jun 10, 2020 at 11:41 AM Luke Small 
>wrote:
>>
>>> if you have access to packages, you could "pkg_add pv"
>>>
>>> and:
>>>
>>> "dd if=/dev/random | pv | of=/dev/rsdXc bs=1m"
>>>
>>> It will show you in real time how much random
>>>
>>> data has been written to disk.
>>>
>>> -Luke
>>>
>>


Re: unexpected behavior

2020-06-10 Thread Stuart Henderson
On 2020-06-09, Sonic  wrote:
> Was wondering if I wanted such an interface for management purposes,
> that is - unconnected during normal installed operation but accepting
> dhcp assignment when connected - could it be placed in a different
> domain (not r0)? This way it should be available when needed but yet
> not interfere with the r0 routing table, that is /etc/mygate would be
> valid and used for the interfaces in r0. Can a new routing domain work
> via dhcp or must its network be defined when it is created?
>
>

Yes.




Re: Filling a 4TB Disk with Random Data

2020-06-10 Thread Luke Small
if you have access to packages, you could "pkg_add pv"

and:

"dd if=/dev/random | pv | dd of=/dev/rsdXc bs=1m"

It will show you in real time how much random

data has been written to disk.

-Luke


On Wed, Jun 10, 2020 at 11:43 AM Luke Small  wrote:

> I mean: "dd if=/dev/random | pv | dd of=/dev/rsdXc bs=1m"
>
> -Luke
>
>
> On Wed, Jun 10, 2020 at 11:41 AM Luke Small  wrote:
>
>> if you have access to packages, you could "pkg_add pv"
>>
>> and:
>>
>> "dd if=/dev/random | pv | of=/dev/rsdXc bs=1m"
>>
>> It will show you in real time how much random
>>
>> data has been written to disk.
>>
>> -Luke
>>
>


Re: dmesg memory not match spdmem and bios

2020-06-10 Thread Stuart Henderson
On 2020-06-10, man Chan  wrote:
>  You mean the memory limitation of i386 is 4G.  Am I right ?

A 32-bit kernel can only access memory mapped to addresses below 4GB.

The actual amount of memory that you can use depends on where the
BIOS/UEFI maps the memory (it reserves some addresses for device i/o
etc).

That's why you see a lower "available memory" amount than 4GB.



kernel: protection fault trap

2020-06-10 Thread deserter666
I've witnessed the same bug twice now, couldn't find
kernel err msg last time in the logs. I took a note
this time.

kernel: protection fault trap, code=0
Stopped at  drm_mode_rmfb_work_fn+0x37: movq%rdx,0x8(%rcx)
ddb{1}>

On both instances, the error was triggered when I logout
from xenodm. (CMS-q). Also this occured after a sysupgrade
in both cases.

On a separate case, I'm coming a across a new behaviour
during startup.

drm : drm_WARN_ON(!IS_PLATFORM(dev_priv, INTEL_SKYLAKE) &&
!IS_PLATFORM(dev_priv,
INTEL_KABYLAKE))drm_connector_attach_content_protection_property: stub
drm_connector_attach_content_protection_property: stub
drm_connector_attach_content_protection_property: stub
i915_perf_register: stub
debugfs_gt_register: stub

After the first "drm :" I get a connection lost signal on
my monitor. Then display comes through after a few seconds
while turning up startup scripts.

There used to be short time during shift to inteldrm and
no connection was lost either. I'm just putting this across
since both cases are related to drm.




Re: Disabling OpenBSD Login Prompt

2020-06-10 Thread Steve Williams

Hi,

Do you have the proper ioctls to set baud rate, parity, start bits, stop 
bits so that the serial port is configured correctly?


What about flow control?  rts/cts, xon/xoff.

Dealing with a serial port is it's own art.

Cheers,
Steve W.

On 10/06/2020 3:03 a.m., Valdrin MUJA wrote:

Hi Misc,

I want to disable OpenBSD Login prompt at startup -and also after logging out-. 
Because I want to run my external program instead of ksh. There is an login 
prompt also in my program and I want to use it.

I updated the /etc/ttys ;

valdrin# cat /etc/ttys
#
#   $OpenBSD: ttys,v 1.2 2008/01/09 17:39:42 miod Exp $
#
# name  getty   typestatus  comments
#
console "/usr/libexec/getty std.9600"   vt220   off secure
ttyC0   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC1   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC2   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC3   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC4   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC5   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC6   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC7   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC8   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC9   "/usr/libexec/getty std.9600"   vt220   off secure
ttyCa   "/usr/libexec/getty std.9600"   vt220   off secure
ttyCb   "/usr/libexec/getty std.9600"   vt220   off secure
tty00   "/root/myprogram"   vt220on secure
tty01   "/usr/libexec/getty std.9600"   unknown off
tty02   "/usr/libexec/getty std.9600"   unknown off
tty03   "/usr/libexec/getty std.9600"   unknown off
tty04   "/usr/libexec/getty std.9600"   unknown off
tty05   "/usr/libexec/getty std.9600"   unknown off
tty06   "/usr/libexec/getty std.9600"   unknown off
tty07   "/usr/libexec/getty std.9600"   unknown off

I'm connected the device with com0 port so I updated the tty00 to run my 
external program. However; system is stucking after date appears on startup.


starting network
reordering libraries: done.
starting early daemons: syslogd ntpd.
starting RPC daemons:.
savecore: no core dump
checking quotas: done.
clearing /tmp
kern.securelevel: 0 -> 1
creating runtime link editor directory cache.
preserving editor files.
starting network daemons: sshd.
starting local daemons: cron.
Wed Jun 10 10:27:04 +03 2020


Also, I tried "chsh" and "chpass" , but still OpenBSD login prompt appears.. 
How can I overcome this issue?

Thanks..





Re: dmesg memory not match spdmem and bios

2020-06-10 Thread Zé Loff



Wrong architecture.  You should be running amd64, not i386

On Wed, Jun 10, 2020 at 02:02:32PM +, man Chan wrote:
> Hello,
> I just got a second Gaga-H97N-wifi motherbroad and installed
> openbsd6.6 Stable. The  dmesg shows real and avail memory does not 
> match with the spdmem.  Anyone know how to solve this problem ? 
> Please help.
> Thanks
> Clarence
> OpenBSD 6.6-stable (GENERIC.MP) #1: Sun Jun  7 14:00:04 HKT 2020
>     r...@dell.my.domain:/usr/src/sys/arch/i386/compile/GENERIC.MP


-- 
 



Re: Disabling OpenBSD Login Prompt

2020-06-10 Thread Ottavio Caruso
On Wed, 10 Jun 2020 at 10:03, Valdrin MUJA  wrote:
>
> Hi Misc,
>
> I want to disable OpenBSD Login prompt at startup -and also after logging 
> out-. Because I want to run my external program instead of ksh. There is an 
> login prompt also in my program and I want to use it.
>

What do you mean by "login prompt"? Maybe the MOTD?

You need to login in your system, right? Unless your program is a
shell (and registered in /etc/shells), you won't be able to log in.

https://man.openbsd.org/shells.5
https://man.openbsd.org/login.1

-- 
Ottavio Caruso



Disabling OpenBSD Login Prompt

2020-06-10 Thread Valdrin MUJA
Hi Misc,



I want to disable OpenBSD Login prompt at startup -and also after logging out-. 
Because I want to run my external program instead of ksh. There is an login 
prompt also in my program and I want to use it. 



I updated the /etc/ttys ; 

valdrin# cat /etc/ttys
#
#   $OpenBSD: ttys,v 1.2 2008/01/09 17:39:42 miod Exp $
#
# name  getty   typestatus  comments
#
console "/usr/libexec/getty std.9600"   vt220   off secure
ttyC0   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC1   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC2   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC3   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC4   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC5   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC6   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC7   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC8   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC9   "/usr/libexec/getty std.9600"   vt220   off secure
ttyCa   "/usr/libexec/getty std.9600"   vt220   off secure
ttyCb   "/usr/libexec/getty std.9600"   vt220   off secure
tty00   "/root/myprogram"   vt220on secure
tty01   "/usr/libexec/getty std.9600"   unknown off
tty02   "/usr/libexec/getty std.9600"   unknown off
tty03   "/usr/libexec/getty std.9600"   unknown off
tty04   "/usr/libexec/getty std.9600"   unknown off
tty05   "/usr/libexec/getty std.9600"   unknown off
tty06   "/usr/libexec/getty std.9600"   unknown off
tty07   "/usr/libexec/getty std.9600"   unknown off



I'm connected the device with com0 port so I updated the tty00 to run my 
external program. However; system is stucking after date appears on startup. 



starting network 
reordering libraries: done.
starting early daemons: syslogd ntpd.
starting RPC daemons:.
savecore: no core dump
checking quotas: done.
clearing /tmp
kern.securelevel: 0 -> 1
creating runtime link editor directory cache.
preserving editor files.
starting network daemons: sshd.
starting local daemons: cron.
Wed Jun 10 10:27:04 +03 2020





Also, I tried "chsh" and "chpass" , but still OpenBSD login prompt appears.. 
How can I overcome this issue?



Thanks..


Re: Ynt: Disabling OpenBSD Login Prompt

2020-06-10 Thread Kapetanakis Giannis
On 10/06/2020 12:52, Valdrin MUJA wrote:
> Sorry for lack of information,
>
> Firstly, my program is a kind of interactive shell which has own login 
> prompt. What I want to do is run my program on startup and do not use OpenBSD 
> login prompt. 
>
> When I use "chsh", firstly OpenBSD Login Prompt appearing, after that my 
> program is running and my program's login prompt appearing. 
>
> Lastly, I tried to update /etc/ttys and replace getty with my program to 
> disable OpenBSD login prompt and run my program. However, obviously this 
> didn't work.
>
> In short, I want to disable OpenBSD Login prompt and run my program.


So login shell (chsh) has nothing to do with this. Shell is  executed after 
login which is executed after getty.


/etc/ttys needs to be changed. reboot after that.


But why do you want to change the default getty login? If you just want to 
change what is displayed you can probably create a custom entry in 
/etc/gettytab. Also there is /etc/motd for custom messages after login, as 
another user said.


Does your program handling terminal correctly?
Does it handle login in a secure way?

R u sure?


G





Re: iked keeps reconnecting every 8 minutes

2020-06-10 Thread Tobias Heider
On Tue, Jun 09, 2020 at 08:13:53PM +, Leclerc, Sebastien wrote:
> > > > Before 6.7 iked didn't start DPD in this particular case.
> > > > It kicks in if the tunnel is up and there haven't been any incoming ESP 
> > > > packets
> > > > in the last 5 minutes.
> > > > A possible workaround would be to ping through the tunnel to have at 
> > > > least one
> > > > incoming packet every 5 minutes.
> > >
> > > There is definitely ESP packets continuously, as there are 3-8 RDP 
> > > sessions
> > > in this tunnel during workhours. That's why it's a problem, people get 
> > > their
> > > RDP session disconnected every 8 minutes.
> > >
> > 
> > If true that would certainly be a bug.
> > Could you try running iked with -dvv and look for ikev2_ike_sa_alive 
> > messages?
> > It should look like this:
> > 
> > ikev2_ike_sa_alive: incoming CHILD SA spi 0x last used 0 second(s) 
> > ago
> 
> spi=0x09ce404cdca4ee1d: ikev2_childsa_enable: loaded SPIs: 0x4cd06b6d, 
> 0x0e7dbe7d
> spi=0x09ce404cdca4ee1d: ikev2_childsa_enable: loaded flows: 
> ESP-192.168.1.0/24=192.168.100.0/24(0), 
> ESP-192.168.1.0/24=192.168.150.0/24(0), ESP-192.0.2.2/32=192.0.2.199/32(0)
> spi=0x09ce404cdca4ee1d: sa_state: VALID -> ESTABLISHED from 192.0.2.199:500 
> to 192.0.2.2:500 policy 'POLICYNAME'
> spi=0x09ce404cdca4ee1d: established peer 192.0.2.199:500[IPV4/192.0.2.199] 
> local 192.0.2.2:500[IPV4/192.0.2.2] policy 'POLICYNAME' as initiator
> ...
> ikev2_ike_sa_alive: incoming CHILD SA spi 0x0e7dbe7d last used 1 second(s) ago
> 
> I don't see the ikev2_ike_sa_alive message for the other SPI (0x4cd06b6d), is 
> it normal?

This is normal.

> And then it doesn't reply back :
> 
> ikev2_ike_sa_alive: IKE SA 0xed2d646c000 ispi 0x09ce404cdca4ee1d rspi 
> 0x714a5bb2f7ccc4d4 last received 300 second(s) ago
> ikev2_ike_sa_alive: sending alive check
> ikev2_msg_encrypt: decrypted length 4
> ikev2_msg_encrypt: padded length 16
> ikev2_msg_encrypt: length 5, padding 11, output length 44
> ikev2_next_payload: length 48 nextpayload NONE
> ikev2_msg_integr: message length 76
> ikev2_msg_integr: integrity checksum length 12
> ikev2_pld_parse: header ispi 0x09ce404cdca4ee1d rspi 0x714a5bb2f7ccc4d4 
> nextpayload SK version 0x20 exchange INFORMATIONAL flags 0x08 msgid 2 length 
> 76 response 0
> ikev2_pld_payloads: payload SK nextpayload NONE critical 0x00 length 48
> ikev2_msg_decrypt: IV length 16
> ikev2_msg_decrypt: encrypted payload length 16
> ikev2_msg_decrypt: integrity checksum length 12
> ikev2_msg_decrypt: integrity check succeeded
> ikev2_msg_decrypt: decrypted payload length 16/16 padding 11
> spi=0x09ce404cdca4ee1d: send INFORMATIONAL req 2 peer 192.0.2.199:500 local 
> 192.0.2.2:500, 76 bytes
> ...
> spi=0x09ce404cdca4ee1d: retransmit 1 INFORMATIONAL req 2 peer 192.0.2.199:500 
> local 192.0.2.2:500
> ...
> spi=0x09ce404cdca4ee1d: retransmit 2 INFORMATIONAL req 2 peer 192.0.2.199:500 
> local 192.0.2.2:500
> spi=0x09ce404cdca4ee1d: retransmit 3 INFORMATIONAL req 2 peer 192.0.2.199:500 
> local 192.0.2.2:500
> spi=0x09ce404cdca4ee1d: retransmit 4 INFORMATIONAL req 2 peer 192.0.2.199:500 
> local 192.0.2.2:500
> ...
> ikev2_ike_sa_alive: IKE SA 0xed2d646c000 ispi 0x09ce404cdca4ee1d rspi 
> 0x714a5bb2f7ccc4d4 last received 360 second(s) ago
> ...
> spi=0x09ce404cdca4ee1d: retransmit 5 INFORMATIONAL req 2 peer 192.0.2.199:500 
> local 192.0.2.2:500
> ...
> ikev2_ike_sa_alive: IKE SA 0xed2d646c000 ispi 0x09ce404cdca4ee1d rspi 
> 0x714a5bb2f7ccc4d4 last received 420 second(s) ago
> ...
> ikev2_msg_retransmit_timeout: retransmit limit reached for req 2
> spi=0x09ce404cdca4ee1d: sa_free: retransmit limit reached
> config_free_proposals: free 0xed2a4156f80
> config_free_proposals: free 0xed2a4156180
> config_free_childsas: free 0xed2c6179700
> config_free_childsas: free 0xed275c07400
> config_free_childsas: free 0xed33fcbba00
> config_free_childsas: free 0xed2c6177200
> sa_free_flows: free 0xed247848800
> sa_free_flows: free 0xed2b3308800
> sa_free_flows: free 0xed2e78cfc00
> sa_free_flows: free 0xed247849800
> sa_free_flows: free 0xed2e78cf000
> sa_free_flows: free 0xed247848c00
> 
> 
> > "ipsecctl -sa -v" shows you SA packet counters, if you find one that has
> > 0 input packets that's probably the cause.
> 
> All SAs have packet counters > 0, see those for this tunnel :
> 
> esp tunnel from 192.0.2.2 to 192.0.2.199 spi 0x4cd06b6a auth hmac-sha1 enc aes
> sa: spi 0x4cd06b6a auth hmac-sha1 enc aes
> state mature replay 64 flags 0x4
> lifetime_cur: alloc 0 bytes 501965 add 1591730080 first 1591730081
> lifetime_hard: alloc 0 bytes 536870912 add 10800 first 0
> lifetime_soft: alloc 0 bytes 497679335 add 10011 first 0
> address_src: 192.0.2.2
> address_dst: 192.0.2.199
> identity_src: type prefix id 0: IPV4/192.0.2.2
> identity_dst: type prefix id 0: IPV4/192.0.2.199
> lifetime_lastuse: alloc 0 bytes 0 add 0 first 1591730260
> counter:
>   

Ynt: Disabling OpenBSD Login Prompt

2020-06-10 Thread Valdrin MUJA
Sorry for lack of information,

Firstly, my program is a kind of interactive shell which has own login prompt. 
What I want to do is run my program on startup and do not use OpenBSD login 
prompt.

When I use "chsh", firstly OpenBSD Login Prompt appearing, after that my 
program is running and my program's login prompt appearing.

Lastly, I tried to update /etc/ttys and replace getty with my program to 
disable OpenBSD login prompt and run my program. However, obviously this didn't 
work.

In short, I want to disable OpenBSD Login prompt and run my program.

Gönderen: Kapetanakis Giannis  adına 
owner-m...@openbsd.org 
Gönderildi: 10 Haziran 2020 Çarşamba 12:21
Kime: misc@openbsd.org 
Konu: Re: Disabling OpenBSD Login Prompt

On 10/06/2020 12:03, Valdrin MUJA wrote:
> Hi Misc,
>
> I want to disable OpenBSD Login prompt at startup -and also after logging 
> out-. Because I want to run my external program instead of ksh. There is an 
> login prompt also in my program and I want to use it.
>
> I updated the /etc/ttys ;
>
> valdrin# cat /etc/ttys
> #
> #   $OpenBSD: ttys,v 1.2 2008/01/09 17:39:42 miod Exp $
> #
> # name  getty   typestatus  comments
> #
> console "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC0   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC1   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC2   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC3   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC4   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC5   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC6   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC7   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC8   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC9   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyCa   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyCb   "/usr/libexec/getty std.9600"   vt220   off secure
> tty00   "/root/myprogram"   vt220on secure
> tty01   "/usr/libexec/getty std.9600"   unknown off
> tty02   "/usr/libexec/getty std.9600"   unknown off
> tty03   "/usr/libexec/getty std.9600"   unknown off
> tty04   "/usr/libexec/getty std.9600"   unknown off
> tty05   "/usr/libexec/getty std.9600"   unknown off
> tty06   "/usr/libexec/getty std.9600"   unknown off
> tty07   "/usr/libexec/getty std.9600"   unknown off
>
> I'm connected the device with com0 port so I updated the tty00 to run my 
> external program. However; system is stucking after date appears on startup.
>
>
> starting network
> reordering libraries: done.
> starting early daemons: syslogd ntpd.
> starting RPC daemons:.
> savecore: no core dump
> checking quotas: done.
> clearing /tmp
> kern.securelevel: 0 -> 1
> creating runtime link editor directory cache.
> preserving editor files.
> starting network daemons: sshd.
> starting local daemons: cron.
> Wed Jun 10 10:27:04 +03 2020
>
>
> Also, I tried "chsh" and "chpass" , but still OpenBSD login prompt appears.. 
> How can I overcome this issue?
>
> Thanks..


Since you're mixing login prompt (getty) with login shell (ksh) and since you 
don't provide info about "yourprogram" I believe that maybe you you've mixing 
things up?

If you want to change a user's login shell, chsh(1) should be used.
This specifies what shell is run for that user after login is successful.

getty(8) is controlled by /etc/ttys - ttys(5) and has nothing to do with user 
login shell.

read the man pages.

G



Re: Disabling OpenBSD Login Prompt

2020-06-10 Thread Kapetanakis Giannis
On 10/06/2020 12:03, Valdrin MUJA wrote:
> Hi Misc,
>
> I want to disable OpenBSD Login prompt at startup -and also after logging 
> out-. Because I want to run my external program instead of ksh. There is an 
> login prompt also in my program and I want to use it.
>
> I updated the /etc/ttys ;
>
> valdrin# cat /etc/ttys
> #
> #   $OpenBSD: ttys,v 1.2 2008/01/09 17:39:42 miod Exp $
> #
> # name  getty   typestatus  comments
> #
> console "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC0   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC1   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC2   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC3   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC4   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC5   "/usr/libexec/getty std.9600"   vt220   on  secure
> ttyC6   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC7   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC8   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyC9   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyCa   "/usr/libexec/getty std.9600"   vt220   off secure
> ttyCb   "/usr/libexec/getty std.9600"   vt220   off secure
> tty00   "/root/myprogram"   vt220on secure
> tty01   "/usr/libexec/getty std.9600"   unknown off
> tty02   "/usr/libexec/getty std.9600"   unknown off
> tty03   "/usr/libexec/getty std.9600"   unknown off
> tty04   "/usr/libexec/getty std.9600"   unknown off
> tty05   "/usr/libexec/getty std.9600"   unknown off
> tty06   "/usr/libexec/getty std.9600"   unknown off
> tty07   "/usr/libexec/getty std.9600"   unknown off
>
> I'm connected the device with com0 port so I updated the tty00 to run my 
> external program. However; system is stucking after date appears on startup.
>
>
> starting network
> reordering libraries: done.
> starting early daemons: syslogd ntpd.
> starting RPC daemons:.
> savecore: no core dump
> checking quotas: done.
> clearing /tmp
> kern.securelevel: 0 -> 1
> creating runtime link editor directory cache.
> preserving editor files.
> starting network daemons: sshd.
> starting local daemons: cron.
> Wed Jun 10 10:27:04 +03 2020
>
>
> Also, I tried "chsh" and "chpass" , but still OpenBSD login prompt appears.. 
> How can I overcome this issue?
>
> Thanks..


Since you're mixing login prompt (getty) with login shell (ksh) and since you 
don't provide info about "yourprogram" I believe that maybe you you've mixing 
things up?

If you want to change a user's login shell, chsh(1) should be used.
This specifies what shell is run for that user after login is successful.

getty(8) is controlled by /etc/ttys - ttys(5) and has nothing to do with user 
login shell.

read the man pages.

G



Disabling OpenBSD Login Prompt

2020-06-10 Thread Valdrin MUJA
Hi Misc,

I want to disable OpenBSD Login prompt at startup -and also after logging out-. 
Because I want to run my external program instead of ksh. There is an login 
prompt also in my program and I want to use it.

I updated the /etc/ttys ;

valdrin# cat /etc/ttys
#
#   $OpenBSD: ttys,v 1.2 2008/01/09 17:39:42 miod Exp $
#
# name  getty   typestatus  comments
#
console "/usr/libexec/getty std.9600"   vt220   off secure
ttyC0   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC1   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC2   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC3   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC4   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC5   "/usr/libexec/getty std.9600"   vt220   on  secure
ttyC6   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC7   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC8   "/usr/libexec/getty std.9600"   vt220   off secure
ttyC9   "/usr/libexec/getty std.9600"   vt220   off secure
ttyCa   "/usr/libexec/getty std.9600"   vt220   off secure
ttyCb   "/usr/libexec/getty std.9600"   vt220   off secure
tty00   "/root/myprogram"   vt220on secure
tty01   "/usr/libexec/getty std.9600"   unknown off
tty02   "/usr/libexec/getty std.9600"   unknown off
tty03   "/usr/libexec/getty std.9600"   unknown off
tty04   "/usr/libexec/getty std.9600"   unknown off
tty05   "/usr/libexec/getty std.9600"   unknown off
tty06   "/usr/libexec/getty std.9600"   unknown off
tty07   "/usr/libexec/getty std.9600"   unknown off

I'm connected the device with com0 port so I updated the tty00 to run my 
external program. However; system is stucking after date appears on startup.


starting network
reordering libraries: done.
starting early daemons: syslogd ntpd.
starting RPC daemons:.
savecore: no core dump
checking quotas: done.
clearing /tmp
kern.securelevel: 0 -> 1
creating runtime link editor directory cache.
preserving editor files.
starting network daemons: sshd.
starting local daemons: cron.
Wed Jun 10 10:27:04 +03 2020


Also, I tried "chsh" and "chpass" , but still OpenBSD login prompt appears.. 
How can I overcome this issue?

Thanks..