Re: vi vs ed in bsd.rd - proposal

2013-01-11 Thread Paul de Weerd
On Sat, Jan 12, 2013 at 08:13:33AM +0100, Otto Moerbeek wrote:
| On Sat, Jan 12, 2013 at 07:39:27AM +0100, Paul de Weerd wrote:
| 
| > On Sat, Jan 12, 2013 at 01:34:44AM -0300, Carlo Borelli wrote:
| > | > If you claim to be a unix administrator, learn ed.
| > | >
| > | 
| > | Sorry, completely wrong. An unix admin use only vi not wordstar or ed.
| > 
| > You know vi but you don't know ed.  Right.  Know your software and its
| > history - vi is ed with visual editing bolted on.  Once you recognize
| > this, you'll have no problems at all dealing with ed.
| 
| slighty wrong. vi is *ex* plus visual editing.

Sure, I skipped a step .. history went ed -> ex -> vi (and that's not
a completely accurate progression either with ed being written by
Thompson and ex (and later vi) by Joy who was an avid ed user), but
the influences are obvious.

The point was that it's easy to learn and use ed if you are already 
familiar with vi.

| But the advice remains. ed is a skil must know to call yourself a unix
| admin. 

Absolutely.

Paul 'WEiRD' de Weerd

-- 
>[<++>-]<+++.>+++[<-->-]<.>+++[<+
+++>-]<.>++[<>-]<+.--.[-]
 http://www.weirdnet.nl/ 



Re: vi vs ed in bsd.rd - proposal

2013-01-11 Thread Christopher Vance
You would fail any system administration course I teach.

On 12/01/2013, at 15:34, Carlo Borelli  wrote:

> 2013/1/12 Nick Holland 
> 
>> On 01/11/13 16:38, Paolo Aglialoro wrote:
>> ...
>>> Btw, how many are really using ed everyday, now in 2013? I believe I'm
>> not
>>> the only one who thinks this. My guess is that vi could be more
>> appreciated
>>> by most of the user base more than ed.
>> 
>> If you claim to be a unix administrator, learn ed.
> 
> Sorry, completely wrong. An unix admin use only vi not wordstar or ed.



Re: vi vs ed in bsd.rd - proposal

2013-01-11 Thread Otto Moerbeek
On Sat, Jan 12, 2013 at 07:39:27AM +0100, Paul de Weerd wrote:

> On Sat, Jan 12, 2013 at 01:34:44AM -0300, Carlo Borelli wrote:
> | > If you claim to be a unix administrator, learn ed.
> | >
> | 
> | Sorry, completely wrong. An unix admin use only vi not wordstar or ed.
> 
> You know vi but you don't know ed.  Right.  Know your software and its
> history - vi is ed with visual editing bolted on.  Once you recognize
> this, you'll have no problems at all dealing with ed.

slighty wrong. vi is *ex* plus visual editing.

But the advice remains. ed is a skil must know to call yourself a unix
admin. 

-Otto
> 
> I like how you try to put your opinion out as fact when the facts are
> against you.  Pretty funny ;)
> 
> Paul 'WEiRD' de Weerd
> 
> -- 
> >[<++>-]<+++.>+++[<-->-]<.>+++[<+
> +++>-]<.>++[<>-]<+.--.[-]
>  http://www.weirdnet.nl/ 



Re: vi vs ed in bsd.rd - proposal

2013-01-11 Thread Paul de Weerd
On Sat, Jan 12, 2013 at 01:34:44AM -0300, Carlo Borelli wrote:
| > If you claim to be a unix administrator, learn ed.
| >
| 
| Sorry, completely wrong. An unix admin use only vi not wordstar or ed.

You know vi but you don't know ed.  Right.  Know your software and its
history - vi is ed with visual editing bolted on.  Once you recognize
this, you'll have no problems at all dealing with ed.

I like how you try to put your opinion out as fact when the facts are
against you.  Pretty funny ;)

Paul 'WEiRD' de Weerd

-- 
>[<++>-]<+++.>+++[<-->-]<.>+++[<+
+++>-]<.>++[<>-]<+.--.[-]
 http://www.weirdnet.nl/ 



Re: vi vs ed in bsd.rd - proposal

2013-01-11 Thread Carlo Borelli
2013/1/12 Christopher Vance 

> You would fail any system administration course I teach.
>

I respect your opinion.
Are you a teacher and not teaching the basic ones? Proudly failing any
course you do.
What else?
Btw, Paolo Aglialoro +1

Registered Linux User #249354
"Ad astra per aspera"



Re: vi vs ed in bsd.rd - proposal

2013-01-11 Thread Carlo Borelli
2013/1/12 Nick Holland 

> On 01/11/13 16:38, Paolo Aglialoro wrote:
> ...
> > Btw, how many are really using ed everyday, now in 2013? I believe I'm
> not
> > the only one who thinks this. My guess is that vi could be more
> appreciated
> > by most of the user base more than ed.
>
> If you claim to be a unix administrator, learn ed.
>

Sorry, completely wrong. An unix admin use only vi not wordstar or ed.



Re: vi vs ed in bsd.rd - proposal

2013-01-11 Thread Nick Holland
On 01/11/13 16:38, Paolo Aglialoro wrote:
...
> Btw, how many are really using ed everyday, now in 2013? I believe I'm not
> the only one who thinks this. My guess is that vi could be more appreciated
> by most of the user base more than ed.

If you claim to be a unix administrator, learn ed.

If you have to bring up your OpenBSD or Solaris machine in single user
mode with an unavailable /usr (and thus, no dynamically linked apps),
you will be glad you know it.  It's an "always there" tool...it "just
works", and it ain't so bad if you spend 15 minutes to learn how it
works before you need it.

Nick.



ImageMagick and perl

2013-01-11 Thread Dmitrij D. Czarkoff
Hello!

I was trying to build a piece of software that uses Image::Magick, when I ran
into the following problem on amd64 -current:

  $ perl -e "use Image::Magick;"
  Can't load 
'/usr/local/libdata/perl5/site_perl/amd64-openbsd/auto/Image/Magick/Magick.so' 
for module Image::Magick: Cannot load specified object at 
/usr/libdata/perl5/amd64-openbsd/5.12.2/DynaLoader.pm line 200.
   at -e line 1
  Compilation failed in require at -e line 1.
  BEGIN failed--compilation aborted at -e line 1.
  &Image::Magick::constant not defined. The required ImageMagick libraries are 
not installed or not installed properly.
  END failed--call queue aborted at -e line 1.

On my another box (i386 5.2) I get another error:

  % perl -e "use Image::Magick;"
  perl:/usr/local/lib/libMagickCore.so.3.0: undefined symbol 
'pthread_mutexattr_init'
  lazy binding failed!
  zsh: segmentation fault (core dumped)  perl -e "use Image::Magick;"

Is there any way to use Image::Magick on OpenBSD? If no, why does it get
built?

-- 
Dmitrij D. Czarkoff



Re: Foxconn NanoPC nT-i1250 fails to boot after install

2013-01-11 Thread Stefan Sperling
On Fri, Jan 11, 2013 at 04:44:07PM -0800, Kent Fritz wrote:
> I dug a little deeper, and defined PCKBCDEBUG in
> /usr/src/sys/dev/ic/pckbc.c, and it spews:
> pckbc_cmd: lost 0xfc
> 
> Looking at pckbc_poll_cmd1, it looks like there's an infinite loop if
> it doesn't get back a response it expects.  What's best: specifically
> handling 0xfc, or erroring out on any unexpected response with
> "cmd->status = ENXIO; return;"?  (I did the former and it works for
> me.)

I see. So this is happening during pms_probe() which runs before the
protocol is selected. Maybe fix it like this? I think the code should
cope with hardware that returns unrecognizable garbage. But I don't
know very much about PS/2.

Thanks for pinning down the problem!

Index: pckbc.c
===
RCS file: /cvs/src/sys/dev/ic/pckbc.c,v
retrieving revision 1.31
diff -u -p -r1.31 pckbc.c
--- pckbc.c 17 Oct 2012 19:16:10 -  1.31
+++ pckbc.c 12 Jan 2013 01:25:41 -
@@ -620,6 +620,11 @@ pckbc_poll_cmd1(struct pckbc_internal *t
 #ifdef PCKBCDEBUG
printf("pckbc_cmd: lost 0x%x\n", c);
 #endif
+   /* Don't retry cmd forever. */
+   if (cmd->retries++ >= 5) {
+   cmd->status = EIO;
+   return;
+   }
}
 
while (cmd->responseidx < cmd->responselen) {



Re: Use pax instead of cpio in FAQ 14.4 (Adding extra disks)

2013-01-11 Thread Christian Weisgerber
Jeremy Evans  wrote:

> 1) Switch from cpio -pdum to pax -rw -p e.

Seems fine to me.

> I'm not sure if there are other reasons to use cpio over pax.

Nope.  On OpenBSD, tar/cpio/pax are all frontends to the same program
anyway.

> However, when I replaced I disk last night and tried to use cpio
> to copy partitions, I noticed that it didn't work on bsd.rd.

I tend to recommend dump|restore, but those aren't on bsd.rd.

> Thoughts/OKs?

ok

-- 
Christian "naddy" Weisgerber  na...@mips.inka.de



Re: Unused swap

2013-01-11 Thread Christian Weisgerber
Constantine A. Murenin  wrote:

> plus, last i checked, firefox was not even 64-bit friendly anyways

Bullshit.

-- 
Christian "naddy" Weisgerber  na...@mips.inka.de



Re: Foxconn NanoPC nT-i1250 fails to boot after install

2013-01-11 Thread Kent Fritz
I dug a little deeper, and defined PCKBCDEBUG in
/usr/src/sys/dev/ic/pckbc.c, and it spews:
pckbc_cmd: lost 0xfc

Looking at pckbc_poll_cmd1, it looks like there's an infinite loop if
it doesn't get back a response it expects.  What's best: specifically
handling 0xfc, or erroring out on any unexpected response with
"cmd->status = ENXIO; return;"?  (I did the former and it works for
me.)



Re: Unused swap

2013-01-11 Thread Constantine A. Murenin
http://www.openbsd.org/cgi-bin/cvsweb/src/etc/login.conf.in
http://www.openbsd.org/cgi-bin/cvsweb/src/etc/mklogin.conf
http://www.openbsd.org/cgi-bin/man.cgi?query=login.conf&sektion=5

plus, last i checked, firefox was not even 64-bit friendly anyways

C.

On 11 January 2013 15:28, Lars von den Driesch
 wrote:
> Hi
> I just discovered another strangeness on my installation. Firefox
> keeps seg-faulting on me when I have a lot of tabs open with webpages
> that draw a lot of memory. This is easy to reproduce - I just open
> engadget.com more often and open subsites by clicking randomly on that
> page.
> When I start firefox from xterm it gives me an "out of memory" error
> after a while and writes a core file to disk. This led me looking to
> my swap partition when I discovered that swap seems to be unused on
> this system although it exists and the system seems to know about it.
> It just isn't filled when needed.
> This is a snapshot on amd64 from 7 Jan. The partitions  were created
> during initial install. So this might have been a problem from the
> beginning but I discovered it now because I am using the system more
> often lately.
> I have found an ancient bugreport from 1999 for sparc/1007 reporting
> exactly this but this is basically the only thing I found about this
> topic. So I believe I am missing something obvious again that only me
> would be able to fall over ;-)
>
> Thanks
> Lars
>
> -swapctl -l this display never changes
> Device  512-blocks UsedAvail Capacity  Priority
> /dev/sd0b  93740810  9374081 0%0
>
>
> -systat swap gives me this but this display never ever changes
> 5 usersLoad 0.13 0.16 0.47 Sat Jan 12 00:03:07 2013
> DISK 512-blocks   USED  10\ 20\ 30\
> 40\ 50\ 60\ 70\ 80\ 90\100\
> sd0b9374081  0
>
> -disklabel /dev/sd0c
> #size   offset  fstype [fsize bsize  cpg]
>   a:615763200   64  4.2BSD   4096 327681 # /
>   b:  9374081615763264swap   # none
>
> -fstab
> c6dfab3c9cca1a9c.b none swap sw
> c6dfab3c9cca1a9c.a / ffs rw 1 1
>
> -dmesg
> OpenBSD 5.2-current (GENERIC.MP) #12: Mon Jan  7 07:59:56 MST 2013
> dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP
> real mem = 4157472768 (3964MB)
> avail mem = 4024295424 (3837MB)
> mainbus0 at root
> bios0 at mainbus0: SMBIOS rev. 2.4 @ 0xf0100 (57 entries)
> bios0: vendor Award Software International, Inc. version "F11" date 09/16/2009
> bios0: Gigabyte Technology Co., Ltd. GA-MA78GM-S2H
> acpi0 at bios0: rev 0
> acpi0: sleep states S0 S3 S4 S5
> acpi0: tables DSDT FACP SSDT HPET MCFG APIC
> acpi0: wakeup devices USB0(S3) USB1(S3) USB2(S3) USB3(S3) USB4(S3)
> USB5(S3) USB6(S3) SBAZ(S4) P2P_(S5) PCE2(S4) PCE3(S4) PCE4(S4)
> PCE5(S4) PCE6(S4) PCE7(S4) PCE9(S4) PCEA(S4) PCEB(S4) PCEC(S4)
> PS2M(S5) PS2K(S5) PCI0(S5)
> acpitimer0 at acpi0: 3579545 Hz, 32 bits
> acpihpet0 at acpi0: 14318180 Hz
> acpimcfg0 at acpi0 addr 0xe000, bus 0-255
> acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
> cpu0 at mainbus0: apid 0 (boot processor)
> cpu0: AMD Athlon(tm) Dual Core Processor 4850e, 2511.77 MHz
> cpu0: 
> FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16,NXE,MMXX,FFXSR,LONG,3DNOW2,3DNOW,LAHF,CMPLEG,SVM,EAPICSP,AMCR8,3DNOWP
> cpu0: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB
> 64b/line 16-way L2 cache
> cpu0: ITLB 32 4KB entries fully associative, 8 4MB entries fully associative
> cpu0: DTLB 32 4KB entries fully associative, 8 4MB entries fully associative
> cpu0: apic clock running at 200MHz
> cpu1 at mainbus0: apid 1 (application processor)
> cpu1: AMD Athlon(tm) Dual Core Processor 4850e, 2511.44 MHz
> cpu1: 
> FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16,NXE,MMXX,FFXSR,LONG,3DNOW2,3DNOW,LAHF,CMPLEG,SVM,EAPICSP,AMCR8,3DNOWP
> cpu1: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB
> 64b/line 16-way L2 cache
> cpu1: ITLB 32 4KB entries fully associative, 8 4MB entries fully associative
> cpu1: DTLB 32 4KB entries fully associative, 8 4MB entries fully associative
> ioapic0 at mainbus0: apid 2 pa 0xfec0, version 21, 24 pins
> ioapic0: misconfigured as apic 0, remapped to apid 2
> acpiprt0 at acpi0: bus 0 (PCI0)
> acpiprt1 at acpi0: bus 3 (P2P_)
> acpiprt2 at acpi0: bus -1 (PCE2)
> acpiprt3 at acpi0: bus -1 (PCE3)
> acpiprt4 at acpi0: bus -1 (PCE4)
> acpiprt5 at acpi0: bus -1 (PCE5)
> acpiprt6 at acpi0: bus -1 (PCE6)
> acpiprt7 at acpi0: bus -1 (PCE7)
> acpiprt8 at acpi0: bus -1 (PCE9)
> acpiprt9 at acpi0: bus 2 (PCEA)
> acpiprt10 at acpi0: bus -1 (PCEB)
> acpiprt11 at acpi0: bus -1 (PCEC)
> acpiprt12 at acpi0: bus 1 (AGP_)
> acpicpu0 at acpi0: PSS
> acpicpu1 at acpi0: PSS
> acpibtn0 at acpi0: PWRB
> cpu0: PowerNow! K8 2511 MHz: speeds: 2500

Re: Unused swap

2013-01-11 Thread Lars von den Driesch
Hi again,

I just followed the FAQ 14.5.3 and created a swap file and added it to
the system. Unfortunately this didn't help.

Thanks again

Lars

On Sat, Jan 12, 2013 at 12:28 AM, Lars von den Driesch
 wrote:
> Hi
> I just discovered another strangeness on my installation. Firefox
> keeps seg-faulting on me when I have a lot of tabs open with webpages
> that draw a lot of memory. This is easy to reproduce - I just open
> engadget.com more often and open subsites by clicking randomly on that
> page.
> When I start firefox from xterm it gives me an "out of memory" error
> after a while and writes a core file to disk. This led me looking to
> my swap partition when I discovered that swap seems to be unused on
> this system although it exists and the system seems to know about it.
> It just isn't filled when needed.
> This is a snapshot on amd64 from 7 Jan. The partitions  were created
> during initial install. So this might have been a problem from the
> beginning but I discovered it now because I am using the system more
> often lately.
> I have found an ancient bugreport from 1999 for sparc/1007 reporting
> exactly this but this is basically the only thing I found about this
> topic. So I believe I am missing something obvious again that only me
> would be able to fall over ;-)
>
> Thanks
> Lars
>
> -swapctl -l this display never changes
> Device  512-blocks UsedAvail Capacity  Priority
> /dev/sd0b  93740810  9374081 0%0
>
>
> -systat swap gives me this but this display never ever changes
> 5 usersLoad 0.13 0.16 0.47 Sat Jan 12 00:03:07 2013
> DISK 512-blocks   USED  10\ 20\ 30\
> 40\ 50\ 60\ 70\ 80\ 90\100\
> sd0b9374081  0
>
> -disklabel /dev/sd0c
> #size   offset  fstype [fsize bsize  cpg]
>   a:615763200   64  4.2BSD   4096 327681 # /
>   b:  9374081615763264swap   # none
>
> -fstab
> c6dfab3c9cca1a9c.b none swap sw
> c6dfab3c9cca1a9c.a / ffs rw 1 1
>
> -dmesg
> OpenBSD 5.2-current (GENERIC.MP) #12: Mon Jan  7 07:59:56 MST 2013
> dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP
> real mem = 4157472768 (3964MB)
> avail mem = 4024295424 (3837MB)
> mainbus0 at root
> bios0 at mainbus0: SMBIOS rev. 2.4 @ 0xf0100 (57 entries)
> bios0: vendor Award Software International, Inc. version "F11" date 09/16/2009
> bios0: Gigabyte Technology Co., Ltd. GA-MA78GM-S2H
> acpi0 at bios0: rev 0
> acpi0: sleep states S0 S3 S4 S5
> acpi0: tables DSDT FACP SSDT HPET MCFG APIC
> acpi0: wakeup devices USB0(S3) USB1(S3) USB2(S3) USB3(S3) USB4(S3)
> USB5(S3) USB6(S3) SBAZ(S4) P2P_(S5) PCE2(S4) PCE3(S4) PCE4(S4)
> PCE5(S4) PCE6(S4) PCE7(S4) PCE9(S4) PCEA(S4) PCEB(S4) PCEC(S4)
> PS2M(S5) PS2K(S5) PCI0(S5)
> acpitimer0 at acpi0: 3579545 Hz, 32 bits
> acpihpet0 at acpi0: 14318180 Hz
> acpimcfg0 at acpi0 addr 0xe000, bus 0-255
> acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
> cpu0 at mainbus0: apid 0 (boot processor)
> cpu0: AMD Athlon(tm) Dual Core Processor 4850e, 2511.77 MHz
> cpu0: 
> FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16,NXE,MMXX,FFXSR,LONG,3DNOW2,3DNOW,LAHF,CMPLEG,SVM,EAPICSP,AMCR8,3DNOWP
> cpu0: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB
> 64b/line 16-way L2 cache
> cpu0: ITLB 32 4KB entries fully associative, 8 4MB entries fully associative
> cpu0: DTLB 32 4KB entries fully associative, 8 4MB entries fully associative
> cpu0: apic clock running at 200MHz
> cpu1 at mainbus0: apid 1 (application processor)
> cpu1: AMD Athlon(tm) Dual Core Processor 4850e, 2511.44 MHz
> cpu1: 
> FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,CX16,NXE,MMXX,FFXSR,LONG,3DNOW2,3DNOW,LAHF,CMPLEG,SVM,EAPICSP,AMCR8,3DNOWP
> cpu1: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB
> 64b/line 16-way L2 cache
> cpu1: ITLB 32 4KB entries fully associative, 8 4MB entries fully associative
> cpu1: DTLB 32 4KB entries fully associative, 8 4MB entries fully associative
> ioapic0 at mainbus0: apid 2 pa 0xfec0, version 21, 24 pins
> ioapic0: misconfigured as apic 0, remapped to apid 2
> acpiprt0 at acpi0: bus 0 (PCI0)
> acpiprt1 at acpi0: bus 3 (P2P_)
> acpiprt2 at acpi0: bus -1 (PCE2)
> acpiprt3 at acpi0: bus -1 (PCE3)
> acpiprt4 at acpi0: bus -1 (PCE4)
> acpiprt5 at acpi0: bus -1 (PCE5)
> acpiprt6 at acpi0: bus -1 (PCE6)
> acpiprt7 at acpi0: bus -1 (PCE7)
> acpiprt8 at acpi0: bus -1 (PCE9)
> acpiprt9 at acpi0: bus 2 (PCEA)
> acpiprt10 at acpi0: bus -1 (PCEB)
> acpiprt11 at acpi0: bus -1 (PCEC)
> acpiprt12 at acpi0: bus 1 (AGP_)
> acpicpu0 at acpi0: PSS
> acpicpu1 at acpi0: PSS
> acpibtn0 at acpi0: PWRB
> cpu0: PowerNow! K8 2511 MHz: speeds: 2500 2400 2200 2000 1800 1000 MHz
> pci0 at mainbus0 bus 0
> 0:0:0: mem address conflict 0xe000/0x2

Re: vi vs ed in bsd.rd - proposal

2013-01-11 Thread Miod Vallat
> The only editing available tool in bsd.rd, the infamous ed, made me sweat
> cold with fear not to correctly spell its syntax or do some logic mistake.
> I would have been way more lighthearted if I had vi available.

Actually, vi used to be in the installation media, 15 years ago. Lack of
space caused it to be removed, although for unconstrained installation
media (i.e. bsd.rd or anything which does not need to fit on a floppy)
it might be worth bring it back.

> Btw, how many are really using ed everyday, now in 2013?

I am using ed, maybe not every day, but several times a week. And I use
it a lot when in the OpenBSD installer, to do some post-install setup
everytime I have completed an installation (this is because I am too
lazy to setup a siteXX.tgz tarball).

>  I believe I'm not
> the only one who thinks this. My guess is that vi could be more appreciated
> by most of the user base more than ed.

But ed is the standard text editor. This is the only editor noone will
complain about. If we start putting vi back on the installation media,
it won't be long until people complain about the lack of an
emacs-compatible editor.

>   This is the raw situation:
> 
> /usr/bin/vi = 343320 bytes
> /bin/ed = 238864 bytes
> delta = 104456 bytes
> 
> 100K of executable, when compressed, wouldn't be "that" much in terms of
> difference,

Except your figures are wrong. What you need to check is the output of
size(1) on both binaries, and after relinking vi as a static binary,
since ed is statically linked while vi is not.

Now on a random system here (admittedly not an x86 one), I get:
textdatabss dec hex
177074  743696252   280762  448ba   /bin/ed
740510  755630772   778838  be256   /usr/bin/vi.static

which is closer to 500KB of delta. A third of floppy52.fs.

Miod



vi vs ed in bsd.rd - proposal

2013-01-11 Thread Paolo Aglialoro
Hello misc,

there were recently some comments about customizing bsd.rd contents and
making one of own's choice/taste. This reminded me about an unpleasant
situation in which I found myself kinda 2 years ago:

sparc64 machine, a neglected typo in fstab while changing a disk mountpoint
and boom! - no boot :(

This machine was in a server room (where there was no quick possibility to
setup a rarpd server to netboot bsd.rd, thing which would therefore
especially apply for a customized one) and so the only solution was to use
an install CD and its console.

The only editing available tool in bsd.rd, the infamous ed, made me sweat
cold with fear not to correctly spell its syntax or do some logic mistake.
I would have been way more lighthearted if I had vi available.

Btw, how many are really using ed everyday, now in 2013? I believe I'm not
the only one who thinks this. My guess is that vi could be more appreciated
by most of the user base more than ed.

So, today, for the sake of curiosity I sshd that machine (now updated to
5.2) and examined/usr/src/distrib/sparc64/bsd.rd/list in order to look for
"space" (e.g. some similar commands, but failed to, also more and less are
the same file) to fit vi. This is the raw situation:

/usr/bin/vi = 343320 bytes
/bin/ed = 238864 bytes
delta = 104456 bytes

100K of executable, when compressed, wouldn't be "that" much in terms of
difference, but would have an enormous impact on user-friendlyness and
flexibility of editing (funny, I never thought I would have called vi
user-friendly! Anyway, compared to ed, also old DOS edlin was).

So basically my proposal would be substituting ed with vi.

My alternative proposal would be only adding vi just for sparc64, after
all, how many sparc64 boxes do nowadays boot from a floppy disk? Most of
them don't have one at all, and the ones who do, also feature a CD-ROM
drive.

Thanks for your feedback!



Re: integrated graphics

2013-01-11 Thread Chris Cappuccio
Zoran Kolic [zko...@sbb.rs] wrote:
> 
> Yeah, I like amd better. On desktop it is 8120 bulldozer. And I
> like it.
> 
> I might bother gentle readers, but have no clue what to buy and
> stay alive. I need exact processor name. So, if someone has amd
> or intel, integrated, wirking on amd64 5.2, please say the name
> of it and I will get the same one.
> Best regards
> 

The core i3-3225 is ivy bridge based, which means the graphics only works under 
-current and no DRM acceleration until the driver support improves. But, it is 
a very fast chip, and very low power. No graphics card to heat up, and when KMS 
support works, it will be quite fast (if you care about DRM). I don't think the 
newer radeon stuff is DRM accelerated either, so I'd go with the fast, low 
power shit myself...



Re: Running OpenBSD on Raspberry Pi

2013-01-11 Thread Patrick Wildt
Hello,

I'm currently working on porting OpenBSD to the Freescale i.MX6, an ARM
Cortex-A9 (1-4 cores).
It is already supporting USB and SDMMC, works like a charm.
The i.MX6 itself got some interesting features like PCIe, SATA and Gigabit
Ethernet.

So, if 200$ don't sound too much, that might be an alternative.

\Patrick

http://boundarydevices.com/products/sabre-lite-imx6-sbc/
http://boundarydevices.com/products/nitrogen6x-board-imx6-arm-cortex-a9-sbc/

Am 09.01.2013 um 20:21 schrieb Gene :

> On Wed, Jan 9, 2013 at 10:54 AM, Andres Genovez 
wrote:
>> 2012/12/31 BARDOU Pierre 
>>
>>> Hello,
>>>
>>> I would be very interested by an OpenBSD port too.
>>> Usage : home router with firewall, DNS and DHCP.
>>>
>>> I am looking into FreeBSD and NetBSD ports, but I would prefer to have
the
>>> latest PF and OpenSSH versions... plus I am more used to OpenBSD and I
like
>>> using it :-)
>>>
>>> If somebody knows X86 hardware able to do the same (routing/firewlling 20
>>> mbps traffic, VLAN, fits in a tiny box, power consumption below 5W, price
>>> around 50$) as the raspberry I am interested BTW.
>>>
>> I am interested too, can somebody give an advice on what hardware to use?
>> maybe 5 lan or at least two lan? an below 100?
>>
>
> For under $100 USD your best bet is to look for a used computer on
> craigslist or a yard sale and install another NIC in it.  But, this
> will not get you at 5 watts or less.
>
> For under $200 look at either PC Engines ALIX boards or Soekris.  eBay
> has plenty of them.  You can manage 5W or less this route.
>
> For the Raspberry Pi you will not get OpenBSD.  You will have to use
> Linux and configure it manually, including recompiling the kernel with
> iptables support.  You *might* be able to get under $100, but it won't
> be under 5 watts and it will be a jalopy.  USB ethernet adapters start
> around $25 new.
>
> -Gene



Use pax instead of cpio in FAQ 14.4 (Adding extra disks)

2013-01-11 Thread Jeremy Evans
Two changes:

1) Switch from cpio -pdum to pax -rw -p e.  cpio -pdum requires
find which isn't available on bsd.rd, while pax -rw -p e works
fine on bsd.rd.

2) Use a more complete example.

I'm not sure if there are other reasons to use cpio over pax.
However, when I replaced I disk last night and tried to use cpio
to copy partitions, I noticed that it didn't work on bsd.rd.

Thoughts/OKs?

Jeremy

Index: faq14.html
===
RCS file: /cvs/www/faq/faq14.html,v
retrieving revision 1.202
diff -u -p -r1.202 faq14.html
--- faq14.html  19 May 2010 12:41:02 -  1.202
+++ faq14.html  11 Jan 2013 20:19:16 -
@@ -638,8 +638,14 @@ Finally, add it to
 
 
 What if you need to migrate an existing directory like /usr/local? You
-should mount the new drive in /mnt and use cpio -pdum to copy 
/usr/local
-to the /mnt directory.  Edit the
+should mount the new drive in /mnt and copy /usr/local to the /mnt directory.
+Example:
+
+
+# cd /usr/local && pax -rw -p e . /mnt
+
+
+Edit the
 http://www.openbsd.org/cgi-bin/man.cgi?query=fstab&sektion=5";>/etc/fstab(5)
 file to show that the /usr/local partition is now /dev/sd2d (your
 freshly formatted partition). Example:



Re: Foxconn NanoPC nT-i1250 fails to boot after install

2013-01-11 Thread Kenneth R Westerback
On Fri, Jan 11, 2013 at 01:16:53PM +0100, Martin Pieuchot wrote:
> On 10/01/13(Thu) 14:08, Kent Fritz wrote:
> > On Thu, Jan 10, 2013 at 9:26 AM, Stefan Sperling  wrote:
> > > Can you please try to find out which protocol probe routine is
> > > responsible for hanging the machine?
> > >
> > None of them.  I tried as you suggested, then just #if'd  out every
> > entry in that structure.  No change in behavior.
> > 
> > (BTW: First time compiling my own kernel.  The FAQ rocks!)
> 
> Do you have any "usb legacy" option or similar turned on in your bios?
> If yes you can try to turn it off.
> 
> M.
> 

It was "USB Legacy Storage" on one of my machines. If this was on, then
booting hung in the BIOS if a USB disk was plugged in and then the boot
was attempted.

 Ken



Re: integrated graphics

2013-01-11 Thread Zoran Kolic
> Sadly right now Intel is going to be the best if you are going to use 
> the integrated graphics. Intel graphics tend to be better supported than 
> AMD (ATI).

I already have freebsd desktop and laptop. I want to get small
box, to put it in a corner, left in my room and play with it.
The only small case available here is chieftec bt-02b-180.
There is not much space inside. So, integrated.
On the laptop I type this I have:
CPU: Intel(R) Core(TM) i3-2350M CPU @ 2.30GHz (2294.84-MHz K8-class CPU)
Graphics works with kms. Once it is up, I cannot go back to
console. No biggie for now.
What I want to ask is: what intel cpu in fact? I'm not familiar
with the topic. Would be perfect if I might go with g550 or si-
milar cheap one. i3-2120 is over 100 euros here. Add mobo and
you see how it goes.
>From earlier posts I was sure something like a4-3300 plus a55m
motherboard would suffice. Am I wrong?

> Now if you have no concern for the integrated GPU and plan on using a 
> GPU that is supported I always say AMD. More performance for the price 
> and to me seems more stable under multithreaded load.

Yeah, I like amd better. On desktop it is 8120 bulldozer. And I
like it.

I might bother gentle readers, but have no clue what to buy and
stay alive. I need exact processor name. So, if someone has amd
or intel, integrated, wirking on amd64 5.2, please say the name
of it and I will get the same one.
Best regards

Zoran



Re: integrated graphics

2013-01-11 Thread Jason Barbier

On 1/10/2013 7:15 AM, Zoran Kolic wrote:

I found it too hard to find proper laptop for sane sum
of green papers, to run openbsd amd64.
In a haze of quest, I set my eyes on two lovely comp
cases:
chieftec bt-02b-180
silverstone sg05
Digested question would be: what integrated cpu works
on 5.2 amd64? Better to go after intel or amd? There
are posts of both sandybridge and amd fusion with gra-
phics working. I will get the lower end of one this
list recommends as a choice. If amd, probably fm1
socket, asus with realtek 8111 e/f ethernet.
Simple: what cpu?

  Zoran



Sadly right now Intel is going to be the best if you are going to use 
the integrated graphics. Intel graphics tend to be better supported than 
AMD (ATI). That may change here in the next few generations as AMD 
abandons UMS for KMS but if you want to make sure you'll get your full 
resolution Intel.


Now if you have no concern for the integrated GPU and plan on using a 
GPU that is supported I always say AMD. More performance for the price 
and to me seems more stable under multithreaded load.


--
Jason Barbier



Re: msi_delroute() panic

2013-01-11 Thread Jim Miller
I can try.  Theo also sent me some ideas to try which involved cutting
out PCI Express hotplug support from

sys/dev/pci/ppb.c

Do you have reason to believe this has been fixed?

-Jim

On 1/11/13 8:25 AM, Sebastian Benoit wrote:
> Jim Miller(jmil...@sri-inc.com) on 2013.01.09 15:20:03 -0500:
>> Hi All,
>>
>> I saw a previous post back in late December where someone was discussing
>> a random panic() related to msi_delroute().  I'm having the same problem
>> I believe on a OpenBSD 5.1 box.  The panic manifests itself about every
>> week but no I can't find any specific event that is the cause.  It
>> appears related to the em driver thinking it is being removed.  Any
>> ideas or suggestions on how to debug this further?
> Can you reproduce it with a -current snapshot?
>
> /Benno
>
>> ddb{2}> trace
>> Debugger() at Debugger+0x5
>> panic() at panic+0xe4
>> msi_delroute() at msi_delroute+0x54
>> intr_disestablish() at intr_disestablish+0xe9
>> em_detach() at em_detach+0x26
>> config_detach() at config_detach+0x143
>> config_detach_children() at config_detach_children+0x3e
>> pci_detach_devices() at pci_detach_devices+0x15
>> ppb_hotplug_remove() at ppb_hotplug_remove+0x26
>> workq_thread() at workq_thread+0x33
>> end trace frame: 0x0, count: -10
>>
>> ddb{2}> show panic
>> msi_delroute: no msi capability
>>
>> ddb{2}> machine ddbcpu 1
>> Stopped at  Debugger+0x5:   leave
>> RUN AT LEAST 'trace' AND 'ps' AND INCLUDE OUTPUT WHEN REPORTING THIS PANIC!
>> IF RUNNING SMP, USE 'mach ddbcpu <#>' AND 'trace' ON OTHER PROCESSORS, TOO.
>> DO NOT EVEN BOTHER REPORTING THIS WITHOUT INCLUDING THAT INFORMATION!
>>
>> ddb{1}> ps
>>PID   PPID   PGRPUID  S   FLAGS  WAIT  COMMAND
>>   7473  31910   7473  0  30x80  ttyin bash
>>  21722  31910  21722  0  30x80  ttyin bash
>>  31910  1  31910  0  30x80  selectscreen
>>   5621  1   5621  0  30x80  ttyin getty
>>   6818  1   6818  0  30x80  selectsendmail
>>  27397  1  27397  0  30x80  ttyin getty
>>  18642  1  18642  0  30x80  ttyin getty
>>  20939  1  20939  0  30x80  ttyin getty
>>  19043  1  19043  0  30x80  ttyin getty
>>  22270  1  22270  0  30x80  ttyin getty
>>  13738  1  13738  0  30x80  selectcron
>>  17462  1  17462 99  30x80  poll  sndiod
>>  25578  1  25578  0  30x80  selectsshd
>>   3068   6655   6655 68  30x80  selectsasyncd
>>   6655  1   6655  0  30x80  selectsasyncd
>>  8   4076   4076 68  30x80  selectisakmpd
>>   4076  1   4076  0  30x80  netio isakmpd
>>  16603  1  16603  0  30x80  poll  ntpd
>>   9965  14530   9965 83  30x80  poll  ntpd
>>  14530  1  14530 83  30x80  poll  ntpd
>>  28104   8325   8325 70  30x80  selectnamed
>>   8325  1   8325  0  30x80  netio named
>>   5060  11080  11080 74  30x80  bpf   pflogd
>>  11080  1  11080  0  30x80  netio pflogd
>>  27911  10551  10551 73  30x80  poll  syslogd
>>  10551  1  10551  0  30x80  netio syslogd
>> 16  0  0  0  30x100200  aiodoned  aiodoned
>> 15  0  0  0  30x100200  syncerupdate
>> 14  0  0  0  30x100200  cleaner   cleaner
>> 13  0  0  0  30x100200  reaperreaper
>> 12  0  0  0  30x100200  pgdaemon  pagedaemon
>> 11  0  0  0  30x100200  bored crypto
>> 10  0  0  0  30x100200  pftm  pfpurge
>>  9  0  0  0  30x100200  usbtskusbtask
>>  8  0  0  0  30x100200  usbatsk   usbatsk
>>  7  0  0  0  30x100200  acpi0 acpi0
>>  6  0  0  0  7  0x40100200idle3
>>  5  0  0  0  3  0x40100200idle2
>> *4  0  0  0  7  0x40100200idle1
>>  3  0  0  0  70x100200syswq
>>  2  0  0  0  7  0x40100200idle0
>>  1  0  1  0  30x80  wait  init
>>  0 -1  0  0  3   0x200  scheduler swapper
>>
>> ddb{1}> machine ddbcpu 2
>> Stopped at  Debugger+0x5:   leave
>> RUN AT LEAST 'trace' AND 'ps' AND INCLUDE OUTPUT WHEN REPORTING THIS PANIC!
>> IF RUNNING SMP, USE 'mach ddbcpu <#>' AND 'trace' ON OTHER PROCESSORS, TOO.
>> DO NOT EVEN BOTHER REPORTING THIS WITHOUT INCLUDING THAT INFORMATION!
>>
>> ddb{2}> trace
>> Debugger() at Debugger+0x5
>> panic() at panic+0

Re: new computer

2013-01-11 Thread john slee
On 10 January 2013 22:21, Matt Morrow  wrote:

> You do realize the typical life of a battery is about a year?


Poppycock.

My FondletopPro battery still gives damn close to the performance
it gave new in early 2011. The battery in my Fondleslab 3GS is
near 4 years now and hasn't degraded that much either. Same
again for my Dell Latitude corporate drone unit.

If so many folks here are recommending Thinkpads, it's probably
because (a) they are (or at least used to be) very well engineered
laptops, and (b) shit works, yo.

John



Re: PF filtering on MAC address

2013-01-11 Thread Alexey E. Suslikov
Erling Westenvik  gmail.com> writes:

> 
> Is it possible to have PF filter on MAC address on a machine with only
> one physical nic? I'm aware that MAC filtering can only be done on a
> machine configured as a bridge, but how to configure such a bridge?

afaik, bridge(4) mac filtering only affects bridge forwarding.

I think you can cook something using a bridge with a vether(4)
as bridge member.

Cheers,
Alexey



Re: Foxconn NanoPC nT-i1250 fails to boot after install

2013-01-11 Thread Martin Pieuchot
On 10/01/13(Thu) 14:08, Kent Fritz wrote:
> On Thu, Jan 10, 2013 at 9:26 AM, Stefan Sperling  wrote:
> > Can you please try to find out which protocol probe routine is
> > responsible for hanging the machine?
> >
> None of them.  I tried as you suggested, then just #if'd  out every
> entry in that structure.  No change in behavior.
> 
> (BTW: First time compiling my own kernel.  The FAQ rocks!)

Do you have any "usb legacy" option or similar turned on in your bios?
If yes you can try to turn it off.

M.