Re: Child suspend/resume

2014-08-14 Thread Alexandr Krivulya
I've done three suspend/resume cycle during last workday and all works
fine. Sorry for misled.

13.08.2014 18:35, Justin Hibbits пишет:
 That's odd, because another tester reported everything worked correctly
 for him.  Could you send me the output of a verbose boot dmesg (boot
 -v), devinfo -rv, and pciconf -lv?

 Thanks,
 Justin

 On Wed, 13 Aug 2014 09:17:24 +0300
 Alexandr Krivulya shur...@shurik.kiev.ua wrote:

 Now laptop resumes, screen turned on and I see in dmesg acpi: resumed
 at ..., but neither keyboard nor mouse don't work and host is not
 accessible from network.

 12.08.2014 17:06, Justin Hibbits пишет:
 Hi Alexandr,

 Thanks.  I got another confirmation that it didn't work, and may
 have found the cause.  I have another patch that you can find at
 https://phabric.freebsd.org/D590 which fixes a typo that I had made.
 Could you try that?

 (Added current@ so everyone else sees this as well).

 Thanks!

 - Justin

 On Tue, 12 Aug 2014 11:18:29 +0300
 Alexandr Krivulya shur...@shurik.kiev.ua wrote:

 Hi, Justin
 After applying your patch my thinkpad e530 (FreeBSD 11.0-CURRENT,
 amd64) doesn't resume any more - screen remains black.

 11.08.2014 08:30, Justin Hibbits (by way of Justin Hibbits
 chmeeed...@gmail.com) пишет:
 Hi all,

 The attached patch is completely untested, due to lack of existing
 suspendable hardware (no x86 machines).  It does compile cleanly
 against head, though. I don't think it should change any behavior,
 I tried to keep the essence of the code path the same.

 It was suggested that I break up my multipass suspend/resume code
 into incremental parts, so this is part one.  It adds a
 BUS_SUSPEND_CHILD/BUS_RESUME_CHILD, as well as helper functions,
 bus_generic_suspend_child()/bus_generic_resume_child(), and
 modifies the PCI driver to use this new facility.

 I'd like some feedback, and testing of this, to make sure I didn't
 break anything.

 Thanks,
 Justin


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

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

Re: android bsd connectivity tools etc ?

2014-08-14 Thread Per olof Ljungmark
On 08/14/14 01:47, Julian H. Stacey wrote:
 Hi,
 Any tips for Android / FreeBSD BSD tools for connectivity etc ?
 
 I just got a Samsung Galaxy Note 3, with Android 4.4.2 kernel 3.4.0
 
 It directs me to 
   https://www.android.com/filetransfer/
 which seems binary for mac
 
 I recall I will need current for IP tethering
   
 http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-usb-tethering.html
   
 http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-aggregation.html#networking-lagg-wired-and-wireless
 
 I'll build a current from a 10.0-RELEASE partition, 
 but now looking with 9.2-RELEASE I see:
 
 /dev/
 lrwxr-xr-x  1 root  wheel9 Aug 14 00:01 ugen1.5@ - usb/1.5.0
 crw---  1 root  operator  0x7a Aug 14 00:00 usb/1.5.0
 crw---  1 root  operator  0x8f Aug 14 00:00 usb/1.5.1
 crw---  1 root  operator  0x90 Aug 14 00:00 usb/1.5.2
 
 devd .conf will need:
match   vendor0x04e8;
match   product   0x6860;
match   devclass  0x00;
match   devsubclass   0x00;
match   sernum6758498c;
match   release   0x0400;
 I've no idea what to do for attach
 
 http://www.freebsd.org/cgi/ports.cgi?query=androidstype=all
 has just
   /usr/ports/devel/android-tools-adb/pkg-descr
  these for cross compiling later:
   /usr/ports/lang/*gnatdroid*/pkg-descr
 
 I also found 
   ports/
   deskutils/tine20
   net/crtmpserver
   net/linphone
   https://source.android.com/source/index.html
 
 Any URLs, tips, comments welcome, Thanks
 
 Cheers,
 Julian
 

I gave up on using mass storage and turned to this instead:

https://play.google.com/store/apps/details?id=lutey.FTPServerhl=en

Works very well.

For tethering I have no idea, sorry.

Cheers,

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


Re: android bsd connectivity tools etc ?

2014-08-14 Thread Lars Engels
On Thu, Aug 14, 2014 at 08:29:37AM +0200, Per olof Ljungmark wrote:
 On 08/14/14 01:47, Julian H. Stacey wrote:
  Hi,
  Any tips for Android / FreeBSD BSD tools for connectivity etc ?
  
  I just got a Samsung Galaxy Note 3, with Android 4.4.2 kernel 3.4.0
  
  It directs me to 
  https://www.android.com/filetransfer/
  which seems binary for mac
  
  I recall I will need current for IP tethering
  
  http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-usb-tethering.html
  
  http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-aggregation.html#networking-lagg-wired-and-wireless
  
  I'll build a current from a 10.0-RELEASE partition, 
  but now looking with 9.2-RELEASE I see:
  
  /dev/
  lrwxr-xr-x  1 root  wheel9 Aug 14 00:01 ugen1.5@ - usb/1.5.0
  crw---  1 root  operator  0x7a Aug 14 00:00 usb/1.5.0
  crw---  1 root  operator  0x8f Aug 14 00:00 usb/1.5.1
  crw---  1 root  operator  0x90 Aug 14 00:00 usb/1.5.2
  
  devd .conf will need:
 match   vendor0x04e8;
 match   product   0x6860;
 match   devclass  0x00;
 match   devsubclass   0x00;
 match   sernum6758498c;
 match   release   0x0400;
  I've no idea what to do for attach
  
  http://www.freebsd.org/cgi/ports.cgi?query=androidstype=all
  has just
  /usr/ports/devel/android-tools-adb/pkg-descr
   these for cross compiling later:
  /usr/ports/lang/*gnatdroid*/pkg-descr
  
  I also found 
  ports/
  deskutils/tine20
  net/crtmpserver
  net/linphone
  https://source.android.com/source/index.html
  
  Any URLs, tips, comments welcome, Thanks
  
  Cheers,
  Julian
  
 
 I gave up on using mass storage and turned to this instead:
 
 https://play.google.com/store/apps/details?id=lutey.FTPServerhl=en
 
 Works very well.
 
 For tethering I have no idea, sorry.

There's also Airdroid [1]. After installing the App on the phone you can
connect to it with your PC's browser, up- and download files, send
messages, etc.


[1] https://play.google.com/store/apps/details?id=com.sand.airdroid


pgpNjlvpZjFYr.pgp
Description: PGP signature


shmget (No space left on device) issue with firefox

2014-08-14 Thread Beeblebrox
I have been having difficulty getting firefox to work, so I built it with
DEBUG and this error shows up when starting with $ firefox -safe-mode =
shmget failed: error 28 (No space left on device)

What Shared Memory setting do I need to change so as to get rid of this
error? Alternatively, is this a mozilla bug? shmall looks sufficiently large
to me, and setting it to unlimited seems a bit risky.

My Shared Memory settings ATM on 4G physical RAM:
$  ipcs -M
shmmax:536870912
shmmin:1
shmmni:  192
shmseg:  128
shmall:   131072

MEMORY INFORMATION:
mem_wire:1543798784 (   1472MB) [ 39%]
mem_active:  +451334144 (430MB) [ 11%]
mem_inactive:+   1510998016 (   1441MB) [ 38%]
mem_cache:   +0 (  0MB) [  0%]
mem_free:+378961920 (361MB) [  9%]
mem_gap_vm:  +  1544192 (  1MB) [  0%]
--  --- --
mem_all: =   3886637056 (   3706MB) [100%]
mem_gap_sys: +123482112 (117MB)
--  ---
mem_phys:=   4010119168 (   3824MB)
mem_gap_hw:  +284848128 (271MB)
--  ---
mem_hw:  =   4294967296 (   4096MB)






-
FreeBSD-11-current_amd64_root-on-zfs_RadeonKMS
--
View this message in context: 
http://freebsd.1045724.n5.nabble.com/shmget-No-space-left-on-device-issue-with-firefox-tp5938162.html
Sent from the freebsd-current mailing list archive at Nabble.com.
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: HOWTO articles for migrating from Linux to FreeBSD, especially for pkg?

2014-08-14 Thread David Chisnall
On 14 Aug 2014, at 02:34, Russell L. Carter rcar...@pinyon.org wrote:

 So I would be very willing to contribute to this project, if that
 makes sense.
 
 Best,
 Russell
 
 (what list should this move to? Perhaps ports?)

I'd suggest docs.  Note that currently, the docs team is the smallest part of 
FreeBSD, yet is responsible for one of the most important user-facing portions. 
 People interested in joining the docs team are always very welcome.  The 
#bsddocs channel on EFNet is a good place to chat with existing docs folks.

David

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


Re: libthr and main thread stack size

2014-08-14 Thread Ivan A. Kosarev

On 08/13/2014 01:40 AM, Dimitry Andric wrote:

On 08 Aug 2014, at 13:22, Konstantin Belousov kostik...@gmail.com wrote:

On Fri, Aug 08, 2014 at 12:32:56PM +0400, Ivan A. Kosarev wrote:

On 08/08/2014 09:28 AM, Konstantin Belousov wrote:

On Thu, Aug 07, 2014 at 04:18:12PM +0400, Ivan A. Kosarev wrote:

Hello,

According to libthr's thr_init.c (the 9.2 version) init_main_thread()
allocates s.c. red zone below the main stack in order to protect other
stacks. The size of the main stack is determined by the
_thr_stack_initial variable that is declared extern though it doesn't
seem it can be changed. The value of the variable is set to 4M on 64-bit
platforms which is obviously not sufficient for the most of real programs.

Can anyone please confirm that there is no way to increase the stack
size for the main thread and thus any program linked against libthr has
only a few megabytes of stack memory for its main thread--whatever the
system stack size (ulimit -s) is set to?

Yes, there is no way to change the main thread stack clamping.
Could you provide a reasonable use case for the 4MB stack ?

Traversing trees with recursive functions or on-stack grammar parsers?

I just ran into a similar issue while running one of clang 3.5's test
cases (see http://llvm.org/PR20635 ).  On i386, it used up approximately
2MB of stack, then ran into the guard page, and segfaulted.

I was quite amazed to find out that ulimit -s didn't help at all, until
I remembered this thread. :-)


Yes, that was the point: at least some of real programs consume more 
stack space than what we have with the hardcoded libthr's limits. Also, 
it looks a bit weird to me that adding thread support/linking against 
libthr affects how much stack space we can consume and whether it can be 
controlled with ulimit.


The original issue I've run into is one of the Asan's tests:

http://reviews.llvm.org/D4562

--

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


nscd not caching

2014-08-14 Thread Eggert, Lars
[Resending to current@, since I can't get it to work on -CURRENT either.]

Hi,

anyone have an idea why nscd would not be caching NIS lookups?

My nsswitch.conf looks as follows:

group: cache files nis
hosts: cache files dns
networks: cache files
passwd: cache files nis
shells: files
services: cache files nis
protocols: cache files
rpc: cache files

nisdomain is set and ypbind is started, and I see lots of NIS traffic going in 
and out.

But nothing is cached; running nscd with -t just prints this and then then 
nothing, ever:

M1 from main: successfully daemonized
M1 from main: request agents registered successfully
M2 from cache: cache was successfully initialized
M2 from runtime environment: using socket /var/run/nscd
M2 from runtime environment: successfully initialized
M1 from main: thread #0 was successfully created
M1 from main: thread #1 was successfully created
M1 from main: thread #2 was successfully created
M1 from main: thread #3 was successfully created
M1 from main: thread #4 was successfully created
M1 from main: thread #5 was successfully created
M1 from main: thread #6 was successfully created
M1 from main: thread #7 was successfully created

Lars



signature.asc
Description: Message signed with OpenPGP using GPGMail


Re: android bsd connectivity tools etc ?

2014-08-14 Thread Gary Jennejohn
On Thu, 14 Aug 2014 13:51:04 +0930
Shane Ambler free...@shaneware.biz wrote:

 On 14/08/2014 09:17, Julian H. Stacey wrote:
  Hi,
  Any tips for Android / FreeBSD BSD tools for connectivity etc ?
  
  I just got a Samsung Galaxy Note 3, with Android 4.4.2 kernel 3.4.0
 
  I'll build a current from a 10.0-RELEASE partition, 
  but now looking with 9.2-RELEASE I see:
  
  /dev/
  lrwxr-xr-x  1 root  wheel9 Aug 14 00:01 ugen1.5@ - usb/1.5.0
  crw---  1 root  operator  0x7a Aug 14 00:00 usb/1.5.0
  crw---  1 root  operator  0x8f Aug 14 00:00 usb/1.5.1
  crw---  1 root  operator  0x90 Aug 14 00:00 usb/1.5.2
  
 
 I have a cheap Huawei phone running 2.3.6
 When I plug in the usb cable to charge it, it shows up as 3 devices
 
 da0 at umass-sim1 bus 1 scbus5 target 0 lun 0
 da0:  Android Adapter 0100 Removable Direct Access SCSI-2 device
 cd1 at umass-sim1 bus 1 scbus5 target 0 lun 1
 cd1:  Android Adapter 0100 Removable CD-ROM SCSI-2 device
 da1 at umass-sim1 bus 1 scbus5 target 0 lun 2
 da1:  Android Adapter 0100 Removable Direct Access SCSI-2 device
 
 On the phone I get a message to turn on usb mass storage after which I
 can mount_msdosfs /dev/da0s1 and get access to the sdcard in the phone.
 
 It looks like mass storage was hidden in 4.0 and maybe removed after 4.2.
 Try searching the android app store for usb mass storage.
 
 Online storage like google drive?
 

Running HEAD-11.

I have a Zopo Z980+ running 4.2.2.  I see this when I plug it in:

Aug 14 08:19:44 ernst kernel: ugen6.2: MediaTek at usbus6
Aug 14 08:19:44 ernst kernel: umass0: Mass Storage on usbus6
Aug 14 08:19:44 ernst kernel: da0 at umass-sim0 bus 0 scbus8 target 0 lun 0
Aug 14 08:19:44 ernst kernel: da0: Linux File-CD Gadget  Removable Direct 
Access SCSI-2 device
Aug 14 08:19:44 ernst kernel: da0: 40.000MB/s transfers
Aug 14 08:19:44 ernst kernel: da0: Attempt to query device size failed: NOT 
READY, Medium not present
Aug 14 08:19:44 ernst kernel: da0: quirks=0x2NO_6_BYTE
Aug 14 08:19:44 ernst kernel: da1 at umass-sim0 bus 0 scbus8 target 0 lun 1
Aug 14 08:19:44 ernst kernel: da1: Linux File-CD Gadget  Removable Direct 
Access SCSI-2 device
Aug 14 08:19:44 ernst kernel: da1: 40.000MB/s transfers
Aug 14 08:19:44 ernst kernel: da1: Attempt to query device size failed: NOT 
READY, Medium not present
Aug 14 08:19:44 ernst kernel: da1: quirks=0x2NO_6_BYTE

This trace corresponds to the internal and external storage.

After enabling USB storage on the phone I can mount the internal
storage, but not the external storage.

You have to be sure that USB debugging is turned off in the
developer options.  These may not even be visible on your
device because Google hid them at around 4.2.

I suspect that you just need some quirks to support the device.

-- 
Gary Jennejohn
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: android bsd connectivity tools etc ?

2014-08-14 Thread Luigi Rizzo
On Thu, Aug 14, 2014 at 09:40:56AM +0200, Lars Engels wrote:
 On Thu, Aug 14, 2014 at 08:29:37AM +0200, Per olof Ljungmark wrote:
  On 08/14/14 01:47, Julian H. Stacey wrote:
   Hi,
   Any tips for Android / FreeBSD BSD tools for connectivity etc ?
...
 There's also Airdroid [1]. After installing the App on the phone you can
 connect to it with your PC's browser, up- and download files, send
 messages, etc.
 
 [1] https://play.google.com/store/apps/details?id=com.sand.airdroid

quite nice (security concerns apart).
Looks also nice as a home monitoring solution.

cheers
luigi
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


installing packages into a mounted system

2014-08-14 Thread Matthias Apitz

Hello,

I've compiled ~1300 packages with poudriere 3.1pre on a 'head' system;
went fine;

mounted below /mnt is a complete new system (an USB key) which boots
fine alreaday; the 1300 resulting *.txz file are copied into /mnt/PKGDIR

in the past, using the pkg_* tools, I could just install the packages
with:

# PKG_PATH=/PKGDIR
# export PKG_PATH
# chroot /mnt pkg_add xorg-7.7
# chroot /mnt pkg_add kde-4.10.5
...

How this can be done now with pkg(8)? I thought I will compile a
pkg-static and move this to into the /mnt system too with

# chroot /mnt mkdir -p /usr/local/sbin
# cp -p /usr/local/sbin/pkg-static /mnt/usr/local/sbin

pkg-static(8) works there, bringing up the help with:

# chroot /mnt /usr/local/sbin/pkg-static help

But, how do I specify that it should install for example xorg-7.7
having its file (and all others) in /mnt/PKGDIR/xorg-7.7.txz 

It seems to look for some files digests.txz or repo.txz which I do not
have:

# PACKAGESITE=file://PKGDIR export PACKAGESITE
# chroot /mnt /usr/local/sbin/pkg-static install xorg-7.7
Updating repository catalogue
pkg-static: file://PKGDIR/digests.txz: No such file or directory
pkg-static: No digest falling back on legacy catalog format
pkg-static: file://PKGDIR/repo.txz: No such file or directory 

Any hints?

Thx

matthias


-- 
Matthias Apitz   |  /\   ASCII Ribbon Campaign:
E-mail: g...@unixarea.de |  \ /   - No HTML/RTF in E-mail
WWW: http://www.unixarea.de/ |   X- No proprietary attachments
phone: +49-170-4527211   |  / \   - Respect for open standards
 | en.wikipedia.org/wiki/ASCII_Ribbon_Campaign
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: installing packages into a mounted system

2014-08-14 Thread Matthias Apitz
El día Thursday, August 14, 2014 a las 09:22:38AM -0400, Nikolai Lifanov 
escribió:

  # PACKAGESITE=file://PKGDIR export PACKAGESITE
  # chroot /mnt /usr/local/sbin/pkg-static install xorg-7.7
  Updating repository catalogue
  pkg-static: file://PKGDIR/digests.txz: No such file or directory
  pkg-static: No digest falling back on legacy catalog format
  pkg-static: file://PKGDIR/repo.txz: No such file or directory 
  
 
 From the man page:
  pkg [-v] [-d] [-l] [-N] [-j jail name or id | -c chroot path]
 
 You could try copying pkg-static inside the chroot and use pkg-static -c
 (from the host, don't invoke the chroot command manually).
 
 I have been installing packages to jails this way for a while.

# pkg-static -c /mnt install xorg-7.7

gives the same error messages as above.

Thanks

matthias
-- 
Matthias Apitz   |  /\   ASCII Ribbon Campaign:
E-mail: g...@unixarea.de |  \ /   - No HTML/RTF in E-mail
WWW: http://www.unixarea.de/ |   X- No proprietary attachments
phone: +49-170-4527211   |  / \   - Respect for open standards
 | en.wikipedia.org/wiki/ASCII_Ribbon_Campaign
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org

Re: installing packages into a mounted system

2014-08-14 Thread Michael Gmelin
On Thu, 14 Aug 2014 15:31:11 +0200
Matthias Apitz g...@unixarea.de wrote:

 El día Thursday, August 14, 2014 a las 09:22:38AM -0400, Nikolai
 Lifanov escribió:
 
   # PACKAGESITE=file://PKGDIR export PACKAGESITE
   # chroot /mnt /usr/local/sbin/pkg-static install xorg-7.7
   Updating repository catalogue
   pkg-static: file://PKGDIR/digests.txz: No such file or directory
   pkg-static: No digest falling back on legacy catalog format
   pkg-static: file://PKGDIR/repo.txz: No such file or directory 
   
  
  From the man page:
   pkg [-v] [-d] [-l] [-N] [-j jail name or id | -c chroot
  path]
  
  You could try copying pkg-static inside the chroot and use
  pkg-static -c (from the host, don't invoke the chroot command
  manually).
  
  I have been installing packages to jails this way for a while.
 
 # pkg-static -c /mnt install xorg-7.7
 
 gives the same error messages as above.
 

Did you run pkg repo on your repo, e.g.

cd mypackerepodir
pkg repo .

If you don't want to use a repo you could also use pkg
add, e.g.

cd $PKGDIR  pkg add xorg-7.7.txz

-- 
Michael Gmelin
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org

Re: PostgreSQL performance on FreeBSD

2014-08-14 Thread John Baldwin
On Tuesday, August 12, 2014 5:36:26 pm Adrian Chadd wrote:
 On 12 August 2014 11:09, John Baldwin j...@freebsd.org wrote:
  On Wednesday, July 16, 2014 1:52:45 pm Adrian Chadd wrote:
  Hi!
 
 
  On 16 July 2014 06:29, Konstantin Belousov kostik...@gmail.com wrote:
   On Fri, Jun 27, 2014 at 03:56:13PM +0300, Konstantin Belousov wrote:
   Hi,
   I did some measurements and hacks to see about the performance and
   scalability of PostgreSQL 9.3 on FreeBSD, sponsored by The FreeBSD
   Foundation.
  
   The results are described in https://kib.kiev.ua/kib/pgsql_perf.pdf.
   The uncommitted patches, referenced in the article, are available as
   https://kib.kiev.ua/kib/pig1.patch.txt
   https://kib.kiev.ua/kib/patch-2
  
   A followup to the original paper.
  
   Most importantly, I identified the cause for the drop on the graph
   after the 30 clients, which appeared to be the debugging version
   of malloc(3) in libc.
  
   Also there are some updates on the patches.
  
   New version of the paper is available at
   https://www.kib.kiev.ua/kib/pgsql_perf_v2.0.pdf
   The changes are marked as 'update for version 2.0'.
 
  Would you mind trying a default (non-PRODUCTION) build, but with junk
  filling turned off?
 
  adrian@adrian-hackbox:~ % ls -l /etc/malloc.conf
 
  lrwxr-xr-x  1 root  wheel  10 Jun 24 04:37 /etc/malloc.conf - junk:false
 
  That fixes almost all of the malloc debug performance issues that I
  see without having to recompile.
 
  I'd like to know if you see any after that.
 
  OTOH, I have actually seen junk profiling _improve_ performance in certain
  cases as it forces promotion of allocated pages to superpages since all 
  pages
  are dirtied.  (I have a local hack that adds a new malloc option to 
  explicitly
  memset() new pages allocated via mmap() that gives the same benefit without
  the junking overheadon each malloc() / free(), but it does increase physical
  RAM usage.)
 
 Hm. this isn't a jemalloc config option?

No, jemalloc does have a 'zero fill' option, but that runs on every malloc so
it is just as expensive as junking.  What my hack does is only zero the pages
when they are first mmap'd, so subsequent free() / malloc() cycles that reuse
the pages do not do any zeroing.

-- 
John Baldwin
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: PostgreSQL performance on FreeBSD

2014-08-14 Thread John Baldwin
On Wednesday, August 13, 2014 1:00:22 pm Alan Cox wrote:
 On Tue, Aug 12, 2014 at 1:09 PM, John Baldwin j...@freebsd.org wrote:
 
  On Wednesday, July 16, 2014 1:52:45 pm Adrian Chadd wrote:
   Hi!
  
  
   On 16 July 2014 06:29, Konstantin Belousov kostik...@gmail.com wrote:
On Fri, Jun 27, 2014 at 03:56:13PM +0300, Konstantin Belousov wrote:
Hi,
I did some measurements and hacks to see about the performance and
scalability of PostgreSQL 9.3 on FreeBSD, sponsored by The FreeBSD
Foundation.
   
The results are described in https://kib.kiev.ua/kib/pgsql_perf.pdf.
The uncommitted patches, referenced in the article, are available as
https://kib.kiev.ua/kib/pig1.patch.txt
https://kib.kiev.ua/kib/patch-2
   
A followup to the original paper.
   
Most importantly, I identified the cause for the drop on the graph
after the 30 clients, which appeared to be the debugging version
of malloc(3) in libc.
   
Also there are some updates on the patches.
   
New version of the paper is available at
https://www.kib.kiev.ua/kib/pgsql_perf_v2.0.pdf
The changes are marked as 'update for version 2.0'.
  
   Would you mind trying a default (non-PRODUCTION) build, but with junk
   filling turned off?
  
   adrian@adrian-hackbox:~ % ls -l /etc/malloc.conf
  
   lrwxr-xr-x  1 root  wheel  10 Jun 24 04:37 /etc/malloc.conf - junk:false
  
   That fixes almost all of the malloc debug performance issues that I
   see without having to recompile.
  
   I'd like to know if you see any after that.
 
  OTOH, I have actually seen junk profiling _improve_ performance in certain
  cases as it forces promotion of allocated pages to superpages since all
  pages
  are dirtied.  (I have a local hack that adds a new malloc option to
  explicitly
  memset() new pages allocated via mmap() that gives the same benefit without
  the junking overheadon each malloc() / free(), but it does increase
  physical
  RAM usage.)
 
 
 
 John,
 
 A couple small steps have been taken toward eliminating the need for this
 hack: the addition of the page size index field to struct vm_page and the
 addition of a similarly named parameter to pmap_enter().  However, at the
 moment, the only tangible effect is in the automatic prefaulting by
 mmap(2).  Instead of establishing 96 4KB page mappings, the automatic
 prefaulting establishes 96 page mappings whose size is determined by the
 size of the physical pages that it finds in the vm object.  So, the
 prefaulting overhead remains constant, but the coverage provided by the
 automatic prefaulting will vary with the underlying page size.

Yes, I think what we might actually want is what I mentioned in person at
BSDCan: some sort of flag to mmap() that malloc() could use to assume that any
reservations are fully used when they are reserved.  This would avoid the need
to wait for all pages to be dirtied before promotion provides a superpage
mapping and would avoid demotions while still allowing the kernel to gracefully
fall back to regular pages if a reservation can't be made.

-- 
John Baldwin
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: Child suspend/resume

2014-08-14 Thread Justin Hibbits
Thanks Alexandr!

- Justin

On Wed, Aug 13, 2014 at 11:33 PM, Alexandr Krivulya
shur...@shurik.kiev.ua wrote:
 I've done three suspend/resume cycle during last workday and all works
 fine. Sorry for misled.

 13.08.2014 18:35, Justin Hibbits пишет:
 That's odd, because another tester reported everything worked correctly
 for him.  Could you send me the output of a verbose boot dmesg (boot
 -v), devinfo -rv, and pciconf -lv?

 Thanks,
 Justin

 On Wed, 13 Aug 2014 09:17:24 +0300
 Alexandr Krivulya shur...@shurik.kiev.ua wrote:

 Now laptop resumes, screen turned on and I see in dmesg acpi: resumed
 at ..., but neither keyboard nor mouse don't work and host is not
 accessible from network.

 12.08.2014 17:06, Justin Hibbits пишет:
 Hi Alexandr,

 Thanks.  I got another confirmation that it didn't work, and may
 have found the cause.  I have another patch that you can find at
 https://phabric.freebsd.org/D590 which fixes a typo that I had made.
 Could you try that?

 (Added current@ so everyone else sees this as well).

 Thanks!

 - Justin

 On Tue, 12 Aug 2014 11:18:29 +0300
 Alexandr Krivulya shur...@shurik.kiev.ua wrote:

 Hi, Justin
 After applying your patch my thinkpad e530 (FreeBSD 11.0-CURRENT,
 amd64) doesn't resume any more - screen remains black.

 11.08.2014 08:30, Justin Hibbits (by way of Justin Hibbits
 chmeeed...@gmail.com) пишет:
 Hi all,

 The attached patch is completely untested, due to lack of existing
 suspendable hardware (no x86 machines).  It does compile cleanly
 against head, though. I don't think it should change any behavior,
 I tried to keep the essence of the code path the same.

 It was suggested that I break up my multipass suspend/resume code
 into incremental parts, so this is part one.  It adds a
 BUS_SUSPEND_CHILD/BUS_RESUME_CHILD, as well as helper functions,
 bus_generic_suspend_child()/bus_generic_resume_child(), and
 modifies the PCI driver to use this new facility.

 I'd like some feedback, and testing of this, to make sure I didn't
 break anything.

 Thanks,
 Justin


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

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

Re: PostgreSQL performance on FreeBSD

2014-08-14 Thread Alan Cox
On 08/14/2014 10:47, John Baldwin wrote:
 On Wednesday, August 13, 2014 1:00:22 pm Alan Cox wrote:
 On Tue, Aug 12, 2014 at 1:09 PM, John Baldwin j...@freebsd.org wrote:

 On Wednesday, July 16, 2014 1:52:45 pm Adrian Chadd wrote:
 Hi!


 On 16 July 2014 06:29, Konstantin Belousov kostik...@gmail.com wrote:
 On Fri, Jun 27, 2014 at 03:56:13PM +0300, Konstantin Belousov wrote:
 Hi,
 I did some measurements and hacks to see about the performance and
 scalability of PostgreSQL 9.3 on FreeBSD, sponsored by The FreeBSD
 Foundation.

 The results are described in https://kib.kiev.ua/kib/pgsql_perf.pdf.
 The uncommitted patches, referenced in the article, are available as
 https://kib.kiev.ua/kib/pig1.patch.txt
 https://kib.kiev.ua/kib/patch-2
 A followup to the original paper.

 Most importantly, I identified the cause for the drop on the graph
 after the 30 clients, which appeared to be the debugging version
 of malloc(3) in libc.

 Also there are some updates on the patches.

 New version of the paper is available at
 https://www.kib.kiev.ua/kib/pgsql_perf_v2.0.pdf
 The changes are marked as 'update for version 2.0'.
 Would you mind trying a default (non-PRODUCTION) build, but with junk
 filling turned off?

 adrian@adrian-hackbox:~ % ls -l /etc/malloc.conf

 lrwxr-xr-x  1 root  wheel  10 Jun 24 04:37 /etc/malloc.conf - junk:false

 That fixes almost all of the malloc debug performance issues that I
 see without having to recompile.

 I'd like to know if you see any after that.
 OTOH, I have actually seen junk profiling _improve_ performance in certain
 cases as it forces promotion of allocated pages to superpages since all
 pages
 are dirtied.  (I have a local hack that adds a new malloc option to
 explicitly
 memset() new pages allocated via mmap() that gives the same benefit without
 the junking overheadon each malloc() / free(), but it does increase
 physical
 RAM usage.)


 John,

 A couple small steps have been taken toward eliminating the need for this
 hack: the addition of the page size index field to struct vm_page and the
 addition of a similarly named parameter to pmap_enter().  However, at the
 moment, the only tangible effect is in the automatic prefaulting by
 mmap(2).  Instead of establishing 96 4KB page mappings, the automatic
 prefaulting establishes 96 page mappings whose size is determined by the
 size of the physical pages that it finds in the vm object.  So, the
 prefaulting overhead remains constant, but the coverage provided by the
 automatic prefaulting will vary with the underlying page size.
 Yes, I think what we might actually want is what I mentioned in person at
 BSDCan: some sort of flag to mmap() that malloc() could use to assume that any
 reservations are fully used when they are reserved.  This would avoid the need
 to wait for all pages to be dirtied before promotion provides a superpage
 mapping and would avoid demotions while still allowing the kernel to 
 gracefully
 fall back to regular pages if a reservation can't be made.


I agree.

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


Re: installing packages into a mounted system

2014-08-14 Thread Matthias Apitz

Hello,

To close this thread: after reading and understandig how it should work,
I have found the following easy solution:

# chroot /mnt pkg-static repo /PKGDIR
Creating repository in /PKGDIR: 83%
...
Packing files for repository: 100%

# chroot /mnt mkdir -p /usr/local/etc/pkg/repos
# vim /mnt/usr/local/etc/pkg/repos/myrepo.conf
# cat /mnt/usr/local/etc/pkg/repos/myrepo.conf

   FreeBSD: {
   url: file:/PKGDIR,
   enabled: true,
   }

# chroot /mnt pkg-static -R /usr/local/etc/pkg/repos/  install autoconf-2.69
Updating repository catalogue
FreeBSD repository is up-to-date
All repositories are up-to-date
The following 5 packages will be affected (of 0 checked):

New packages to be INSTALLED:
autoconf: 2.69
indexinfo: 0.2
perl5: 5.16.3_11
m4: 1.4.17_1,1
autoconf-wrapper: 20131203

The process will require 45 MB more space
13 MB to be downloaded

Proceed with this action [y/N]: y
Fetching autoconf-2.69.txz: 100% of 529 KB   
Fetching indexinfo-0.2.txz: 100% of 6 KB   
Fetching perl5-5.16.3_11.txz: 100% of 12 MB   
Fetching m4-1.4.17_1,1.txz: 100% of 183 KB   
Fetching autoconf-wrapper-20131203.txz: 100% of 4 KB   
Checking integrity... done (0 conflicting)
[1/5] Installing indexinfo-0.2: 100%
[2/5] Installing perl5-5.16.3_11: 100%
[3/5] Installing m4-1.4.17_1,1: 100%
[4/5] Installing autoconf-wrapper-20131203: 100%
[5/5] Installing autoconf-2.69: 100%

# chroot /mnt pkg-static info  
autoconf-2.69  Automatically configure source code on many Un*x 
platforms
autoconf-wrapper-20131203  Wrapper script for GNU autoconf
indexinfo-0.2  Utility to regenerate the GNU info page index
m4-1.4.17_1,1  GNU m4
perl5-5.16.3_11Practical Extraction and Report Language


Works fine. Thanks to the people who designed this new pkg tool.

matthias
-- 
Matthias Apitz   |  /\   ASCII Ribbon Campaign:
E-mail: g...@unixarea.de |  \ /   - No HTML/RTF in E-mail
WWW: http://www.unixarea.de/ |   X- No proprietary attachments
phone: +49-170-4527211   |  / \   - Respect for open standards
 | en.wikipedia.org/wiki/ASCII_Ribbon_Campaign
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


[PATCH] Add locking to mcd(4)

2014-08-14 Thread John Baldwin
This patch adds locking to mcd(4) and marks it MPSAFE.  This patch is against 
HEAD but probably applies to 9 and 10 as well.  Please enable INVARIANTS while 
testing.

http://www.FreeBSD.org/~jhb/patches/mcd_locking.patch

-- 
John Baldwin
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


[PATCH] Replace timeout(9) with callout(9) in ips(4)

2014-08-14 Thread John Baldwin
This patch converts the ips(4) driver to the callout(9) API and adds 
additional locking to remove its use of Giant.  The patch is against HEAD but 
probably applies to 9 and 10 as well.  Please test with INVARIANTS enabled.

http://www.FreeBSD.org/~jhb/patches/ips_callout.patch

-- 
John Baldwin
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


[PATCH] Switch ofw_console(4) to callout(9)

2014-08-14 Thread John Baldwin
This patch switches the ofw_console driver from timeout(9) to callout(9).  The 
patch is against HEAD but it probably applies to 9 and 10.  Please test with 
INVARIANTS enabled.

http://www.FreeBSD.org/~jhb/patches/ofw_console_callout.patch

-- 
John Baldwin
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


[PATCH] Add locking to iir(4)

2014-08-14 Thread John Baldwin
This patch fixes various issues in the iir(4) driver and adds locking to make 
it MPSAFE.  The patch is against HEAD though I expect it probably applies to 
9 and 10 as well.  Please test with INVARIANTS enabled.

http://www.FreeBSD.org/~jhb/patches/iir_locking.patch

-- 
John Baldwin
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


[PATCH] Add locking to mly(4)

2014-08-14 Thread John Baldwin
This patch adds locking to mly(4) and marks it MPSAFE.  This patch is against 
HEAD but probably applies to 9 and 10 as well.  Please enable INVARIANTS while 
testing.

http://www.FreeBSD.org/~jhb/patches/mly_locking.patch

-- 
John Baldwin
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


[PATCH] Switch pst(4) to callout(9)

2014-08-14 Thread John Baldwin
This patch switches the pst(4) driver from timeout(9) to callout(9).  It also 
cleans up detach a bit.  The patch is against HEAD but probably applies to 9 
and 10.  Please test with INVARIANTS enabled.

http://www.FreeBSD.org/~jhb/patches/pst_callout.patch

-- 
John Baldwin
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: android bsd connectivity tools etc ?

2014-08-14 Thread Thiago Barroso Perrotta
Nowadays I'm using syncthing [1] for file transfer. ADB over WIFI also
works great.

[1]: http://svnweb.freebsd.org/ports/head/net/syncthing/

PS.: Sorry if I've sent you multiple e-mails.


2014-08-13 20:47 GMT-03:00 Julian H. Stacey j...@berklix.com:

 Hi,
 Any tips for Android / FreeBSD BSD tools for connectivity etc ?

 I just got a Samsung Galaxy Note 3, with Android 4.4.2 kernel 3.4.0

 It directs me to
 https://www.android.com/filetransfer/
 which seems binary for mac

 I recall I will need current for IP tethering

 http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-usb-tethering.html

 http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-aggregation.html#networking-lagg-wired-and-wireless

 I'll build a current from a 10.0-RELEASE partition,
 but now looking with 9.2-RELEASE I see:

 /dev/
 lrwxr-xr-x  1 root  wheel9 Aug 14 00:01 ugen1.5@ - usb/1.5.0
 crw---  1 root  operator  0x7a Aug 14 00:00 usb/1.5.0
 crw---  1 root  operator  0x8f Aug 14 00:00 usb/1.5.1
 crw---  1 root  operator  0x90 Aug 14 00:00 usb/1.5.2

 devd .conf will need:
match   vendor0x04e8;
match   product   0x6860;
match   devclass  0x00;
match   devsubclass   0x00;
match   sernum6758498c;
match   release   0x0400;
 I've no idea what to do for attach

 http://www.freebsd.org/cgi/ports.cgi?query=androidstype=all
 has just
 /usr/ports/devel/android-tools-adb/pkg-descr
  these for cross compiling later:
 /usr/ports/lang/*gnatdroid*/pkg-descr

 I also found
 ports/
 deskutils/tine20
 net/crtmpserver
 net/linphone
 https://source.android.com/source/index.html

 Any URLs, tips, comments welcome, Thanks

 Cheers,
 Julian
 --
 Julian Stacey, BSD Linux Unix'78 C Sys Eng Consultant Munich
 http://berklix.com
 Interleave replies Below, like a play script.
 ___
 freebsd-current@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-current
 To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org




-- 

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


Re: android bsd connectivity tools etc ?

2014-08-14 Thread Thiago Barroso Perrotta
Nowadays I'm using syncthing [1] for file transfer. ADB over WIFI also
works great.


[1]: http://svnweb.freebsd.org/ports/head/net/syncthing/


2014-08-14 8:47 GMT-03:00 Luigi Rizzo ri...@iet.unipi.it:

 On Thu, Aug 14, 2014 at 09:40:56AM +0200, Lars Engels wrote:
  On Thu, Aug 14, 2014 at 08:29:37AM +0200, Per olof Ljungmark wrote:
   On 08/14/14 01:47, Julian H. Stacey wrote:
Hi,
Any tips for Android / FreeBSD BSD tools for connectivity etc ?
 ...
  There's also Airdroid [1]. After installing the App on the phone you can
  connect to it with your PC's browser, up- and download files, send
  messages, etc.
 
  [1] https://play.google.com/store/apps/details?id=com.sand.airdroid

 quite nice (security concerns apart).
 Looks also nice as a home monitoring solution.

 cheers
 luigi
 ___
 freebsd-current@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-current
 To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org




-- 

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


Re: android bsd connectivity tools etc ?

2014-08-14 Thread Thiago Barroso Perrotta
Nowadays I'm using syncthing [1] for file transfer. ADB over WIFI also
works great.

[1]: http://svnweb.freebsd.org/ports/head/net/syncthing/
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: android bsd connectivity tools etc ?

2014-08-14 Thread Adam Vande More
On Wed, Aug 13, 2014 at 6:47 PM, Julian H. Stacey j...@berklix.com wrote:

 Hi,
 Any tips for Android / FreeBSD BSD tools for connectivity etc ?

 I just got a Samsung Galaxy Note 3, with Android 4.4.2 kernel 3.4.0

 It directs me to
 https://www.android.com/filetransfer/
 which seems binary for mac

 I recall I will need current for IP tethering

 http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-usb-tethering.html

 http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-aggregation.html#networking-lagg-wired-and-wireless

 I'll build a current from a 10.0-RELEASE partition,
 but now looking with 9.2-RELEASE I see:

 /dev/
 lrwxr-xr-x  1 root  wheel9 Aug 14 00:01 ugen1.5@ - usb/1.5.0
 crw---  1 root  operator  0x7a Aug 14 00:00 usb/1.5.0
 crw---  1 root  operator  0x8f Aug 14 00:00 usb/1.5.1
 crw---  1 root  operator  0x90 Aug 14 00:00 usb/1.5.2

 devd .conf will need:
match   vendor0x04e8;
match   product   0x6860;
match   devclass  0x00;
match   devsubclass   0x00;
match   sernum6758498c;
match   release   0x0400;
 I've no idea what to do for attach

 http://www.freebsd.org/cgi/ports.cgi?query=androidstype=all
 has just
 /usr/ports/devel/android-tools-adb/pkg-descr
  these for cross compiling later:
 /usr/ports/lang/*gnatdroid*/pkg-descr

 I also found
 ports/
 deskutils/tine20
 net/crtmpserver
 net/linphone
 https://source.android.com/source/index.html

 Any URLs, tips, comments welcome, Thanks


Android can run an sshd server as well as a socks proxy.


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