complete in src tree build world w/o /usr/include/** ?

2004-03-11 Thread Bjoern A. Zeeb
Hi,

I once again ran into the problem that a buildworld didn't succeed as
unpriv. user without populating some headers to the base system before.

But I do not want to populate headers that do not match my installed
system on that machine if I am building for another one. This leads to
inconsistency.

Is there any chance that the whole source tree could be built w/o
/usr/include/** ?
or should that be the case already ?
or why can't it be done ?

-- 
Greetings

Bjoern A. Zeeb  bzeeb at Zabbadoz dot NeT
56 69 73 69 74  http://www.zabbadoz.net/
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


FreeBSD Live Upgrade best practice?

2004-03-11 Thread Daniel Lang
Hi,

I'd like to try some sort of Live Upgrade.

Given: -STABLE box with an extra disk.

Intended procedure:

- Install 5.2.1-RELEASE (given it works on that box)
  on the extra disk
- Adapt configuration from -STABLE 
- shutdown
- change -STABLE disk with 5.2.1 disk
- boot and run 5.2.1
- optionally update to 5-CURRENT

Is this a feasable procedure? 

How would I best install the 5.2.1 on the extra disk.
I thought I'd just extract the -release tarballs
using the install.sh script? However there is also 
mtree information, and of course the extra disk is
not mounted on / but on /mnt

What do I else need to think of? 

I know that I probably cannot create UFS2 filesystems with
the -stable system. But I guess I can run UFS(1) as well 
until I move each filesystem to UFS2 using the (now spare)
old -stable system disk.

Maybe someone has already done such a thing?

Thanks  best regards,
 Daniel
-- 
IRCnet: Mr-Spock- Eddie would go! -
 Daniel Lang * [EMAIL PROTECTED] * +49 89 289 18532 * http://www.leo.org/~dl/


smime.p7s
Description: S/MIME cryptographic signature


Re: complete in src tree build world w/o /usr/include/** ?

2004-03-11 Thread Ruslan Ermilov
On Thu, Mar 11, 2004 at 09:52:41AM +, Bjoern A. Zeeb wrote:
 Hi,
 
 I once again ran into the problem that a buildworld didn't succeed as
 unpriv. user without populating some headers to the base system before.
 
 But I do not want to populate headers that do not match my installed
 system on that machine if I am building for another one. This leads to
 inconsistency.
 
 Is there any chance that the whole source tree could be built w/o
 /usr/include/** ?
 
A complete (and consistent with the rest of the running world)
/usr/include is a prerequisite for a successful buildworld.

 or should that be the case already ?
 
No.

 or why can't it be done ?
 
We build some tools (like compiler, binutils, make, etc.) using
the system headers, libraries, compiler, and binutils.


Cheers,
-- 
Ruslan Ermilov
FreeBSD committer
[EMAIL PROTECTED]


pgp0.pgp
Description: PGP signature


Using Kernel level mutex in FreeBSD 4.8

2004-03-11 Thread jitendra pande
Hi,
 
I am trying to use kernle level mutex in my driver for FreeBSD 4.8.  I tried searching 
for kernel level mutex but couldn't find any information on the same.
 
The kernel level mutex functions mtx_lock(..), mutex(..), mtx_init(..) and other mtx_ 
functions are available from FreeBSD 5.0 onwards and not in FreeBSD 4.8.
 
Kindly adavice me how should i proceed.
 
Also is there anything like Gaint lock in FreeBSD 4.8. If so then how can i use it.
 
Any early reply will be of great help.
 
Thanks in advance
Jitendra



-
Do you Yahoo!?
Yahoo! Search - Find what you’re looking for faster.
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Fw: 5.2 / 5.2.1 Highpoint 374 RAID 5 driver support

2004-03-11 Thread Robert Eckardt
On Wed, 10 Mar 2004 13:49:39 -, Steven Hartland wrote
 I'm looking to get the 374 working with  5.2 / 5.2.1 does anyone have
 any info on this. Highpoint have a driver for all the old version but
 no source / 5.2 download. Can we get the source or is their an
 alternative.
 
Steve

Hi Steve,

there should be basic support in the ATA-driver. (For the 372 there is.)

However, it does not support initial synchronization of two disks and
the handling in case of an error is very limited.
You either have to start using an already existing array or resync using
some BIOS tool. Later, the driver does not care whether the content of
the RAID is identical or not.

Robert


___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


off topic - disk crash

2004-03-11 Thread C. Kukulies
Today an important (no backup of course) 46 GB IBM Deskstar
IDE disk crashed. It has a FreeBSD 4.8 on it with important data and programs.
Yes, shame on me that I didn't care about doing backups on it but it
has happened.

I evend tend to expend the bucks to get it recovered but a little
prediagnosis I would not to be left untried.

The disk boots into FreeBSD but already at power on time the disk does
seek retries or some recalibration noise.

The question is what else can I do to recover the data.
Put it in the icebox? Turn the computer upside down?

Any ideas would be welcome.

I thought of getting a second identical disk to exchange electronics
only but since it partially functions it looks more like surface corruption,
doesn't it?

--
Chris Christoph P. U. Kukulies kukulies (at) rwth-aachen.de
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


i386/identcpu.c question

2004-03-11 Thread RMH

Hello hackers,

there are several lines in i386/identcpu.c:

case 0x600:
/* Check the particular flavor of 686 */
switch (cpu_id  0xf0) {
case 0x00:
strcat(cpu_model, Pentium Pro A-step);
break;
case 0x10:
strcat(cpu_model, Pentium Pro);
break;
case 0x30:
case 0x50:
case 0x60:
strcat(cpu_model,
Pentium II/Pentium II Xeon/Celeron);
cpu = CPU_PII;
break;
case 0x70:
case 0x80:
case 0xa0:
case 0xb0:
strcat(cpu_model,
Pentium III/Pentium III Xeon/Celeron);
cpu = CPU_PIII;
break;

0x30 stands for 0.35-micron Klamath core (Pentium II), there
were no Celeron or Xeon CPUs produced using it. There was
PIIOD, but check for the OverDrive is done separately.

By the way, 0x60 stands for Celeron (Mendocino) and mobile
Pentium II (Dixon) only; 0x70 -- for Pentium III (Katmai)
and Pentium III Xeon (Tanner) only; 0x80 -- for Celeron
(Coppermine-128) and Pentium III (Coppermine) only; 0xa0 --
for Pentium III Xeon (Cascades) only; 0xb0 -- for Celeron
(Tualatin) and Pentium III (Tualatin) only.

case 0x30:
strcat(cpu_model, Pentium II);
cpu = CPU_PII;
break;
case 0x50:
strcat(cpu_model,
Pentium II/Pentium II Xeon/Celeron);
cpu = CPU_PII;
break;
case 0x60:
strcat(cpu_model,
Mobile Pentium II/Celeron);
cpu = CPU_PII;
break;
case 0x70:
strcat(cpu_model,
Pentium III/Pentium III Xeon);
cpu = CPU_PIII;
break;
case 0x80:
strcat(cpu_model, Pentium III/Celeron);
cpu = CPU_PIII;
break;
case 0xa0:
strcat(cpu_model, Pentium III Xeon);
cpu = CPU_PIII;
break;
case 0xb0:
strcat(cpu_model, Pentium III/Celeron);
cpu = CPU_PIII;
break;

I suppose it doesn't take a lot of code to fix, but it looks
much better when a CPU is recognised properly (or close to).

---
Regards,
 Rhett


---
Spazio ILLIMITATO per la tua Email, Scanner Antivirus,
Antispam, Backup e POP3. Prova la nuova Email di superEva:
http://webmail.supereva.it/
---

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: 5.2 / 5.2.1 Highpoint 374 RAID 5 driver support

2004-03-11 Thread Sren Schmidt
Steven Hartland wrote:
I'm looking to get the 374 working with  5.2 / 5.2.1 does anyone have
any info on this. Highpoint have a driver for all the old version but
no source / 5.2 download. Can we get the source or is their an
alternative.
The HPT374 has been supported for quite some time (it even is on 
-stable), however Highpoint added RAID5 to thier software RAID engine 
sometime back, and that I do not support yet. When/if this will happend 
depends alot on what goings to happen with geom/vinum/raidframe/ataraid,
I'd very much like to not have to code RAID5 support in ataraid, but to 
use some generic code that should have been in the system for this. 
However I dont see this happening anytime soon, and I'm getting more and 
more requests for this for HPT and Promise products, so it might be time 
for me to look for parties interested enough in this to make me have 
time to do it...

-Sren
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: off topic - disk crash

2004-03-11 Thread Daniel Lang
Hi,

C. Kukulies wrote on Wed, Mar 10, 2004 at 06:36:52PM +0100:
[..]
 The disk boots into FreeBSD but already at power on time the disk does
 seek retries or some recalibration noise.
 
 The question is what else can I do to recover the data.
 Put it in the icebox? Turn the computer upside down?
[..]

Put it into another box running a working FreeBSD
and enough disk-space to contain all the contents of
the damaged disk.

Check if you can still read the disklabel
(just do disklabel ad1s1 (or whatever your device is)).

If you can read the disklabel, grab the contents of
each partition with dd, use the 'conv=noerror,sync'
options to fill unreadable sectors with zeros.

Turn the resulting partition-image files into devices using
vnconfig.

Now you can either:

 a) fsck the devices and then mount them to grab what is left
of the data. This is the more reliable way, but fsck may
render some data inaccessible.
If the superblock is damaged, read fsck and newfs manpages,
as well as the handbook, how to get a backup-copy
of your superblock.

 b) mount the device read-only and grab what is left of the data.
If the filesystem is badly damaged, this could panic your
machine. So don't do it unless you really have to.

You can make a copy of the partition image-files, and do the
fsck on one copy. You still have the other one if you want
to try without fsck.

If you cannot read the disklabel, you can still use dd to 
make an image of the whole disk. But you will have to find
the partition-boundaries for yourself. There is a tool in the
ports to find filesystem boundaries, IIRC. I don't recall the
name of this tool, though.

HTH,
 Daniel
-- 
IRCnet: Mr-Spock - Cool people don't move, they just hang around. -  
Daniel Lang * [EMAIL PROTECTED] * ++49 89 289 18532  * http://www.leo.org/~dl/


smime.p7s
Description: S/MIME cryptographic signature


Re: FreeBSD Live Upgrade best practice?

2004-03-11 Thread Colin Percival
At 10:19 11/03/2004, Daniel Lang wrote:
I'd like to try some sort of Live Upgrade.

Given: -STABLE box with an extra disk.

[snip]

Maybe someone has already done such a thing?
  My depenguinator is useful for this purpose; it creates a
disk image, which you can write to your second drive, which
boots into a memory disk; you can then slice, partition,
create filesystems, and generally do whatever you like with
the system -- without needing anything beyond a network
connection.
Colin Percival

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: FreeBSD Live Upgrade best practice?

2004-03-11 Thread Daniel Lang
Dear Colin,

Colin Percival wrote on Thu, Mar 11, 2004 at 03:22:12PM +:
 Given: -STABLE box with an extra disk.
 
 [snip]
 
 Maybe someone has already done such a thing?
 
   My depenguinator is useful for this purpose; it creates a
 disk image, which you can write to your second drive, which
 boots into a memory disk; you can then slice, partition,
 create filesystems, and generally do whatever you like with
 the system -- without needing anything beyond a network
 connection.

Care to share an URL? 

atleo6:~#grep depenguinator /usr/ports/INDEX
atleo6:~#

However. If I understand you correctly, I need to boot this 
diskimage and then do a 'regular' install? Anything I could
also do, using a CDROM or a boot-floppy? Or is there some
other benefit?

The purpose of my live-upgrade mission is not to get rid of CD-ROM
or floppy requirements, but to minimize downtime.

Hmmm, I just have another thought... Possibly there is a way
to provide make installkernel/installworld with a different
destination directory?

Like:

make installkernel -DDESTDIR=/mnt
make installworld -DDESTDIR=/mnt

Would this be another possibility?

Best regards,
 Daniel Lang
-- 
IRCnet: Mr-Spock - ceterum censeo Microsoftinem esse delendam -  
 Daniel Lang * [EMAIL PROTECTED] * +49 89 289 18532 * http://www.leo.org/~dl/


smime.p7s
Description: S/MIME cryptographic signature


Re: HEADSUP!!! USB MFC committed..

2004-03-11 Thread Shunsuke Akiyama
At Wed, 10 Mar 2004 22:18:05 +0900,
Shunsuke Akiyama wrote:

 At Mon, 8 Mar 2004 01:38:07 +0900,
 Yoshihiko Sarumaru wrote:
 
  I report you about a USB problem that would be occur with my
  laptop after you MFC'ed USB stuff.
  
  With GENERIC kernel, it is fine and there are no changes from
  before, but with no usb kernel + usb.ko + umass.ko, it would be
  panic everytime on boot.
  
  It is not depend on umass. The panic would be happen when I
  didn't load umass.ko but ucom.ko + umodem.ko and plug USB modem
  (PHS phone).
 
 I reproduced this panic, and tracked this down.
 This is a kernel module dependency problem.
 
 Please try attached patch, and let me know the result.
 If this patch fix your problem, I'll commit this.

Grrr, my patch makes another problem about loading kernel module.

I tried to load umodem.ko by hand with kernel which have compiled-in
uhci and usb drivers.  Then I got an error like following.

  # kldload umodem
  module_register: module usb/uhub already exists!
  linker_file_sysinit usb.ko failed to register! 17
  kldload: can't load umodem: Exec format error

Hum, this is different from CURRENT's behavior.
I think in-kernel loader/linker should be fixed first.
-- 
Shunsuke Akiyama
[EMAIL PROTECTED]
[EMAIL PROTECTED]
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Error when making installworld : SOLVED

2004-03-11 Thread Andrew J Caines
Ganbold said...
 I added group authpf and everything worked well.

Isn't this exactly the kind of thing which mergemaster -p is supposed to
pick up?


-Andrew-
-- 
 ___
| -Andrew J. Caines-   Unix Systems Engineer   [EMAIL PROTECTED]  |
| They that can give up essential liberty to obtain a little temporary |
|  safety deserve neither liberty nor safety - Benjamin Franklin, 1759 |
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: HEADSUP!!! USB MFC committed..

2004-03-11 Thread Julian Elischer


On Fri, 12 Mar 2004, Shunsuke Akiyama wrote:

 At Wed, 10 Mar 2004 22:18:05 +0900,
 Shunsuke Akiyama wrote:
 
  At Mon, 8 Mar 2004 01:38:07 +0900,
  Yoshihiko Sarumaru wrote:
  
   I report you about a USB problem that would be occur with my
   laptop after you MFC'ed USB stuff.
   
   With GENERIC kernel, it is fine and there are no changes from
   before, but with no usb kernel + usb.ko + umass.ko, it would be
   panic everytime on boot.
   
   It is not depend on umass. The panic would be happen when I
   didn't load umass.ko but ucom.ko + umodem.ko and plug USB modem
   (PHS phone).
  
  I reproduced this panic, and tracked this down.
  This is a kernel module dependency problem.
  
  Please try attached patch, and let me know the result.
  If this patch fix your problem, I'll commit this.
 
 Grrr, my patch makes another problem about loading kernel module.
 
 I tried to load umodem.ko by hand with kernel which have compiled-in
 uhci and usb drivers.  Then I got an error like following.
 
   # kldload umodem
   module_register: module usb/uhub already exists!
   linker_file_sysinit usb.ko failed to register! 17
   kldload: can't load umodem: Exec format error
 
 Hum, this is different from CURRENT's behavior.
 I think in-kernel loader/linker should be fixed first.

On the other hand teh netgraph autoloading workd better in 4.x than it
did in 5.x.
(last time I checked about 6 months ago)



 -- 
 Shunsuke Akiyama
 [EMAIL PROTECTED]
 [EMAIL PROTECTED]
 

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: HDD problem research (was HDD questions)

2004-03-11 Thread Roman Kurakin
Thanks.

This weekend I'll try last version from 4.x branch, and early versions 
of 5.x branch
may be this would help me to find 10 diffs :-)))

Best regards,
Roman Kurakin
[EMAIL PROTECTED] wrote:

Does any body have Segate drive ST380021A working with FreeBSD?
   

I do. For ~ 1.5 years now. Still running 4.6.2-RELEASE; booted 4.8-RELEASE
live-CD (frenzy.org.ua) without any problem.
ad0: 76319MB ST380021A [155061/16/63] at ata0-master UDMA100

IDE controller: Intel ICH4

Timestamp: 0x40500478
[SorAlx]  http://cydem.org.ua/
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]
 



___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: off topic - disk crash

2004-03-11 Thread Dan Nelson
In the last episode (Mar 11), Daniel Lang said:
 C. Kukulies wrote on Wed, Mar 10, 2004 at 06:36:52PM +0100:
 [..]
  The disk boots into FreeBSD but already at power on time the disk
  does seek retries or some recalibration noise.
  
  The question is what else can I do to recover the data. Put it in
  the icebox? Turn the computer upside down?
 
 Put it into another box running a working FreeBSD and enough
 disk-space to contain all the contents of the damaged disk.
 
 Check if you can still read the disklabel (just do disklabel ad1s1
 (or whatever your device is)).
 
 If you can read the disklabel, grab the contents of each partition
 with dd, use the 'conv=noerror,sync' options to fill unreadable
 sectors with zeros.

Also, if it looks like a single bad area of the disk, try a dd starting
a couple megs past the bad spot (with iseek+oseek) if the drive stops
responding after it hits the bad area.  I recovered data from a failed
disk this way.



-- 
Dan Nelson
[EMAIL PROTECTED]
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Strange behaviour in assembly language program

2004-03-11 Thread Chris Doherty
On Wed, Mar 03, 2004 at 08:12:28PM +, Daniela said: 
 This code works to return 0x57:   31 c0 40 6a 57 50 cd 80
 But that needs 8 bytes! Can't it be shortened?

this may not help you, and was done on Linux, but is an excellent read if
you haven't seen it (actually it's fun to read even if you have):

http://www.muppetlabs.com/~breadbox/software/tiny/teensy.html

chris

---
Chris Doherty
chris [at] randomcamel.net

I think, said Christopher Robin, that we ought to eat
all our provisions now, so we won't have so much to carry.
   -- A. A. Milne
---
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Using Kernel level mutex in FreeBSD 4.8

2004-03-11 Thread Artis Caune
afaik 4.x use spl(9)

int s;
s = splimp();
... critical code ...

splx(s);



On Thu, 11 Mar 2004 05:33:02 -0800 (PST), jitendra pande 
[EMAIL PROTECTED] wrote:

Hi,

I am trying to use kernle level mutex in my driver for FreeBSD 4.8.  I 
tried searching for kernel level mutex but couldn't find any information 
on the same.

The kernel level mutex functions mtx_lock(..), mutex(..), mtx_init(..) 
and other mtx_ functions are available from FreeBSD 5.0 onwards and not 
in FreeBSD 4.8.

Kindly adavice me how should i proceed.

Also is there anything like Gaint lock in FreeBSD 4.8. If so then how 
can i use it.

Any early reply will be of great help.

Thanks in advance
Jitendra


-
Do you Yahoo!?
Yahoo! Search - Find what youre looking for faster.
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to 
[EMAIL PROTECTED]



--
Artis
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: off topic - disk crash

2004-03-11 Thread Marcus Beaman
You could also use dd with the bs/count operands to skip the bad blocks,
but this will probably be much more frustrating that the conv operand. 
Another option (that is slower than dd but less stressful on the failing
drive) I've used are the dump/restore utilities.  I have the specific
commands for Solaris, but the process should work for FreeBSD with some
alterations (I can email it to you off list if you would like).  This is
the general procedure I use for the dump/restore utilities: 
1.  Attach second ide drive to cable/controller, same size or larger
than the failing disk.  This will be your recovery disk. 
2.  Boot from CD into single user mode (for freebsd check out
www.freesbie.org site and/or use the port). 
3.  Format, partition, label (make sure it is bootable), and create the
new file system on the recovery disk so it is identical to the old disk.

4.  Fsck the new and failing disks. 
5.  Setup and verify your swap partition on the recovery disk. 
6.  Mount the recovery disk partition. 
7.  Dump/restore the old disk partition to the new disk partition. 
Repeat 6/7 for each partition.
8.  Mount the failing disk partitions and compare to the recovery disk
for consistency. 
9.  Unmount all disk partitions.
10. Shutdown the system, remove the failing drive/CD, power it back up,
and test.

-Marcus

-
Marcus Beaman
Data Network Operations Analyst
DAS/IRMD/ENS NOC
503-378-3627
-

---REPLY---
Date: Thu, 11 Mar 2004 15:21:28 +0100
From: Daniel Lang [EMAIL PROTECTED]
To: C. Kukulies [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Re: off topic - disk crash
 Hi,
 
 C. Kukulies wrote on Wed, Mar 10, 2004 at 06:36:52PM +0100:
 [..]
  The disk boots into FreeBSD but already at power on time the disk
  does seek retries or some recalibration noise.
  
  The question is what else can I do to recover the data.
  Put it in the icebox? Turn the computer upside down?
 [..]
 
 Put it into another box running a working FreeBSD
 and enough disk-space to contain all the contents of
 the damaged disk.
 
 Check if you can still read the disklabel
 (just do disklabel ad1s1 (or whatever your device is)).
 
 If you can read the disklabel, grab the contents of
 each partition with dd, use the 'conv=noerror,sync'
 options to fill unreadable sectors with zeros.
 
 Turn the resulting partition-image files into devices using
 vnconfig.
 
 Now you can either:
 
  a) fsck the devices and then mount them to grab what is left
 of the data. This is the more reliable way, but fsck may
   render some data inaccessible.
   If the superblock is damaged, read fsck and newfs manpages,
   as well as the handbook, how to get a backup-copy
   of your superblock.
 
  b) mount the device read-only and grab what is left of the data.
 If the filesystem is badly damaged, this could panic your
   machine. So don't do it unless you really have to.
 
 You can make a copy of the partition image-files, and do the
 fsck on one copy. You still have the other one if you want
 to try without fsck.
 
 If you cannot read the disklabel, you can still use dd to 
 make an image of the whole disk. But you will have to find
 the partition-boundaries for yourself. There is a tool in the
 ports to find filesystem boundaries, IIRC. I don't recall the
 name of this tool, though.
 
 HTH,
  Daniel

---END REPLY---
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: i386/identcpu.c question

2004-03-11 Thread John Baldwin
On Wednesday 10 March 2004 10:51 pm, RMH wrote:
 Hello hackers,

 there are several lines in i386/identcpu.c:

 case 0x600:
 /* Check the particular flavor of 686 */
 switch (cpu_id  0xf0) {
   case 0x00:
   strcat(cpu_model, Pentium Pro A-step);
   break;
   case 0x10:
   strcat(cpu_model, Pentium Pro);
   break;
   case 0x30:
   case 0x50:
   case 0x60:
   strcat(cpu_model,
   Pentium II/Pentium II Xeon/Celeron);
   cpu = CPU_PII;
   break;
   case 0x70:
   case 0x80:
   case 0xa0:
   case 0xb0:
   strcat(cpu_model,
   Pentium III/Pentium III Xeon/Celeron);
   cpu = CPU_PIII;
   break;

 0x30 stands for 0.35-micron Klamath core (Pentium II), there
 were no Celeron or Xeon CPUs produced using it. There was
 PIIOD, but check for the OverDrive is done separately.

 By the way, 0x60 stands for Celeron (Mendocino) and mobile
 Pentium II (Dixon) only; 0x70 -- for Pentium III (Katmai)
 and Pentium III Xeon (Tanner) only; 0x80 -- for Celeron
 (Coppermine-128) and Pentium III (Coppermine) only; 0xa0 --
 for Pentium III Xeon (Cascades) only; 0xb0 -- for Celeron
 (Tualatin) and Pentium III (Tualatin) only.

   case 0x30:
   strcat(cpu_model, Pentium II);
   cpu = CPU_PII;
   break;
   case 0x50:
   strcat(cpu_model,
   Pentium II/Pentium II Xeon/Celeron);
   cpu = CPU_PII;
   break;
   case 0x60:
   strcat(cpu_model,
   Mobile Pentium II/Celeron);
   cpu = CPU_PII;
   break;
   case 0x70:
   strcat(cpu_model,
   Pentium III/Pentium III Xeon);
   cpu = CPU_PIII;
   break;
   case 0x80:
   strcat(cpu_model, Pentium III/Celeron);
   cpu = CPU_PIII;
   break;
   case 0xa0:
   strcat(cpu_model, Pentium III Xeon);
   cpu = CPU_PIII;
   break;
   case 0xb0:
   strcat(cpu_model, Pentium III/Celeron);
   cpu = CPU_PIII;
   break;

 I suppose it doesn't take a lot of code to fix, but it looks
 much better when a CPU is recognised properly (or close to).

It used to be like this but was considered too much work to maintain and was 
consolidated.  Note that on modern CPUs we use the name provided by extended 
cpuid.

-- 
John Baldwin [EMAIL PROTECTED]http://www.FreeBSD.org/~jhb/
Power Users Use the Power to Serve  =  http://www.FreeBSD.org
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Strange behaviour in assembly language program

2004-03-11 Thread ari
[EMAIL PROTECTED] said this stuff:

 This code works to return 0x57:   31 c0 40 6a 57 50 cd 80
 But that needs 8 bytes! Can't it be shortened?
 I noticed that some registers contain zero on program startup. Can I safely 
 assume they are always initialized to zero and just leave that 31 c0 out?

Freebsd explicitly zeros its registers before executing a program (it
then sets specific registers, such as the program counter, flags, and
stack pointer).  This behavior takes place in an architecture-dependent
function, however, so one cannot take for granted that such a thing will
occur, nor can one necessarily presume that all generic registers will
be zero (indeed, on i386, ebx is set to ps_strings, which may be nonzero
when executing bsdi binaries).  Still, this is the case as of freebsd
4.5 (alpha, i386) and 5.1 (alpha, amd64, i386, sparc64).  Those are the
versions and architectures that i briefly checked.

This information is in the files with pattern:

arch/arch/machdep.c

The function in question is exec_setregs on freebsd 5.x, or setregs
on freebsd 4.x.

ari

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


make install (kernel) without /modules dir

2004-03-11 Thread Roman Kurakin
Hi,

   It seems that I've found another problem. If /modules dir would be 
removed,
make install (of kernel and kernel modules) will not create modules dir 
and you'll
get /modules file with one of the modules inside.

One of the variants is to add flag -d to install or other to mkdir -p 
explicitly:

--- Makefile.oldFri Mar 12 00:13:45 2004
+++ MakefileFri Mar 12 00:15:03 2004
@@ -626,6 +626,7 @@
   cp -p ${DESTDIR}/modules/* ${DESTDIR}/modules.old; \
   fi;
.endif
+   mkdir -p ${DESTDIR}/modules
cd $S/modules ; env ${MKMODULESENV} ${MAKE} install
modules-reinstall modules-reinstall.debug:

Best regards,
   Roman Kurakin


___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: make install (kernel) without /modules dir

2004-03-11 Thread Roman Kurakin
I forget to say that this problem is for 4. branch

Roman Kurakin wrote:

Hi,

   It seems that I've found another problem. If /modules dir would be 
removed,
make install (of kernel and kernel modules) will not create modules 
dir and you'll
get /modules file with one of the modules inside.

One of the variants is to add flag -d to install or other to mkdir -p 
explicitly:

--- Makefile.oldFri Mar 12 00:13:45 2004
+++ MakefileFri Mar 12 00:15:03 2004
@@ -626,6 +626,7 @@
   cp -p ${DESTDIR}/modules/* ${DESTDIR}/modules.old; \
   fi;
.endif
+   mkdir -p ${DESTDIR}/modules
cd $S/modules ; env ${MKMODULESENV} ${MAKE} install
modules-reinstall modules-reinstall.debug:

Best regards,
   Roman Kurakin


___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to 
[EMAIL PROTECTED]






___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


inetd needs discard service in /etc/services

2004-03-11 Thread Brooks Davis
While updating my diskless setup, I was trying to determine the minimal
set of entries required in /etc/services in addition to a NIS + line
to get a system to boot cleanly.  I discovered that inetd depends on the
existence of the discard service.

The dependency is due to the fact that getaddrinfo is used to generate
sockaddr_in(6) struct's and it's not really up to the task when we know
neither the hostname or the service name.  For some reason, discard was
picked when IPv6 support was added and it's remained ever sense.  A
better organization of the code could work around this problem one of
several ways, but that's more work then I want to do at this time.

There also appears to be a secondary bug, probably in getaddrinfo that
means that even though we can look discard up in NIS when inetd is
started, it isn't being resolved there by getaddrinfo.

I would like to commit the following patch.  It changes the port from
discard to syslog and documents the dependency.  I choose syslog because
it really does need to be in /etc/services on most machines since it
starts before NIS.  I'll also file a PR against inetd in hopes that
someone gets board enough to fix it some day.

Any objections?

-- Brooks

Index: inetd.8
===
RCS file: /usr/cvs/src/usr.sbin/inetd/inetd.8,v
retrieving revision 1.78
diff -u -p -r1.78 inetd.8
--- inetd.8 29 Feb 2004 15:49:26 -  1.78
+++ inetd.8 12 Mar 2004 00:55:54 -
@@ -919,3 +919,13 @@ The
 .Fx
 TCP Wrappers support first appeared in
 .Fx 3.2 .
+.Sh BUGS
+The
+.Nm
+utility requires that the
+.Qq syslog
+service be defined in
+.Pa /etc/inetd.conf
+unless the
+.Fl a
+argument is given.
Index: inetd.c
===
RCS file: /usr/cvs/src/usr.sbin/inetd/inetd.c,v
retrieving revision 1.123
diff -u -p -r1.123 inetd.c
--- inetd.c 30 Oct 2003 22:56:44 -  1.123
+++ inetd.c 12 Mar 2004 00:51:19 -
@@ -404,7 +404,7 @@ main(int argc, char **argv)
 *   hostname or servname is non NULL.
 *   So when hostname is NULL, set dummy value to servname.
 */
-   servname = (hostname == NULL) ? discard /* dummy */ : NULL;
+   servname = (hostname == NULL) ? syslog /* dummy */ : NULL;
 
bzero(hints, sizeof(struct addrinfo));
hints.ai_flags = AI_PASSIVE;

-- 
Any statement of the form X is the one, true Y is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4


pgp0.pgp
Description: PGP signature


RE: Intel i8xx watchdog driver

2004-03-11 Thread Wm. Daryl Hawkins
I would love to incorporate it in both source trees if possible.  Before
it goes into current, I need to make some changes so that it will work
with Poul-Henning Kamp's new watchdog driver model.  Hopefully, I'll get
to work on that some tomorrow.  I'll release a new version for current
as soon as it's ready.

-- Daryl 

-Original Message-
From: Mike Tancsa [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, March 10, 2004 9:17 PM
To: Wm. Daryl Hawkins
Cc: [EMAIL PROTECTED]
Subject: Re: Intel i8xx watchdog driver


Wow, this is great!  I tried it out on a few RELENG_4 boxes and it works
as expected 

wdog0 on motherboard
isab0: Found Intel 82801DB watchdog device

Are there any plans to incorporate this into the 5.x and 4.x source
tree ?   This would be useful to a lot of people.

---Mike

On Wed, 10 Mar 2004 10:54:38 -0600, in sentex.lists.freebsd.hackers you
wrote:


I've written a driver and userland daemon for the Intel i8xx TCO 
watchdog timer.  This is my first driver and it's only seen limited 
testing, so proceed with caution!  I've tested it with 4.9 and 5.2.1 on

a Supermicro P4SGE motherboard and would be grateful for any 
suggestions, comments, bug reports, or complaints!  :)  If there is 
sufficient interest (and once I've gotten some comment on the structure

and inner workings of this driver), I'd also like to write a driver for

the AMD-8000 series chipset.  You can get the driver at: 
http://freebsd.tamu.edu/wdog/

-- Daryl


Daryl Hawkins
Network Systems
Texas AM University
[EMAIL PROTECTED]
___
[EMAIL PROTECTED] mailing list 
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to
[EMAIL PROTECTED]

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


diff included in commit mail

2004-03-11 Thread Mark Santcroos
Hi,

I know it was discussed once somewhere, but I can't find the thread in 
question.

What I would like to be able to do is see the actual commit included in the
mail. I know it can't be done at the moment the message arrives, as that is
before it arrives in my cvs tree.

On my machine I have the cvs repo mirrored, so doing it in realtime is no
problem.

Does anybody have scripts or whatever available to do this?

Thanks

Mark
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


RE: Intel i8xx watchdog driver

2004-03-11 Thread Mike Tancsa
Thanks, thats great news.  Perhaps even as a port would do the trick.

---Mike

At 08:07 PM 11/03/2004, Wm. Daryl Hawkins wrote:
I would love to incorporate it in both source trees if possible.  Before
it goes into current, I need to make some changes so that it will work
with Poul-Henning Kamp's new watchdog driver model.  Hopefully, I'll get
to work on that some tomorrow.  I'll release a new version for current
as soon as it's ready.
-- Daryl

-Original Message-
From: Mike Tancsa [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 9:17 PM
To: Wm. Daryl Hawkins
Cc: [EMAIL PROTECTED]
Subject: Re: Intel i8xx watchdog driver
Wow, this is great!  I tried it out on a few RELENG_4 boxes and it works
as expected
wdog0 on motherboard
isab0: Found Intel 82801DB watchdog device
Are there any plans to incorporate this into the 5.x and 4.x source
tree ?   This would be useful to a lot of people.
---Mike

On Wed, 10 Mar 2004 10:54:38 -0600, in sentex.lists.freebsd.hackers you
wrote:

I've written a driver and userland daemon for the Intel i8xx TCO
watchdog timer.  This is my first driver and it's only seen limited
testing, so proceed with caution!  I've tested it with 4.9 and 5.2.1 on
a Supermicro P4SGE motherboard and would be grateful for any
suggestions, comments, bug reports, or complaints!  :)  If there is
sufficient interest (and once I've gotten some comment on the structure
and inner workings of this driver), I'd also like to write a driver for

the AMD-8000 series chipset.  You can get the driver at:
http://freebsd.tamu.edu/wdog/

-- Daryl


Daryl Hawkins
Network Systems
Texas AM University
[EMAIL PROTECTED]
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to
[EMAIL PROTECTED]
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


mysql-4.0.18 build problem in FreeBSD-5.2-CURRENT

2004-03-11 Thread Ganbold
Hi all,

Today I wanted to upgrade mysql-4.0.17 to mysql-4.0.18 in 
FreeBSD-5.2-CURRENT and got error below.
I did updated FreeBSD on March 3 2004 using cvsup.

I used following options to compile mysql from ports collection:

make WITH_CHARSET=cp1251 WITH_LINUXTHREADS=yes BUILD_STATIC=yes install

Error message:
-
/usr/lib/libc.a(res_init.o): In function `__h_error':
res_init.o(.text+0x1104): multiple definition of `__h_error'
/usr/local/lib/liblthread.a(errno.o):/usr/ports/devel/linuxthreads/work/linuxthreads-2.2.3_14/errno.c:29: 
first defined here
/usr/bin/ld: Warning: size of symbol `__h_error' changed from 88 to 36 in 
/usr/lib/libc.a(res_init.o)
*** Error code 1

Stop in /usr/ports/databases/mysql40-server/work/mysql-4.0.18/sql.
*** Error code 1
Stop in /usr/ports/databases/mysql40-server/work/mysql-4.0.18/sql.
*** Error code 1
Stop in /usr/ports/databases/mysql40-server/work/mysql-4.0.18/sql.
*** Error code 1
Stop in /usr/ports/databases/mysql40-server/work/mysql-4.0.18.
*** Error code 1
Stop in /usr/ports/databases/mysql40-server/work/mysql-4.0.18.
*** Error code 1
Stop in /usr/ports/databases/mysql40-server.
---
What should I do in this case? Is there anybody solved this problem before?
Linuxthreads is installed from ports collection.
tia,

Ganbold

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]