doscmd under FreeBSD 4.0 20000214-SNAP

2000-03-08 Thread Alexey N. Dokuchaev

Hi!

There's a problem.  I'm trying to run ${SUBJ} unsing MSDOS 6.22 bootable
diskette, with .doscmdrc file from man doscmd(1).  That's what I get:

Unknown interrupt 15 function 4101
Unknown interrupt 15 function 8796
doscmd: fatal error int16 func 0x1 only supported in X mode

If I try to run 'doscmd -r', I get:

mmap: Invalid argument

Any ideas?  I have no X installed, btw.  I'll try MSDOS 6.0, but I don't
think version really matters at this early stage :-(

P.S.  and what happened to that "VM86" option in kernel?



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



RE: Sysinstall 'A'uto partitioning

2000-03-08 Thread Koster, K.J.

 
 I was actually planning a near-complete rewrite of sysinstall 
 anyway!  How
 about everyone throwing in whatever suggestions you would like ( about
 anything regarding sysinstall ), and I will try to incorporate them!?
 
Well, I've been toying with ideas on how to integrate the disklabel and the
filesystem item. Now you have to allocate FreeBSD space first, and partition
it later. If (like me) you're working with several disks, this is a pain.
You are bound to have to switch back and forth.

For complete newbies, having "two formatting menus" seems weird too, and may
be confusing. (I'm quoting one of my housemates).

How about turning away from the raw hardware view a little bit (but no too
much) and work like you would do on the piece of scrap paper you use while
running sysinstall:

"hum, I need 35Mb for /, let's see where there's room. Ah, I can place it on
da0s1a." partion tables update and slices get created "Good, now I need
2x64Mb swap, one on da0s1b, and one on da1s1b", etc...

I find it a little hard to put into words, but if anyone is interested I can
clean up my idea and clarify it.

Also, I'd really love to be able to configure ccd stripe sets from
sysinstall, but I would not be surprised if that was too much to ask. :)

Kees Jan

==
 You are only young once,
  but you can stay immature all your life


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



rtld breakage still in -stable, or is it me?

2000-03-08 Thread Niall Smart

Hi

A few days ago I upgraded by system to -stable from 3.2-RELEASE and
several
programs which use dlopen stopped working, most notably mod_perl.  For
example:

# apachectl start
[Wed Mar  8 10:19:35 2000] [error] Can't load
'/usr/local/lib/perl5/site_perl/5.005/i386-freebsd/auto/Time/HiRes/HiRes.so'
for module Time::HiRes:
/usr/local/lib/perl5/site_perl/5.005/i386-freebsd/auto/Time/HiRes/HiRes.so:
Undefined symbol "PL_stack_max" at
/usr/libdata/perl/5.00503/DynaLoader.pm line 169.

 at /usr/local/lib/perl5/site_perl/5.005/HTML/Mason/Interp.pm line 25
BEGIN failed--compilation aborted at
/usr/local/lib/perl5/site_perl/5.005/HTML/Mason.pm line 9.
BEGIN failed--compilation aborted at /usr/local/web/mason/handler.pl
line 3.

Syntax error on line 1204 of /usr/local/apache-1.3/conf/httpd.conf:
Can't load
'/usr/local/lib/perl5/site_perl/5.005/i386-freebsd/auto/Time/HiRes/HiRes.so'
for module Time::HiRes:
/usr/local/lib/perl5/site_perl/5.005/i386-freebsd/auto/Time/HiRes/HiRes.so:
Undefined symbol "PL_stack_max" at
/usr/libdata/perl/5.00503/DynaLoader.pm line 169.

 at /usr/local/lib/perl5/site_perl/5.005/HTML/Mason/Interp.pm line 25
BEGIN failed--compilation aborted at
/usr/local/lib/perl5/site_perl/5.005/HTML/Mason.pm line 9.
BEGIN failed--compilation aborted at /usr/local/web/mason/handler.pl
line 3.

/usr/local/apache-1.3/bin/apachectl start: httpd could not be started

Furthermore:

niall% nm /usr/lib/libperl.so | grep PL_stack_max
00090630 B PL_stack_max

The Time::HiRes module loads fine when I invoke perl from the command
line.
It appears I amn't the only one having this problem:

http://x42.deja.com/getdoc.xp?AN=582680524
http://x30.deja.com/getdoc.xp?AN=591070824
http://x31.deja.com/getdoc.xp?AN=573655265
http://x31.deja.com/getdoc.xp?AN=565253105

A recompile of apache etc did not solve the problem, neither did a
make world yesterday  Any hints?

Regards,

Niall


--
Niall Smart

email:  [EMAIL PROTECTED]
phone:  (087) 8052390


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Jordan K. Hubbard

 For complete newbies, having "two formatting menus" seems weird too, and may
 be confusing. (I'm quoting one of my housemates).

For complete newbies, you really only want to ask one question up-front:

"Do you want to use all available disk space for FreeBSD?"

If the answer is yes, you go do the rest on their behalf without
asking anything more than, perhaps, what kind of installation they
want (desktop, server, etc).  If the answer is no, then you get into
the more detailed questions.

- Jordan


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: ijppp for isdn, ppp compression, and netgraph (also: load balancing)

2000-03-08 Thread Hellmuth Michaelis


(CC: stripped)

From the keyboard of Archie Cobbs:

 Here is my list of things that 'should be done' at some point:
 
   1. Implement the various PPP compression types as netgraph nodes,
  starting with Deflate, then maybe predictor-1, STAC (if we can
  do it legally), and MPPC (same thing).

Sounds good. The link in the original mail points to a Linux (GPL)
implementation of the STAC compression. Since i was under the impression
that STAC is patented, i've contacted the author about this and it seems
that STAC either did not notice his implementation, does not care about
it, or that it is legal to reimplement it here in Germany or Europe.

Perhaps it might be possible to use this somehow, or at least provide
hooks to use it ...

   2. We should come up with a 'standard' netgraph control message
  API for an ISDN basic rate interface, and have i4b implement
  this interface.  Then mpd/ppp/etc can "know" this interface
  and therefore work automatically with any ISDN BRI device.
  Here is the interface that we use at Whistle:
ftp://ftp.whistle.com/pub/archie/netgraph/ng_tn.h
  (note: the switch types are #defined in another file but include
  all of the usual suspects: ETSI, NI-1, ATT, DMS100, etc.)

The problem here is, that the Whistle ISDN stack has a fundamentally
different view of the world than i4b has :-) As far as i understood it,
the Whistle ISDN stack is almost completely configurable by using 
netgraph messages whereas i4b is configured by its isdnd config file.

I have made some experiments with mppd over the i4b netgraph b-channel
interface and it works beautifully here without any additional 
configuration messages necessary. But i have no idea, if the real world
demands some control messages, such as dial, dial a number, hangup etc.

Any ideas how to proceed with this ?

hellmuth
-- 
Hellmuth MichaelisTel   +49 40 55 97 47-70
HCS Hanseatischer Computerservice GmbHFax   +49 40 55 97 47-77
Oldesloer Strasse 97-99   Mail  hm [at] hcs.de
D-22457 Hamburg   WWW   http://www.hcs.de


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Block out PING.

2000-03-08 Thread Kasper

Is there any way to stop the machine to answer on ping, so that my machine
doenst answer on any ping? My server has been ping attacked a few times.

./Kasper



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



RE: Sysinstall 'A'uto partitioning

2000-03-08 Thread Koster, K.J.

 
 "Do you want to use all available disk space for
 FreeBSD?"

For complete newbies this is indeed better than my suggestion.
 
For the level above that (and I count myself here) a merged menu might just
be more user friendly.

Kees Jan

==
 You are only young once,
  but you can stay immature all your life


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Jordan K. Hubbard

 For the level above that (and I count myself here) a merged menu might just
 be more user friendly.

And I don't disagree.  The only thing which prevented me from merging
them to begin with was the fact that dialog/curses represent an
insufficiently advanced UI technology for taking adequate advantage of
the available screen real-estate.  No scrolling list boxes and such
make it necessary to simulate that kind of behavior in the application
and I didn't have time to do that on top of everything else in
sysinstall.  Maybe Mr. Gold will handle this for us in his
semi-mythical sysinstall rewrite. :-)

- Jordan


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Garance A Drosihn

At 3:06 AM -0800 3/8/00, Jordan K. Hubbard wrote:
  For complete newbies, having "two formatting menus" seems weird
  too, and may be confusing. (I'm quoting one of my housemates).

For complete newbies, you really only want to ask one question up-front:

"Do you want to use all available disk space for FreeBSD?"

If the answer is yes, you go do the rest on their behalf without
asking anything more than, perhaps, what kind of installation they
want (desktop, server, etc).  If the answer is no, then you get into
the more detailed questions.

I think that gets back to the original observation though.  If you
do have super-simple option for newbies (which sounds like a good
idea to me), then that option should be picking better sizes for
partitions than the current default sizes.

The first time I installed freebsd, I picked numbers that were
a little larger than the defaults for '/' and '/var', and still
found myself needing to redo the entire installation in less
than a week because /var was too small.  That was fine enough
for me, as I just figured it as a learning experience and went
ahead and redid everything.  Newbies might not like learning
experiences quite that much.  (and actually, every time I do a
new install I keep bumping up the size a bit more).

Or are you saying that the newbie option would just use the
entire disk as one partition (the way that MacOS 10 server
does...)?   (well, I guess it'd have to be two partitions, with
one of them being for swap space...).

(I don't think this is a crisis or anything that needs to change
right this second, but assuming the installation is going to stick
with multiple partitions, then I do think that the default sizes
for some of these partitions should be larger).


---
Garance Alistair Drosehn   =   [EMAIL PROTECTED]
Senior Systems Programmer  or  [EMAIL PROTECTED]
Rensselaer Polytechnic Institute


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Jordan K. Hubbard

 The first time I installed freebsd, I picked numbers that were
 a little larger than the defaults for '/' and '/var', and still
 found myself needing to redo the entire installation in less
 than a week because /var was too small.  That was fine enough

And as you've seen by subsequent discussion, it's impossible
to derive a "one size fits all" solution for something like /var.

I would expect this to come out of the "I know where you want it, now
what kind of install will this be?" question which the newbie
installer gets to answer second.  If they pick "mail server" from
the menu then /var will get a totally different ratio % assigned
to it.  If they pick "personal workstation" then 20MB is, if anything,
perhaps a little high.

 Or are you saying that the newbie option would just use the
 entire disk as one partition (the way that MacOS 10 server
 does...)?

No, that's evil for a lot of reasons which I won't go into here. :)

- Jordan


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Block out PING.

2000-03-08 Thread Kelly Yancey

On Wed, 8 Mar 2000, Kasper wrote:

 Is there any way to stop the machine to answer on ping, so that my machine
 doenst answer on any ping? My server has been ping attacked a few times.
 
 ./Kasper
 
 

  Try ipfw(8)

  Kelly

--
Kelly Yancey  -  [EMAIL PROTECTED]  -  Richmond, VA
Analyst / E-business Development, Bell Industries  http://www.bellind.com/
Maintainer, BSD Driver Database   http://www.posi.net/freebsd/drivers/
Coordinator, Team FreeBSDhttp://www.posi.net/freebsd/Team-FreeBSD/



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Wes Peters

"Koster, K.J." wrote:
 
 Also, I'd really love to be able to configure ccd stripe sets from
 sysinstall, but I would not be surprised if that was too much to ask. :)

Being able to configure vinum slices would be nice, too.  Especially
once Greg commits support for booting from vinum volumes.  Think about
booting from mirrored volumes for reliability.

-- 
"Where am I, and what am I doing in this handbasket?"

Wes Peters Softweyr LLC
[EMAIL PROTECTED]   http://softweyr.com/


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Block out PING.

2000-03-08 Thread Wes Peters

Kasper wrote:
 
 Is there any way to stop the machine to answer on ping, so that my machine
 doenst answer on any ping? My server has been ping attacked a few times.

Firewall or filter the inbound ICMP echo request packets.

-- 
"Where am I, and what am I doing in this handbasket?"

Wes Peters Softweyr LLC
[EMAIL PROTECTED]   http://softweyr.com/


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Block out PING.

2000-03-08 Thread Dan Nelson

In the last episode (Mar 08), Kasper said:
 Is there any way to stop the machine to answer on ping, so that my
 machine doenst answer on any ping? My server has been ping attacked a
 few times.

This won't help you, as the problem with pingfloods is usually the sent
packets, not your responses.  By the time the ping requests have
reached your machine, your connection is probably already maxed out.

T?Modem
Attacker(s) --- ( Internet cloud )   You

1000 pps-1000 pps  -  20 pps   -.
  )
  20 pps-   20 pps -  20 pps  -'




-- 
Dan Nelson
[EMAIL PROTECTED]


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Daniel C. Sobral

"Jordan K. Hubbard" wrote:
 
  The first time I installed freebsd, I picked numbers that were
  a little larger than the defaults for '/' and '/var', and still
  found myself needing to redo the entire installation in less
  than a week because /var was too small.  That was fine enough
 
 And as you've seen by subsequent discussion, it's impossible
 to derive a "one size fits all" solution for something like /var.
 
 I would expect this to come out of the "I know where you want it, now
 what kind of install will this be?" question which the newbie
 installer gets to answer second.  If they pick "mail server" from
 the menu then /var will get a totally different ratio % assigned
 to it.  If they pick "personal workstation" then 20MB is, if anything,
 perhaps a little high.
 
  Or are you saying that the newbie option would just use the
  entire disk as one partition (the way that MacOS 10 server
  does...)?
 
 No, that's evil for a lot of reasons which I won't go into here. :)

I don't agree... A small /, and a huge /usr, with an additional var
symlink, shouldn't cause any troubles to newbies, and avoid some
problems. I think that the "use all available space" option ought to do
this.

--
Daniel C. Sobral(8-DCS)
[EMAIL PROTECTED]
[EMAIL PROTECTED]

One Unix to rule them all, One Resolver to find them,
One IP to bring them all and in the zone bind them.


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Jordan K. Hubbard

  No, that's evil for a lot of reasons which I won't go into here. :)
 
 I don't agree... A small /, and a huge /usr, with an additional var

Not surprising since you're not even arguing with the point I was
making. :)  I said that a big / was evil.

- Jordan


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Lodable kernel modules

2000-03-08 Thread Boris Popov

On Wed, 8 Mar 2000, Johan Kruger wrote:

 Hi there, sorry to bother you, just want to as two quick questions ..
 I looked as examples at ncp.ko and nwfs.ko ???
 
 1) If i look in the compiled nwfs directory, what is the __hack_file for ??,

This is fake file to put dependency entry in the linked file. See
resulting command lines for more details. I think that those files will
gone in the near future (of course, module dependancy will work).

 2) Why could'nt i load the ncp.ko in the ncp directory ( Exec format error )
 unless i removed the ipx support from the Makefile ??

Because your kernel doesn't have an IPX support compiled in, and
ncp.ko module requires it by default.

--
Boris Popov
http://www.butya.kz/~bp/



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Where is pci_intr_establish() _thread_sys_read()?

2000-03-08 Thread Zhihui Zhang


On Mon, 6 Mar 2000, Chris Costello wrote:

 On Monday, March 06, 2000, Zhihui Zhang wrote:
  Can anyone tell me where is the code for pci_intr_establish() and
  _thread_sys_read()? I could not find them under /usr/src.
 
I can tell you offhand that _thread_sys_anything is the _real_
 syscall for `anything'.  This is because a lot of syscalls are
 reimplemented within libc_r for reasons that are kind of obvious
 (directly calling the read syscall from one thread would block
 all the other threads in a process).  So _thread_sys_open() ==
 open(2), _thread_sys_read() == read(2), etc.
 
You are right.  In file libc/i386/SYS.h , you can see the following:

#define PSYSCALL(x) 2: PIC_PROLOGUE; jmp PIC_PLT(HIDENAME(cerror)); \
ENTRY(__CONCAT(_thread_sys_,x)); \
lea __CONCAT(SYS_,x),%eax; KERNCALL; jb 2b

-Zhihui



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Proposed FAQ on assembly programming

2000-03-08 Thread Thomas M. Sommers

The question of how to write an assembly language program on FreeBSD
comes up occasionally. The main difficulty is that it is not immediately
obvious how to make a system call without using libc, which may not
always be desirable. There does not seem to be any documentation on this
(other than the kernel source). I have drafted a FAQ that very briefly
shows how to write the canonical "Hello, world." program in FreeBSD
assembler. The draft can be found at
http://home.ptd.net/~tms2/hello.html


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: doscmd under FreeBSD 4.0 20000214-SNAP

2000-03-08 Thread Sam Leffler

INT15's are typically a result of unexpected interrupts or a printer
acknowledge IRQ; ignore them.  INT16's are video requests; function 1 in
this case sets the cursor type.  The video requests are done to draw the
boot menu that (probably) lets you pick whether to boot w/ or w/o certain
device support (e.g. SCSI or CD-ROM).  When I hit this I got further by
running doscmd w/ the -x option; sounds like that's not an option for you
(though beware I was running on BSD/OS 4.0 and not FreeBSD).

If you want to learn about this sort of stuff get a copy of The Undocumented
PC.

I'd be interested in talking to anyone that's successfully using doscmd to
do anything.  I want to use it to run a DOS app that communicates with a
Panasonic KSU but can't seem to get keyboard input to work when using an X
window.

Sam

- Original Message -
From: "Alexey N. Dokuchaev" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, March 08, 2000 12:44 AM
Subject: doscmd under FreeBSD 4.0 2214-SNAP


 Hi!

 There's a problem.  I'm trying to run ${SUBJ} unsing MSDOS 6.22 bootable
 diskette, with .doscmdrc file from man doscmd(1).  That's what I get:

 Unknown interrupt 15 function 4101
 Unknown interrupt 15 function 8796
 doscmd: fatal error int16 func 0x1 only supported in X mode

 If I try to run 'doscmd -r', I get:

 mmap: Invalid argument

 Any ideas?  I have no X installed, btw.  I'll try MSDOS 6.0, but I don't
 think version really matters at this early stage :-(

 P.S.  and what happened to that "VM86" option in kernel?



 To Unsubscribe: send mail to [EMAIL PROTECTED]
 with "unsubscribe freebsd-hackers" in the body of the message




To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Jamie Bowden

On Thu, 9 Mar 2000, Daniel C. Sobral wrote:

:"Jordan K. Hubbard" wrote:

:  Or are you saying that the newbie option would just use the
:  entire disk as one partition (the way that MacOS 10 server
:  does...)?

: No, that's evil for a lot of reasons which I won't go into here. :)

:I don't agree... A small /, and a huge /usr, with an additional var
:symlink, shouldn't cause any troubles to newbies, and avoid some
:problems. I think that the "use all available space" option ought to do
:this.

Something like this:

12:44pm lich  /home/jamie %df -k
Filesystem Type  kbytes use avail  %use Mounted on
/dev/root   xfs998162931970497  30  /
/dev/usrxfs  8717760  2909580  5808180  34  /usr

This is an Irix box, but I tend to partition my FreeBSD boxes the same
way (for workstations anyway, servers of course vary; which was the point
of this discussion I believe).

Even with servers I only vary the above slightly.  If a part of the
directory tree needs more space I will throw a disk on and slice it up.

Here's a sample:

12:48pm banshee  /home/jamie %df -k
Filesystem Type  kbytes use avail  %use Mounted on
/dev/root   xfs998163399765819  35  /
/dev/usrxfs  4166080  3202004   964076  77  /usr
/dev/dsk/dks1d4s7   xfs  8759744  1916808  6842936  22  /usr/home5
/dev/dsk/dks1d2s7   xfs  4268480   520436  3748044  13  /usr/local

The next chunk of space to get it's own drive is /var/spool, which for me
contains user mail queues as well as mqueue, named maps, and ftp's home.

Optimally you would just add more space a grow a filesystem into it, but
that unrealistic for a multitude of reasons.

I have swap divided among the three drives currently like so:

12:52pm banshee  /home/jamie %swap -l
lswap path devpri swaplo   blocks free  maxswapvswap
1 /dev/swap
   0,1050  0   262144   262144   2621440
2 /dev/dsk/dks1d2s2
   0,1480  0   262144   262144   2621440
3 /dev/dsk/dks1d4s2
   0,1550  0   262144   262144   2621440

/dev/root, /dev/usr, and /dev/swap all come off the root drive, which Irix
uses the above easy to remember names for.  I could just as easily mount
them using the actual device node entries as well.

Someone mentioned booting off mirrored drives.  This I've done before as
well.  I've done it in Solaris and Irix.  

Sun's meta tools are an example of how not to do this.  One way mirroring,
you start with two filesystems, one live, one empty, and hope your
corruption doesn't spread to your mirror should you have any.  This was as
of Solaris 2.6.1.  If disksuite got any better in 2.7, or 2.8, I don't
know.

With Irix you have two raw devices, which you assign as mirrors, and you
then newfs and apply data.  If either fails, it drops till you repair and
bring it back online.  Still not as nice as external SCSI to SCSI RAID
doing it for you, but definately better than the above.  I won's say XLV
is perfect by any stretch of the imagination, but it beats Disksuite all
to hell for a software RAID solution.

Disksuite and XLV both support 0+1, and it's basically the same as using
single partitions as mirrors.  Suffice it to say, if you have to deal with
/dev/md on a Solaris box, run.

Jamie Bowden

-- 

"Of course, that's sort of like asking how other than Marketing, 
Microsoft is different from any other software company..."
Kenneth G. Cavness



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: ijppp for isdn, ppp compression, and netgraph (also: load balancing)

2000-03-08 Thread Archie Cobbs

Hellmuth Michaelis writes:
2. We should come up with a 'standard' netgraph control message
   API for an ISDN basic rate interface, and have i4b implement
   this interface.  Then mpd/ppp/etc can "know" this interface
   and therefore work automatically with any ISDN BRI device.
   Here is the interface that we use at Whistle:
 ftp://ftp.whistle.com/pub/archie/netgraph/ng_tn.h
   (note: the switch types are #defined in another file but include
   all of the usual suspects: ETSI, NI-1, ATT, DMS100, etc.)
 
 The problem here is, that the Whistle ISDN stack has a fundamentally
 different view of the world than i4b has :-) As far as i understood it,
 the Whistle ISDN stack is almost completely configurable by using 
 netgraph messages whereas i4b is configured by its isdnd config file.
 
 I have made some experiments with mppd over the i4b netgraph b-channel
 interface and it works beautifully here without any additional 
 configuration messages necessary. But i have no idea, if the real world
 demands some control messages, such as dial, dial a number, hangup etc.

Yes, our way of doing things was of course designed for our particular
application.  It depends on what you want to do with an 'ISDN node'.

The /dev/i4b interface is actually pretty close to equivalent to
our netgraph control message API. The main differences seem to be:

  - Our API is strictly limited to ISDN operation, e.g., there
are no equivalents to I4B_TIMEOUT_UPD, I4B_UPDOWN_IND, or
MSG_IDLE_TIMEOUT_IND and no connection to sppp(8)

  - Our API allows more ISDN-related configuration, e.g., changing
switch type.

  - Our API is at a slightly higher level.. we don't have the
CDID_REQ or PROCEEDING_IND messages; when rejecting a call,
you don't get to specify the cause code, it's always
set to 21 for you, etc.

So the /dev/i4b and our netgraph API are actually quite similar.

Of course, a major difference is that with /dev/i4b you don't
get the B-channels exposed as netgraph node hooks, which is
very useful... but as you've shown already this is easy to add.
This gets you a "half netgraphified" ISDN node.

One thing that would be easy to do is to simply convert all of the
/dev/i4b ioctl's directly into netgraph control messages.  This
doesn't really buy you anything much though -- really just a
different interface for the same thing.

But if there were future plans to do all kinds of wacky things
with an ISDN device that would benefit by having it fully
netgraphified, maybe this would be worth doing.

-Archie

___
Archie Cobbs   *   Whistle Communications, Inc.  *   http://www.whistle.com


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: enabling APIC without SMP

2000-03-08 Thread Matthew Jacob



I'll second this request.

 Hi,
   I'm using a FreeBSD-current snapshot from 3rd January 2000. It seems
 that in order to enable APICs (option APIC_IO in kernel configuration file),
 one needs to also compile the kernel with SMP support (option SMP in kernel
 configuration file). While enabling the APIC is desirable even on a 
 uniprocessor (provides more IRQs, interrupt ovhd becomes less, provides
 on-chip timer), enabling SMP support on a uniprocessor brings down the 
 performance (I've noticed a degradation of 22% in performance of a webserver
 when a kernel was compiled with SMP support than without). Would it be possible
 to allow enabling the APIC without requiring support for SMP in future
 versions of FreeBSD ?
 
 Since I'm using a snapshot that's about two months old, I apologize if the
 above has already been addressed in the latest snapshots.
 
 
 
 - Mohit
 
 
 To Unsubscribe: send mail to [EMAIL PROTECTED]
 with "unsubscribe freebsd-hackers" in the body of the message
 



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



inner workings of the C compiler

2000-03-08 Thread Oscar Bonilla

i'm working on the C library, and to make debuggin easy i've copied
/usr/src/lib/libc to another directory and only build libc.a.

i've also copied /usr/src/lib/csu/i386-elf to another directory and 
have enabled debug symbols on both csu and libc.

to try things out i create a static binary and coerce it to use my
C library instead of the system's one.

this is how i compile my program:

cc -g -DYP -DFreeBSD -Wall -pedantic -ansi -c -I../../libc/include nss-test.c 
cc -g -nostdlib -static -L../../libc -o nss-test nss-test.o \
../../csu/i386-elf/crt1.o ../../csu/i386-elf/crti.o -lc

now, the program runs fine, but at the very end gives me a bus error
and core dumps... i've tracked the bug to the following call in line 90
csu/i386-elf/crt1.c in function _start()

atexit(_fini);

at this point, in gdb

(gdb) print _fini
$1 = {text variable, no debug info} 0x80528e4
(gdb) step
atexit (fn=0x80528e4)
at /usr/home/obonilla/freebsd/nss/libc/../libc/stdlib/atexit.c:59
1: __progname = 0xbfbffa86 "nss-test"
(gdb) print fn
$2 = (void (*)()) 0

fn is the argument to atexit()

later, in fuction exit() it will try to dereference a null pointer due
to the above...

i'm puzzled by this behavior... am i missing something?
how is it possible that the value i'm seeing before the call to atexit()
(0x80528e4) gets to be null once inside atexit()?

thanks and regards,

-oscar

-- 
pgp public key: finger [EMAIL PROTECTED]
pgp fingerprint: 6D 18 8C 90 4C DF F0 4B  DF 35 1F 69 A1 33 C7 BC


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Oliver Fromme

Matthew Dillon [EMAIL PROTECTED] wrote in list.freebsd-hackers:
  I'll tell ya, I *never* use the auto-defaults.

Me neither.  :-)

  They are way too
  tiny.  A 50MB root barely fits the kernel and you can run it out of
  space doing an installworld.  I almost always do this:

That's probably because you're a developper, I guess you have
at least a dozen kernels lying around.  ;-)
30 Mbyte for / is enough for me.

BTW (replying to Jordan's statement), I agree that one big /
is a Bad Thing[TM].  Usually I try to separate stuff that's
often written to (/var, /home) from the static data (/, /usr).
That also makes backups easier.  Furthermore, it is important
to separate partitions which could easily overflow (user homes,
spool directories) from "critical" things.  That has saved my
day a few times.  ;-)

Well, as someone else said, you can't make it fit everybody.

What I would like to see in sysinstall is an option to make
/tmp an MFS.  But then again, that would probably open yet
another can of worms...

Regards
   Oliver

-- 
Oliver Fromme, Leibnizstr. 18/61, 38678 Clausthal, Germany
(Info: finger userinfo:[EMAIL PROTECTED])

"In jedem Stück Kohle wartet ein Diamant auf seine Geburt"
 (Terry Pratchett)


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Block out PING.

2000-03-08 Thread Oliver Fromme

Kasper [EMAIL PROTECTED] wrote in list.freebsd-hackers:
  Is there any way to stop the machine to answer on ping, so that my machine
  doenst answer on any ping? My server has been ping attacked a few times.

I'd recommend that you add

   options   "ICMP_BANDLIM"

to your kernel.  This will limit the amount of ICMP replies that
your machine is sending out, without turning off ICMP completely
(which would be a _very_ bad thing).  You can tune the bandwidth
limit with sysctl net.inet.icmp.icmplim.

However, if the _incoming_ ICMP packets are already filling up
your line and causing trouble, there's nothing that you could do
against it on your side, I'm afraid.  Then you should try to
track down who's attacking you, and get those bad boys LARTed.
You could also try to ask your ISP for help.

Regards
   Oliver

PS:  "Pings" are just a particular type of ICMP packets (ICMP
ECHO requests and ICMP ECHO replies, respectively).

-- 
Oliver Fromme, Leibnizstr. 18/61, 38678 Clausthal, Germany
(Info: finger userinfo:[EMAIL PROTECTED])

"In jedem Stück Kohle wartet ein Diamant auf seine Geburt"
 (Terry Pratchett)


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: inner workings of the C compiler

2000-03-08 Thread Alfred Perlstein

* Oscar Bonilla [EMAIL PROTECTED] [000308 13:37] wrote:
 i'm working on the C library, and to make debuggin easy i've copied
 /usr/src/lib/libc to another directory and only build libc.a.
 
 i've also copied /usr/src/lib/csu/i386-elf to another directory and 
 have enabled debug symbols on both csu and libc.
 
 to try things out i create a static binary and coerce it to use my
 C library instead of the system's one.

I'm pretty sure this can be done a hell of a lot easier by using shared
libraries and using the enviornment variables LD_LIBRARY_PATH and
LD_PRELOAD, see the rtld manpage for more help.

good luck,
-Alfred


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Nik Clayton

This looks like as good a place as any to hang this;

On Tue, Mar 07, 2000 at 09:14:34PM -0800, Matthew Dillon wrote:
 I'll tell ya, I *never* use the auto-defaults.  They are way too
 tiny.  A 50MB root barely fits the kernel and you can run it out of
 space doing an installworld.  I almost always do this:
 
   /   128M
   swap(double system memory at a minimum)
   /var128M
   /var/tmp128M
   /usr(at least 1G)
   /u1 (remainder, if it's a big disk)
 
   /tmp softlink to /var/tmp(because having two tmp's is stupid)
   /home softlink to /u1/home

Here's a documentation of my current recommended practice which'll 
probably turn in to an article somewhere in the doc/ tree some time.

Comments welcome.

N

Recommended disk and partition layout

  In order to reduce space wastage, and provide a flexible partition layout
  for future work, the following disk partition layout is recommended.

  First, you need three 'standard' filesystems, of roughly this size:
  
/50m
/var 50m
/usr 250m

  A 50m / should be sufficient for static /bin and /sbin, as well as /etc,
  other configuration files, and a local /tmp.

  Similarly, a 50m /var covers most log files, assuming the machine isn't
  doing anything too log intensive.  Don't worry about the size of incoming
  and outgoing mail spools, or the print spooler at the moment.

  Finally, a 250m /usr covers all the standard stuff, and leaves room for
  expansion in the future.

  Now, create one more filesystem,

/local/0 rest of the disk

  If you have any more disks, create 1 filesystem per disk, and arrange to
  mount them as /local/1, /local/2, and so on.

  The known space fillers can then be moved on to /local/{0,1,2,...} as
  necessary, and then symlinked back in to place.  For example;

mkdir -p /local/0/usr
mkdir -p /local/0/var
mkdir -p /local/0/home
cd /usr
mv src /local/0/usr
mv obj /local/0/usr
mv ports /local/0/usr
mv X11R6 /local/0/usr
ln -s /local/0/usr/* .
cd /var
mv mail /local/0/var
mv spool /local/0/var
ln -s /local/0/var/* .

  and so on.  Adjust the disks you move stuff to, depending on how many disks
  you have, and expected usage.

  For example, if you only have one disk, then /local/0/usr/{src,ports,obj}
  and /local/0/home/ncvs[1] will all have to be on one disk.

  When you add a second disk, you will definitely want to move
  /local/0/usr/obj to /local/1/usr/obj, and /local/0/home/ncvs to
  /local/1/home/ncvs (and update their symlinks).  This is because:

1.  If you do a CVS checkout from /home/ncvs to /usr/src, two different
disks will be used, speeding things up considerably.

2.  If you do a "make world", the source will be read from /usr/src,
on the first disk, and the compiled programs (and object files)
will be written to /usr/obj, on the second disk, and again, this
will speed things up.

Problems with this approach

  By placing everything on one (or a few) large filesystems, you lose
  finegrained control.

  For example, if /var/mail and /var/spool are symlinks to /local/0/var/mail
  and /local/0/var/spool respectively, then there is the possibility that
  large incoming e-mails can use up all the disk space, preventing anything
  that requires /var/spool (such as lpd(8)) from working properly -- and vice
  versa, as large print jobs may halt reception of incoming e-mail.

  To an extent, you can work around this problem with quotas.  For example,
  the mail system runs as group 'mail', so you can set a group quota for mail
  to prevent it filling up the disk.  Some daemons also have configuration
  options to prevent them filling up the disk, such as the lpd(8) minfree
  file.

--

[1]  Assuming you've got a local copy of the CVS tree you checkout /usr/src
 from
 
-- 
Internet connection, $19.95 a month.  Computer, $799.95.  Modem, $149.95.
Telephone line, $24.95 a month.  Software, free.  USENET transmission,
hundreds if not thousands of dollars.  Thinking before posting, priceless.
Somethings in life you can't buy.  For everything else, there's MasterCard.
  -- Graham Reed, in the Scary Devil Monastery


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Warner Losh

In message [EMAIL PROTECTED] Wes Peters writes:
: Being able to configure vinum slices would be nice, too.  Especially
: once Greg commits support for booting from vinum volumes.  Think about
: booting from mirrored volumes for reliability.

Having vinum support in sysinstall would cut into my consulting
business :-).  Setting up a mirrored system is hard enough that people
are hiring consultants to do it.

Warner


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: doscmd under FreeBSD 4.0 20000214-SNAP

2000-03-08 Thread Warner Losh

In message 084c01bf8928$62a968f0$0132a8c0@MELANGE "Sam Leffler" writes:
: I'd be interested in talking to anyone that's successfully using doscmd to
: do anything.  I want to use it to run a DOS app that communicates with a
: Panasonic KSU but can't seem to get keyboard input to work when using an X
: window.

Which window manager?  I think that doscmd's window isn't icccm
compliant in that it doesn't set the Focus hint properly.

Warner


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: New packaging system (was: Sysinstall 'A'uto partitioning)

2000-03-08 Thread Kenny Drobnack

  I was actually planning a near-complete rewrite of sysinstall anyway!  How
  about everyone throwing in whatever suggestions you would like ( about
  anything regarding sysinstall ), and I will try to incorporate them!?
 
 It has already been re-written, complete with the new packaging system.  It
 just has some rough edges that need to be fixed, and the code needs to be
 documented.  The package is called libh, and you will find links to it if
 you search the archives.

I have a suggestion.  I have a laptop with Debian Linux on it, and I love
the way it does the packaging system.  For those not familiar with it, I
will try to briefly explain how it works.  You run it, set what version of
Debian Linux you have (stable or unstable, I think there's a 3rd option
too, which I can't remember).  Then set what kind of media you're
installing from (CD-ROM, nfs, hard drive, ftp, etc).  It looks for a file
called PACKAGES.GZ and from that builds a list of all the packages
available from whatever source it was pointed at.  Whenever you select a
package too get, it automagically selects all the required dependencies.
And then it doesn't download the packages until you tell it to.
On top of all this, dselect has an update feature that puts
Windows Update to shame (not hard actually :-)  If you point dselect at a
archive that has more recent versions of some programs, it will tell you
which programs have newer versions available, and give you a chance to
download it, if that be your heart's desire.
I figure some of these features could be a great addition to the
ports collection, as well as the pkg_* tools.
Another idea, I've noticed a trend in some programs of having a
GUI interface, as well as a command-line mode.  To me, this sounds like it
would be great to have with a package management tool.

-
In computer terms, hardware is the stuff you can hit with a baseball bat,
and software is the stuff you can only swear at.
   -from a web page explaining what hardware, software, and firmware are




To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Mark Newton

On Wed, Mar 08, 2000 at 05:30:00PM -0700, Warner Losh wrote:

  Having vinum support in sysinstall would cut into my consulting
  business :-).

"Oh, sorry, let's not do that then!" :-)

  Setting up a mirrored system is hard enough that people
  are hiring consultants to do it.

Yes, I have to say that I've done a couple of these myself.  

Another thing which would be useful is the ability to "vinum-ize" 
an existing filesystem without destroying it first.  On Solaris and
IRIX I can do that by creating a logical volume with a single plex
which just happens to contain the same partition as the existing
filesystem, thereby wrapping the filesystem in the logical volume.
I can then mount that logical volume;  the entire process takes about
two minutes.  Adding additional plexes to it to grow it or add redundancy
is then done in the same way that'd be done for any other logical
volume.

I'm not sure that you can do that with vinum, though.  Greg and I talked
about it about six months ago as a nice thing to have, but there are,
of course, other priorities...

- mark

-- 
Mark Newton   Email:  [EMAIL PROTECTED] (W)
Network Engineer  Email:  [EMAIL PROTECTED]  (H)
Internode Systems Pty Ltd Desk:   +61-8-82232999
"Network Man" - Anagram of "Mark Newton"  Mobile: +61-416-202-223


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: ijppp for isdn, ppp compression, and netgraph (also: load balancing)

2000-03-08 Thread Brian Somers

 Juergen Lock writes:
   when this is done the netgraph PPP nodes (which can support
these compression types will be usable.
  
  They could, but they don't yet, right? :)
  
   Maybe it still should be added to ijppp first cause debugging user
  processes is easier than the kernel...  and at the usual isdn bri
  speeds a user process should still be pretty fast enough.
 
 That makes perfect sense.. just be sure to write the code so that
 it's easily ported to the kernel.. the main issues being mbuf's..
 for that it's probably eassiest to just punt and copy each packet
 into a contiguous buffer.

I've done a small amount of work on making ppp(8)-style mbufs look 
more like real mbufs with this in mind.  If I can bring the whole 
interface in line, this problem will go away.  Of course this'll 
probably then introduce a compatibility problem with {Net,Open}BSD...

 -Archie
 
 ___
 Archie Cobbs   *   Whistle Communications, Inc.  *   http://www.whistle.com

-- 
Brian [EMAIL PROTECTED]brian@[uk.]FreeBSD.org
  http://www.Awfulhak.org   brian@[uk.]OpenBSD.org
Don't _EVER_ lose your sense of humour !




To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Sysinstall 'A'uto partitioning

2000-03-08 Thread Colin


On 08-Mar-2000 Jordan K. Hubbard wrote:
 And as you've seen by subsequent discussion, it's impossible
 to derive a "one size fits all" solution for something like /var.
 
 I would expect this to come out of the "I know where you want it, now
 what kind of install will this be?" question which the newbie
 installer gets to answer second.  If they pick "mail server" from
 the menu then /var will get a totally different ratio % assigned
 to it.  If they pick "personal workstation" then 20MB is, if anything,
 perhaps a little high.

 
 I might be completely out in left field somewhere, but I don't see that
the defaults should be that important.  We're discussing what is fundamentally
a server oriented system, and realistically we have to assume some minimum
level of understanding on the part of the person(s) installing it.  From
experience I can say that commercial Unix knowledge translates very quickly to
FreeBSD, including the basic concepts behind partitioning a disk, so for a
(resonably experienced) server administrator there should not really be an issue
here.
 If you owned a company, would you want someone who didn't at least make an
effort to research the system requirements prior to install running your mail
servers?  Even in the M$ world, it's become abundantly clear that setting up
any kind of server requires a serious investment in time and effort and
learning.  Who are we to deprive the newbies of that adventure ;)  
 For those setting it up to experiment/learn, the defaults worked okay for
everybody I've helped get started.  In those types of situations, a couple of
re-installs should probably be expected, anyway, as the newbie inadvertently
breaks things ("I was told that find / -exec rm {} ';' would free up lots of
disk space by a friend of mine who uses Linux...").  Especially using server
software as a desktop OS.
 I guess I'm saying that the auto partitioning scheme is fine, although
arguably not optimum for a desktop.


Cheers,
Colin


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



freeBSD booting src info

2000-03-08 Thread BSDknowledge seeker

Hi
Is there a document available which explains the freeBSD's booting
sequence -
ie. the place where the kernel is mapped, initialisation of the page tables,
segment descriptors and so on.
 If the relevant files are also mentioned, all the better.
Thanks


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: New packaging system (was: Sysinstall 'A'uto partitioning)

2000-03-08 Thread Doug Barton

Kenny Drobnack wrote:

 I have a suggestion.  I have a laptop with Debian Linux on it, and I love
 the way it does the packaging system.

We have command line tools to do all the things you described, and
sysinstall is a GUI front end to the existing package system. As for
wish lists, the archives are full of them. Patches talk. :)

Doug
-- 
"Welcome to the desert of the real." 

- Laurence Fishburne as Morpheus, "The Matrix"


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



enabling APIC without SMP

2000-03-08 Thread Mohit Aron

Hi,
I'm using a FreeBSD-current snapshot from 3rd January 2000. It seems
that in order to enable APICs (option APIC_IO in kernel configuration file),
one needs to also compile the kernel with SMP support (option SMP in kernel
configuration file). While enabling the APIC is desirable even on a 
uniprocessor (provides more IRQs, interrupt ovhd becomes less, provides
on-chip timer), enabling SMP support on a uniprocessor brings down the 
performance (I've noticed a degradation of 22% in performance of a webserver
when a kernel was compiled with SMP support than without). Would it be possible
to allow enabling the APIC without requiring support for SMP in future
versions of FreeBSD ?

Since I'm using a snapshot that's about two months old, I apologize if the
above has already been addressed in the latest snapshots.



- Mohit


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message