Re: Activating libssp

2012-05-30 Thread Jeremie Le Hen
Mel,

On Tue, May 29, 2012 at 02:54:06PM +0200, Mel Flynn wrote:
 On 28-5-2012 23:22, Jeremie Le Hen wrote:
  
  I'm not sure what you mean, but -fstack-protector is documented in GCC
  documentation, I suppose it's the same for Clang but I didn't check.
  You can disable it on FreeBSD by setting WITHOUT_SSP in src.conf(5).
 
 Right, I wasn't very clear with that, so let me clarify:
 - _FORTIFY_SOURCE is used in /usr/include/ssp/ssp.h
 - There is a shared library /lib/libssp.so
 - In the sources of the software there is no mention of ssp.h or -lssp
 - In the sources of the software there are conditionals based on
 _FORTIFY_SOURCE being defined.
 
 So, for me as port maintainer, it looks as though adding
 -D_FORTIFY_SOURCE=2 does absolutely nothing for the software, unless I
 also #include ssp/ssp.h and add -lssp to LDFLAGS, unless there's some
 magic in libc or the compiler that activates bits and overrides the
 definitions for the symbols.
 Based on the commit message, I assume that adding _FORTIFY_SOURCE to
 CFLAGS does nothing, as the actual setting of this flag is compiled into
 libc.
 And -fstack-protector tells the compiler to activate the stack protector
 callbacks that are again, implemented in libc. Without this, they won't
 be activated. Does this sound correct?

This is correct.  The only way to activate SSP is to use
-fstack-protector (or -fstack-protector-all).  In the near future I
intend to add a knob to enable this on all ports (at least on all which
honor our CFLAGS), but this requires a patch to the base system which,
in turn, requires an exp run before being committed (requested in PR
168010).

So I would advice you not wasting your time to enable SSP on a per-port
basis unless you have a strong need for it.  Simply ensure that it
honors CFLAGS and hopefully this will be turned on before the end of
summer.

-- 
Jeremie Le Hen

Men are born free and equal.  Later on, they're on their own.
Jean Yanne
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to freebsd-hackers-unsubscr...@freebsd.org


Re: Please help me diagnose this crazy VMWare/FreeBSD 8.x crash

2012-05-30 Thread John Baldwin
On Thursday, May 24, 2012 9:47:46 am Mark Felder wrote:
 On Wed, 23 May 2012 17:30:40 -0500, Adrian Chadd adr...@freebsd.org  
 wrote:
 
  Hi,
 
  can you please, -please- file a PR? And place all of the above
  information in it so we don't lose it?
 
 
 I'd be glad to post a PR and assist in helping to get it permanently  
 fixed. I certainly don't want this data to get lost and honestly our  
 business uses FreeBSD on VMWare so much that we really need a permanent  
 fix as much as anyone else :-)
 
 The reason I've hesitated to post a PR so far is that I didn't have any  
 truly useful or concrete evidence of where the problem lies. After Dane  
 Foster contacted me and told me he could recreate the crash on demand with  
 his workload it was easier to narrow things down. The suggestion that it  
 was an interrupts issue (by possibly Bjoern Zeeb?) and Dane's discovery  
 that his crashes ceased when em0 and mpt0 share an IRQ, but em0 is  
 completely unused was starting to prove there is some strong evidence here  
 in favor of the interrupts issue.
 
 Dane, what's the status on your end? Has your fix still been successful?  
 Is it also stable if you simply set hint.mpt.0.msi_enable=1 ?

Hmm, so the set of ps output you have from DDB shows a lot of runnable 
processes and swi6 (Giant taskq) as the only running thread (all consistent
with your hang).  (And that is from your Ctrl-Alt-Esc)

Do you only have one CPU in this VM?  If not, do you know which threads
the other CPUs were running (e.g. do you have ps7.png, etc.)?

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


Re: ULE/sched issues on stable/9 - why isn't preemption occuring?

2012-05-30 Thread John Baldwin
On Tuesday, May 29, 2012 4:08:23 pm Adrian Chadd wrote:
 Hi Alexander and others,
 
 I've been tinkering with ath(4) IO scheduling and taskqueues. In order
 to get proper in order TX IO occuring, I've placed ath_start() into
 a taskqueue so now whenever ath_start() is called, it just schedules a
 taskqueue entry to run.
 
 However, performance is worse. :-)
 
 Here's a schedgraph trace.
 
 http://people.freebsd.org/~adrian/ath/ktr.4-ath-iperf-using-taskqueue-for-
tx.ktr.gz
 
 I've thrown this through schedgraph.py on stable/9 and I've found some
 rather annoying behaviour. It seems that the ath0 taskqueue stays in
 the runq add state for quite a long time (1.5ms and longer) because
 something else is going on on CPU #0.
 
 I'm very confused about what's going on. I'd like a hand trying to
 figure out why the schedgraph output is the way it is.
 
 Thanks!

As mentioned on IRC, you need to disable powerd and set machdep.idle=spin
and get new traces.  Right now your traces show multiple things executing
on a single CPU.

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


Re: Please help me diagnose this crazy VMWare/FreeBSD 8.x crash

2012-05-30 Thread Mark Felder

On Wed, 30 May 2012 10:06:13 -0500, John Baldwin j...@freebsd.org wrote:



Do you only have one CPU in this VM?  If not, do you know which threads
the other CPUs were running (e.g. do you have ps7.png, etc.)?


correct, only one CPU in the VM
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to freebsd-hackers-unsubscr...@freebsd.org


Re: proper newfs options for SSD disk

2012-05-30 Thread Wojciech Puchar

...
# geli attach /dev/md1
Enter passphrase:
# dd if=/dev/md1.eli of=/dev/null bs=128k count=4k
536868864 bytes transferred in 35.093015 secs (15298454 bytes/sec)
# dd if=/dev/zero of=/dev/md1.eli bs=128k count=4k
536868864 bytes transferred in 38.044995 secs (14111419 bytes/sec)
# geli detach /dev/md1
# mdconfig -d -u 1

As you can see the EeePC with it's Intel Celeron CPU of only 900 MHz is
even faster then the Acer with Atom CPU;


yes this is normal. Intel Atom have low IPC, but high IPJ (instruction per 
joule, still low compared to ARM). Yet - if you have hyperthreading it is 
actually not bad in IPC too with 2 threads.


I generally think intel atom is great x86 processor as you simply do not 
need more power for PERSONAL computer.



BTW: On the EeePC I run 10-CURRENT, KDE 3.5.10 and never encounter
performance issues while reading, writing etc.


right. It is normal. Even KDE is not that really that CPU bound, but still 
useless.



Concerning your hint installing the systen on the second SSD of around
16 GByte (marketing GBytes :-)), the BIOS by itself is unable to boot

right. 16 billion bytes.

A simple marketing trick to cheat you for 7.6%


from; one has to go (by pressing ESC) to the boot menu to pick it up as
current boot device; any idea how this could be changed?


boot from 4GB. just put /boot here and add

vfs.root.mountfrom=ufs:XXX

where XXX is your root filesystem device name with /dev/ stripped

do not forget to bsdlabel -B your.4GB.SSD

WARNING: you must have proper disklabel with a: partition containing UFS 
with /boot.


But you may have a partition equal to whole disk

  a:  117231408  04.2BSD0 0 0
  c:  117231408  0unused0 0 # raw part, don't edit


and it is absolutely OK, UFS do not overwrite first few sectors as it is 
reserved for it.


And PLEASE DO NOT make this stupid MSDOS style slices. It is not just 
unneeded but introduces mess and only mess.


just have /dev/ad0a not /dev/ad0s1a

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


Re: TeXLive merge into FreeBSD ports tree - FreeBSD project idea

2012-05-30 Thread Aldis Berjoza
On Sat, 26 May 2012 22:45:37 +1200
Sam Lin sam.lin...@gmail.com wrote:

  Hi FreeBSD fellows,
 
 Those who are using LaTeX on FreeBSD must know that tetex has been
 discontinued years ago and that TeXLive is now recommended, however
 TeXLive has never been merged in the ports tree on FreeBSD and that
 tetex is still used on FreeBSD ports. Although there have been some
 customized work so that FreeBSD users can install and use TeXLive
 on FreeBSD machine (for example,
 http://code.google.com/p/freebsd-texlive/wiki/Installing), this is
 quite confusing and may still cause conflict on the system side when
 using or maintaining it.
 
 There has also been years of gossips that a Japanese developer Hiroki
 Sato (hrs@freebsd) has been working on this matter for the last years
 and therefore the FreeBSD admin panel don't want anyone else to work
 on this and merge it into the ports tree.
 
 I actually contacted Hiroki Sato in the beginning of last year (2011)
 regarding this, and in his reply he said that there had been several
 technical issues but most of them had been solved and almost ready to
 merge into the port tree, and that he was planning to go forward
 after the 8.2/7.4 releases (one or two weeks later from that time
 stage) are out. However, more than a year has passed since then and
 still nothing happened. I tried to contact him several times after
 that (email, tweet, etc) but haven't heard anything back from him at
 all.
 
 Is TeXLive really going to be merged into the FreeBSD ports tree as
 Hiroki Sato mentioned previously? Or is this just a myth??
 
 I am now thinking that this should be put into the FreeBSD Project
 ideas List [http://wiki.freebsd.org/IdeasPage].
 
 Regards,
 Sam


Hey, Sam!

I which TeXLive would be merged in FreeBSD ports. Romain is doing great
job maintaining it. And it work, And it work now. In fact it works for
more than a year.


-- 
Aldis Berjoza


signature.asc
Description: PGP signature


Re: proper newfs options for SSD disk

2012-05-30 Thread Matthias Apitz
El día Wednesday, May 30, 2012 a las 07:44:37PM +0200, Wojciech Puchar escribió:

  Concerning your hint installing the systen on the second SSD of around
  16 GByte (marketing GBytes :-)), the BIOS by itself is unable to boot
 right. 16 billion bytes.
 
 A simple marketing trick to cheat you for 7.6%

I think, it's only 7.3%

$ bc
(16*1024*1024*1024-160)/160*100
7.300

but it's just to cheat you; and nobody cares about 1179869184 bytes, more
then 1 billion of bytes :-(

matthias
-- 
Matthias Apitz
e g...@unixarea.de - w http://www.unixarea.de/
UNIX since V7 on PDP-11, UNIX on mainframe since ESER 1055 (IBM /370)
UNIX on x86 since SVR4.2 UnixWare 2.1.2, FreeBSD since 2.2.5
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to freebsd-hackers-unsubscr...@freebsd.org


usertime stale at about 371k seconds

2012-05-30 Thread Andrey Zonov

Hi,

I have long running process for which `ps -o usertime -p $pid' shows 
always the same time - 6190:07.65, `ps -o cputime -p $pid' for the same 
process continue to grow and now it's 21538:53.61.  It looks like 
overflow in resource usage code or something.


Any ideas?

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


Re: Please help me diagnose this crazy VMWare/FreeBSD 8.x crash

2012-05-30 Thread John Baldwin
On Wednesday, May 30, 2012 12:07:50 pm Mark Felder wrote:
 On Wed, 30 May 2012 10:06:13 -0500, John Baldwin j...@freebsd.org wrote:
 
 
  Do you only have one CPU in this VM?  If not, do you know which threads
  the other CPUs were running (e.g. do you have ps7.png, etc.)?
 
 correct, only one CPU in the VM

Humm, can you test it with 2 CPUs?

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


Re: Please help me diagnose this crazy VMWare/FreeBSD 8.x crash

2012-05-30 Thread Mark Felder

On Wed, 30 May 2012 12:17:07 -0500, John Baldwin j...@freebsd.org wrote:



Humm, can you test it with 2 CPUs?



We primarily only run with 1 CPU. We have seen it crash on multiple CPU  
VMs. Also, Dane Foster appeared to have been using multiple CPUs in his  
video transcoding VMs.


Unfortunately I can't give you more information at the moment. I'm working  
with Dane to compile easy to follow steps that recreate this failure. I  
have not been successful in getting this to crash on demand in my  
environment, but Dane has so we're trying to recreate his.

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


Re: ULE/sched issues on stable/9 - why isn't preemption occuring?

2012-05-30 Thread Adrian Chadd
Hi,

I've re-run the test with powerd and sleep state stuff disabled - lo
and behold, UDP tests are now up around 240-250MBit, what I'd expect
for this 2 stream 11n device.

So why is it that I lose roughly 80MBit of throughput with powerd and
C2/C3 enabled, when there's plenty of CPU going around? The NIC
certainly isn't going to sleep (I've not even added that code.)



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


Re: proper newfs options for SSD disk

2012-05-30 Thread Wojciech Puchar

Concerning your hint installing the systen on the second SSD of around
16 GByte (marketing GBytes :-)), the BIOS by itself is unable to boot

right. 16 billion bytes.

A simple marketing trick to cheat you for 7.6%


I think, it's only 7.3%

$ bc
(16*1024*1024*1024-160)/160*100
7.300


thanks.


but it's just to cheat you; and nobody cares about 1179869184 bytes, more
then 1 billion of bytes :-(


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