HP 24x6 Autoloader: CHIOMOVE: Device Busy

2008-08-23 Thread thomas

Hi,

I recently installed a HP DDS3 Autoloader 24x6 on a x86 with 4.3.
Loading of tapes works without problems, but unloading the tape after  
writing to it causes a 'Device busy' message:


# /bin/chio move slot 0 drive 0

# /sbin/dump -0uanf /dev/nrst0 /dev/wd0a
...
# /bin/mt -f /dev/nrst0 rewind

# /bin/chio move drive 0 slot 0
chio: /dev/ch0: CHIOMOVE: Device busy

The 'Device busy' message appears even after hours of waiting or  
rebooting. Shuting down the system (halt) and restarting it solves the  
problem.


Furthermore, after I do an interactive restore(8) (without restoring  
any files) I can move the tape back to the slot.


Do you have any ideas what may cause this 'Device busy' messages?
Best Regrads
Thomas


dmesg:
OpenBSD 4.3 (GENERIC) #698: Wed Mar 12 11:07:05 MDT 2008
[EMAIL PROTECTED]:/usr/src/sys/arch/i386/compile/GENERIC
cpu0: Intel Pentium III (GenuineIntel 686-class) 936 MHz
cpu0:  
FPU 
,V86 
,DE 
,PSE 
,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,MMX,FXSR,SSE

real mem  = 267939840 (255MB)
avail mem = 251031552 (239MB)
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 07/11/01, BIOS32 rev. 0 @  
0xfdb30, SMBIOS rev. 2.3 @ 0xf0620 (23 entries)

bios0: vendor American Megatrends Inc. version 062710 date 07/15/97
bios0: MSI MS-6309
apm0 at bios0: Power Management spec V1.2
apm0: AC on, battery charge unknown
acpi at bios0 function 0x0 not configured
pcibios0 at bios0: rev 2.1 @ 0xf/0x1
pcibios0: PCI IRQ Routing Table rev 1.0 @ 0xf7a70/160 (8 entries)
pcibios0: PCI Interrupt Router at 000:07:0 (VIA VT82C686 ISA rev 0x00)
pcibios0: PCI bus #1 is the last bus
bios0: ROM list: 0xc/0xc800 0xcc800/0x3800
cpu0 at mainbus0
pci0 at mainbus0 bus 0: configuration mode 1 (no bios)
pchb0 at pci0 dev 0 function 0 VIA VT82C691 PCI rev 0xc4
agp0 at pchb0: v2, aperture at 0xe000, size 0x1000
ppb0 at pci0 dev 1 function 0 VIA VT82C598 AGP rev 0x00
pci1 at ppb0 bus 1
vga1 at pci1 dev 0 function 0 NVIDIA GeForce2 MX 100 rev 0xb2
wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation)
wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
pcib0 at pci0 dev 7 function 0 VIA VT82C686 ISA rev 0x40
pciide0 at pci0 dev 7 function 1 VIA VT82C571 IDE rev 0x06: ATA100,  
channel 0 configured to compatibility, channel 1 configured to  
compatibility

pciide0: channel 0 disabled (no drives)
wd0 at pciide0 channel 1 drive 0: IC35L040AVER07-0
wd0: 16-sector PIO, LBA, 39266MB, 80418240 sectors
wd0(pciide0:1:0): using PIO mode 4, Ultra-DMA mode 5
uhci0 at pci0 dev 7 function 2 VIA VT83C572 USB rev 0x16: irq 12
uhci1 at pci0 dev 7 function 3 VIA VT83C572 USB rev 0x16: irq 12
viaenv0 at pci0 dev 7 function 4 VIA VT82C686 SMBus rev 0x40: 24-bit  
timer at 3579545Hz

auvia0 at pci0 dev 7 function 5 VIA VT82C686 AC97 rev 0x50: irq 10
ac97: codec id 0x49434511 (ICEnsemble ICE1232)
ac97: codec features headphone, 18 bit DAC, 18 bit ADC, KS Waves 3D
audio0 at auvia0
ahc0 at pci0 dev 14 function 0 Adaptec AIC-7850 rev 0x03: irq 11
scsibus0 at ahc0: 8 targets
st0 at scsibus0 targ 0 lun 0: HP, C1557A, U812 SCSI2 1/sequential  
removable
ch0 at scsibus0 targ 0 lun 1: HP, C1557A, U812 SCSI2 8/changer  
removable
xl0 at pci0 dev 15 function 0 3Com 3c900B 10Mbps rev 0x04: irq 10,  
address 00:01:02:e0:d7:2c
xl1 at pci0 dev 16 function 0 3Com 3c905B 100Base-TX rev 0x30: irq  
10, address 00:50:04:6a:ff:06

exphy0 at xl1 phy 24: 3Com internal media interface
xl2 at pci0 dev 17 function 0 3Com 3c905B 100Base-TX rev 0x30: irq  
12, address 00:10:5a:64:86:c7

exphy1 at xl2 phy 24: 3Com internal media interface
xl3 at pci0 dev 18 function 0 3Com 3c905B 100Base-TX rev 0x30: irq  
10, address 00:10:5a:64:86:95

exphy2 at xl3 phy 24: 3Com internal media interface
isa0 at pcib0
isadma0 at isa0
pckbc0 at isa0 port 0x60/5
pckbd0 at pckbc0 (kbd slot)
pckbc0: using irq 1 for kbd slot
wskbd0 at pckbd0: console keyboard, using wsdisplay0
pcppi0 at isa0 port 0x61
midi0 at pcppi0: PC speaker
spkr0 at pcppi0
lpt0 at isa0 port 0x378/4 irq 7
npx0 at isa0 port 0xf0/16: reported by CPUID; using exception 16
pccom0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
pccom1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo
fdc0 at isa0 port 0x3f0/6 irq 6 drq 2
fd0 at fdc0 drive 0: 1.44MB 80 cyl, 2 head, 18 sec
usb0 at uhci0: USB revision 1.0
uhub0 at usb0 VIA UHCI root hub rev 1.00/1.00 addr 1
usb1 at uhci1: USB revision 1.0
uhub1 at usb1 VIA UHCI root hub rev 1.00/1.00 addr 1
biomask fb65 netmask ff65 ttymask ffe7
mtrr: Pentium Pro MTRR support
softraid0 at root
root on wd0a swap on wd0b dump on wd0b



isakmpd

2008-08-23 Thread Daniel Rapp
Hi, i am looking for example configs on isakmpd where there is more then one
tunnel..

I have a openbsd (4.2) firewall with a tunnel config in isakmpd.conf and i
want to add a roadwarrior tunnel to..
I think i have seen some sample config before but i cant seem to find any
now..

Any help would be appreciated..

/Daniel



Re: I'm embarassed. (Re: shell not reading login script)

2008-08-23 Thread Joel Rees

On 平成 20/08/22, at 19:21, Philip Guenther wrote:


2008/8/21 Joel Rees [EMAIL PROTECTED]:

On 平成 20/08/21, at 12:12, Philip Guenther wrote:


2008/8/20 Joel Rees [EMAIL PROTECTED]:


export PROFMARKER=.profile


would you believe I put that in .profile, like the marker said?

...etc

Now that you've said it, yes, I do.  If you think it unreasonable to
not assume that from your first message, then you haven't followed
enough QA exchanges on mailing lists.




  People do things that are
completely insane to others and then don't believe it when people say
that was non-obvious.


Yeah, it's been a while since I've been on tech lists, and then I was  
just feeling prickly this last week. Too distracted by the things I'm  
not getting done to post anything but brain-dumps for questions.


Thanks for the discussion.


[...]


If you're wondering why the shotgun approach, I couldn't figure  
out, with my
login shell set to sh, why the shell was behaving like csh. Still  
don't get

it.


sigh  What do you mean by behaving like csh?  The only prominent
reference to csh behavior I see in your previous note is this:


Except, csh picks up one marker, sh and ksh pick up none. So I'm
still puzzled


Meh. Definitely not clear writing on my part.

When I start csh at the command line in xterm, csh sources .cshrc  
like I expect. (That is, the flag shows up in the environment.)


But neither sh nor ksh source .profile when I run them from the  
command line.



[...]
For the the second (parameters to X11), that depends on how you run
X.  xinit, xdm, or something else?  Remote sessions?


xdm. That is, I cleared the flag that prevents xdm running in /etc/ 
rc.conf.local. (Not booted up in openbsd right now, but I think maybe  
you'll recognize that?) Not because I intended it that way, just that  
I haven't loaded anything besides all the X11 sets in the install  
image from the web. (Yeah, I know, I should buy the CDs, but, well,  
my budget for this project is really too tight in the first place.


I'd ask more questions, but I'm out of time for now. Spun my wheels  
too long, couldn't seem to generate useful search phrases or even  
questions. I've forgotten too much stuff. I'll have to pick this back  
up in a month or three. Maybe I'll try this project again with Fedora  
if I can figure out how to do it without yaboot (Don't ask. I don't  
know all the reasons why parted killed my Mac OS 9 drivers when I  
told it to partition a 1MB partition for yaboot.) and over Christmas  
try putting openbsd on the AMD box in the other room so I can  
practice a bit in the environment that has the most support.


Thanks again.

Joel Rees
(waiting for a 3+GHz ARM processor to come out,
to test Steve's willingness to switch again.)



Re: Ethernet (and sound?) doesn't work on my new notebook

2008-08-23 Thread thacrazze
No idea for my problem?

On Wed, Aug 20, 2008 at 11:20 PM, thacrazze [EMAIL PROTECTED] wrote:
 Hello,

 I have a new new notebook, an ASUS F5SL-AP177D with the following 
 configuration:
 Pentium Dual-Core T2390 2x 1.86GHz - 2048MB - 250GB - DVD+/-RW DL -
 ATI Mobility Radeon HD 3470 256MB - 4x USB 2.0/Modem/Gb LAN/WLAN
 802.11bg - ExpressCard Slot - 4in1 Card Reader (SD/MMC/MS/MS Pro) -
 Webcam (1.3 Megapixel) - 15.4 WXGA glare TFT (1280x800) - FreeDOS -
 Li-Ion storage-battery - 2.60kg


 So I want to install OpenBSD. But my ethernet doesnt work on OpenBSD
 (I tested 4.3-stable and 4.4-current [2008-08-19 and 2008-08-12]
 amd64)

 Here is the relevant part of my dmesg/4.4-current: (hand-written
 copied from display, because no connection to internet)
 -openbsd 4.4 dmesg amd64--
 pchb0 at pci0 dev 0 function 0 vendor SiS, unknown product 0x0671 rev 0x00
 vga1 at pci1 dev 0 function 0 vendor ATI, unknown product 0x95c4 rev 0x00
 vendor SiS, unknown product 0x0968 (class bridge subclass ISA, rev
 0x01) at pci0 dev 2 function 0 not configured
 SiS 191 rev 0x02 at pci0 dev 4 function 0 not configured
 pciide1 at pci0 dev 5 function 0 vendor SiS, unknown product 0x1183
 rev 0x03: byte 2110
 SiS 966 HD Audio rev 0x00 at pci0 dev 15 function 0 not configured
 uhid at uhidev0 not configured
 

 I hope someone can help me :), and sorry for my bad english

 Best regards,
 thacrazze

 .
 .
 .
 .
 .
 For comparison some parts from my linux dmesg:
 
 [EMAIL PROTECTED]:~$ dmesg|grep eth0
 [   28.365283] eth0: RGMII mode.
 [   28.365290] eth0: Enabling Auto-negotiation.
 [   39.591987] eth0: mii ext = .
 [   39.607970] eth0: mii lpa = 41e1 adv = 01e1.
 [   39.607974] eth0: link on 100 Mbps Full Duplex mode.
 [   39.791778] eth0: mii ext = .
 [   39.807757] eth0: mii lpa = 41e1 adv = 01e1.
 [   39.807762] eth0: link on 100 Mbps Full Duplex mode.
 [   57.736671] eth0: no IPv6 routers present
 [EMAIL PROTECTED]:~$ dmesg|grep sis
 [   18.852012] pata_sis :00:02.5: version 0.5.2
 [   18.852241] scsi0 : pata_sis
 [   18.852300] scsi1 : pata_sis
 [   19.347890] sata_sis :00:05.0: version 1.0
 [   19.347918] sata_sis :00:05.0: Detected SiS
 1183/966/966L/968/680 controller in PATA mode
 [   19.352480] scsi2 : sata_sis
 [   19.355174] scsi3 : sata_sis
 [   27.733026] sis190 Gigabit Ethernet driver 1.2 loaded.
 [EMAIL PROTECTED]:~$ dmesg|grep SiS
 [   19.347918] sata_sis :00:05.0: Detected SiS
 1183/966/966L/968/680 controller in PATA mode
 [   28.365278] :00:04.0: SiS 191 PCI Gigabit Ethernet adapter at
 c2e84c00 (IRQ: 19), 00:1e:8c:7e:ae:d8

 And for sound I need under Linux in /etc/modprobe.d/alsa-base:
 options snd-hda-intel model=lenovo

 (I will delete Linux when OpenBSD works with sound  ethernet)



Re: Ethernet (and sound?) doesn't work on my new notebook

2008-08-23 Thread Martin Toft
On Sat, Aug 23, 2008 at 07:01:21PM +0200, thacrazze wrote:
 No idea for my problem?

A quick glance at sis(4) (man sis) and http://www.openbsd.org/i386.html
(the section Gigabit Ethernet Adapters) indicates that your SiS 191
network card just isn't supported.



Booting from /dev/rwd0c (aka wd0)

2008-08-23 Thread Lars Noodén
I have the main system on a smaller, pre-existing drive set up with a
recent 4.4 i386 snapshot on a Dell Optiplex gx270.  Booting is normal
until I add two SATA drives.

OpenBSD sees the drive as wd0, but fdisk sees it as /dev/rwd0c, so the
effect is that when booting, this error message comes up:

Using drive 0, partition 3.
 No O/S

What can be done, while keeping the new drives for non-system data only,
to boot from the original drive?

Is there some trick that can be done with the MBR on the other drives to
point it to the original drive with /bsd on it?

-Lars



Re: I'm embarassed. (Re: shell not reading login script)

2008-08-23 Thread Philip Guenther
2008/8/23 Joel Rees [EMAIL PROTECTED]:
 On 平成 20/08/22, at 19:21, Philip Guenther wrote:
 2008/8/21 Joel Rees [EMAIL PROTECTED]:
...
 When I start csh at the command line in xterm, csh sources .cshrc like I
 expect. (That is, the flag shows up in the environment.)

 But neither sh nor ksh source .profile when I run them from the command
 line.

Right, because they only source .profile when run as login shells.
However, if you set the ENV environment variable to the path of a file
to parse before you invoked sh or ksh, then they would parse that
file.  I.e.:

$ cat /home/users/guenther/.env
echo foo
PS1='inner$ '
$ env ENV=$HOME/.env ksh
foo
inner$ exit
$

...
 xdm. That is, I cleared the flag that prevents xdm running in
 /etc/rc.conf.local. (Not booted up in openbsd right now, but I think maybe
 you'll recognize that?)

Gotcha.  In that case my recommendation is:
1) have xterm start login shells by putting this line in $HOME/.Xresources
  XTerm*loginShell: true
and, if you have a $HOME.xsession file, then make sure it has a
line like this:
  test -r $HOME/.Xresources  xrdb -load $HOME/.Xresources
near its top.

2) put all your .profile file the following types of stuff:
   - setting and exporting of environment variables (including CVSROOT)
   - umask
   - export ENV=$HOME/.kshrc  (or whatever file you prefer)

3) put in your $ENV file the following types of stuff:
   - shell functions
   - shell settings that aren't environment variables, such as MAILCHECK,
 set -o emacs, 'bind'
   - stuff that requires a terminal (stty, tset), but wrapped in a
test like this:
if [ -t 0 ]; then
   stty blah blah
fi
 so that it doesn't run if you don't actually have a terminal


Hopefully that'll give you a place to start from when you have a
chance to take another stab at this.


Philip Guenther



Re: Booting from /dev/rwd0c (aka wd0)

2008-08-23 Thread Peter N. M. Hansteen
Lars NoodC)n [EMAIL PROTECTED] writes:

 I have the main system on a smaller, pre-existing drive set up with a
 recent 4.4 i386 snapshot on a Dell Optiplex gx270.  Booting is normal
 until I add two SATA drives.

I assume you have already fiddled with BIOS options for boot device
order?  SATAs are generally quicker at most things than IDEs, and
there could be settings (BIOS ones) that automagically change once you
plug in the faster drives.  Worth checking anyway.

-- 
Peter N. M. Hansteen, member of the first RFC 1149 implementation team
http://bsdly.blogspot.com/ http://www.bsdly.net/ http://www.nuug.no/
Remember to set the evil bit on all malicious network traffic
delilah spamd[29949]: 85.152.224.147: disconnected after 42673 seconds.



Re: Booting from /dev/rwd0c (aka wd0)

2008-08-23 Thread Nick Holland
Lars Noodin wrote:
 I have the main system on a smaller, pre-existing drive set up with a
 recent 4.4 i386 snapshot on a Dell Optiplex gx270.  Booting is normal
 until I add two SATA drives.
 
 OpenBSD sees the drive as wd0, but fdisk sees it as /dev/rwd0c, so the
 effect is that when booting, this error message comes up:

your cause and effect is wrong.

 
   Using drive 0, partition 3.
No O/S
 
 What can be done, while keeping the new drives for non-system data only,
 to boot from the original drive?
 
 Is there some trick that can be done with the MBR on the other drives to
 point it to the original drive with /bsd on it?
 
 -Lars

this is not an OpenBSD problem, your BIOS is booting from the wrong
disk.  This other disk has an MBR on it, but not an active partition
(and in your case, probably nothing to boot from).

The answer to your asked question is, fight with your BIOS.

My counter question is, is it worth it?  (Hint: no!).  It is not
likely to be worth it to try to mix a smaller older IDE drive
with a new big SATA drives.  Get all done with it, you now have
three failure points instead of two.  Put whatever you want on
the SATA drives, remove the IDE.

Get your BIOS to boot from the disk you want it to.  Then you can
fight with the OpenBSD issues, like your boot drive might be wd2
instead of the wd0 you are expecting.  Certainly can be dealt with,
but a pain.

In the case of a GX270, a BIOS update might be very very useful for
you, as yes, they had SATA support, but not sure how perfect or
flexible it was early on.

Last time I did a lot of disks on a single box, I found it easiest
to quit using the on-board SATA interface, put everything in PCI
connected SATA cards, and pry the BIOS chip off all the boards
other than the one I wanted to boot from.  Then I moved that around
until I found the slot ordering that gave me a port on the card
with the boot ROM at wd0.  Could I maintain a machine that booted
from, say, wd3?  Sure.  Could I expect anyone else to?  No.  Again,
not OpenBSD issues, the PC systems get exciting when you pack a
lot of different kinds of BIOSs in one system.

I've done this battle in Windows.  I can assure you, OpenBSD is
much easier... :)

Nick.



Re: Booting from /dev/rwd0c (aka wd0)

2008-08-23 Thread Peter N. M. Hansteen
Nick Holland [EMAIL PROTECTED] writes:

 with the boot ROM at wd0.  Could I maintain a machine that booted
 from, say, wd3?  Sure.  Could I expect anyone else to?  No.  

You certainly have a point there. One of the boxes in my pen has

$ mount
/dev/wd2a on / type ffs (local)
/dev/wd1a on /home type ffs (local, nodev, nosuid)
/dev/wd0a on /var type ffs (local, nodev, nosuid)

mainly because I got tired of fighting the BIOS and moving IDE cables
around, it was getting late, the rig had already extracted its one
required blood sacrifice, etc

 I've done this battle in Windows.  I can assure you, OpenBSD is
 much easier... :)

Amen to that.

- P

-- 
Peter N. M. Hansteen, member of the first RFC 1149 implementation team
http://bsdly.blogspot.com/ http://www.bsdly.net/ http://www.nuug.no/
Remember to set the evil bit on all malicious network traffic
delilah spamd[29949]: 85.152.224.147: disconnected after 42673 seconds.



[semi-OT] using IPv4 addresses in alternative formats (i.e. not dotted decimal notation)

2008-08-23 Thread ropers
Hiya,

I only recently learned that when addressing an Internet server/host
by IPv4 address, it is possible to not use the standard dotted decimal
notation (abc.def.uvw.xyz) but instead use any of a number of
alternative formats; for example it is possible to specify the IP
address in all-decimal dword format, or as an octal or hexadecimal
number, etc.

If this is news to you, and if you have a bit of time to waste, you
could read a bit more here:
http://www.reddit.com/comments/6usfd/case_study_is_php_embarrasingly_slower_than_java/c04xgjf
http://www.pc-help.org/obscure.htm

Now, I was really surprised to learn of all of this, as this info is
hardly ever mentioned everywhere, and it seems to me that even many
fairly seasoned IT people aren't aware of these possibilities. E.g.
the http://www.3com.com/other/pdfs/infra/corpinfo/en_US/501302.pdf
that's linked from the OpenBSD FAQ also doesn't mention these
alternative notations at all.

So I wonder:

Does anyone know whether these alternative notations
(dword/octal/hexadecimal...) are officially *supposed* to work? Or is
it more of an accident that they do? Are there any RFCs on this? (A
cursory search didn't turn up anything that seemed appropriate.)
Presumably it's a matter of the TCP/IP stack that they do work? But it
seems not all tools appear to do support this; e.g. I couldn't find a
way to look up 2172650943 with whois or host, but ping and ftp work
fine, as does the traditional notation 129.128.5.191. Firefox however
appears to work fine with dword/all-decimal IPv4 addresses, as does
lynx. So I wonder what's expected behaviour here, and whether the
tools that don't work with alternate notations should work? Also, does
all of this have implications for pf.conf? A bit of googling told me
that black hats sometimes try to use these alternate notations to get
around restrictions.

Thanks and regards,
--ropers



Re: [semi-OT] using IPv4 addresses in alternative formats (i.e. not dotted decimal notation)

2008-08-23 Thread Marc Balmer
* ropers wrote:
 Hiya,
 
 I only recently learned that when addressing an Internet server/host
 by IPv4 address, it is possible to not use the standard dotted decimal
 notation (abc.def.uvw.xyz) but instead use any of a number of
 alternative formats; for example it is possible to specify the IP
 address in all-decimal dword format, or as an octal or hexadecimal
 number, etc.

it actually took me by surprise.  I named my package build machines
4.2, 4.3, etc., for obvious reasons, but when I tried to ping them
'$ ping 4.2' I was really surprised about the smart-ass stupidity
someone fiddled into ping...

 
 If this is news to you, and if you have a bit of time to waste, you
 could read a bit more here:
 http://www.reddit.com/comments/6usfd/case_study_is_php_embarrasingly_slower_than_java/c04xgjf
 http://www.pc-help.org/obscure.htm
 
 Now, I was really surprised to learn of all of this, as this info is
 hardly ever mentioned everywhere, and it seems to me that even many
 fairly seasoned IT people aren't aware of these possibilities. E.g.
 the http://www.3com.com/other/pdfs/infra/corpinfo/en_US/501302.pdf
 that's linked from the OpenBSD FAQ also doesn't mention these
 alternative notations at all.
 
 So I wonder:
 
 Does anyone know whether these alternative notations
 (dword/octal/hexadecimal...) are officially *supposed* to work? Or is
 it more of an accident that they do? Are there any RFCs on this? (A
 cursory search didn't turn up anything that seemed appropriate.)
 Presumably it's a matter of the TCP/IP stack that they do work? But it
 seems not all tools appear to do support this; e.g. I couldn't find a
 way to look up 2172650943 with whois or host, but ping and ftp work
 fine, as does the traditional notation 129.128.5.191. Firefox however
 appears to work fine with dword/all-decimal IPv4 addresses, as does
 lynx. So I wonder what's expected behaviour here, and whether the
 tools that don't work with alternate notations should work? Also, does
 all of this have implications for pf.conf? A bit of googling told me
 that black hats sometimes try to use these alternate notations to get
 around restrictions.
 
 Thanks and regards,
 --ropers



Re: From address when using mail command

2008-08-23 Thread Aaron W. Hsu
Hey there,

I think I understand your (worked around) problem...

From [EMAIL PROTECTED] Sat Aug 23 14:49:55 2008
Subject: Re: From address when using mail command

Actually this was not my problem. My server is mail and web host
for several small sites.  I will say that the link below would
have been really great to have when I was setting up sendmail.
I really struggled to find any site with a complete, yet simple
explanation of how to get things going.  m4 works quite easily
once you know how, but I really had to browse for hours to get
the simple answer how to use it.

Richard Toohey sent me a message suggesting an obvious answer I
should have thought of, since I use it in cgi scripts anyway.
Just to use sendmail directly, since mail is really just an
incomplete way of accessing sendmail.

I would call this more of a workaround than a solution, though it could 
solve the problem perfectly well for you. For me, there are actually 
feature in mail(1) that I use which would make sendmail inconvenient 
for me. If the server you are using really does service mail, then 
things are even easier to work with. If I understand your situation, 
you are saying that your local hostname is different than the main 
domain for which the server receives and relays mail. 

Generally, this is easy to work by a simple MASQUERADING setting. 
If you know that all mail (except local) that you want to send out 
should come from the main domain (whose MX records presumably point 
to the hostname of your server) then you just have to setup up a 
few MASQUERADING statements in your mc file, maybe do some settings 
like local_no_masquerade and you are set. Then you should be able 
to use just about any mail client that relies on sendmail in any 
similar fashion as does mail(1).

I think this is probably the more robust solution, but you're free 
to do it with raw sendmail if you life, which is actually a solution 
much the same way that the GUI mail clients do (they pipe in the 
full headers to sendmail and give the user the option to change 
the From address).

Aaron



Re: [semi-OT] using IPv4 addresses in alternative formats (i.e. not dotted decimal notation)

2008-08-23 Thread Christian Weisgerber
ropers [EMAIL PROTECTED] wrote:

 I only recently learned that when addressing an Internet server/host
 by IPv4 address, it is possible to not use the standard dotted decimal
 notation (abc.def.uvw.xyz) but instead use any of a number of
 alternative formats; for example it is possible to specify the IP
 address in all-decimal dword format, or as an octal or hexadecimal
 number, etc.

Yes, see inet(3).

 Does anyone know whether these alternative notations
 (dword/octal/hexadecimal...) are officially *supposed* to work?

It's the input format specified for inet_aton() and friends.
I'm too lazy to research if this is actually in some standard or
just tradition going back 25 years to 4.2BSD.

 But it seems not all tools appear to do support this;

It depends on what functions they use to transform a printable
representation into an actual address; e.g. inet_pton() accepts a
more limited range of formats.

 Also, does all of this have implications for pf.conf?

There was a bit of discussion how a netblock address in a format
like 192.168/16 should be interpreted.  Just use four-part dotted
addresses and you don't have to wonder.

 A bit of googling told me that black hats sometimes try to use
 these alternate notations to get around restrictions.

If the people putting the restrictions in place are stupid enough
to match on addresses as strings rather than in some normalized
format...

-- 
Christian naddy Weisgerber  [EMAIL PROTECTED]