Re: smtpd doesn't start

2017-05-31 Thread Choose a display name
>Did you ever post smtpd.conf? This issue seems odd.

I did, but for some reason my messages are damaged
on the marc. Here it is on the nabble, the third message.
http://openbsd-archive.7691.n7.nabble.com/smtpd-doesn-t-start-td319036.html

Re: smtpd doesn't start

2017-05-29 Thread Choose a display name
>Try defining your hostname in /etc/hosts
>If you have a static address, define it with that address. If it's a dynamic 
>>address, define it as 127.0.1.1

Thank you, it worked, but I also had to add "lookup file bind" to the 
resolv.conf.

Re: smtpd doesn't start

2017-05-29 Thread Choose a display name
Turns out, you were right, Ted. It is a DNS failure.
Here is the relevant part of ktrace of the smtpd:

# kdump | tail -40
31531 smtpd RET clock_gettime 0
31531 smtpd CALL poll(0x7f7d75d0,1,2)
31531 smtpd STRU struct pollfd { fd=3, events=0x1, revents=0<> }
31531 smtpd RET poll 0
31531 smtpd CALL recvfrom(3,0x1dc776e6f000,0x1000,0,0,0)
31531 smtpd RET recvfrom -1 errno 35 Resource temporarily unavailable
31531 smtpd CALL close(3)
31531 smtpd RET close 0
31531 smtpd CALL socket(AF_INET,0x5002,0
)
31531 smtpd RET socket 3
31531 smtpd CALL connect(3,0x1dc7d136ecb0,16)
31531 smtpd STRU struct sockaddr { AF_INET, 192.168.1.1:53 }
31531 smtpd RET connect 0
31531 smtpd CALL sendto(3,0x1dc781f2a200,0x18,0,0,0)
31531 smtpd GIO fd 3 wrote 24 bytes
"\r\M-T\^A\0\0\^A\0\0\0\0\0\0\^Fmypcname\0\0\^\\0\^A"
31531 smtpd RET sendto 24/0x18
31531 smtpd CALL clock_gettime(CLOCK_MONOTONIC,0x7f7d75c0)
31531 smtpd STRU struct timespec { 35917.002552533 }
31531 smtpd RET clock_gettime 0
31531 smtpd CALL poll(0x7f7d75d0,1,2)
31531 smtpd STRU struct pollfd { fd=3, events=0x1, revents=0<> }
31531 smtpd RET poll 0
31531 smtpd CALL recvfrom(3,0x1dc776e6f000,0x1000,0,0,0)
31531 smtpd RET recvfrom -1 errno 35 Resource temporarily unavailable
31531 smtpd CALL close(3)
31531 smtpd RET close 0
31531 smtpd CALL socket(AF_INET,0x5002,0
)
31531 smtpd RET socket 3
31531 smtpd CALL connect(3,0x1dc7d136ecb0,16)
31531 smtpd STRU struct sockaddr { AF_INET, 192.168.1.1:53 }
31531 smtpd RET connect 0
31531 smtpd CALL sendto(3,0x1dc781f2a200,0x18,0,0,0)
31531 smtpd GIO fd 3 wrote 24 bytes
"\r\M-T\^A\0\0\^A\0\0\0\0\0\0\^Fmypcname\0\0\^\\0\^A"
31531 smtpd RET sendto 24/0x18
31531 smtpd CALL clock_gettime(CLOCK_MONOTONIC,0x7f7d75c0)
31531 smtpd STRU struct timespec { 35937.012972572 }
31531 smtpd RET clock_gettime 0
31531 smtpd CALL poll(0x7f7d75d0,1,4)

And so on.
If I understand correct, the problem is that my DNS server on 192.168.1.1
can't lookup an IP address for "mypcname", which is not a registered
domain name, just cooked-up hostname of the machine running smtpd.
Honestly, I don't know how it could be fixed. Could anybody help me?

Re: smtpd doesn't start

2017-05-29 Thread Choose a display name
>this sounds a lot like a DNS failure.

DNS seems to work.

# cat /etc/resolv.conf

# Generated by athn0 dhclient
nameserver 192.168.1.1

# dig protonmail.com MX

; <<>> DiG 9.4.2-P2 <<>> protonmail.com MX
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 26238
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;protonmail.com. IN MX

;; ANSWER SECTION:
protonmail.com. 3600 IN MX 5 mail.protonmail.ch.
protonmail.com. 3600 IN MX 10 mail1.protonmail.ch.

;; Query time: 59 msec
;; SERVER: 192.168.1.1#53(192.168.1.1)
;; WHEN: Mon May 29 12:55:12 2017
;; MSG SIZE rcvd: 88

# dig @8.8.8.8 protonmail.com MX

; <<>> DiG 9.4.2-P2 <<>> @8.8.8.8 protonmail.com MX
; (1 server found)
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 48677
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;protonmail.com. IN MX

;; ANSWER SECTION:
protonmail.com. 1199 IN MX 5 mail.protonmail.ch.
protonmail.com. 1199 IN MX 10 mail1.protonmail.ch.

;; Query time: 107 msec
;; SERVER: 8.8.8.8#53(8.8.8.8)
;; WHEN: Mon May 29 12:55:52 2017
;; MSG SIZE rcvd: 88

>Hello,
>I had the same problem recently.
>Please check the rights on the file smtpd.conf and if necessary
>chmod 600 smtpd.conf

It doesn't help, smtpd hangs with 644, 600, 000 chmodded smtpd.conf
and without smtpd.conf at all.

Re: smtpd doesn't start

2017-05-26 Thread Choose a display name
>As always, you can post your smtpd.config, dmesg and any errors
>you're receiving. "it doesn't work" and "i have a problem" won't
>get you much help on this list.

I get no error, smtpd just hangs if network is up.
It looks like this:

# smtpctl show stats
smtpctl: smtpd doesn't seem to be running
# /usr/sbin/smtpd
(it hangs without any output)
^C
# /usr/sbin/smtpd -dv
(same thing)
^C
# /usr/sbin/smtpd -n
(hangs again)
^C
# ifconfig athn0 down
# /usr/sbin/smtpd -d
info: OpenSMTPD 6.0.0 starting
# smtpctl show stats
control.session=1
...
# cat /etc/mail/smtpd.conf
# $OpenBSD: smtpd.conf,v 1.9 2016/05/03 18:43:45 jung Exp $

# This is the smtpd server system-wide configuration file.
# See smtpd.conf(5) for more information.

table aliases file:/etc/mail/aliases

# To accept external mail, replace with: listen on all
#
listen on lo0

# Uncomment the following to accept external mail for domain "example.org"
#
# accept from any for domain "example.org" alias  deliver to mbox
accept for local alias  deliver to mbox
accept from local for any relay
# cat /etc/hostname.athn0
nwid nwid
wpakey wpakey
dhcp
# dmesg
OpenBSD 6.1 (GENERIC.MP) #6: Mon May 22 20:34:30 CEST 2017
rob...@syspatch-61-amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC
.MP
real mem = 8533958656 (8138MB)
avail mem = 8270639104 (7887MB)
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 2.7 @ 0x7daa0020 (8 entries)
bios0: vendor coreboot version "CBET4000 4.5" date 10/18/2016
bios0: LENOVO 745584G
acpi0 at bios0: rev 2
acpi0: sleep states S0 S3 S4 S5
acpi0: tables DSDT FACP SSDT MCFG TCPA APIC DMAR HPET
acpi0: wakeup devices HDEF(S4) USB1(S4) USB2(S4) USB3(S4) EHC1(S4) USB4(S4) USB5
(S4) USB6(S4) EHC2(S4) SLT1(S4) SLT2(S4) SLT3(S4) SLT6(S4) LANC(S3) LANR(S3) 
SLPB(S3) [...]
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpimcfg0 at acpi0 addr 0xf000, bus 0-63
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Intel(R) Core(TM)2 Duo CPU P8600 @ 2.40GHz, 1600.34 MHz
cpu0: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CF
LUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,XSAVE,NXE,LONG,LAHF,PERF,SENSOR
cpu0: 3MB 64b/line 8-way L2 cache
cpu0: smt 0, core 0, package 0
mtrr: Pentium Pro MTRR support, 8 var ranges, 88 fixed ranges
cpu0: apic clock running at 266MHz
cpu0: mwait min=64, max=64, C-substates=0.2.2.2.2.1.3, IBE
cpu1 at mainbus0: apid 1 (application processor)
cpu1: Intel(R) Core(TM)2 Duo CPU P8600 @ 2.40GHz, 1600.06 MHz
cpu1: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CF
LUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,XSAVE,NXE,LONG,LAHF,PERF,SENSOR
cpu1: 3MB 64b/line 8-way L2 cache
cpu1: smt 0, core 1, package 0
ioapic0 at mainbus0: apid 2 pa 0xfec0, version 20, 24 pins
acpihpet0 at acpi0: 14318179 Hz
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus -1 (PEGP)
acpiprt2 at acpi0: bus 1 (RP01)
acpiprt3 at acpi0: bus 2 (RP02)
acpiprt4 at acpi0: bus 3 (RP03)
acpiprt5 at acpi0: bus 4 (RP04)
acpiprt6 at acpi0: bus -1 (RP05)
acpiprt7 at acpi0: bus -1 (RP06)
acpiprt8 at acpi0: bus 5 (PCIB)
acpiec0 at acpi0
acpicpu0 at acpi0
C1: bogo buffer
C2: bogo buffer
C3: bogo buffer: C1(@1 halt!), PSS
acpicpu1 at acpi0
C1: bogo buffer
C2: bogo buffer
C3: bogo buffer: C1(@1 halt!), PSS
acpitz0 at acpi0: critical temperature is 127 degC
acpitz1 at acpi0: critical temperature is 99 degC
acpithinkpad0 at acpi0
acpiac0 at acpi0: AC unit online
acpibat0 at acpi0: BAT0 model "08K8193" serial 15 type LION oem "JingYi"
acpibat1 at acpi0: BAT1 not present
acpibtn0 at acpi0: SLPB
acpibtn1 at acpi0: LID_
"PNP0303" at acpi0 not configured
"PNP0F13" at acpi0 not configured
"GOOGCB00" at acpi0 not configured
acpidock0 at acpi0: DOCK not docked (0)
acpivideo0 at acpi0: GFX0
acpivout0 at acpivideo0: LCD0
cpu0: Enhanced SpeedStep 1600 MHz: speeds: 2401, 2400, 1600, 800 MHz
pci0 at mainbus0 bus 0
pchb0 at pci0 dev 0 function 0 "Intel GM45 Host" rev 0x07
inteldrm0 at pci0 dev 2 function 0 "Intel GM45 Video" rev 0x07
drm0 at inteldrm0
intagp0 at inteldrm0
agp0 at intagp0: aperture at 0xd000, size 0x1000
inteldrm0: msi
inteldrm0: 1280x800, 32bpp
error: [drm:pid0:intel_pipe_config_compare] *ERROR* mismatch in adjusted_mode.fl
ags(DRM_MODE_FLAG_PHSYNC) (expected 0, found 1)
pipe state doesn't match!
wsdisplay0 at inteldrm0 mux 1: console (std, vt100 emulation)
wsdisplay0: screen 1-5 added (std, vt100 emulation)
"Intel GM45 Video" rev 0x07 at pci0 dev 2 function 1 not configured
em0 at pci0 dev 25 function 0 "Intel ICH9 IGP M" rev 0x03: msi, address 00:11:22
:33:44:55
uhci0 at pci0 dev 26 function 0 "Intel 82801I USB" rev 0x03: apic 2 int 16
uhci1 at pci0 dev 26 function 1 "Intel 82801I USB" rev 0x03: apic 2 int 17
uhci2 at pci0 dev 26 function 2 "Intel 82801I USB" rev 0x03: apic 2 int 18
ehci

allowaperture and X11

2017-05-25 Thread Choose a display name
I run stable OpenBSD on amd64 thinkpad and I found this in my Xorg.log:

>checkDevMem: failed to open /dev/xf86 and /dev/mem
>(Operation not permitted)
>Check that you have set 'machdep.allowaperture=1'
>in /etc/sysctl.conf and reboot your machine
>refer to xf86(4) for details

Do I need to follow this instructions even if X seems to work okay?
The installer didn't set it when I told I expect to run the X Windows System
and I have no /etc/sysctl.conf yet.

Re: Difficulties with the sh manual page

2017-05-25 Thread Choose a display name
>>yes, should be the same, see the cd coomand,
>I meant, see the description of the cd command in the opengroup docs.

Yes, ksh's and sh's cd seems to work the exact same way, despite man page
of the latter not saying what it does when CDPATH is null.

And about PPID Theo understood me right.

Thank you both!

smtpd doesn't start

2017-05-25 Thread Choose a display name
I'm faced with a problem on the stable. The moment a network interface
goes up smtpd cannot be started. I mean, it hangs and gives no output,
neither with -dv or -Fv options, it even hangs with -n. Without a network
it still works as expected. I changed no related config, I believe. How
could I debug (and even better fix) that?
Thank you.

majordomo errata

2017-05-24 Thread Choose a display name
The first sentence of the "Unsubscribing from Mailing Lists" section
of majordomo's response to "help" command contains a typo.

>Your original intro message should contains the exact command

It should contain, not "contains".
Also, according to the message lists owners' addresses must be of
the form:

>listname-ow...@openbsd.org
>This is the address of the person or persons who maintain the
>mailing list.

But, at least when you subscribe to the @misc you receive a message
from the owner-m...@openbsd.org.

Typo in the mg tutorial

2017-05-24 Thread Choose a display name
mg tutorial contains some "M-x open-file" command, but mg has only
"M-x find-file" command as far as I can see.

rc.d manual erratum

2017-05-24 Thread Choose a display name
Section ENVIRONMENT in the rc.d manual starts with:

>Daemon control scripts use a fixed number of sh(1) variables when starting a 
>daemon.
>The following three can be overridden by site-specific values ...

And description of four variables follow, not three.

Difficulties with the sh manual page

2017-05-24 Thread Choose a display name
I don't quite understand the description of the PPID in the sh manual.

>PPID The shell's parent process ID. Subshells have the same
> PPID as the parent of the current shell.

PPID is the shell's parent's pid, okay (by the way, shouldn't the
second "'s" be added?). But, according to the next sentence, subshells
have the same value in their PPIDs as the current shell's parent have
in its PPID. Is it correct?

Also, I had a problem understanding how does cd work. It is stated
there that when cd is called with argument not starting with a slash
or dot then CDPATH is searched, but what if the variable is unset? It
says nothing about such case.

>cd [-L | -P] [dir]
>Change the current working directory to dir, or $HOME by default. If
>dir is set to `-', change to the previous working directory and print
>the (now current) working directory. If dir does not begin with a
>slash or dot, CDPATH is searched for the directory.

ksh manual says that the current directory is searched in such case.
Does sh's cd work the same way? If so, it might be good idea to include
that to the manual.

Thank you.