Re: OpenSMTPD getting closer to stable ;-)

2012-09-07 Thread Thomas Jeunet
On Fri, Sep 7, 2012 at 4:32 AM, David Walker davidianwal...@gmail.com wrote:
 Gilles Chehade gilles () poolp ! org
 We are getting closer to a stable version of OpenSMTPD

 Which to my mind raises the question of how OpenSMTPD is to be
 implemented alongside Sendmail in the base system.
 Presumably, as per other items that are included in base but not the
 default, i.e. DNS services, etcetera, there will be a perhaps lengthy
 period where these systems co-exist and are both intended to be usable
 in their own right.

 AFAIUI, currently base contains some specific OpenSMTPD items for use
 and documentation, smtpd and smtpd(8), smtpctl and smtpctl(8),
 smtpd.conf and smtpd.conf(5) ...
 These items exist in their own name space and are accessible.

 These man pages, and by extension these services, reference and depend
 on utilities and concomitant man pages which are taxonomically
 identical to similar items designed for Sendmail ...
 Being labelled identically there's only room for one of each and as
 Sendmail is the current default mail system the OpenSMTPD items are
 not installed.

 The OpenSMTPD man pages don't make this clear and other than OpenSMTPD
 not working when the Sendmail incumbents are used and referenced
 there's no indication that something is awry.

 For instance, if I read smtpd.conf(5) I see references like this:
  map map source type source
  Maps are used to provide additional configuration information for
  smtpd(8).

  map may be named freely.

  type may be one of the following:

  db   Mappings are stored in a file created using makemap(8).
   This is the default type if none is specified.
  plainMappings are stored in a plain text file using the same
   format as used to generate makemap(8) mappings.

 On any system from the last year or so, following the reference to
 makemap(8) takes me to the installed Sendmail items.

 As the OpenSMTPD makemap(8) man page puts it:
 The
 .Nm
 command first appeared in
 .Ox 4.6
 as a replacement for the equivalent command shipped with sendmail.

 So I get some OpenSMTPD items, which depend on other items that are
 not installed, but still appear and do something, as identically named
 items that Sendmail relies on are installed instead.

 I may be out of touch here, but certainly in the past this was my
 experience, using OpenSMTPD items in base and following documentation
 and assuming that the included items were correct and appropriate.
 Assumption might not be the best idea, but in this case the assumption
 was that the Sendmail utilities and documentation were functionally
 effective as if this was not the case that OpenSMTPD would have it's
 own utilities that were included in base also and of necessity
 labelled originally.

 Best wishes.


You might have missed the mailwrapper(8) reference in smtpd(8) :

 smtpd is not enabled by default.  In order to use it as the system
 mailer, ensure the mail queue is empty, then stop sendmail(8):

   # /etc/rc.d/sendmail stop

 Modify the current mailwrapper(8) settings by editing /etc/mailer.conf:

   sendmail/usr/sbin/smtpctl
   send-mail   /usr/sbin/smtpctl
   mailq   /usr/sbin/smtpctl
   makemap /usr/libexec/smtpd/makemap
   newaliases  /usr/libexec/smtpd/makemap

 Rebuild the aliases database, and enable the daemon:

   # newaliases
   # echo sendmail_flags=NO  /etc/rc.conf.local
   # echo smtpd_flags=  /etc/rc.conf.local
   # /etc/rc.d/smtpd start



Re: Proper way to update system + ports?

2011-12-23 Thread Thomas Jeunet
On Fri, Dec 23, 2011 at 06:19, Barry Grumbine barry.grumb...@gmail.com
wrote:
 On Thu, Dec 22, 2011 at 3:29 PM, Corey clinge...@gmail.com wrote:
 On 12/21/2011 06:46 PM, Stuart Henderson wrote:

 On 2011-12-21, Coreyclinge...@gmail.com  wrote:

 On 12/20/2011 11:16 AM, Stuart Henderson wrote:

 Then afterwards, can I check out the -current branch from CVS as
 I do with -stable? i.e. # cvs -d$CVSROOT checkout -P src
 Or am I not supposed to fetch   build -current at all? Would it

 You can checkout src if you want, but you don't have to,
 you can just install the binary sets just as you would for a release

 be safer to just download the /snapshots/i386/install50.iso every
 couple weeks and do a fresh install every time? I guess I will

 There's really no need for fresh installs, upgrades work very well

 No need for install*.iso either, just download a new bsd.rd and
 boot that from the boot loader (boot /bsd.rd) and do a network
 upgrade install

 Out of curiosity, is this more efficient and/or less loading on the
 servers than downloading the iso (assuming one installs all sets)?

 Doesn't make a lot of difference server-side but I know it's a lot
 easier for me to boot a different kernel and point it at a (possibly
 locally mirrored or pre-downloaded) set of files than it is to
 download an iso, burn a cd and boot from it - I imagine this is
 the case for most people.


 Ah...ok. I'm usually following -current on only one or two machines, so I
 never really thought of setting up a local mirror (though there may be
 other
 advantages to doing that). How do you keep your local file mirror in sync
 with newer kernels/snapshots? Or do you do the local repo and the kernel
 somewhat independently, and just try new kernels (and read release notes)
 and see if stuff breaks?

 C


 Hi there,

 I just wanted to chime in with an alternate perspective.  I've been
 running snapshots for two or three years now.  Here's my procedure:

 1. download installXX.iso
 2. mount installXX.iso (http://openbsd.org/faq/faq14.html#MountImage)
 3. cp /mnt/5.0/i386/bsd.rd /
 4. cp -R /mnt/5.0 /
 5. reboot
 6. boot boot bsd.rd
 7. Upgrade
For Location of sets? type disk
For Is the disk partition already mounted? say yes
 8. After reboot use sysmerge and pkg_add -ui

 This works very nicely for me.

 I came across this method two or three years ago when I got tired of
 burning CDs.
 Also, I pay attention to when the latest snapshot packages were built,
 and try to pick a snapshot close to that date.

 BTW, this works for release-release, release-snapshot,
 snapshot-snapshot, I even successfully went from i386 to amd64 once,
 but I guarantee that is an unsupported move... haven't had the huevos
 to try it yet, but I think I could even get away skipping a release
 (eg. 4.8-5.0).

 If you use sysmerge and pay attention to the upgrade instructions
 (http://openbsd.org/faq/upgrade50.html) life is good.  sysmerge kicks
 some serious ass..


 -Barry


For the record, i use a similar method.

1. snapdl (in ports, sysutils/snapdl)
   For Path to download sets? (or 'pretend' ) type /5.0/amd64
(adjust accordingly version and arch)
2. reboot
3. boot boot /5.0/amd64/bsd.rd
4. Upgrade
   For Location of sets? type disk
   For Is the disk partition already mounted? say yes
5. After reboot use sysmerge and pkg_add -ui

By the way, the following diff would save me one keystroke but I don't
know how many use external disk or store upgrade sets on another disk
than the one used to boot.
Index: install.sub
===
RCS file: /cvs/src/distrib/miniroot/install.sub,v
retrieving revision 1.655
diff -u -p -r1.655 install.sub
--- install.sub 22 Nov 2011 14:02:14 -  1.655
+++ install.sub 23 Dec 2011 13:41:33 -
@@ -1447,7 +1447,7 @@ install_cdrom() {
 }

 install_disk() {
-   ask_yn Is the disk partition already mounted?
+   ask_yn Is the disk partition already mounted? y
if [[ $resp == n ]]; then
get_drive disk '$(bsort $(get_dkdevs))' \
'$(bsort $(rmel $ROOTDISK $(get_dkdevs)))' || return

Regards,
--
Thomas Jeunet



cwm core dump with group and java applicatio

2011-12-23 Thread Thomas Jeunet
Hello misc@,

I'm using cwm on amd64 -current. I'm using the group feature and when
using a Java application, cycling back to the group with this window
cores dump cwm:
(gdb) bt
#0  0x00020c8f354e in XRestackWindows () from /usr/X11R6/lib/libX11.so.15.0
#1  0x0040919d in group_show (sc=0x20ecf0400, gc=0x20ecf0530)
at /usr/xenocara/app/cwm/group.c:138
#2  0x004089af in xev_handle_keypress (ee=0x7f7daab0)
at /usr/xenocara/app/cwm/xevents.c:313
#3  0x00408add in xev_loop () at /usr/xenocara/app/cwm/xevents.c:423
#4  0x00403d3b in main (argc=3, argv=Variable argv is not available.
)
at /usr/xenocara/app/cwm/calmwm.c:90

Apparently, gc-nhidden is more or less corrupted:
(gdb) p *(struct group_ctx *) gc
$2 = {entry = {tqe_next = 0x20ecf0560, tqe_prev = 0x20ecf0500}, clients = {
tqh_first = 0x2099aa800, tqh_last = 0x2099aac10}, shortcut = 2,
  hidden = 1, nhidden = 5393, highstack = 1}
(gdb) p gc-clients-tqh_first
$3 = (struct client_ctx *) 0x2099aa800
(gdb) p gc-clients-tqh_first-entry-tqe_next
$4 = (struct client_ctx *) 0x2099aa600
(gdb) p gc-clients-tqh_first-entry-tqe_next-entry-tqe_next
$5 = (struct client_ctx *) 0x2099aa000
(gdb) p 
gc-clients-tqh_first-entry-tqe_next-entry-tqe_next-entry-tqe_next
$6 = (struct client_ctx *) 0x2099aac00
(gdb) p 
gc-clients-tqh_first-entry-tqe_next-entry-tqe_next-entry-tqe_next-entry-tqe_next
$7 = (struct client_ctx *) 0x0

So I have 4 windows in this group, all of which are either:
(gdb) p gc-clients-tqh_first-app_name
$8 = 0x201c08680 sun-awt-X11-XFramePeer
(gdb) p gc-clients-tqh_first-entry-tqe_next-app_name
$9 = 0x201c08720 sun-awt-X11-XDialogPeer

Actually, only 2 windows were displayed at this time, so I guess this is
related to issues between Java and X11 I always heard about.
The nhidden variable is only incremented in 2 places : group_hide and
group_movetogroup, so I guess the root cause lie there. However I don't
know enough of cwm internals to dig deeper. Therefore, I temporarily
made the following patch:

Index: group.c
===
RCS file: /cvs/xenocara/app/cwm/group.c,v
retrieving revision 1.54
diff -u -p -r1.54 group.c
--- group.c 12 Oct 2011 15:43:50 -  1.54
+++ group.c 21 Dec 2011 22:54:11 -
@@ -135,7 +135,7 @@ group_show(struct screen_ctx *sc, struct
}
}

-   XRestackWindows(X_Dpy, winlist, gc-nhidden);
+   XRestackWindows(X_Dpy, winlist, gc-highstack);
xfree(winlist);

gc-hidden = 0;

Anyone has a proper fix?


Cheers,
-- 
Thomas Jeunet



Re: How to mount usb disk at boot

2011-05-02 Thread Thomas Jeunet
On Mon, May 2, 2011 at 11:31, Ivo Chutkin open...@bgone.net wrote:
 Hello misc,
 I have problem mounting usb disk at boot time (namely Western Digital My
 Book 1130) on Alix2d2 board, dmesg below.
 I am getting this message and the disk is not mounted:
 mount_ffs: /dev/sd0a on /data: Device not configured

[snip]

 Dmesg:
 OpenBSD 4.8-stable (GENERIC) #1: Wed Apr  6 17:51:44 EEST 2011
r...@mail.bgone.bg:/usr/src/sys/arch/i386/compile/GENERIC
[snip]
 Automatic boot in progress: starting file system checks.
 /dev/rwd0a: file system is clean; not checking
 /dev/rwd0e: file system is clean; not checking
 /dev/rwd0d: file system is clean; not checking
 mount_ffs: /dev/sd0a on /data: Device not configured
[snip]
 sd0 at scsibus0 targ 1 lun 0: WD, My Book 1130, 1012 SCSI4 0/direct fixed
 sd0: 953837MB, 512 bytes/sec, 1953458176 sec total
[snip]
 OpenBSD/i386 (asterisk1.my.domain) (tty00)


Hello,

your sd0 disk is discovered later in the boot process. Have a look at
hotplugd(8) to mount your disk as soon as it's discovered :

Regards,
--
Thomas Jeunet



Re: (Perhaps?) dumb pf question relating to tables

2010-11-10 Thread Thomas Jeunet
On Wed, Nov 10, 2010 at 13:45, Tor Houghton t...@bogus.net wrote:
 Hello,

 May I ask whether or not per user ownership (or permission to update) a
 table is/will be possible?

 I am pondering the best mechanism for a  non-root process to add/remove
 addresses to a table.

 Kind regards,

 Tor


You might be interested in having a look at authpf(8) eventually?



HP Mini 5101 acpi problem

2010-09-03 Thread Thomas Jeunet
Hello misc@,

I have currently access to an HP Mini 5101 for a short period of time.
I tried booting OpenBSD on this machine to see how it worked, and I had
to diable ACPI in order to boot.

dmesg and pcidump -vv follows, and I have acpidump output at hand.

-- 
Thomas Jeunet 

dmesg:  
OpenBSD 4.8-current (GENERIC.MP) #373: Tue Aug 31 22:09:07 MDT 2010
dera...@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC.MP
cpu0: Intel(R) Atom(TM) CPU N280 @ 1.66GHz (GenuineIntel 686-class) 1.67 GHz
cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,EST,TM2,SSSE3,xTPR,PDCM,MOVBE
real mem  = 2138468352 (2039MB)
avail mem = 2093494272 (1996MB)
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 07/06/09, BIOS32 rev. 0 @ 0xf, SMBIOS 
rev. 2.4 @ 0xf3d9d (23 entries)
bios0: vendor Hewlett-Packard version 68DGI Ver. F.01 date 07/06/2009
bios0: Hewlett-Packard HP Mini 5101
acpi0 at bios0: rev 2
acpi0: sleep states S0 S3 S4 S5
acpi0: tables DSDT FACP SLIC HPET APIC MCFG TCPA SSDT SSDT SSDT SSDT SSDT
acpi0: wakeup devices C09B(S5) C0F9(S3) C100(S3) C103(S3) C10A(S5) C1EA(S5) 
C11D(S5) C1EB(S5) C120(S5) C1F3(S5)
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpihpet0 at acpi0: 14318179 Hz
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: apic clock running at 166MHz
cpu1 at mainbus0: apid 1 (application processor)
cpu1: Intel(R) Atom(TM) CPU N280 @ 1.66GHz (GenuineIntel 686-class) 1.67 GHz
cpu1: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,EST,TM2,SSSE3,xTPR,PDCM,MOVBE
ioapic0 at mainbus0: apid 1 pa 0xfec0, version 20, 24 pins
ioapic0: misconfigured as apic 0, remapped to apid 1
acpiprt0 at acpi0: bus 2 (C09B)
acpiprt1 at acpi0: bus 8 (C10A)
acpiprt2 at acpi0: bus 24 (C11D)
acpiprt3 at acpi0: bus 32 (C120)
acpiprt4 at acpi0: bus 0 (C002)
acpiec0 at acpi0
acpicpu0 at acpi0: C2, C1, PSS
acpicpu1 at acpi0: C2, C1, PSS
acpipwrres0 at acpi0: C1DE
acpipwrres1 at acpi0: C1E1
acpipwrres2 at acpi0: C2E8
acpipwrres3 at acpi0: C2E9
acpipwrres4 at acpi0: C2EA
acpipwrres5 at acpi0: C2EB
acpipwrres6 at acpi0: C2EC
acpitz0 at acpi0: critical temperature 95 degC
acpitz1 at acpi0: critical temperature 105 degC
acpitz2 at acpi0: critical temperature 75 degC
acpitz3 at acpi0: critical temperature 105 degC
acpitz4 at acpi0: critical temperature 110 degC
acpibat0 at acpi0: C1CB model Primary serial 57563 2009/07/24 type LIon oem 
Hewlett-Packard
acpibat1 at acpi0: C1CA not present
acpiac0 at acpi0: AC unit online
acpibtn0 at acpi0: C201
acpibtn1 at acpi0: C1D0
acpivideo0 at acpi0: C088
acpivout0 at acpivideo0: C149
acpivout1 at acpivideo0: C14A
acpivout2 at acpivideo0: C14F
acpivout3 at acpivideo0: C150
bios0: ROM list: 0xc/0xec00!
cpu0: Enhanced SpeedStep 1663 MHz: speeds: 1667, 1333, 1000 MHz
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
pchb0 at pci0 dev 0 function 0 Intel 82945GME Host rev 0x03
vga1 at pci0 dev 2 function 0 Intel 82945GME Video rev 0x03
wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation)
wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
intagp0 at vga1
agp0 at intagp0: aperture at 0xd000, size 0x1000
inteldrm0 at vga1: apic 1 int 16 (irq 10)
drm0 at inteldrm0
Intel 82945GM Video rev 0x03 at pci0 dev 2 function 1 not configured
azalia0 at pci0 dev 27 function 0 Intel 82801GB HD Audio rev 0x01: apic 1 int 
21 (irq 10)
azalia0: codecs: Analog Devices AD1984A
audio0 at azalia0
ppb0 at pci0 dev 28 function 0 Intel 82801GB PCIE rev 0x01: apic 1 int 16 
(irq 10)
pci1 at ppb0 bus 8
vendor Broadcom, unknown product 0x4353 (class network subclass 
miscellaneous, rev 0x01) at pci1 dev 0 function 0 not configured
ppb1 at pci0 dev 28 function 2 Intel 82801GB PCIE rev 0x01: apic 1 int 18 
(irq 11)
pci2 at ppb1 bus 24
ppb2 at pci0 dev 28 function 3 Intel 82801GB PCIE rev 0x01: apic 1 int 19 
(irq 10)
pci3 at ppb2 bus 32
mskc0 at pci3 dev 0 function 0 Marvell Yukon 88E8072 rev 0x10, Yukon-2 
Extreme rev. B0 (0x2): apic 1 int 19 (irq 10)
msk0 at mskc0 port A: address 00:25:b3:75:c0:c2
eephy0 at msk0 phy 0: 88E1149 Gigabit PHY, rev. 1
uhci0 at pci0 dev 29 function 0 Intel 82801GB USB rev 0x01: apic 1 int 20 
(irq 10)
uhci1 at pci0 dev 29 function 1 Intel 82801GB USB rev 0x01: apic 1 int 21 
(irq 11)
uhci2 at pci0 dev 29 function 2 Intel 82801GB USB rev 0x01: apic 1 int 18 
(irq 11)
uhci3 at pci0 dev 29 function 3 Intel 82801GB USB rev 0x01: apic 1 int 19 
(irq 10)
ehci0 at pci0 dev 29 function 7 Intel 82801GB USB rev 0x01: apic 1 int 20 
(irq 10)
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 Intel EHCI root hub rev 2.00/1.00 addr 1
ppb3 at pci0 dev 30 function 0 Intel 82801BAM Hub-to-PCI rev 0xe1
pci4 at ppb3 bus 2
ichpcib0 at pci0 dev 31 function 0 Intel 82801GBM LPC rev 0x01: PM disabled
pciide0 at pci0 dev 31 function 2 Intel 82801GBM SATA rev 0x01: DMA, channel

GCC manpage glitch

2010-08-16 Thread Thomas Jeunet
Hello,

The gcc manpage contains some weird glitches, for instance :
(usually Cv'-.1v'h'-1p'+h'-1p'+v'.1v'h'-1p')

I tracked it down to (usually \*(C+) in the man page's source.
However, I'm not a *roff expert so I don't know where to look, so I
just let you know.

Regards



Re: Logging when interfaces go down

2009-09-18 Thread Thomas Jeunet
On Fri, Sep 18, 2009 at 15:37, Ian Chard ian.ch...@ict.ox.ac.uk wrote:
 Hi,

 Is it possible to log, or in some other way capture the event, when network
 interfaces go down?

 Thanks
 - Ian

 --
 Ian Chard, Senior Unix and Network Gorilla | E: ian.ch...@sers.ox.ac.uk
 Systems and Electronic Resources Service   | T:  80587 / (01865) 280587
 Oxford University Library Services | F:  (01865) 242287



See ifstated : http://www.openbsd.org/cgi-bin/man.cgi?query=ifstated

--
Thomas Jeunet



Re: Use memory as disk

2009-08-21 Thread Thomas Jeunet
On Fri, Aug 21, 2009 at 2:03 PM, obvvbooo
obvvbbvvb...@googlemail.com wrote:
 Hi,

 Is there a way to use memory as a disk/partition? Such as mount it to
 /mnt/mem or such things. I can't find information of this in the man pages
 and after googled, I found rd for OpenBSD, which seems similar with md
 in FreeBSD. But still not useful. Anybody help?

 Thanks



I guess you're looking for mfs. See man mfs