Re: Thinkpad X61s cannot boot 9.1-BETA1

2012-09-15 Thread Lars Engels
On Fri, Sep 14, 2012 at 03:15:04PM +0300, Andriy Gapon wrote:
> on 14/09/2012 11:17 Lars Engels said the following:
> > Here's are some more dmesgs:
> > 
> > http://bsd-geek.de/FreeBSD/T61_dmesg.boot.9.works   # PCBSD 9.1-RC1 
> > successuful boot on AC power
> > http://bsd-geek.de/FreeBSD/T61_dmesg.boot.10.works  # FreeBSD 10-CURRENT 
> > successful boot on battery
> > http://bsd-geek.de/FreeBSD/T61_dmesg.boot.9_10.diff # Their diff
> > 
> 
> Is it possible to produce two verbose dmesgs for 10 - one on AC power and one 
> on
> battery?
> I think that now you can complete booting in both cases.

Yes, they're here:

http://bsd-geek.de/FreeBSD/T61_dmesg.boot.10.works
http://bsd-geek.de/FreeBSD/T61_dmesg.boot.10_i8254.works
http://bsd-geek.de/FreeBSD/T61_dmesg.boot.10_eventtimer.diff

It shows also that with i8254 I'm having USB problems.


pgpPYCDDDJ5Rf.pgp
Description: PGP signature


Re: how to update ports while using pkgng?

2012-09-15 Thread Marcelo Gondim

Em 15/09/2012 01:41, Mike Manilone escreveu:

Hi,

I'm using ports with pkgng enabled. But I found that portmaster won't 
work. Is there any way to update ports? Thanks!


Hi,

I use "portsnap fetch update" and "portmaster" to update my ports.

Gondim
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: bsnmpd always died on HDD detach

2012-09-15 Thread Mikolaj Golub
On Sun, Sep 09, 2012 at 11:56:55PM +0200, Miroslav Lachman wrote:
> I am running bsnmpd with basic snmpd.config (only community and location 
> changed).
> 
> When there is a problem with HDD and disk disapeared from ATA channel 
> (eg.: disc physically removed) the bsnmpd always dumps core:
> 
> kernel: pid 1188 (bsnmpd), uid 0: exited on signal 11 (core dumped)
> 
> I see this for a long rime on all releases of 7.x and 8.x branches (i386 
> and amd64). I did not tested 9.x.

Ok, I was able to to reproduce this under qemu doing
  
  atacontrol detach ata1

It crashes in snmp_hostres module, in

  refresh_device_tbl->refresh_disk_storage_tbl->disk_OS_get_ATA_disks

when traversing device_map list and dereferencing map->entry_p, which
is NULL here.

device_map table is used for consistent device table indexing.

refresh_device_tbl(), refresh routine for hrDeviceTable, checks the
list of available devices and calls device_entry_delete() for devices
that have gone. It does not remove the entry from device_map table,
but just sets entry_p to NULL for it (to preserve index reuse by
another device).

Then refresh_disk_storage_tbl() is called, which in turn calls

 disk_OS_get_ATA_disks();
 disk_OS_get_MD_disks();
 disk_OS_get_disks();

and it crashes in disk_OS_get_ATA_disks() when the removed map entry
is dereferenced.

I am attaching the patch that fixes the issue for me.

I was wandering why the issue was not observed after md device
removal, as disk_OS_get_MD_disks() did the same things. It has turned
out that hostres just does not see md devices, so this function is
currently useless. hostres gets devices from devinfo(3), which does
not return md devices.

disk_OS_get_disks() calls kern.disks sysctl to get the list of disks,
and uses device_map differently, so it is not affected.

-- 
Mikolaj Golub
Index: usr.sbin/bsnmpd/modules/snmp_hostres/hostres_diskstorage_tbl.c
===
--- usr.sbin/bsnmpd/modules/snmp_hostres/hostres_diskstorage_tbl.c	(revision 240529)
+++ usr.sbin/bsnmpd/modules/snmp_hostres/hostres_diskstorage_tbl.c	(working copy)
@@ -287,6 +287,9 @@ disk_OS_get_ATA_disks(void)
 
 	/* Walk over the device table looking for ata disks */
 	STAILQ_FOREACH(map, &device_map, link) {
+		/* Skip deleted entries. */
+		if (map->entry_p == NULL)
+			continue;
 		for (found = lookup; found->media != DSM_UNKNOWN; found++) {
 			if (strncmp(map->name_key, found->dev_name,
 			strlen(found->dev_name)) != 0)
@@ -345,6 +348,9 @@ disk_OS_get_MD_disks(void)
 
 	/* Look for md devices */
 	STAILQ_FOREACH(map, &device_map, link) {
+		/* Skip deleted entries. */
+		if (map->entry_p == NULL)
+			continue;
 		if (sscanf(map->name_key, "md%d", &unit) != 1)
 			continue;
 
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"

Re: how to update ports while using pkgng?

2012-09-15 Thread Jamie Paul Griffin
[ Freddie Cash wrote on Fri 14.Sep'12 at 21:54:29 -0700 ]

> Read the pkgng faq online. There's a link to a patch for portmaster, and
> info on what to add to make.conf.

Can I ask: why is it still necessary for us to patch portmaster, can this not 
be implemented using an option during `make config` when installing portmaster 
or updating it, etc.?
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: how to update ports while using pkgng?

2012-09-15 Thread Eitan Adler
On 15 September 2012 17:44, Jamie Paul Griffin  wrote:
> [ Freddie Cash wrote on Fri 14.Sep'12 at 21:54:29 -0700 ]
>
>> Read the pkgng faq online. There's a link to a patch for portmaster, and
>> info on what to add to make.conf.
>
> Can I ask: why is it still necessary for us to patch portmaster, can this not 
> be implemented using an option during `make config` when installing 
> portmaster or updating it, etc.?

The maintainer of portmaster does not believe the patch to be of
sufficient quality to make it into the mainstream release. It should
be considered a "third party hack" for now.


-- 
Eitan Adler
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"