Re: [gentoo-user] g++ -fnothrow-opt

2014-01-26 Thread Florian Philipp
Am 22.01.2014 18:42, schrieb Florian Philipp:
 Hi list!
 
 I'm wondering if anyone tried setting -fnothrow-opt as a CXX_FLAG in
 make.conf?
 
 It makes C++ throw() statements behave like C++11 nothrow. This could
 have measurable performance benefits and will reduce code size. The only
 downside is that, when a function violates its throw() guarantee,
 terminate() will be called instead of unexpected().
 
 However, neither function is allowed to do anything but terminate the
 program. So all you possibly lose is a meaningful error message just
 before the program crashes.
 
 So, what do you think? Safe to enable by default?
 
 Thanks in advance!
 Florian Philipp
 

As a follow-up:
I grepped all distfiles to identify candidates for testing this flag.
The only package that I have installed (KDE desktop) that makes regular
use of throw() statements is LibreOffice. However, since LO already
enables the similar -fno-enforce-eh-specs flag, there seems to be no
significant advantage in enabling -fnothrow-opt.

Other packages only use these statements in the rare cases that it is
required for STL compatibility (subclassing extensions, specializing
templates).

For now I add -fno-enforce-eh-specs and -fnothrow-opt to my CXXFLAGS but
I doubt it will help much.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Portage performance dropped considerably

2014-01-26 Thread Florian Philipp
Am 26.01.2014 15:35, schrieb Nikos Chantziaras:
 Anyone else noticed this yet? Some portage update seems to have made
 emerge -uDN @world perform about 10 times slower than before. It used
 to take seconds, now it takes about 4 minutes only to tell me that
 there's nothing to update. And it does that every time, even directly in
 succession and with the caches warm.
 
 Is it just me?
 
 

As a remedy, you can try to use portage with pypy. I've used this setup
for half a year and it works well.

make.conf:
PYTHON_TARGETS=python2_7 python3_3 pypy2_0

/etc/portage/package.keywords:
dev-python/pypy
virtual/pypy

/etc/portage/package.use:
sys-apps/portage pypy2_0

/etc/portage/profile/package.use.mask
sys-apps/portage -python_targets_pypy2_0 -pypy2_0

I could give you figures for the performance improvement but they are
probably not very helpful as I have 289 overlays active. That means
portage regularly requires more than a Gig memory for dependency
calculation.

Downsides:
- emerging pypy takes forever and uses a lot of memory
- userfetch and userpriv don't work

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Portage performance dropped considerably

2014-01-26 Thread Florian Philipp
Am 26.01.2014 17:15, schrieb hasufell:
 On 01/26/2014 05:06 PM, Florian Philipp wrote:
 Downsides:
 - emerging pypy takes forever and uses a lot of memory
 - userfetch and userpriv don't work

 
 
 It also regularly causes segfaults.
 
 zmedico/#gentoo-portage hasufell: yeah, I get random segfaults with
 pypy also (always seems to be in libc iirc)
 

Not on my machine. YMMV.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


[gentoo-user] g++ -fnothrow-opt

2014-01-22 Thread Florian Philipp
Hi list!

I'm wondering if anyone tried setting -fnothrow-opt as a CXX_FLAG in
make.conf?

It makes C++ throw() statements behave like C++11 nothrow. This could
have measurable performance benefits and will reduce code size. The only
downside is that, when a function violates its throw() guarantee,
terminate() will be called instead of unexpected().

However, neither function is allowed to do anything but terminate the
program. So all you possibly lose is a meaningful error message just
before the program crashes.

So, what do you think? Safe to enable by default?

Thanks in advance!
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] look for a file type + sort

2013-09-14 Thread Florian Philipp
Am 14.09.2013 06:04, schrieb Mark David Dumlao:
 
 On Sep 13, 2013 9:53 PM, Yuri K. Shatroff yks-...@yandex.ru
 mailto:yks-...@yandex.ru wrote:

 On 13.09.2013 17:43, Mark David Dumlao wrote:

 On Fri, Sep 13, 2013 at 9:36 PM, Yuri K. Shatroff yks-...@yandex.ru
 mailto:yks-...@yandex.ru wrote:

 On 13.09.2013 10:24, Jean-Christophe Bach wrote:
 [ ... ]


 This one should work:

 find /home/joseph/ -iname *.pdf -exec ls -l --sort=time {} +



 -exec is not suitable here because it spawns a `ls` process per each
 found
 entry; aside from being slow, this disallows sorting at all.


 This is incorrect. If you terminate exec with '+' instead of '\;',
 only a single
 instance of the command is run - the command line is built by appending
 each found file to the end of the {} placeholder.


 Sorry, I'm ashamed
 I didn't know about this feature. Does it also handle spaces correctly?

 
 I'm not sure how the internals work. As best as I can guess, it
 constructs the argv directly so spaces shouldn't be an issue. Spaces are
 an issue when the output is piped through, since the pipe itself knows
 no difference between filename and output spaces, hence the need to
 force zero delimiters between filenames. Since find runs the command
 directly, you shouldn't encounter this. But Ive yet to test.
 

Your assumption is correct. exec cannot be fooled with whitespaces.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] look for a file type + sort

2013-09-13 Thread Florian Philipp
Am 13.09.2013 08:24, schrieb Jean-Christophe Bach:
 * Canek Peláez Valdés can...@gmail.com [13.09.2013. @00:16:51 -0500]:
 
 On Fri, Sep 13, 2013 at 12:11 AM, Joseph syscon...@gmail.com wrote:
 On 09/13/13 00:04, Canek Peláez Valdés wrote:

 On Thu, Sep 12, 2013 at 11:58 PM, Canek Peláez Valdés can...@gmail.com
 wrote:

 On Thu, Sep 12, 2013 at 11:48 PM, Joseph syscon...@gmail.com wrote:

 I want to list recursively certain type of files eg. *.pdf but I want to
 display: date, path and newest file first.

 What is the easiest way of doing it?


 ls -l --sort=time $(find /path -iname *.pdf)

 If there are no spaces in the filenames/directories, you can drop the
 quotes from $().


 Sorry, it doesn't work with spaces even with the quotes; if you don't
 have spaces in the directories/filenames, do

 ls -l --sort=time $(find /path -iname *.pdf)

 If you have spaces, you need to set/restore IFS:

 S=${IFS}; IFS=$'\n'; ls -l --sort=time $(find . -iname *.pdf); IFS=${S}

 Regards.
 --
 Canek Peláez Valdés
 Posgrado en Ciencia e Ingeniería de la Computación
 Universidad Nacional Autónoma de México


 Hm, I've tried:
 ls -l --sort=time $(find /home/joseph -iname *.jpg)

 got:
 ls: invalid option -- '/'

 The exact same command (changing joseph with canek) works for me,
 except in directories/filenames with spaces, as expected. Do you have
 an alias for ls? What does find /home/joseph -iname *.jpg returns?

 Regards.
 -- 
 Canek Peláez Valdés
 
 Hi,
 
 This one should work:
 
 find /home/joseph/ -iname *.pdf -exec ls -l --sort=time {} +
 
 Regards,
 
 JC
 

This won't work if there are too many files because find will eventually
start ls multiple times.

Try this instead:
find /path -iname '*.pdf' -printf '%T@\t%Tc\t%p\n' | sort -nr |
cut -f 2-

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Two RTCs - how to choose in dependence of existence to eth0

2013-08-22 Thread Florian Philipp
Am 22.08.2013 19:24, schrieb meino.cra...@gmx.de:
 Hi,
 
 there are two RTC in my system. One is powered by the 
 power of the system itsself and will forget space and
 time if the system is powered off. This is RTC0.
 The second one is powered by a little CR3216. This one
 will not forget the time. This is RTC1
 The system itsself is portable and will be used with and
 without access to the internet (no ethernet, no eth0).
 
 Surely it is possible to hack together a script which will
 run at boot time to figure out the source of the valid time.
 But this is somehow less elegant and gentoo-ish as it should be.
 
 I didnt found an application (via eix) which address this problem.
 
 What is the recommended way to accomplish this task?
 
 Thank you very much in advance for any help!
 Best regards,
 mcc
 

I'm slightly confused. Do you need to use rtc0 at all? You can simply
configure your kernel to use rtc1 with CONFIG_RTC_HCTOSYS_DEVICE.

And for the hwclock init script you could add -f /dev/rtc1 to the options.

What else is there to do?

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] more on SSD: swap

2013-07-21 Thread Florian Philipp
Am 21.07.2013 17:39, schrieb luis jure:
 on 2013-07-21 at 15:42 Peter Wilmott wrote:
 
 TBH, unless you are really stressing your RAM usage (Lots of VMs or Java 
 applications, stuff like that) I'd go without swap.
 
 it's true that most of the time 12BG is more than enough for me and i
 don't use swap space on disk. i wouldn't go for a swapless system, though,
 specially since i'm going to put things on tmpfs.
 
 a few GB (i'm thinking about 8) of swap space on disk won't hurt, and i'd
 feel safer. that's the idea of reducing swappiness to 1 or 0, anyway.
 

Also think about using zswap or frontswap. Both work well despite still
being in staging in current kernels. Zswap will be stabilized in kernel
3.11, I think.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Filesystem recommendation for external media storage

2013-06-26 Thread Florian Philipp
Am 26.06.2013 16:22, schrieb Alan McKinnon:
 On 26/06/2013 15:09, Frank Steinmetzger wrote:
 Hi list

 By chance I found an external 3 TB disk for a bargain and now I’m planning 
 its
 partitioning. I am thus looking for a filesystem that doesn’t necessarily
 need file permissions to function, the reason being that I might want to take
 the disk to other people in order to copy files around. That’s why I don’t
 really want to use ext4 (my FS of choice for everything else).

[...]

 Windows compatibility is not a must, but a nice-to-have. That would reduce my
 remaining choices to ExFAT, I presume.
 

BTW: What's the Linux status on that one?

 
 That's how I see it too.
 
 I used to use ext4 for external media but quickly found that my notebook
 was the only box that could use them...
 

Isn't group id 100 defined as the users group on most Linuxen nowadays?

chgrp 100 $mount  chmod 2777 $mount

should work reasonably well.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] File system meta-data indexer / checker

2013-06-16 Thread Florian Philipp
Am 16.06.2013 23:14, schrieb Ciprian Dorin Craciun:
 Hello all!
 
 While struggling with managing various old backups --- just
 imagine 10 or so copies of almost the same content, some with `rsync`,
 some with `rdiff-backup`, yet some others on plain ISO's, all over a
 range of a few years --- I stumbled upon the following missing piece
 in the Linux tools ecosystem:  a file-system crawler that records
 **only** meta-data, like all the info available through `stat`, plus
 an assortment of hashes of the files (at least MD5 and SHA-1,2
 family), and optionally ACL's and extended attributes.  Thus I was
 wondering if someone knows a tool that fits this description.
 
 
[...]
 
 Thus, are there any other alternatives?  (Just to be clear, I
 don't need a backup solution, just something to record file-system
 meta-data.  Maybe a meta-backup solution... :) )
 
 Ciprian.
 

Do you mean something like `cp --attributes-only`?

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Dolphin's nfs:// kioslave transfers files slowly

2013-05-11 Thread Florian Philipp
Am 09.05.2013 17:01, schrieb Alan McKinnon:
 Hi,
 
 Dolphin has a kioslave for nfs, used as nfs:// and mine runs slowly :-)
 
 A transfer from my laptop to my media server using a regular nfs mount
 runs at max speed (100Mb) over the LAN.
 Using nfs:// it's 15% of that at most, usually around 10Mb or so.
 I see the same thing at the office when comparing smb:// and a regular
 smbfs mount using cifs.
 
 I'm clueless about where to even start looking :-)
 What could explain this behaviour?
 
 [nfs:// and smb:// seem to use libs that implement those protocols, much
 like how XBMC uses libnfs, KDE just doesn't use the libnfs project to do it]
 

Try watching it in Wireshark and compare a normal NFS mount vs. Dolphin.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Delays while building Libre Office.

2013-05-04 Thread Florian Philipp
Am 02.05.2013 18:27, schrieb Alan Mackenzie:
 Hi, Gentoo.
 
 I've just built libreoffice-3.6.6.2 and it took 2 hours 10 minutes on my
 2.6 GHz quad core Athlon 2.  It used to take about an hour.
 
 Watching the build, it became evident that the first 50 minutes or so
 was taken up by several hundred mkdir operations (more precisely, mkdir
 -p long path).  Some of these mkdir's would take, perhaps, a minute to
 execute.  All the while, top showed make taking 100% of one core.
 
 There seems to be something suboptimal here.  Has anybody else seen
 this, or does anybody have any ideas how to fix the problem?
 

I'm seeing the same behavior here.
libreoffice-3.6.6.2 on a mostly stable system.
btrfs on lvm on dmcrypt on a hybrid disk.
kernel 3.7.5 pf-sources.

I don't think is has anything to do with the file system or hardware.
make is eating 200M memory and uses 100% CPU, not mkdir. I guess the
script is just buggy.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Partitions - last questions...

2013-04-28 Thread Florian Philipp
Am 24.04.2013 18:12, schrieb Tanstaafl:
 On 2013-04-24 11:31 AM, Florian Philipp li...@binarywings.net wrote:
 Am 24.04.2013 17:12, schrieb Tanstaafl:
 Ok, but - does it make sense to add the noexec option to /var/tmp? Is it
 possible that there are other apps that need exec capability in there?
 
 It makes sense. Any world-writable directory should be noexec to make
 script injection harder. Other directories, too, like /var/www (if you
 can, i.e. no cgi). I cannot tell you if any application might need it.
 Try it. It is easy enough to revert, maybe even with a `mount -o
 remount`, I'm not sure.

 Also, look at
 http://serverfault.com/questions/72356/how-useful-is-mounting-tmp-noexec
 
 Hmmm, this only talks about /tmp... I'm talking about /var/tmp...
 
 So, I guess you're right, I'll just need to try it and see...
 

Just stumbled across this:
http://blog.siphos.be/2013/04/securely-handling-libffi/

Might be relevant, might be not.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Partitions - last questions...

2013-04-24 Thread Florian Philipp
Am 24.04.2013 12:48, schrieb Tanstaafl:
 On 2013-04-23 1:59 PM, Neil Bothwick n...@digimed.co.uk wrote:
 On Tue, 23 Apr 2013 18:34:38 +0200, Florian Philipp wrote:

 So - first, is 5G way too big for the two /tmp dirs? I have lots of
 space, but hate waste
 
 If you worry about waste consider bind-mounting both from the same
 partition and install quotas to avoid one filling up the other.

 Or set PORTAGE_TMPDIR to use /tmp. Then /var/tmp will be so small you
 can leave it as a sub-directory of /var.

 If this is a server, 5G is fine for this, but for a desktop it may need
 to be bigger, to accommodate LibreOffice builds.
 
 One thing I'm trying to do is make the system as secure as possible at
 the filesystem level, and I've read that making /tmp and /var/tmp
 separate partitions so you can mount them /nodev/noexec/nosuid is one
 way to make things a bit more secure...

noexec won't work for portage so put PORTAGE_TMPDIR somewhere else.

 
 On that note, I realized I can't make two /tmp's in lvm, so, I guess I
 can make a vtmp, and just bind that to /var/tmp in fstab like:
 
 /dev/vg/vtmp/var/tmp ext4 nodev,noexec,nosuid 0 0
 
 Will that work?

Sure why not but you should set the pass column to 2 instead of 0.

Regards,
Florian Philipp





signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Partitions - last questions...

2013-04-24 Thread Florian Philipp
Am 24.04.2013 17:12, schrieb Tanstaafl:
 On 2013-04-24 8:48 AM, Florian Philipp li...@binarywings.net wrote:
 One thing I'm trying to do is make the system as secure as
 possible at the filesystem level, and I've read that making /tmp
 and /var/tmp separate partitions so you can mount them
 /nodev/noexec/nosuid is one way to make things a bit more
 secure...
 
 noexec won't work for portage so put PORTAGE_TMPDIR somewhere else.
 
 Ok, but - does it make sense to add the noexec option to /var/tmp? Is it
 possible that there are other apps that need exec capability in there?
 

It makes sense. Any world-writable directory should be noexec to make
script injection harder. Other directories, too, like /var/www (if you
can, i.e. no cgi). I cannot tell you if any application might need it.
Try it. It is easy enough to revert, maybe even with a `mount -o
remount`, I'm not sure.

Also, look at
http://serverfault.com/questions/72356/how-useful-is-mounting-tmp-noexec

 On that note, I realized I can't make two /tmp's in lvm, so, I guess I
 can make a vtmp, and just bind that to /var/tmp in fstab like:

 /dev/vg/vtmp/var/tmp ext4 nodev,noexec,nosuid 0 0

 Will that work?
 
 Sure why not but you should set the pass column to 2 instead of 0.
 
 What is the 'pass' column? Th 5th column is the 'dump' column, and the
 6th is the 'fsck' column, afaik?
 

Okay, your fsck column is called pass in my fstab. Anyway, a value
of two means fsck after root, one means fsck as root and 0 no
fsck. See `man fstab`. Obviously you want fsck.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] KDM stucking!

2013-04-23 Thread Florian Philipp
Am 23.04.2013 05:04, schrieb Jackie:
 Starting up Gentoo today and found that after I entered my password in
 KDM and the screen just stuck there with nothing for a while(maybe more
 than 1min) and then splash came up.This never appeared before and I
 don't know why.The only thing I did and might have something to do with
 it is that I happened to have deleted the /var/tmp/kdecache-username
 directory.So,is this reason? And what should I do now? Here is my
 ~/.xsession-errors file:http://pastebin.com/7N3A9bCc
 Thanks.
 

What happens when you use login on the terminal and then use startx?

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Partitions - last questions...

2013-04-23 Thread Florian Philipp
Am 23.04.2013 16:44, schrieb Tanstaafl:
 Ok, this is the last question I need to answer for myself before
 installing a final version of my new virtualized gentoo server...
 
 I'll be using the following partition layout:
 
 /boot (ext2), 100M
 /swap, 2G
 / (ext4), 40G
 
 then on LVM
 
 /tmp (ext2), 5G? - how big?
 /var/tmp (ext2), 5G? - how big?

If this is a production server I wouldn't use ext2. In the case of a
crash or reboot, you don't want to loose precious uptime just because of
fsck or corrupted file systems.

 /var/log (ext4) - size? should I even have this separate?

Doesn't need to be separate but could prevent a runaway process from
filling /var just because it is spamming log entries. Could also be
achieved with quotas.

 /var (xfs), 750G
 /snapshots (xfs), 10G? - for lvm snapshots of /var for backups
 
 I'm not using a separate /home because there are no system users beyond
 my admin user (and the system user accounts)...
 
 So - first, is 5G way too big for the two /tmp dirs? I have lots of
 space, but hate waste
 

If you worry about waste consider bind-mounting both from the same
partition and install quotas to avoid one filling up the other. A bit
like poor-man's btrfs sub volumes.

Since you are using LVM you should also keep some unallocated memory,
start with smaller partitions and monitor usage. A cron job that looks
at `df` and sends a mail when a partition is more than x% full helps a lot.

 This mail server is not all that busy, and the backups only take about
 an hour, so I guesstimate that there won't be more than about 100-300MB
 of changes at the *extreme* outside of the envelope, so the 10G is most
 likely extreme overkill... but I'll know soon enough, and besides, I've
 got plenty of disk space to play with.
 
 One question... I have some MySQL databases running on this system too,
 for my userdbs, and on the new server, SOGo (groupware)...
 
 Is it recommended to incorporate scripts to perform dumps of the dbs, or
 is the lvm snapshot reliable enough for backing these up in their raw
 state?
 

Restoring from lvm snapshot is like restoring after a black out or
similar crash. Having proper dumps is always a good idea.

 Thanks as always for comments/suggestions/criticisms...
 

Hope this helps,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


[gentoo-user] ext4 inline data

2013-03-29 Thread Florian Philipp
Hi list!

I noticed that beginning with kernel 3.8, ext4 can store small files
entirely inside the inode. But I couldn't find much additional information:

- Is the improvement automatically enabled?

- Is the change backwards compatible? Can I still read such files with
kernel 3.7?

- Can current stable e2fsprogs (especially e2fsck) handle this?

Thanks in advance!
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] IO latency issues

2013-03-10 Thread Florian Philipp
Am 10.03.2013 00:53, schrieb cosmoslx lin:
 2013/3/10 Volker Armin Hemmann volkerar...@googlemail.com
 mailto:volkerar...@googlemail.com
 
 Am 09.03.2013 19:15, schrieb Florian Philipp:
  Hi list!
 
  Whenever I do sequential IO for a long stretch of time (e.g.
 md5summing
  40 GB), I'm experiencing high load (ca. 6 on a 4 CPU system) and
  temporary freezes of most applications. For example, switching between
  tabs in konsole sometimes takes more than 2 seconds.
 
[...]
 
 congratulation. You hit 'the bug'. Been around for ages, but for magical
 reasons kernel dev are unable to see or unable to do something about it.
 If you are using a vanilla kernel, posting on lkml might be the right
 thing to do.
 
 I have try the BFQ patch outside of the kernel mainline, it works well.
 Maybe you would like to see:
 http://algo.ing.unimo.it/people/paolo/disk_sched/
 

Thanks. I'll try pf-sources which should to include that patch set.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] IO latency issues

2013-03-10 Thread Florian Philipp
Am 10.03.2013 13:48, schrieb Florian Philipp:
 Am 10.03.2013 00:53, schrieb cosmoslx lin:
 2013/3/10 Volker Armin Hemmann volkerar...@googlemail.com
 mailto:volkerar...@googlemail.com

 Am 09.03.2013 19:15, schrieb Florian Philipp:
  Hi list!
 
  Whenever I do sequential IO for a long stretch of time (e.g.
 md5summing
  40 GB), I'm experiencing high load (ca. 6 on a 4 CPU system) and
  temporary freezes of most applications. For example, switching between
  tabs in konsole sometimes takes more than 2 seconds.
 
 [...]
 
 congratulation. You hit 'the bug'. Been around for ages, but for magical
 reasons kernel dev are unable to see or unable to do something about it.
 If you are using a vanilla kernel, posting on lkml might be the right
 thing to do.

 I have try the BFQ patch outside of the kernel mainline, it works well.
 Maybe you would like to see:
 http://algo.ing.unimo.it/people/paolo/disk_sched/

 
 Thanks. I'll try pf-sources which should to include that patch set.
 
 Regards,
 Florian Philipp
 

pf-sources (only BFQ enabled, not BFS) helped somewhat. kswapd still
likes to keep one CPU busy when IO is happening but I suspect cleancache
to be the culprit for that. I'll test without it later.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


[gentoo-user] IO latency issues

2013-03-09 Thread Florian Philipp
Hi list!

Whenever I do sequential IO for a long stretch of time (e.g. md5summing
40 GB), I'm experiencing high load (ca. 6 on a 4 CPU system) and
temporary freezes of most applications. For example, switching between
tabs in konsole sometimes takes more than 2 seconds.

When doing this on an ext4 filesystem, the load seems to result from
khugepaged and kswapd0 as well as some kworkers.

I think I've had similar issues with NFS over wifi but I cannot test
this now.

Today I copied 60GB from my hard disk to an USB disk formatted with
NTFS, issuing the copy command from KDE's dolphin. The freezes became so
long it was impossible to work and then X11 locked up and had to be killed.

I tried using a preemptive kernel but that didn't seem to help. blkio
and cpu cgroups didn't help either. Ionice seems to be the only solution
but while I'm okay with that, my dad won't be. Can anyone tell me what
is causing this behavior?

Throughput is good, by the way. That's why I don't suspect a driver issue.

Thanks in advance!
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] /etc/hosts include file?

2013-03-08 Thread Florian Philipp
Am 08.03.2013 01:29, schrieb Michael Mol:
 On 03/07/2013 05:24 PM, Alan McKinnon wrote:
 Anyone know if there's a way to get /etc/hosts to support the notion of
 an include file? I did my homework and found nothing, maybe someone else
 knows more.

 I really do need this, I have an app that discovers things on the
 network and knows their address. This makes it's automated way into DNS
 but takes a few days, and another app needs to use the fqdn right now.
 So /etc/hosts is the way to go for the interim three days.

 I've worked around it by creating /etc/hosts.d/ containing a header and
 a data file. cat the two and redirect to /etc/hosts.d/hosts and the real
 hosts file is a symlink to that. It's a sub-directory as none of these
 apps run as root and only root can modiy the real hosts file.

 This works well enough, but a supported include mechanism would make
 life so much simpler, not to mention easier for my colleagues to
 understand what the blazes I set up :-)
 
 No, there's not an include directive.
 
 There are, however, two other ways to get hostnames recognized.
 
 The first is /etc/resolv.conf . You can point your host at a local DNS
 server which is aware of the discovered hosts, and which forwards the
 rest of the queries. (This is how Samba 4's internal DNS server
 operates; anything it knows, it responds to. Everything else, it forwards.)
 

dnsmasq also works like this and is probably easier to set up. FWIW it
also supports include files.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] {OT} RAM apache MaxClients (rock a hard place)

2013-03-07 Thread Florian Philipp
Am 06.03.2013 22:30, schrieb Alan McKinnon:
 On 06/03/2013 23:22, Michael Mol wrote:
 On 03/06/2013 04:07 PM, Alan McKinnon wrote:
 On 06/03/2013 22:59, Michael Mol wrote:
 On 03/06/2013 03:54 PM, Grant wrote:
 I lowered my MaxClients setting in apache a long time ago after
 running out of memory a couple times.  I recently optimized my
 website's code and sped the site way up, and now I find myself
 periodically up against MaxClients.  Is a RAM upgrade the only
 practical way to solve this sort of problem?

 Use a reverse proxy in caching mode.

 A request served up by the proxy server is a request not served up by
 Apache.

 Squid, nginx and varnish are all decent for the purpose, though squid
 and nginx are probably the more polished than varnish.


 Grant,

 If you optimized the site well, I would imagine your RAM needs per page
 request would go down and you could possibly increase MaxClients again.
 Have you given it a try since the optimization? Increase it slowly bit
 by bit comparing the current performance with what it used to be, and
 make your judgement call.

 Is there some reason why you can't just add more memory to the server?
 It's a fast and very cheap and very effective performance booster with
 very little downtime. But if your slots are full and you need new
 hardware, that's a different story.

 Michael's proxy suggestion is excellent too - I use nginx for this a
 lot. It's amazingly easy to set up, a complete breath of fresh air after
 the gigantic do-all beast that is apache. Performance depends a lot on
 what your sites actually do, if every page is dynamic with changing
 content then a reverse proxy doesn't help much. Only you know what your
 page content is like.

 The thing to remember is that clients request a *lot* of static content,
 too. CSS styles, small images, large images...these cache very well, and
 (IME) represent the bulk of the request numbers.
 
 bang head
 Yes, of course. You are perfectly correct, I forget all about that
 invisible stuff in the background
 /bang head
 
 
 

 Unfortunately, with the way mod_php and friends work with Apache,
 resources consumed by static file requests aren't trivial once you
 realize that the big problem is with the number of concurrent
 requests...so it's best if those can be snapped up by something else, first.

 I've been running squid in front of my server for a few years. I've been
 eyeing CloudFlare, though; they're a CDN that behaves like a reverse
 proxy. You point their system at your server, your DNS at their system,
 and they'll do the heavy lifting for you. (And far better than having
 your own singular caching server would. I've worked at a CDN, and what
 they accomplish is pretty slick.)



 
 

To optimize the caching potential, there are a few tricks. There's an
older tech talk about that from a Yahoo guy [1]. Google's advices are
also worth reading [2] and for a quick and dirty solution, look at [3].

[1] https://www.youtube.com/watch?v=BTHvs3V8DBA
[2] https://developers.google.com/speed/docs/best-practices/caching?hl=de
[3] http://fennb.com/microcaching-speed-your-app-up-250x-with-no-n

BTW: What's the current status of MPM Worker or Event and PHP? Does it
work? Does it help?

Hope this helps,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Re: OT: wrong ram?

2013-03-05 Thread Florian Philipp
Am 05.03.2013 22:14, schrieb walt:
 On 03/05/2013 09:56 AM, Volker Armin Hemmann wrote:
 
 intel introduced an extension for spd information. The ram should work
 just fine. Intel motherboards might or might not make use of the
 additional information. so might or might not amd boards. And no, there
 won't be any risk. DDR3 is DDR3.
 
 I just discovered some bad DDR2 RAM in an older machine (2GB x 2) and I
 tested each stick separately using memtest86.  The result confuses me:
 
 Each 2GB stick fails at exactly the same point in the test (0-32MB), and
 that seems improbable to me.  I'm thinking the mobo might be broken instead
 of the RAM.  Any ideas?
 
 Thanks.  (I have only the one machine that uses DDR2, unfortunately.)
 

Try adjusting the timing as noted on this thread. Maybe slower settings
work better, even if they are below SPD. Also look at the voltages (most
BIOSes show them). If they are considerably off, this could affect your
RAM. A bad power supply is always a suspect when something breaks.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Changing static IP remotely...

2013-02-28 Thread Florian Philipp
Am 28.02.2013 16:37, schrieb Mike Gilbert:
 On Thu, Feb 28, 2013 at 7:38 AM, Michael Mol mike...@gmail.com wrote:
 On 02/27/2013 11:48 PM, Jarry wrote:
 Hi Gentoo users,

 what is the proper way of changing static IP-address remotely
 without the need to restart the whole system (or locking
 me out)?
[...]
 # at -f /root/eth-restart now + 5 min
[...]
 Also, rather than using at to handle things like that, I like to use
 screen; if I get disconnected, programs running inside the screen
 session don't die...and there's no waiting for a scheduled job.

 
 Yeah, screen or tmux is the way to go.
 

`nohup` would work too, right?

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] hwclock: command not found

2013-02-25 Thread Florian Philipp
Am 25.02.2013 21:39, schrieb Joseph:
 I'm updating clock via bash script. When I run it from a command line,
 it works just fine but when I try to run it via crontab I get:
 
 /home/thelma/business/programs/time_date_setting_script.sh: line 3:
 hwclock: command not found
 
 here the script:
 #!/bin/sh
 rdate -s 128.138.140.44
 hwclock --systohc
 
 and crontab entry:
 45 12 * * 1 sh /home/thelma/business/programs/time_date_setting_script.sh
 
 When I run the scrip manually or just the command: hwclock --systohc
 it is working OK; why isn't it working from the crontab?
 

I've noticed that cron doesn't have /sbin and /usr/sbin in PATH. Try
using the absolute path to hwclock.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] No space left on device ?

2013-02-23 Thread Florian Philipp
Am 23.02.2013 15:24, schrieb Joseph:
 On 02/23/13 13:41, Volker Armin Hemmann wrote:

 play around with size. Usually 2GB is more than enough. Except for
 libreoffice.
 Then umount /var/tmp/portage and mount it again.
 
 I have only 8Gb of RAM should I dedicate it all for tmpfs or only 2GB
 

tmpfs uses as much memory as necessary and nothing more. In theory, it
doesn't hurt to add all your memory to it as tmpfs will start to swap
when you run out of memory. However, it is usually a better idea to
unmount the tmpfs and use a regular file system whenever you need more
space.

As Volker noted, it is probably best to use 2GB tmpfs and when you
emerge libreoffice, (and maybe firefox and co.) to switch back to using
a regular fs. You could also expand tmpfs so that it can eat all memory
not used by your applications under normal circumstances.

Example: `free -m`
 total   used   free
-/+ buffers/cache:   4717   3053

So in my case I'm probably fine with a 3GB tmpfs while still avoiding
excessive swapping.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] What to do with /var/run?

2013-02-16 Thread Florian Philipp
Am 16.02.2013 21:08, schrieb Grant:
 I guess the simplest approach is:
 1. drop into single user runlevel (`rc single`)
 2. move the remnants from /var/run to /run
 3. symlink /var/run to /run
 4. reboot or go back to default runlevel (`rc default`)

 /run is a tmpfs mounted at boot time, so anything you copy in there
 before rebooting will disappear.

 Ah that makes sense.  /run/openerp/ disappears after a reboot and
 re-emerging openerp brings it back.  Should that be an ebuild bug?

 - Grant


 Flameeyes was faster:
 https://bugs.gentoo.org/show_bug.cgi?id=451764

 There is a blocker bug for the migration:
 https://bugs.gentoo.org/show_bug.cgi?id=332633
 
 Diego is using openerp-server and I'm using openerp.  So I'm sure I
 understand, does this mean I should file a keepdirs /var/run bug for
 openerp?
 
 - Grant
 

If there is no bug referenced as a dependency of the blocker bug I
linked, by all means, do it (and reference the blocker bug).



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] unmerge sys-fs/udev-171-r9

2013-02-14 Thread Florian Philipp
Am 15.02.2013 03:38, schrieb Canek Peláez Valdés:
 On Thu, Feb 14, 2013 at 7:06 PM, Joseph syscon...@gmail.com wrote:
 Is it safe to unmerge sys-fs/udev-171-r9 it is blocking udev-197
 
 As long as you don't stop udev, nor try to reboot before merging the
 new version, yes.
 
 Regards.
 

The more important question is: Why does it block? udev is not slotted.
An update shouldn't block itself. Something's not right here.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] What to do with /var/run?

2013-02-10 Thread Florian Philipp
Am 10.02.2013 06:11, schrieb Grant:
 I received the following ELOG message after an emerge:
 
  * One or more symlinks to directories have been preserved in order to
  * ensure that files installed via these symlinks remain accessible. This
  * indicates that the mentioned symlink(s) may be obsolete remnants of an
  * old install, and it may be appropriate to replace a given symlink with
  * the directory that it points to.
  *
  * /var/run
 
 Should I change anything?
 
 - Grant
 

If my understanding of the situation is correct, we see this message
whenever a package is updated that in the old version installed to
/var/run and now has migrated to /run.

Even if I'm wrong, there is nothing to be done. /var/run is intended to
be a symlink to /run. If it is, then all is fine.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] SSH UseDNS without IPv6?

2013-02-10 Thread Florian Philipp
Am 09.02.2013 20:58, schrieb Alan McKinnon:
 On 09/02/2013 20:22, Florian Philipp wrote:
 Hi list!

 I have an issue with SSH. It's a variation of the old Set 'UseDNS no'
 to avoid delays with faulty DNS records theme.

 Following setup:
 1. I have a server with IPv6 compiled into the SSH daemon but no actual
 IPv6 network interface.

 2. The SSH client has no IPv6, neither compiled nor active.

 3. The DNS server doesn't serve or support  records. Apparently it
 drops all such requests. All other records for IP and reverse lookup are
 correct.

 Now I'm experiencing the classic, very long delay when connecting to the
 server via SSH because it does DNS lookups. When I look at wireshark
 dumps, I see correctly served A and reverse lookups but the server also
 insists on doing  requests which time out.
 
 When you say the server also insists on doing  requests you mean
 the SSH server, right?
 

 I tried limiting the sshd AddressFamily to inet (aka IPv4) but this
 didn't change anything. Is there another workaround or do I really have
 to deactivate DNS lookups?
 
 Is the server Gentoo and do you really need IPv6 support on it? Did you
 consider rebuilding that host with IPv6 disabled in USE?
 
 IPv6 coexisting with IPv4 is always going to be a tricky problem, and
 the recommended defaults you run into all over are usually intended to
 force people to hurry IPv6 implementation along :-)
 
 There's always a way to change defaults, and I found this:
 
 http://askubuntu.com/questions/32298/prefer-a-ipv4-dns-lookups-before-ipv6-lookups
 
 The magic file you need to edit appears to be
 
 /etc/gai.conf
 

Okay, I fixed my issue: An intermediate DNS server was misconfigured and
recursed on queries for which it is authoritative. Now  queries are
properly answered.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] What to do with /var/run?

2013-02-10 Thread Florian Philipp
Am 10.02.2013 14:14, schrieb Michael Mol:
 On Sun, Feb 10, 2013 at 7:40 AM, Alan McKinnon alan.mckin...@gmail.com 
 wrote:
 On 10/02/2013 13:49, Michael Mol wrote:
 On Feb 10, 2013 3:29 AM, Florian Philipp li...@binarywings.net wrote:

 Am 10.02.2013 06:11, schrieb Grant:
 I received the following ELOG message after an emerge:

  * One or more symlinks to directories have been preserved in order to
  * ensure that files installed via these symlinks remain accessible.
 This
  * indicates that the mentioned symlink(s) may be obsolete remnants of
 an
  * old install, and it may be appropriate to replace a given symlink
 with
  * the directory that it points to.
  *
  * /var/run

[...]
 Even if I'm wrong, there is nothing to be done. /var/run is intended to
 be a symlink to /run. If it is, then all is fine.

[...]

 It's probably better to leave the symlink in place for now. What happens
 when the user installs a package they have never had before and that
 package uses /var/run?

 It will make a directory which isn't what you want.
 
 Hm.
 
 lsof -n|grep /var/run|cut -d\  -f1|sort -u
 
 gives me
 
 acpid
 avahi-dae
 bluetooth
 cupsd
 dbus-daem
 gdm
 syslog-ng
 

That's odd. Is your system up-to-date and recently rebooted? I'm running
most of these services, too. But I have no open files in /var/run.

 Of those, at least avahi and cups are emitting /var/run elogs, which
 tells me they're defaulting to using /var/run instead of /run, if
 /var/run is present.
 
 Obviously, the transition isn't finished yet...software should default
 to /run rather than /var/run, or the symlink can never be known to be
 safe to remove on a given system.
 
 Better to leave the
 symlink in place and train your eyes to ignore the elogs (something we
 humans are extremely good at)
 
 Oh god no...Then you end up like some folks who get bit every time
 something changes (despite being warned about it for a months in
 advance). :)
 

BTW: Am I the only one annoyed by elog messages like If you are
updating from $ANCIENT_VERSION make sure to change $DEPRECATED_FEATURE
lurking in the tree for years? Especially because when you see the
message, it is a pain in the ass to check which version you were
actually using before.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] What to do with /var/run?

2013-02-10 Thread Florian Philipp
Am 10.02.2013 17:39, schrieb Dale:
[...]

 
 Actually, I had something that wouldn't start and said it needed /run. 
 I didn't have one, found references with google that it was the new and
 upcoming thing, so I created it myself.  So, it must have been a bug
 that should have been reported but I didn't realize that.  By creating
 it myself, I created a bit of a problem.  Now what to do about it. 
 

I guess the simplest approach is:
1. drop into single user runlevel (`rc single`)
2. move the remnants from /var/run to /run
3. symlink /var/run to /run
4. reboot or go back to default runlevel (`rc default`)

Hope this helps,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] What to do with /var/run?

2013-02-10 Thread Florian Philipp
Am 10.02.2013 17:46, schrieb cov...@ccs.covici.com:
 Alan McKinnon alan.mckin...@gmail.com wrote:
 
 On 10/02/2013 17:29, cov...@ccs.covici.com wrote:
 I had to actually prevent the migration to /run by changing the
 boot.misc script because if I do not do that, a number of subdirectories
 which I had created in /var/run were not in /run and a number of apps
 would not start properly and indeed it is not taking much space, so I am
 not sure why anyone bothered.  The only other option would have been to
 write something to fix the /run, but that was not what I wanted  to do.
 /var/lock had this same problem also.

 Why would you do that?

 /var/run is broken as the destination folder for what is intended to go
 in it, and it has been broken since day 1:

 /var/run is only available once /var is available or mounted.
 The contents of /var/run are often needed before /var is mounted.
 /run is the correct place for this.

 Problems with the migration are solved using the mv command
 
 But when I let the migration happen -- which was something udev or
 openrc did -- then certain things in my runlevels would not start
 because subdirectories in /var/run which were needed were missing and
 had t o have correct owners and permissions.  /var/lock needed certain
 subdirectories also such as news.  Only way to get them to work under
 /run would be to have a script to run after boot.misc which created all
 the subdirectories and fixed all the owners and permissions which is a
 lot more work -- and it would of course have to be done on each reboot.
 
 

Are these init scripts from packages in the official tree, something you
wrote yourself or some third-party package?

In the first case, check if the problem persists (I bet it's fixed now)
and file a bug report.

In the second case, the best approach is to patch your scripts to use
the `checkpath` command (see `man runscript`) to ensure that the
expected paths exist.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] What to do with /var/run?

2013-02-10 Thread Florian Philipp
Am 10.02.2013 18:56, schrieb Neil Bothwick:
 On Sun, 10 Feb 2013 17:56:45 +0100, Florian Philipp wrote:
 
 I guess the simplest approach is:
 1. drop into single user runlevel (`rc single`)
 2. move the remnants from /var/run to /run
 3. symlink /var/run to /run
 4. reboot or go back to default runlevel (`rc default`)
 
 /run is a tmpfs mounted at boot time, so anything you copy in there
 before rebooting will disappear.
 
 

I know. I considered omitting that step. However, I'm not sure what
exactly keeps running in `rc single` and some stuff in /run looks like
it might be necessary for a clean shutdown.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] What to do with /var/run?

2013-02-10 Thread Florian Philipp
Am 10.02.2013 19:01, schrieb cov...@ccs.covici.com:
 Florian Philipp li...@binarywings.net wrote:
 
 Am 10.02.2013 17:46, schrieb cov...@ccs.covici.com:
 Alan McKinnon alan.mckin...@gmail.com wrote:

 On 10/02/2013 17:29, cov...@ccs.covici.com wrote:
 I had to actually prevent the migration to /run by changing the
 boot.misc script because if I do not do that, a number of subdirectories
 which I had created in /var/run were not in /run and a number of apps
 would not start properly and indeed it is not taking much space, so I am
 not sure why anyone bothered.  The only other option would have been to
 write something to fix the /run, but that was not what I wanted  to do.
 /var/lock had this same problem also.

 Why would you do that?

 /var/run is broken as the destination folder for what is intended to go
 in it, and it has been broken since day 1:

 /var/run is only available once /var is available or mounted.
 The contents of /var/run are often needed before /var is mounted.
 /run is the correct place for this.

 Problems with the migration are solved using the mv command

 But when I let the migration happen -- which was something udev or
 openrc did -- then certain things in my runlevels would not start
 because subdirectories in /var/run which were needed were missing and
 had t o have correct owners and permissions.  /var/lock needed certain
 subdirectories also such as news.  Only way to get them to work under
 /run would be to have a script to run after boot.misc which created all
 the subdirectories and fixed all the owners and permissions which is a
 lot more work -- and it would of course have to be done on each reboot.

 Are these init scripts from packages in the official tree, something you
 wrote yourself or some third-party package?

 In the first case, check if the problem persists (I bet it's fixed now)
 and file a bug report.

 In the second case, the best approach is to patch your scripts to use
 the `checkpath` command (see `man runscript`) to ensure that the
 expected paths exist.
 
 As far as I remember, these are all packages from the tree and I am
 using unstable, so I would have to file a number of bug reports.
 There are a few things  such as freeswitch which I could fix in its
 startup script, but here is the result of 
 find /var/run -type d
 and I would also have to fix owners and permissions unless the package
 maintainers fix things.
 
 /var/run/samba

https://bugs.gentoo.org/show_bug.cgi?id=454676

 /var/run/dbus

https://bugs.gentoo.org/show_bug.cgi?id=387897
Fixed in stable.

 /var/run/named

https://bugs.gentoo.org/show_bug.cgi?id=334535
Fixed in stable.

 /var/run/fail2ban

https://bugs.gentoo.org/show_bug.cgi?id=449966
Fixed without a revision bump.

 /var/run/asterisk

https://bugs.gentoo.org/show_bug.cgi?id=451808
https://bugs.gentoo.org/show_bug.cgi?id=445182
https://bugs.gentoo.org/show_bug.cgi?id=450222
Fixed in stable.

 /var/run/freeswitch

Guess this goes nowhere with maintainer-needed status.
https://bugs.gentoo.org/show_bug.cgi?id=150527

 /var/run/wpa_supplicant

https://bugs.gentoo.org/show_bug.cgi?id=387895
Works for me with /var/run symlink.

 /var/run/gdm
 /var/run/gdm/greeter
 /var/run/gdm/auth-for-gdm-GtotHP

Should work or more people would complain.

 /var/run/openldap

https://bugs.gentoo.org/show_bug.cgi?id=444912
Fixed in testing.

 /var/run/dhcpcd
 /var/run/dhcpcd/ntp.conf
 /var/run/dhcpcd/resolv.conf

Works for me.

 /var/run/pulse

https://bugs.gentoo.org/show_bug.cgi?id=442852

 /var/run/mysqld

Works for me.

 /var/run/cups

https://bugs.gentoo.org/show_bug.cgi?id=451756
Works for me.

 /var/run/cups/certs

https://bugs.gentoo.org/show_bug.cgi?id=387893
Fixed in stable.

 /var/run/radvd

https://bugs.gentoo.org/show_bug.cgi?id=453140
Fixed in stable.

 /var/run/pm-utils
 /var/run/pm-utils/locks
 /var/run/pm-utils/pm-powersave
 /var/run/pm-utils/pm-powersave/storage

Works for me.

 /var/run/proftpd

https://bugs.gentoo.org/show_bug.cgi?id=449360
https://bugs.gentoo.org/show_bug.cgi?id=387889
Fixed in testing.

 /var/run/dhcp

https://bugs.gentoo.org/show_bug.cgi?id=446446
Fixed in stable.

 /var/run/udisks

https://bugs.gentoo.org/show_bug.cgi?id=333893
Fixed in stable.

 /var/run/spamd

https://bugs.gentoo.org/show_bug.cgi?id=455604

 /var/run/ConsoleKit

https://bugs.gentoo.org/show_bug.cgi?id=450224
https://bugs.gentoo.org/show_bug.cgi?id=387901

Works for me.

 /var/run/console

Works for me.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] New USE flags for lvm2?

2013-02-10 Thread Florian Philipp
Am 10.02.2013 19:37, schrieb Tanstaafl:
 I'm prepping for updating some things I've been putting off, and I
 noticed that lvm2 has some new use flags set, and I'm wondering why...
 
 [ebuild U  ] sys-fs/lvm2-2.02.97-r1 [2.02.88] USE=lvm1 readline
 thin%* udev%* (-clvm) (-cman) (-selinux) -static* -static-libs* 1,166 kB
 
 The two that are new/green (with asterisks) are -static and -static-libs...
 
 I'm pretty sure that lvm2 was NOT built with either of these, but is
 there a way to to tell what USE flags were used for the currently
 installed package?
 

I guess you remember wrongly:
Symbol   LocationMeaning
*suffix  transition to or from the enabled state
%suffix  newly added or removed


Read /var/db/pkg/sys-fs/lvm2-2.02.88/IUSE to find out what was enabled.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] New USE flags for lvm2?

2013-02-10 Thread Florian Philipp
Am 10.02.2013 20:07, schrieb Tanstaafl:
 On 2013-02-10 1:47 PM, Florian Philipp li...@binarywings.net wrote:
 Am 10.02.2013 19:37, schrieb Tanstaafl:
 I'm pretty sure that lvm2 was NOT built with either of these, but is
 there a way to to tell what USE flags were used for the currently
 installed package?
 
 I guess you remember wrongly:
 Symbol   LocationMeaning
 *suffix  transition to or from the enabled state
 %suffix  newly added or removed

 Read /var/db/pkg/sys-fs/lvm2-2.02.88/IUSE to find out what was enabled.
 
 Thanks Florian, yep, you're right...
 
 So, the question becomes, why did these change? I do have /user on a
 separate LVM partition, so, is this something I should worry about?
 
 Actually, a bit of googling suggests I shouldn't have had them enabled
 in the first place?
 
 Thanks again
 

My version of lvm2 (-static) has no dependencies to /usr libraries.

equery files lvm2 | while read line; do test -x $line  ldd $line;
done | awk '{print $3}' | sort -u

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] What to do with /var/run?

2013-02-10 Thread Florian Philipp
Am 10.02.2013 20:17, schrieb Grant:
 I guess the simplest approach is:
 1. drop into single user runlevel (`rc single`)
 2. move the remnants from /var/run to /run
 3. symlink /var/run to /run
 4. reboot or go back to default runlevel (`rc default`)

 /run is a tmpfs mounted at boot time, so anything you copy in there
 before rebooting will disappear.
 
 Ah that makes sense.  /run/openerp/ disappears after a reboot and
 re-emerging openerp brings it back.  Should that be an ebuild bug?
 
 - Grant
 

Flameeyes was faster:
https://bugs.gentoo.org/show_bug.cgi?id=451764

There is a blocker bug for the migration:
https://bugs.gentoo.org/show_bug.cgi?id=332633

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


[gentoo-user] SSH UseDNS without IPv6?

2013-02-09 Thread Florian Philipp
Hi list!

I have an issue with SSH. It's a variation of the old Set 'UseDNS no'
to avoid delays with faulty DNS records theme.

Following setup:
1. I have a server with IPv6 compiled into the SSH daemon but no actual
IPv6 network interface.

2. The SSH client has no IPv6, neither compiled nor active.

3. The DNS server doesn't serve or support  records. Apparently it
drops all such requests. All other records for IP and reverse lookup are
correct.

Now I'm experiencing the classic, very long delay when connecting to the
server via SSH because it does DNS lookups. When I look at wireshark
dumps, I see correctly served A and reverse lookups but the server also
insists on doing  requests which time out.

I tried limiting the sshd AddressFamily to inet (aka IPv4) but this
didn't change anything. Is there another workaround or do I really have
to deactivate DNS lookups?

Thanks in advance!
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] udev-197 USE=kmod

2013-01-27 Thread Florian Philipp
Am 27.01.2013 03:24, schrieb Canek Peláez Valdés:
 On Sat, Jan 26, 2013 at 6:15 PM, Florian Philipp li...@binarywings.net 
 wrote:
 Hi list!

 Quick question: If I deactivate the kmod use flag in udev and keep
 sys-apps/module-init-tools, does udev still load modules or is kmod a
 required flag for that?
 
 I'm not 100% sure, but I don't think so. The git repository has not a
 single instance of the strings modprobe or insmod, apparently the
 only way to load modules in udev is to use kmod. I think the kmod
 configure option (which is the one the USE flag activate/deactivate),
 is for systems where all the modules are built-in, like embedded ones.
 

Okay. I thought I've heard about some dev patching udev to work with
modprobe at one point. Could be mistaken or outdated, though.

 Unless udev has no other means to load modules, I think disabling kmod
 assumes then that all the modules are built-in. And if you use
 modules, may I ask why you would prefer module-init-tools over kmod?
 Specially when the later is a drop-in, better supported replacement?
 

Is it really a drop-in? I was under the impression that for example
`modprobe -l` is not implemented (mentioned in a comment on the eudev
fork on LWN). I guess that's outdated as well.

Thanks,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] udev-197: what to do

2013-01-27 Thread Florian Philipp
Am 26.01.2013 19:30, schrieb Allan Gottlieb:
 I have read the news item and still have questions.  The news item
 covers several points.
 
 1. remove udev-postmount:
I did this but worry that I now cannot reboot until I upgrade
udev.  Is that correct?
 

It's a bit of a gamble but I guess the worst that could happen is that
you are dropped into a basic shell. Then it is easy to add
udev-postmount again and reboot.

 The news item does not mention the problem of moving files
 from /usr/lib/udev/rules.d to /lib/udev/rules.d.  Am I correct in
 believing that we still need one of the equivalents of
equery belongs -n /usr/lib/udev | xargs emerge -pv
 
 I used that successfully when one of my testing systems went to
 udev-197.  I would think it is needed (before reboot) on my stable
 systems as well so I am surprised it is not in the news item.
 

I wondered about this as well but at least on my systems, /usr/lib/udev
is already gone. I guess all packages were rev-bumped to fix it.
BTW: A fast way to express `equery belongs -n /usr/lib/udev | xargs
emerge -pv` is simply `emerge -pv1 /usr/lib/udev`

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] udev-197 USE=kmod

2013-01-27 Thread Florian Philipp
Am 27.01.2013 12:33, schrieb Matthias Hanft:
 Florian Philipp wrote:

 Is it really a drop-in? I was under the impression that for example
 `modprobe -l` is not implemented (mentioned in a comment on the eudev
 fork on LWN). I guess that's outdated as well.
 
 I'm using kmod's modprobe, and there is *no* -l option.
 
 -Matt
 

Hmm, any replacement in sight?

Otherwise I guess I'll use an alias like this:
alias modprobe-l=find \/lib64/modules/\$(uname -r)\ -name '*.ko'
-printf '%P\n'



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] udev-197 USE=kmod

2013-01-27 Thread Florian Philipp
Am 27.01.2013 22:01, schrieb Canek Peláez Valdés:
 On Sun, Jan 27, 2013 at 4:30 AM, Florian Philipp li...@binarywings.net 
 wrote:
 Am 27.01.2013 03:24, schrieb Canek Peláez Valdés:
 On Sat, Jan 26, 2013 at 6:15 PM, Florian Philipp li...@binarywings.net 
 wrote:
 Hi list!

 Quick question: If I deactivate the kmod use flag in udev and keep
 sys-apps/module-init-tools, does udev still load modules or is kmod a
 required flag for that?

 I'm not 100% sure, but I don't think so. The git repository has not a
 single instance of the strings modprobe or insmod, apparently the
 only way to load modules in udev is to use kmod. I think the kmod
 configure option (which is the one the USE flag activate/deactivate),
 is for systems where all the modules are built-in, like embedded ones.


 Okay. I thought I've heard about some dev patching udev to work with
 modprobe at one point. Could be mistaken or outdated, though.
 
 The patches in the ebuild don't include anything to use modprobe:
 
 http://dev.gentoo.org/~williamh/dist/udev-197-patches-1.tar.bz2
 

Thanks for looking!

 Unless udev has no other means to load modules, I think disabling kmod
 assumes then that all the modules are built-in. And if you use
 modules, may I ask why you would prefer module-init-tools over kmod?
 Specially when the later is a drop-in, better supported replacement?


 Is it really a drop-in? I was under the impression that for example
 `modprobe -l` is not implemented (mentioned in a comment on the eudev
 fork on LWN). I guess that's outdated as well.
 
 No, modprobe -l is not supported, but it's trivially to emulate, and
 the option was already deprecated in module-init-tools. From the kmod
 README:
 
 kmod-modprobe gained several features to be a 1:1 replacement for
 modprobe. The only missing things are the options '--showconfig' and
 '-t / -l'. These last ones have been deprecated long ago and they will
 be removed from modprobe. A lot of effort has been put on
 kmod-modprobe to ensure it maintains compabitility with modprobe.
 
 As you yourself commented, using an alias with find more than enough.
 
 Regards.


Yeah, easy enough when you know your way around shell scripts and know
where to look. In my opinion, it is still kind of stupid to remove a
useful feature with no replacement.

Hmm, maybe it's time to write a better replacement. Something more like
eix, just for modules ...

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


[gentoo-user] udev-197 USE=kmod

2013-01-26 Thread Florian Philipp
Hi list!

Quick question: If I deactivate the kmod use flag in udev and keep
sys-apps/module-init-tools, does udev still load modules or is kmod a
required flag for that?

Thanks in advance!
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Re: Boost version problem

2013-01-25 Thread Florian Philipp
Am 24.01.2013 20:15, schrieb Florian Philipp:
 Am 24.01.2013 18:57, schrieb Jacques Montier:


 2013/1/24 microcai micro...@fedoraproject.org
 mailto:micro...@fedoraproject.org
 [...]
 
  Libreoffice-4.0 needs boost  1.49 (so works with
 boost-1.52.0-r5) and
  Nightshade LSS (for planetarium but not in portage) needs boost
  1.5
  (so works with 1.49.0-r2).
  Is it possible to install both 1.49 and 1.52 (in new slot) ?

 update Nightshade to work with boost 1.52 is the only way to go.

 
 
  No.
 
  Boost IIRC used to be slotted, but not anymore. Like any other
 package,
  you get one and only one version at a time.
 [...]


 I already tried that, but Nightshade doesn't compile with boost-1.52... :-((

 
 I could rant about the stupidity that is boost and/or packages that
 depend on it for some time but Flameeyes does a far better job at that.
 
 Anyway: if you cannot patch the package, try to install an older boost
 version manually and direct your package to its location.
 
 If you are lucky, your package only needs some template headers from
 boost, not an actual shared library. In that case you can remove your
 local boost copy afterwards.
 
 BTW: These quoting tabs are obnoxious. Is that how Gmail acts nowadays?
 
 Regards,
 Floroan Philipp

The geki-overlay contains a package dev-libs/boost-headers which is
slotted. Maybe that helps.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Re: Boost version problem

2013-01-25 Thread Florian Philipp
Am 25.01.2013 20:02, schrieb Nikos Chantziaras:
 On 24/01/13 21:15, Florian Philipp wrote:
 Am 24.01.2013 18:57, schrieb Jacques Montier:
 2013/1/24 microcai micro...@fedoraproject.org
 mailto:micro...@fedoraproject.org
 [...]
  
   Libreoffice-4.0 needs boost  1.49 (so works with
  boost-1.52.0-r5) and
   Nightshade LSS (for planetarium but not in portage) needs
 boost
   1.5
   (so works with 1.49.0-r2).
   Is it possible to install both 1.49 and 1.52 (in new slot) ?

  update Nightshade to work with boost 1.52 is the only way to go.
 [...]
 I already tried that, but Nightshade doesn't compile with
 boost-1.52... :-((


 I could rant about the stupidity that is boost and/or packages that
 depend on it for some time but Flameeyes does a far better job at that.
 
 I wonder what the view on bundled boost headers is with Gentoo devs. I'm
 currently working on a project where I need boost, and now I'm thinking
 about using BCP (http://www.boost.org/doc/libs/1_52_0/tools/bcp) to
 bundle what I need within the project.  At least this would guarantee
 that the package wouldn't be affected by this issue.
 
 

As I understand it, bundling the headers is exactly what you are
supposed to do with boost.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Re: Boost version problem

2013-01-24 Thread Florian Philipp
Am 24.01.2013 18:57, schrieb Jacques Montier:
 
 
 2013/1/24 microcai micro...@fedoraproject.org
 mailto:micro...@fedoraproject.org
[...]
 
  Libreoffice-4.0 needs boost  1.49 (so works with
 boost-1.52.0-r5) and
  Nightshade LSS (for planetarium but not in portage) needs boost
  1.5
  (so works with 1.49.0-r2).
  Is it possible to install both 1.49 and 1.52 (in new slot) ?
 
 update Nightshade to work with boost 1.52 is the only way to go.
 
 
 
  No.
 
  Boost IIRC used to be slotted, but not anymore. Like any other
 package,
  you get one and only one version at a time.
[...]
 
 
 I already tried that, but Nightshade doesn't compile with boost-1.52... :-((
 

I could rant about the stupidity that is boost and/or packages that
depend on it for some time but Flameeyes does a far better job at that.

Anyway: if you cannot patch the package, try to install an older boost
version manually and direct your package to its location.

If you are lucky, your package only needs some template headers from
boost, not an actual shared library. In that case you can remove your
local boost copy afterwards.

BTW: These quoting tabs are obnoxious. Is that how Gmail acts nowadays?

Regards,
Floroan Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Kernel Questions

2013-01-23 Thread Florian Philipp
Am 24.01.2013 00:27, schrieb Silvio Siefke:
 Hello,
 
 On Tue, 22 Jan 2013 20:48:49 +0100
 Florian Philipp li...@binarywings.net wrote:
[...]
 What kind of workload do we talk about? Properly niced and ioniced
 compile jobs? Is the freeze temporary?
 
 If I run a program, depending on the size the System Freeze for 
 few seconds. When i start emerge -s, emerge --sync, emerge what ever the
 system freeze. Its ever temporary but its make crazy.
 

Hmm, the last time I encountered something like this, DMA was
deactivated for the hard disk. That happened because the wrong driver
(generic IDE) took over. What raw throughput do you get?
`dd if=/dev/sda of=/dev/null bs=4M count=100 iflag=direct`

  
 Odd. Maybe GPU related? Again, does the system recover?
 
 No GPU is deactivated. When have more then 10 tabs, system hang. 
 

You mean you have not enabled drm and/or use the generic vesa driver?
Maybe something is trying to use opengl and software emulation slows you
down.

 Doesn't surprise me. P4 and Atom are both horrible micro architectures.
 But Atom is also horribly stripped down and has a lower clock frequency.
 
 Oh, okay i know Atom is shit, but P4. Which architecture is recommended 
 for?
  

P4s suffer because their pipeline is very long and poorly utilized. In
fact, they can execute fewer instructions per clock tick than a P3.
Anything newer is a vast improvement, especially Core2 and newer.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] How can I update *every* ebuild?

2013-01-23 Thread Florian Philipp
Am 23.01.2013 20:48, schrieb Jarry:
 Hi Gentoo-users,
 I always thought the right way to update everything was:
 
 emerge --update --deep --newuse world
 emerge --update --deep --newuse system
 
 When I try the above mentioned, nothing to update is found.
 Yet when I try i.e. emerge --pretend nasm, I see:
 
 [ebuild U  ] dev-lang/nasm-2.10.05 [2.10.01]
 
 So there is apparently update for dev-lang/nasm, yet it was
 not pulled when I tried to update the world or system.
 And who knows for how many other ebuilds there is update
 available...
 
 So how can I update really *every* ebuild?
 
 Jarry
 

That's because nasm is only a build-dependency. Portage will update it
when it is required for building the next time. Use --with-bdeps y to
change that.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Kernel Questions

2013-01-22 Thread Florian Philipp
Am 22.01.2013 19:43, schrieb Bruce Hill:
 On Wed, Jan 23, 2013 at 06:53:15PM +0100, Silvio Siefke wrote:
 Hello,


 i want ask some questions for the Kernel. 

 How do I find dependencies of each option?

In menuconfig, when you open the help on an item, there is a line
Depends on. If the requirement is not met, the option is not visible
but can be found by searching (press /).

There might also be a line Selects which contains automatically
activated dependencies and Selected by which contains the reverse
dependencies.

 Are there patches for older computers?


Don't think so. If there is a regression, it should get fixed in the
main line kernel.

 I use the good old Pentium 4 on the desktop and an atom on the laptop.
 But I have often the problem when the computer has much to do, that the 
 system freeze.

What kind of workload do we talk about? Properly niced and ioniced
compile jobs? Is the freeze temporary?

 That's on the atom often so. The opera is my favorite 
 Browser, but often the call on a website and the result end in freeze.

Odd. Maybe GPU related? Again, does the system recover?


 What is really strange, when i run emerge --sync ; emerge -avuDN @world,
 the Pentium 4 is faster as the Atom. Is that normal?


Doesn't surprise me. P4 and Atom are both horrible micro architectures.
But Atom is also horribly stripped down and has a lower clock frequency.

[...]
 It were nice some can share the own expirence. The Kernel is so hard to 
 understand, when take off a option, other option run not. I really not
 know what i need and what need. 
 
 Please read Linux Kernel in a Nutshell. You can:
 
 emerge -av app-doc/linux-kernel-in-a-nutshell
 
 and also read it online: http://www.kroah.com/lkn/
 

+1

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] cairo USE flags

2013-01-20 Thread Florian Philipp
Am 19.01.2013 12:36, schrieb Daniel Troeder:
 Am 19.01.2013 11:49, schrieb Florian Philipp:
 Hi list!

 I've noticed that there is probably a lot of performance to be gained
 from activating backend acceleration in cairo. It's just that I have no
 clue about the details:

 drm, gallium and opengl are all described as accelerating backends. Does
 that mean they are mutually exclusive or can I activate them all and
 cairo will sort it out?

 What does the qt4 use flag do? Is it just a language binding?


To answer myself on this: Yes it is.

 Does anyone know a simple benchmark for cairo?

 Thanks in advance!
 Florian Philipp

 I found your question very interesting, and so I used... google :D
 
 - Cairo seems to bring a benchmark with the source in cairo\perf.
 - http://cworth.org/intel/performance_measurement/
 

I stumbled across this, too, while looking at the source tar-ball. I've
done some benchmarks with the macro tests (i.e. traces) on mylaptop
with Intel graphics and a desktop with the free radeon driver.

In both cases, opengl was usually faster (sometimes considerably) than
xlib. xcb never finished for some reason.

 - The Phoronix test suit ofc has a performance test for cairo :)
 - I looked into some examples, and there are BIG differences between
gfx cards:
 http://openbenchmarking.org/prospect/1204129-SU-NVIDIAGEF19/3653c29c52e5da38d1879d193dc660515f97d242
 
 - This posting is most interesting:
 http://lists.cairographics.org/archives/cairo/2012-October/023609.html
 
 As a nvidia blob user it seems I should be using the XRender backend.
 But how? I can USE=-opengl to have that out of the way, but what's with
 the other USE flags?
[...]
 Now I wonder if cairo doesn't simply choose the best one automatically?
 Or should I X -xcb -opengl -openvg?
 (Keeping glib qt4 svg for apps on.)
 
 [..]
 
 I used cairo-trace to start some programs and it seems like programs can
 set their desired backend. There is a /type setting:
 
   /type 42 set   (firefox, soffice, clementine, evince, opera,
 crack-attack, digikam, inkscape)
   /type /xlib set(firefox, soffice, clementine, evince,
 crack-attack, digikam, inkscape)
   /type /xrender set (firefox, soffice, clementine)
 
 
 I wonder what 42 is...
 

I think that's related to a font format.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


[gentoo-user] cairo USE flags

2013-01-19 Thread Florian Philipp
Hi list!

I've noticed that there is probably a lot of performance to be gained
from activating backend acceleration in cairo. It's just that I have no
clue about the details:

drm, gallium and opengl are all described as accelerating backends. Does
that mean they are mutually exclusive or can I activate them all and
cairo will sort it out?

What does the qt4 use flag do? Is it just a language binding?

Does anyone know a simple benchmark for cairo?

Thanks in advance!
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] [OT] Xlib tutorial

2013-01-15 Thread Florian Philipp
Am 15.01.2013 15:12, schrieb pat:
 On Tue, 15 Jan 2013 08:22:03 -0500, Michael Mol wrote
 On Tue, Jan 15, 2013 at 6:55 AM, pat p...@xvalheru.org wrote:
 Hello,

 Sorry for this off topic. I want to learn how to develop UI applications 
 using
 Xlib. I've searched web, but I could not find a tutorial which will explain 
 it
 all (found some short examples). Please, could someone suggest a website or 
 a
 book?

 http://rosettacode.org/wiki/Category:Xlib

 Why the specific interest in Xlib? XCB is probably the better C
 library to use at this point. Actually almost any higher-level 
 toolkit would be a better place to start:

 https://en.wikipedia.org/wiki/List_of_widget_toolkits

 GUI programming is a PITA to do in the first place, and it's
 progressively more painful the more you want to do it right. Don't
 make it harder than it has to be, particularly if you're just getting
 started.

 -- 
 :wq

 Thanks for suggestion. Well I don't want to depend on GTK or Qt.
 
 Thanks
 
  Pat
 

Is this for an embedded platform? Because otherwise, for the sake of
your own sanity and the usability of your application, don't do this!

At least use some lightweight GUI toolkit like xforms or tk.

PS: Please don't top-post if you can avoid it.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] OT: blanking disk of linux appliance

2013-01-14 Thread Florian Philipp
Am 14.01.2013 03:11, schrieb Adam Carter:
 shred and dd available, but not srm etc
 
 I want to remove the user account info before the device is returned,
 but dont want to cripple the device. Filesystem is ext3 with default
 mount options, which implies its mounted with the default data=ordered,
 and according to the docs In both the data=ordered (default) and
 data=writeback modes, shred works as usual
 
 Would these steps be effective?
 - set root pw back to installation default
 - manually create copies of passwd and shadow (named passwd2 shadow2,
 NOT by copying files then deleting extra lines) containing only the
 default installation entries
 - shred /etc/passwd /etc/shadow

Don't forget the backup files created by some tools. For example
/etc/passwd-

 - mv passwd2 and shadow2 to passwd and shadow
 - dd if=/dev/zero of=/blah (to blank all spare blocks on fs, dd will
 bail out once full. Will it miss info from non-fully allocated blocks?)

Don't forget to do this as root to get the last 5%.

If you want to be sure, you can try several overwrite cycles, for
example with binary ones. The easiest way I know to generate such a
sequence is `tr '\000' '\377'  /dev/zero | dd of=...`. Or you can just
allocate /blah and then `shred` it.

 - rm /blah

If you have swap, you should clear that, too.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] How to list NOT installed packages which depend on certain package?

2013-01-13 Thread Florian Philipp
Am 13.01.2013 15:47, schrieb meino.cra...@gmx.de:
 Hi,
 
 how can I list all packages INCLUDING those, which
 are not installed on my system, which depend on a 
 certain package (in my case: dev-libs/boosy) ?
 
 I tried 
 
 emerge d dev-libs/boost
 
 but nothing was found...
 
 Thank you very much in advance for any help!
 
 best regards,
 mcc
 
 
 
 

Try `eix --depend dev-libs/boost`. The results might not match your
particular USE flags or other factors. Read `man eix` for details. Also,
that are only direct dependencies.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] pgo not selected for firefox 18

2013-01-11 Thread Florian Philipp
Am 11.01.2013 13:00, schrieb Adam Carter:
 
 I had noticed it a while ago, it appears to be hardmasked:
 
 
 # Jory A. Pratt anar...@gentoo.org mailto:anar...@gentoo.org (15
 Dec 2012)
 # PGO is known to be busted with most configurations
 www-client/firefox pgo
 
 I never had a single problem with it, so I'm going to unmask it and
 see if anything breaks.
 
 
 I just commented that out in /usr/portage/profiles/base/package.use.mask
 and it compiled fine with pgo and lto using 4.7.2. Ricey...


I guess you didn't have problems because you haven't used stable GCC.
pgo was broken in gcc-4.5 since firefox-16

See https://bugs.gentoo.org/show_bug.cgi?id=439244

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] How to get rid of old gcc?

2013-01-10 Thread Florian Philipp
Am 10.01.2013 19:06, schrieb Paul Hartman:
 On Thu, Jan 10, 2013 at 10:59 AM, Jarry mr.ja...@gmail.com wrote:
 Hi Gentoo users,

 I just updated gcc from 4.5.4 to 4.6.3, switched compiler
 version, rebuilt libtool, but emerge --depclean still
 does not want to remove old gcc. equery list gcc shows
 both are still installed:

 [IP-] [  ] sys-devel/gcc-4.5.4:4.5
 [IP-] [  ] sys-devel/gcc-4.6.3:4.6

 So how can I now remove the old gcc?  I checked again
 Gentoo GCC Upgrade Guide, but did not find a single
 word about it...
 
 If they are in slots, the newer version won't necessarily obsolete the
 older version.
 
 You can use emerge --depclean -p -v gcc:4.5 to view any remaining
 dependencies on that slotted version.
 
 You can use emerge -C gcc:4.5 to remove only that slot's version of gcc.
 

Even better:
emerge -av --depclean gcc:4.5

This will unmerge the gcc slot if and only if there is no dependency.

My guess is you have sys-devel/gcc:4.5 in your world file and not just
sys-devel/gcc and that's the reason why depclean won't clean it up.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] How to get rid of old gcc?

2013-01-10 Thread Florian Philipp
Am 10.01.2013 19:39, schrieb Jarry:
 On 10-Jan-13 19:21, Florian Philipp wrote:
 Am 10.01.2013 19:06, schrieb Paul Hartman:
 On Thu, Jan 10, 2013 at 10:59 AM, Jarry mr.ja...@gmail.com wrote:

 I just updated gcc from 4.5.4 to 4.6.3, switched compiler
 version, rebuilt libtool, but emerge --depclean still
 does not want to remove old gcc. equery list gcc shows
 both are still installed:
 [IP-] [  ] sys-devel/gcc-4.5.4:4.5
 [IP-] [  ] sys-devel/gcc-4.6.3:4.6

 If they are in slots, the newer version won't necessarily obsolete the
 older version.

 You can use emerge --depclean -p -v gcc:4.5 to view any remaining
 dependencies on that slotted version.

 You can use emerge -C gcc:4.5 to remove only that slot's version of
 gcc.

 Even better:
 emerge -av --depclean gcc:4.5

 This will unmerge the gcc slot if and only if there is no dependency.

 My guess is you have sys-devel/gcc:4.5 in your world file and not just
 sys-devel/gcc and that's the reason why depclean won't clean it up.
 
 Well, I have *both* sys-devel/gcc *and* sys-devel/gcc:4.5 in
 /var/lib/portage/world, but how did this happen? I have never
 put it there! I did not install gcc, I think it came as part
 of stage3 (system), so why is it suddenly in my world-file?
 
 Jarry

The only thing that comes to mind is that you once did something like
`emerge -avu gcc:4.5`. The behavior of -u/--update changed some time ago
so that it now adds packages to world if -1/--oneshot is not specified.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] OT: Fighting bit rot

2013-01-08 Thread Florian Philipp
Am 08.01.2013 08:55, schrieb Alan McKinnon:
 On Tue, 08 Jan 2013 08:27:51 +0100
 Florian Philipp li...@binarywings.net wrote:
 
[...]

 As I said above, the point is that I need to detect the error as long
 as I still have a valid backup. Professional archive solutions do
 this on their own but I'm looking for something suitable for desktop
 usage.
 
 rsync might be able to give you something close to what you want
 easily
 
 Use the -n switch for an rsync between your originals and the last
 backup copy, and mail the output to yourself. Parse it looking for 
 and  symbols and investigate why the file changed.
 
 This strikes me as being a very easy solution that you could use
 reliably with a suitable combination of options. 
 
 

Hmm, good idea, albeit similar to the `md5sum -c`. Either tool leaves
you with the problem of distinguishing between legitimate changes (i.e.
a user wrote to the file) and decay.

When you have completely static content, md5sum, rsync and friends are
sufficient. But if you have content that changes from time to time, the
number of false-positives would be too high. In this case, I think you
could easily distinguish by comparing both file content and time stamps.

Now, that of course introduces the problem that decay could occur in the
same time frame as a legitimate change, thus masking the decay. To
reduce this risk, you have to reduce the checking interval.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Re: OT: Fighting bit rot

2013-01-08 Thread Florian Philipp
Am 08.01.2013 16:42, schrieb Michael Mol:
 On Tue, Jan 8, 2013 at 10:29 AM, Grant Edwards
 grant.b.edwa...@gmail.com wrote:
 On 2013-01-08, Florian Philipp li...@binarywings.net wrote:
 Am 08.01.2013 00:20, schrieb Alan McKinnon:
 On Mon, 07 Jan 2013 21:11:35 +0100
 Florian Philipp li...@binarywings.net wrote:

 Hi list!

 I have a use case where I am seriously concerned about bit rot [1]
 and I thought it might be a good idea to start looking for it in my
 own private stuff, too.
 [...]
 [1] http://en.wikipedia.org/wiki/Bit_rot

 Regards,
 Florian Philipp


 You are using a very peculiar definition of bitrot.

 bits do not rot, they are not apples in a barrel. Bitrot usually
 refers to code that goes unmaintained and no longer works in the
 system it was installed. What definition are you using?

 That's why I referred to wikipedia, not the jargon file ;-)

 The wikipedia page to which you refer has _two_ definitions.  The
 uncommon on you're using:

  http://en.wikipedia.org/wiki/Bit_rot#Decay_of_storage_media

   and the the common one:

  http://en.wikipedia.org/wiki/Bit_rot#Problems_with_software

 I've heard the term bit rot for decades, but I've never heard the
 decay of storage media usage.  It's always referred to unmaintained
 code that no longer words because of changes to tools or the
 surrounding environment.
 
 Frankly, I'd heard of bitrot first as applying to decay of storage
 media. But this was back when your average storage media decay
 (floppies and early hard disks) was expected to happen within months,
 if not weeks.
 
 The term's applying to software utility being damaged by assumptions
 about its platform is a far, far newer application of the term. I
 still think of crappy media and errors in transmission before I
 think of platform compatibility decay.
 
 --
 :wq
 

Google Scholar and Google Search have both usages on the first page of
their search results for bit rot. So let's agree that both forms are
common depending on the context. Next time, when I write about Fighting
bugs I'll make it clear if I'm dealing with an infestation of critters.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] OT: Fighting bit rot

2013-01-08 Thread Florian Philipp
Am 08.01.2013 18:41, schrieb Pandu Poluan:
 
 On Jan 8, 2013 11:20 PM, Florian Philipp li...@binarywings.net
 mailto:li...@binarywings.net wrote:

 
 -- snip --
 
[...]

 When you have completely static content, md5sum, rsync and friends are
 sufficient. But if you have content that changes from time to time, the
 number of false-positives would be too high. In this case, I think you
 could easily distinguish by comparing both file content and time stamps.

[...]
 
 IMO, we're all barking up the wrong tree here...
 
 Before a file's content can change without user involvement, bit rot
 must first get through the checksum (CRC?) of the hard disk itself.
 There will be no 'gradual degradation of data', just 'catastrophic data
 loss'.
 

Unfortunately, that's only partly true. Latent disk errors are a well
researched topic [1-3]. CRCs are not perfectly reliable. The trick is to
detect and correct errors while you still have valid backups or other
types of redundancy.

The only way to do this is regular scrubbing. That's why professional
archival solutions offer some kind of self-healing which is usually just
the same as what I proposed (plus whatever on-access integrity checks
the platform supports) [4].

 I would rather focus my efforts on ensuring that my backups are always
 restorable, at least until the most recent time of archival.
 

That's the point:
a) You have to detect when you have to restore from backup.
b) You have to verify that the backup itself is still valid.
c) You have to avoid situations where undetected errors creep into the
backup.

I'm not talking about a purely theoretical possibility. I have
experienced just that: Some data that I have kept lying around for years
was corrupted.

[1] Schwarz et.al: Disk Scrubbing in Large, Archival Storage Systems
http://www.cse.scu.edu/~tschwarz/Papers/mascots04.pdf

[2] Baker et.al: A fresh look at the reliability of long-term digital
storage
http://arxiv.org/pdf/cs/0508130

[3] Bairavasundaram et.al: An Analysis of Latent Sector Errors in Disk
Drives
http://bnrg.eecs.berkeley.edu/~randy/Courses/CS294.F07/11.1.pdf

[4]
http://uk.emc.com/collateral/analyst-reports/kci-evaluation-of-emc-centera.pdf

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] OT: Fighting bit rot

2013-01-08 Thread Florian Philipp
Am 08.01.2013 18:35, schrieb Volker Armin Hemmann:
 Am Dienstag, 8. Januar 2013, 08:27:51 schrieb Florian Philipp:
 Am 08.01.2013 00:20, schrieb Alan McKinnon:
 On Mon, 07 Jan 2013 21:11:35 +0100

 Florian Philipp li...@binarywings.net wrote:
 Hi list!

 I have a use case where I am seriously concerned about bit rot [1]
 and I thought it might be a good idea to start looking for it in my
 own private stuff, too.

 [...]

 [1] http://en.wikipedia.org/wiki/Bit_rot
[...]
 If you mean disk file corruption, then doing it file by file is a
 colossal waste of time IMNSHO. You likely have 1,000,000 files. Are
 you really going to md5sum each one daily? Really?

 Well, not daily but often enough that I likely still have a valid copy
 as a backup.
 
 and who guarantees that the backup is the correct file?
 

That's why I wanted to store md5sum (or sha2sums).

 btw, the solution is zfs and weekly scrub runs.
 

Seems so.



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Re: OT: Fighting bit rot

2013-01-08 Thread Florian Philipp
Am 08.01.2013 20:53, schrieb Grant Edwards:
 On 2013-01-08, Pandu Poluan pa...@poluan.info wrote:
 On Jan 8, 2013 11:20 PM, Florian Philipp li...@binarywings.net wrote:


 -- snip --


 Hmm, good idea, albeit similar to the `md5sum -c`. Either tool leaves
 you with the problem of distinguishing between legitimate changes (i.e.
 a user wrote to the file) and decay.

 When you have completely static content, md5sum, rsync and friends are
 sufficient. But if you have content that changes from time to time, the
 number of false-positives would be too high. In this case, I think you
 could easily distinguish by comparing both file content and time stamps.

 Now, that of course introduces the problem that decay could occur in the
 same time frame as a legitimate change, thus masking the decay. To
 reduce this risk, you have to reduce the checking interval.

 Regards,
 Florian Philipp

 IMO, we're all barking up the wrong tree here...

 Before a file's content can change without user involvement, bit rot must
 first get through the checksum (CRC?) of the hard disk itself. There will
 be no 'gradual degradation of data', just 'catastrophic data loss'.
 
 When a hard drive starts to fail, you don't unknowingly get back
 rotten data with some bits flipped.  You get either a seek error
 or read error, and no data at all.  IIRC, the same is true for
 attempts to read a failing CD.
 
 However, if you've got failing RAM that doesn't have hardware ECC,
 that often appears as corrupted data in files.  If a bit gets
 erroneously flippped in a RAM page that's being used to cache file
 data, and that page is marked as dirty, then the erroneous bits will
 get written back to disk just like the rest of them.
 

Related: The guys in [1] observed md5sums of data and noticed all kinds
of issues: bit rot, temporary controller issues and so on.

[1] Schwarz et.al: Disk Failure Investigations at the Internet Archive
http://www.hpl.hp.com/personal/Mary_Baker/publications/wip.pdf

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


[gentoo-user] OT: Fighting bit rot

2013-01-07 Thread Florian Philipp
Hi list!

I have a use case where I am seriously concerned about bit rot [1] and I
thought it might be a good idea to start looking for it in my own
private stuff, too.

Solving the problem is easy enough:
- Record checksums and timestamps for each file
- Check and update records via cronjob
- If checksum changed but timestamp didn't, notify user
- Let user restore from backup

However, I haven't found any application in portage for this task. Now,
the implementation is easy enough but I'm wondering why it hasn't been
done. Or do I just look for the wrong thing? The only suitable thing
seems to be app-admin/tripwire but that application also looks like
overkill.

[1] http://en.wikipedia.org/wiki/Bit_rot

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] OT: Fighting bit rot

2013-01-07 Thread Florian Philipp
Am 07.01.2013 22:07, schrieb Paul Hartman:
 On Mon, Jan 7, 2013 at 2:11 PM, Florian Philipp li...@binarywings.net wrote:
 Hi list!

 I have a use case where I am seriously concerned about bit rot [1] and I
 thought it might be a good idea to start looking for it in my own
 private stuff, too.

 Solving the problem is easy enough:
 - Record checksums and timestamps for each file
 - Check and update records via cronjob
 - If checksum changed but timestamp didn't, notify user
 - Let user restore from backup

 However, I haven't found any application in portage for this task. Now,
 the implementation is easy enough but I'm wondering why it hasn't been
 done. Or do I just look for the wrong thing? The only suitable thing
 seems to be app-admin/tripwire but that application also looks like
 overkill.
 
 Not really what you are asking for, but I think btrfs and zfs have
 checksumming built-in to the filesystem. I'm not sure what userspace
 tools are like to monitor this, or if it's just an fsck away.
 

Yes, that's a start. `btrfs scrub start` might give something
meaningful. But I'm not really trusting btrfs with valuable data, yet.
And CRC32 isn't much, either.

Thanks anyway,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] OT: Fighting bit rot

2013-01-07 Thread Florian Philipp
Am 07.01.2013 22:33, schrieb Michael Mol:
 On Mon, Jan 7, 2013 at 3:11 PM, Florian Philipp li...@binarywings.net wrote:
 Hi list!

 I have a use case where I am seriously concerned about bit rot [1] and I
 thought it might be a good idea to start looking for it in my own
 private stuff, too.
[...]
 The only suitable thing
 seems to be app-admin/tripwire but that application also looks like
 overkill.
[...]
 
 Have you looked at Tripwire to see if it'll do what you need?
 

Not in detail. I guess you can get it to do that but one look at the
configuration and I told myself, Screw this, I will have coded it in
perl before I understood tripwire.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] OT: Fighting bit rot

2013-01-07 Thread Florian Philipp
Am 08.01.2013 00:20, schrieb Alan McKinnon:
 On Mon, 07 Jan 2013 21:11:35 +0100
 Florian Philipp li...@binarywings.net wrote:
 
 Hi list!

 I have a use case where I am seriously concerned about bit rot [1]
 and I thought it might be a good idea to start looking for it in my
 own private stuff, too.
[...]
 [1] http://en.wikipedia.org/wiki/Bit_rot

 Regards,
 Florian Philipp

 
 You are using a very peculiar definition of bitrot.
 
 bits do not rot, they are not apples in a barrel. Bitrot usually
 refers to code that goes unmaintained and no longer works in the system
 it was installed. What definition are you using?
 

That's why I referred to wikipedia, not the jargon file ;-)

The definition that I thought about was decay of storage media,
especially hard disks. I'm not aware of another commonly used name for
that effect. Disk rot seems to apply only to optical media.

 If you mean crummy code that goes unmaintained, then keep systems up to
 date and report bugs.
 
 If you mean disk file corruption, then doing it file by file is a
 colossal waste of time IMNSHO. You likely have 1,000,000 files. Are
 you really going to md5sum each one daily? Really?
 

Well, not daily but often enough that I likely still have a valid copy
as a backup.

 This is a filesystem task, not a cronjab task. Use a filesystem that
 does proper checksumming. ZFS does it, but that is of course somewhat
 problematic on Linux. Check out the others, it will be something modern
 you need, like ext4 maybe or btrfs
 

AFAIK, ext4 only has checksums for its metadata. Even if the file system
would support appropriate checksums out-of-the-box, I'd still need a
tool to regularly read files and report on errors.

As I said above, the point is that I need to detect the error as long as
I still have a valid backup. Professional archive solutions do this on
their own but I'm looking for something suitable for desktop usage.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Multi monitor and fullscreen games

2013-01-02 Thread Florian Philipp
Am 02.01.2013 06:25, schrieb Sebastian Beßler:
 On 01.01.2013 16:13, Florian Philipp wrote:
 
 With that, fullscreen applications work for me. Some still deactivate
 the second display or change the resolution but otherwise it works just
 fine.
 
 I tried it and it does not help at all, nothing changed. The games still
 stretch over both screens when in fullscreen.
 
 Someone else any idea?
 
 Greetings
 
 Sebastian Beßler
 

Make sure all direct and indirect dependencies have USE=xinerama.
Specifically:

x11-libs/qt-gui
x11-libs/gtk+
media-libs/libsdl
app-emulation/wine

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Multi monitor and fullscreen games

2013-01-01 Thread Florian Philipp
Am 01.01.2013 13:21, schrieb Sebastian Beßler:
 Hi,
 
 I got a second monitor and have KDE running in xinerama big screen mode
 without problems. Most everything works great but every game that I
 tried was streched over both screens when in fullscreen and gets so
 unplayable for me.
 
 Xinerama useflag is set and xinerama is loaded by X without error.
 
 My card:
 
 # lspci |grep VGA
 01:00.0 VGA compatible controller: Advanced Micro Devices [AMD] nee ATI
 Barts PRO [Radeon HD 6800 Series]
 
 I use the opensource drivers with KMS here.
 
[...]
 
 Is there anything that can be done to fix this problems with fullscreen
 games?
 
 The best would be if I could configure X to use the monitors as seperate
 screens 0:1 and 0:2 but when I try to configure this in Xorg.conf the
 second screen is not found and both monitors are configured in clone mode.
 
 This is the xorg.conf that I tried last, atm no xorg.conf is used at all.
 
[...]

I recommend getting rid of xinerama. xrandr can handle multiple monitors
just fine. If you are on KDE, try installing kde-base/kephal and use no
xorg.conf.

I still have the xinerama USE flag enabled globally as it adds
multi-monitor awareness to some applications.

With that, fullscreen applications work for me. Some still deactivate
the second display or change the resolution but otherwise it works just
fine.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] 3.7.1 SATA errors

2012-12-26 Thread Florian Philipp
Am 26.12.2012 02:11, schrieb fe...@crowfix.com:
 On Tue, Dec 25, 2012 at 01:11:04PM +0100, Florian Philipp wrote:
 
 The best way to find out what's wrong is to bisect the kernel, i.e.
 finding the exact commit that caused the issue to appear.

 http://wiki.gentoo.org/wiki/Kernel_git-bisect
 
 Got the repository cloned:
 
 # git clone 
 git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git 
 linux-stable
 
 Tried to start the bisect, but ran into a problem:
 
 # git bisect start
 # git bisect bad v3.7.0
 fatal: Needed a single revision
 Bad rev input: v3.7.0
 
 Tried v3.7.0.0 for fun, same error.
 
 Tried good first, guessing it can't do much harm that a git bisect reset 
 can't fix.
 
 # git bisect good v3.6.10
 a63a7cf3fc2ac1aff657f58ea446c34f3252209a was both good and bad
 # git bisect bad v3.7.0
 fatal: Needed a single revision
 Bad rev input: v3.7.0
 
 Have I grabbed a repository which doesn't include 3.7.0?
 
 Google research continues.
 

`git tag` should give you a list of version numbers. The tag you are
searching for is v3.7.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] 3.7.1 SATA errors

2012-12-25 Thread Florian Philipp
Am 23.12.2012 20:23, schrieb fe...@crowfix.com:
 
 I have since had some time to explore this and find it related to the
 kernel; 3.6.10 works fine, while 3.7.1 fails.  If I reset during the
 3.7.1 boot while it is spewing its error messages, but before the
 kernel ultimately panics, I can reboot with 3.6.10, but if 3.7.1 goes
 all the way to the panic, I have to power off and wait a few minutes
 before a 3.6.10 reboot is succesful.  This is repeatable, but I
 haven't bothered to see how long the system must be off; a few
 minutes is enough.
 
 There are two error messages during the 3.7.1 boot, repeated for all
 SATA drives:
 
 ata5.00: qc timeout (cmd 0x2f) ata5.00: failed to set xfermode
 (err_mask=0x40)
 

The code that prints these messages has not been changed since 2011 so I
guess it is a driver issue. You never posted which driver you use
exactly and your kernel config enables all. Therefore I cannot look further.

The best way to find out what's wrong is to bisect the kernel, i.e.
finding the exact commit that caused the issue to appear.

http://wiki.gentoo.org/wiki/Kernel_git-bisect

Unfortunately, there have been 1545 commits between 3.6 and 3.7. With
blind bisection you need 39 kernels to find the issue. Maybe `git log`
can give you a hint which commits might be relevant.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Good/better/best filesystem for large, static video library?

2012-12-25 Thread Florian Philipp
Am 25.12.2012 16:41, schrieb Mark Knecht:
 Hi,
Merry Christmas to all.
 
Upgrading an external USB2 drive at home this Christmas morning to
 1TB for more video storage space. One large partition, non-raid, files
 are around 1GB. The drive holds only static video files that get
 written once and don't change or get erased. No MythTV stuff or
 anything like that.
 
This disk reside on my main desktop machine and gets backed up
 every couple of days to another USB2 drive (FAT formatted
 unfortunately) which attaches to the TV.
 
With the previous local drive I used ext3 and have had no problems.
 I'm just wondering if there's a better choice  why.
 
 Cheers,
 Mark
 

Ext4 offers better performance for large files. This is especially
notable when you remove them but other operations are faster, too. XFS
would be the traditional large-file choice but since the arrival of
Ext4, I don't see a point in putting up with its quirks anymore.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Good/better/best filesystem for large, static video library?

2012-12-25 Thread Florian Philipp
Am 25.12.2012 19:26, schrieb Mark Knecht:
 On Tue, Dec 25, 2012 at 9:18 AM, Michael Orlitzky mich...@orlitzky.com 
 wrote:
 On 12/25/2012 12:07 PM, Mark Knecht wrote:
 On Tue, Dec 25, 2012 at 8:33 AM, Pandu Poluan pa...@poluan.info wrote:

 On Dec 25, 2012 10:44 PM, Mark Knecht markkne...@gmail.com wrote:
 SNIP
With the previous local drive I used ext3 and have had no problems.
 I'm just wondering if there's a better choice  why.
 SNIP

 For your usage, I think ext3 is the most suitable.

 Do you have another fs in mind?

 Really, no. ext3 has been fine. I didn't see any real advantage to
 ext4 myself. Florian offers the removal argument but I've never
 removed files from this database. It's just movies so the systems just
 grows over time.

[...]
 
 I wonder if there's anything to be said for changing block sizes, etc.
 away from whatever the defaults are? All of the files are currently
 between 350MB  1.2GB so there's never going to be many more than 2K
 files on the drive and I'm assuming the rsync operation if file by
 file so fragmentation in the beginning, and probably over time, is
 going to be pretty low I think.
 

The default of 4k blocks is the largest possible and with big files
there is no advantage in using smaller blocks. In fact, it could come
back to bite you as it limits file sizes. I guess it also increases fsck
times.

Another issue I noticed is that it can cause terrible performance if the
block size is smaller than the physical block size of the device. mke2fs
warns when it detects this.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Good/better/best filesystem for large, static video library?

2012-12-25 Thread Florian Philipp
Am 25.12.2012 18:15, schrieb Dale:
 Florian Philipp wrote:
 Am 25.12.2012 16:41, schrieb Mark Knecht:
 Hi,
Merry Christmas to all.

Upgrading an external USB2 drive at home this Christmas morning to
 1TB for more video storage space. One large partition, non-raid, files
 are around 1GB. The drive holds only static video files that get
 written once and don't change or get erased. No MythTV stuff or
 anything like that.

This disk reside on my main desktop machine and gets backed up
 every couple of days to another USB2 drive (FAT formatted
 unfortunately) which attaches to the TV.

With the previous local drive I used ext3 and have had no problems.
 I'm just wondering if there's a better choice  why.

 Cheers,
 Mark

 Ext4 offers better performance for large files. This is especially
 notable when you remove them but other operations are faster, too. XFS
 would be the traditional large-file choice but since the arrival of
 Ext4, I don't see a point in putting up with its quirks anymore.

 Regards,
 Florian Philipp

 
 
 For those who keep up with my adventures, I use ext4 for my home
 directory which has a LOT of videos.  Some videos are small and some are
 large but I can say this, it is really fast.  No fragmentation either. 
 
 I also use ext4 for my backup drive.  I accidentally deleted some stuff
 one day and I can say this, it is VERY fast.  I'm just glad it was only
 a backup. 
 
 I would second the idea for ext4.  It works great for me.
 
 Dale
 

On an amusing side note: I once was very happy that I happened to be
running ext3 at work. I accidentally started `rm -rf ~/*` and after more
than a minute I wondered why my disk was so busy ...

Anyway, thanks to its slow speed, rm only had time to eat away my rather
unimportant archive and bin directories and hasn't reached doc
yet. Thankfully bash sorts its glob expansions alphabetically. :D

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] building app fails with QT3 requirements

2012-12-22 Thread Florian Philipp
Am 22.12.2012 11:56, schrieb Tamer Higazi:
 Hi people!
 I wanted to build a qt3 application from source, that is not in the
 portage tree.
 
 http://www.tipp10.com/en/index/
 
 What needs to be done from my side to compile this application successful?!
 
 ---
 
 tamer@office /storage/downloads/tipp10_source_v2-1-0 $ ./configure
 Configuring tipp10 ...
 Verifying Qt 3.x Multithreaded (MT) build environment ... fail
 
 Unable to find Qt 'mkspecs'.  Perhaps you need to
 install the Qt 3 development utilities.  You may download
 them either from the vendor of your operating system
 or from http://www.trolltech.com/
 
 If you're sure you have the Qt development utilities
 installed, you might try using the --qtdir option.
 
 

Try --qtdir /usr/share/qt4. Make sure you have enabled
USE=qt3support. If that doesn't work and you cannot patch the app,
there are several overlays that contain a slotted Qt-3:
gentoo-taiwan, n4g, soor

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Questions about optimal mplayer settings

2012-12-19 Thread Florian Philipp
Am 19.12.2012 00:20, schrieb Walter Dnes:
 1) In the past couple of days I finally figured out what I was doing
 wrong with hardware acceleration (causing lack thereof) with an onboard
 Intel GPU in my HTPC machine.  I've applied the same fix to my desktop.
 mplayer now has 5 video output modes that actually show a picture...
 
 xv  X11/Xv

This doesn't use any GPU features. Good compatibility but otherwise not
recommended.

 gl_nosw OpenGL no software rendering

Same as gl just that it fails when you have driver issues that prevent
it from using the GPU. More like a debugging tool.

 x11 X11 ( XImage/Shm )

Practically outdated.

 gl  OpenGL

Recommended. Should work okay without further tuning but offers a lot of
them. Just play around.

 gl2 X11 (OpenGL) - multiple textures version

Unmaintained. Use gl.

 
 Which one has the best playback ability?  Is there a test program or a
 torture test video file I can use for testing?
 
 
 2) When I start up mplayer, the diagnostics include...
 MMX2 supported but disabled
 
 There is no mmx2 in the USE flags or in /proc/cpuinfo
 

That should be USE=mmxext. No clue what's its name in cpuinfo but
since you are running something newer than a P3 it should be a safe bet.

PS: Have to tried mplayer2? It's mostly compatible but offers no
mencoder support but you can install mplayer to get that. It has better
threading support and some other minor improvements.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Dual or Quad CPU complications?

2012-12-15 Thread Florian Philipp
Am 15.12.2012 01:40, schrieb Mick:
 On Thursday 13 Dec 2012 14:13:56 Bruce Hill wrote:
 On Thu, Dec 13, 2012 at 08:44:45AM +0100, J. Roeleveld wrote:
 NUMA is also an option in the kernel. Should also be fully transparent.
 I got one machine with NUMA and only had to set an option for it.

 Does anyone know how to check it's working properly?

 dmesg | grep NUMA
 
 Hmm ... it seems that it can't find NUMA configuration:
 
 $ dmesg | grep UMA
 No NUMA configuration found
 
 Am I supposed to configure something in userspace?  This is what the kernel 
 has:
 
 $ uname -a
 Linux dell_xps 3.5.7-gentoo #2 SMP PREEMPT Mon Nov 26 10:36:47 GMT 2012 
 x86_64 
 Intel(R) Core(TM) i7 CPU Q 720 @ 1.60GHz GenuineIntel GNU/Linux
 
[...]

dell_xps as in XPS laptop? There are no NUMA laptops.

Despite all the stuff about terminology, we are basically talking about
multi-socket systems. Things with mainboards like these [1] as opposed
to these [2].

[1] http://www.newegg.com/Product/Product.aspx?Item=N82E16813131378
[2] http://www.newegg.com/Product/Product.aspx?Item=N82E16813131725

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Dual or Quad CPU complications?

2012-12-15 Thread Florian Philipp
Am 15.12.2012 04:16, schrieb Grant:
So if I have 2 physical CPU's with 4 cores each and I enable
 SMP, I'm
using
8 cores?  Can NUMA be either enabled or disabled when using
 more than
one
physical CPU, or is it required?
  
  
   NUMA is a hardware architecture. It's how you access memory on a
   hardware level: NUMA = Non Uniform Memory Access vs a UMA
 architecture
   of typical (old/legacy) SMP systems (UMA = Uniform Memory Access).
  
   In a UMA system, all the memory belongs to all the sockets. In a NUMA
   system, each socket has it's own local memory. In modern (x86-64)
   processors, each socket has it's own memory controller so each socket
   controls its own local memory. If one socket runs out of memory
 it can
   ask another socket to lend him some memory. In a UMA system, no
 socket
   has to ask since memory is global and belongs to all sockets so
 if one
   socket uses up all the memory ... the rest starve. In NUMA, there's
   more control over who uses what (be it cores or RAM).
  
   If you have a modern dual or quad (or higher #) socket system ...
   you've got NUMA architecture and you can't get rid of it, it's
   hardware, not software.
  
   So I must enable CONFIG_NUMA for more than one physical CPU, and
 disable it
   for only one physical CPU?
 
 
  Yup. But ... Why would you want to disable a socket (CPU)? If you
  disable a socket (CPU) ... you lose the memory attached to that socket
  (CPU) not to mention you lose those cores ;)

 Sure but it sounds like if my system only has one CPU socket,
 CONFIG_NUMA should be disabled.
 
 I read this in make menuconfig:
 
 The kernel will try to allocate memory used by a CPU on the local
 memory controller of the CPU and add some more NUMA awareness to the
 kernel. For 64-bit this is recommended if the system is Intel Core
 i7 (or later), AMD Opteron, or EM64T NUMA.
 
 To be sure I have this right, I should disable CONFIG_NUMA on any system
 with a single physical CPU, even if it's an AMD Opteron?
 
 - Grant

Disable it. You only have one memory controller. There is nothing the
kernel could do wrong without.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] {OT} dedicated server or cloud server?

2012-12-14 Thread Florian Philipp
Am 14.12.2012 08:49, schrieb Grant:
 Would everyone here be in favor of a dedicated server over a cloud
 server from a host with good cloud infrastructure?  The cloud server
 concept is amazing but from what I'm reading a dedicated server at the
 same price point far outperforms it.
 
 - Grant

Last time I did the calculation, a dedicated or normal virtualized
infrastructure was more cost effective as long as you could accurately
predict the performance you need.

Cloud services only really help if you need a high dynamic range
regarding scale and performance, e.g. a service that could get a lot of
new users very fast or is only really active for short time spans.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] {OT} dedicated server or cloud server?

2012-12-14 Thread Florian Philipp
Am 14.12.2012 11:00, schrieb Grant:
  Would everyone here be in favor of a dedicated server over a cloud
  server from a host with good cloud infrastructure?  The cloud server
  concept is amazing but from what I'm reading a dedicated server at the
  same price point far outperforms it.
 
  - Grant

 Last time I did the calculation, a dedicated or normal virtualized
 infrastructure was more cost effective as long as you could accurately
 predict the performance you need.

 Cloud services only really help if you need a high dynamic range
 regarding scale and performance, e.g. a service that could get a lot of
 new users very fast or is only really active for short time spans.
 
 Doesn't a good cloud server also have potentially higher availability
 compared to dedicated?
 
 - Grant

I'd be grateful if anyone can point me at a well conducted study on that
topic. Until then I just say that my anecdotal evidence shows the
opposite: My cheap-ass virtual server has an uptime of 492 days with
only minor, previously announced network outages. During the same time,
Amazon EC2 had what, 3 or 4 major outages?

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] ~amd64 compatibility with modern cpus

2012-12-14 Thread Florian Philipp
Am 14.12.2012 17:18, schrieb fe...@crowfix.com:
 Something went haywire with my 8 or 9 year old dual Opteron ~amd64
 system last night.  I may have a bricked system.  I haven't given up
 yet, but I may have to buy a replacement system.  I have external USB
 drive backups, but the only other computer I have right now is an old
 Mac laptop which can't read Linux LVM partitions.
 
 Questions:
 
 1.  I don't remember, and can't look up, the make.conf processor
 flags I emerge with.  But it is dual Opterons, and ~amd64.  How
 compatible could that be with modern Intel CPUs?  I know Intel
 adopted the extra registers of the AMD64 instruction set, but are
 there other differences which would prevent an Opteron system from
 running as is under an Intel processor?  Maybe AMD still sells
 Opterons, and I will be stuck with building a system.
 

I guess your Opterons used -march=k8. Except of 3dnow, this should be
compatible. You might be lucky.

 2.  Is it feasible to buy some commodity box, like from Dell, with an
 Intel processor, and plug in my two SATA SSD drives and get a console
 boot?  I don't give a fig right now about any GUI interface, and even
 Internet is not the problem.  If it will boot and run emerges, I can
 import the source files for X and Ethernet and other peripherals via
 USB stick.  But SATA drivers ...
 

Yep, SATA drivers will be the biggest issue. Hope you had and will have
AHCI.

 3.  My kernels always have just about every driver compiled in as
 modules, an old habit from when I used to swap in PCI cards like
 crazy.  I don't remember now how many SATA drivers are built in and
 how many are modules; if the commodity box needs SATA drivers which
 aren't built in, that could get tricky.  Are there boot command line
 options to preload certain modules?  Might not do me any good.  I
 think I could scrape by with USB modules, but not SATA.
 

Not possible. You need an initrd or a new kernel. How about compiling a
new kernel on a different box and using a memory stick for grub + /boot?

 For the curious, here is wat happened.  When I left off last night,
 the USB keyboard was only recognized when I unplugged all other USB
 devices, and the system hung at the grub point, with a blank screen.
 
 A reboot failed because it couldn't find the root=/dev/sde drive.
 But the USB keyboard was working because I used it in grub to select
 a new 3.7.0 kernel (had been running 3.6.8).
 
 A second reboot ignored the USB keyboard and generated an ATA error I
 had never seen before for every ATA drive and some I don't have, all
 the way up to ATA13 before I rebooted it again.  I haven't got it to
 boot even this far since, so I can't regenerate that error.  There
 was a 5 second or so delay between these errors, making me think the
 ATAnn designator might not be different drives, just retries.
 [...]

Could be your south bridge. If you want to keep the system, try a
different board.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Question about new USE flags for xf86-video-intel

2012-12-14 Thread Florian Philipp
Am 14.12.2012 18:56, schrieb Mark Knecht:
 On Fri, Dec 14, 2012 at 9:44 AM, Walter Dnes waltd...@waltdnes.org wrote:
   I'm updating a system that's probably gone 2 or 3 months since its
 last update.

 
 !!! The ebuild selected to satisfy x11-drivers/xf86-video-intel has unmet 
 requirements.
 - x11-drivers/xf86-video-intel-2.20.13::gentoo USE=dri -glamor -sna -udev 
 -uxa -xvmc

   The following REQUIRED_USE flag constraints are unsatisfied:
 any-of ( glamor sna uxa )
 

   This is the first time I've run into these options.  A bit of Google
 detective work turned up some articles...

 http://www.phoronix.com/scan.php?page=articleitem=intel_glamor_firstnum=1
 http://ickle.wordpress.com/2012/06/05/an-evening-with-glamor/

 ...which give the impression that SNA is the fastest option overall.
 The phoronix article also mentioned some instability issues with glamor.
 I'll probably be going with SNA.  Does anybody else have any experience
 and/or opinions?

 --
 Walter Dnes waltd...@waltdnes.org
 I don't run desktop environments; I run useful applications

 
 I have no idea about performance but I've got udev and sna enabled at this 
 time.
 

+1

 gandalf ~ # emerge -pv xf86-video-intel
 
 These are the packages that would be merged, in order:
 
 Calculating dependencies... done!
 [ebuild   R] x11-drivers/xf86-video-intel-2.20.13  USE=dri sna
 udev -glamor -uxa -xvmc 0 kB
 
 Total: 1 package (1 reinstall), Size of downloads: 0 kB
 gandalf ~ #
 
 Be forewarned, or please report back if you can, but in my case on the
 two Intel machines I have (one local, one my 84 year old dad uses) X11
 stopped displaying anything after this update. As a quick fix I
 removed the xorg.conf file completely to get a desktop back. This was
 a couple of weeks ago. Removing xorg.conf worked on both machines and
 I haven't gone back to figure out what happened and how to best
 address it.
 

If you don't miss features I say good riddance to xorg.conf.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Intel Atom: architecture, distcc, crossdev and compile flags

2012-12-12 Thread Florian Philipp
Am 12.12.2012 02:40, schrieb Frank Steinmetzger:
 On Tue, Dec 11, 2012 at 09:20:55PM +0100, Florian Philipp wrote:
 
 * From my observations, the benefit of 64 bit over 32 is much smaller for an
   Atom than it is for my Core2.  Am I right to assume thus that the Atom
   architecture doesn’t have much to offer to 64 bit (such as extra 
 registers)?
   I’m not talking about memory here, since it’s limited to 2 GB in any case.


 It has the same set of registers as your Core2.
 
 Incidentally, when I initially set up the netbook, the output of
 gcc -march=native -E -v - /dev/null 21 | sed -n 's/.* -v - //p'
 (which floated around the ML in the past) implied core2, IIRC.
 
 It's just that the Atom micro-architecture is terrible with regard to
 64bit. That's just about the only reason that x32 was invented (and
 now that I've said it, I'm just waiting for the flamewar about it).
 
 Terrible in what way? Inadequate memory throughput? I didn't know x32,
 but from what I've read in the last few minutes it sounds intriguing.
 

Just citing Flameeyes who is citing Intel.
http://blog.flameeyes.eu/2012/06/debunking-x32-myths

[...]
   I sped up the installation process for 32 bit by using a chroot on the big
   machine, which worked nicely.  But it’s not a long-term solution, b/c it
   uses up too much disk space on the host.

 I do the same using NFS, bind mounts and tmpfs. What do you mean by disk
 space?
 
 That I don't have much space left on the host machine for the entire
 chroot. I bind-mount distfiles and portage, but I'm still running low
 on gigabytes.
 I was thinking of NFS quite early, but a friend said it would perform
 not nicely. Also, with all my cables currently occupied, the two are
 connected over a slow WiFi router.  It's one of the rare cases in which
 compressing distcc traffic increases performance. :) The netbook has
 gigabit ethernet, though.  Thank $DEITY for compressed tar pipes over
 SSH.  I wonder what Windows people would do in such a situation. :-]
 

I see. Yep, wifi is really not a good choice for this. NFS works nice,
though. I just ran into some minor trouble when setuid bits would not
survive merging. Haven't debugged this yet as it's easy enough to find
with a script.

[...]
 * The last thing I’m going to set up is filesystem encryption, at least for 
 ~.
   I already know/think that AES would be the best choice due to limited CPU
   power, but what else is there to heed besides key size?

 Nothing, you're good. Hash and key chaining method have negligible
 impact. If you stick with an x86_32 userspace I suggest at least using
 an x64 kernel so you can use of CRYPTO_AES_X86_64.
 
 That's an interesting idea. If I had a 32 bit userland, I would have to
 build new kernels on my big 64 laptop then, right?  I don’t suppose I
 can simply mix chosts, such that I would have a multilib x86_64
 gcc/binutils/glibc, but i686 everything else.
 

Try this.
http://www.gossamer-threads.com/lists/gentoo/user/190919

 I haven't done any comparisons of 32/64 crypto yet, I'm just reading
 docs on Luks (never used it before).  Big stuff (videos, music) won't be
 encrypted anyway, just the sensitive data like mail, documents,
 passwords and personal photos. So the requirements won't be high.
 However I might expand it to /, though that would involve a more
 complicated boot process (I never needed initrds except for bootsplash).
 

I personally see no reason for encrypting root as there is nothing of
interest in there. I just encrypt home, certain /var/* sub-mounts and
other stuff. That way, you can use /etc/init.d/dmcrypt.Actually, I've
tweaked the setup so that I can have LVM on top of Luks. If you're
interested, I can share the change.

 On a sidenote, While I was cleaning up unread mails in the ML, I just
 found your interesting frontswap/zcache trick.
 
 I wonder how many years I'd have to use the device to get back the time
 from improved performance that I spent setting it up in the first place.
 :-D
 

Consider it experience. ;-)

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Intel Atom: architecture, distcc, crossdev and compile flags

2012-12-12 Thread Florian Philipp
Am 12.12.2012 10:40, schrieb Neil Bothwick:
 On Wed, 12 Dec 2012 09:16:58 +0100, Florian Philipp wrote:
 
 I personally see no reason for encrypting root as there is nothing of
 interest in there.
 
 No passwords in /etc? The main reason I encrypt / is that wicd keeps its
 passwords in /etc.
 
 

I substitute with symlinks to /var/lib/*, /srv/* or similar.



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Dual or Quad CPU complications?

2012-12-12 Thread Florian Philipp
Am 13.12.2012 07:23, schrieb Alan McKinnon:
 On Wed, 12 Dec 2012 22:12:18 -0800
 Grant emailgr...@gmail.com wrote:
 
 I've only ever used systems with a single CPU.  I'm looking for a new
 host for a dedicated server (suggestions?) and it looks like I'll
 probably choose a machine with two or four CPUs.  What sort of
 complications does that add to set up and/or maintenance with Gentoo?
 
 No complication.
 
 Configure CONFIG_SMP in the the kernel for multicore.
 Everything else is transparent.
 
 Cores make threads work better, so you'd want to investigate if
 USE=threads is useful for you.
 
 

I think he's looking for advice on NUMA, not SMP.



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Intel Atom: architecture, distcc, crossdev and compile flags

2012-12-11 Thread Florian Philipp
 also tested the runtime of some application (packing and unpacking of
   archives, throughput with dd, mencoder).  If there is interest, I can post
   the result of 21 runs on each platform, measured with GNU time.
 

How about trying some browser benchmarks. Check out the following for
different aspects:
http://ie.microsoft.com/testdrive/performance/mazesolver/default.html
http://www.webkit.org/perf/sunspider/sunspider.html
http://peacekeeper.futuremark.com/run.action

There is also a Qt render benchmark
http://code.google.com/p/qtperf/
Check out app-admin/eselect-qtgraphicssystem and see how they compare in
appearance and numbers.

Regards,
Florian Philipp




signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Localmount starts before LVM

2012-12-10 Thread Florian Philipp
Am 10.12.2012 15:08, schrieb Nilesh Govindrajan:
 Hi,
 
 I have a raid0 (kernel autodetect) array, over which I have put LVM
 and then there are volumes on the LVM for /var, /tmp, swap and /home.
 
 The problem is, raid0 array gets recognized, but localmount fails to
 mount because lvm doesn't seem to start before localmount (due to my
 root being on SSD, I can't watch the output of openrc easily).
 
 For now I have added this to my rc.conf -
 rc_localmount_before=lvm
 rc_localmount_need=lvm
 rc_lvm_after=localmount
 
 This fixes the problem, but localmount still executes before lvm and
 terminates with operational error. Then lvm starts up and localmount
 runs again successfully.
 
 Any idea why this happens?
 
 The localmount script in init.d has proper depends:
 
 depend()
 {
 need fsck
 use lvm modules mtab
 after lvm modules
 keyword -jail -openvz -prefix -vserver -lxc
 }
 
 --
 Nilesh Govindrajan
 http://nileshgr.com
 

Please provide `/sbin/rc-update show`.

Have you tried toggling rc_depend_strict?

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] {OT} Will ARM take over the world?

2012-12-09 Thread Florian Philipp
Am 09.12.2012 04:51, schrieb Michael Mol:
 On Sat, Dec 8, 2012 at 10:25 PM, Grant emailgr...@gmail.com wrote:
 It seems like ARM processors will destroy x86 before too long.  Does anyone
 think this won't happen?
 
 It's looking promising. Not that I have a horse in the race, but I
 very much like ARM's low power consumption. The way I see it, they're
 only a short list of features away from obliterating x86:
 
 * I'd like to see fast division.
 I keep hearing about how this or that is slow because of ARM's lack of
 strong division.
 
 * I'd like to see a modern baseline of strong instructions.
 x86 kept continually improving in a very fragmented way, but there
 were, from time to time, baseline collections of feature sets you
 could expect all processors to have. i386 represented one. i686
 represented one. Currently, it's x86_64, which implies not only a
 64-bit flattened address space and a departure from real mode, but
 also a collection of SIMD instruction sets and other features
 developed between the release of the Pentium Pro and AMD's Hammer
 architecture.
 
 ARM just feels...fragmented. And I don't have the impression I could
 write my code assuming the availability of SIMD (presuming I use
 things like OpenMP to expand my code to leverage it, rather than
 writing processor-specific code. Though OpenCL could very well
 alleviate that issue.)
 

+1 with regard to fragmentation. What I especially despise is the lack
of a common boot infrastructure. If I'm not mistaken, it is still
impossible to make a kernel that boots on all (or at least a large
subset of all) ARM platforms [1].

And then, there is the simple fact that current ARMs lack the raw power
of an x86 and I guess if you scale them up to the point where they can
compete with x86s with regard to computing power per core, there is no
point in switching to ARM to begin with. Sure, you can parallelize and
make a large array of wimpy nodes, but you cannot fool Amdahl's law.
And even where you can parallelize nearly 100%, you risk high latency
[2, 3].

[1] https://lwn.net/Articles/496400/
[2] http://pages.cs.wisc.edu/~jignesh/publ/nonwimpy.pdf
[3] http://research.google.com/pubs/archive/36448.pdf

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Re: Ext4 problem and disk access

2012-12-08 Thread Florian Philipp

 2012/12/8 Nikos Chantziaras rea...@gmail.com mailto:rea...@gmail.com

 On 08/12/12 16:36, Jacques Montier wrote:

 As soon as i mount an ext4 partition on my second 1To HDD,
 the hard drive is always working (read/write) every second
 (even when doing nothing).


 Could it be a disk indexing service, like KDE's Nepomuk?


 Am 08.12.2012 18:30, schrieb Jacques Montier:
 I don't have Nepomuk, but maybe any other indexing service ? I don't know...
 I tried to look at the processes with top and mounting /unmounting
 /dev/sda5 ; i haven't seen any difference...
 
 thank you Nikos,
 
 --
 Jacques
 

Try lsof instead to find processes accessing files. You can also try iotop.

PS: Please don't top-post.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] broadcom-sta and the 3.6.x kernel

2012-12-04 Thread Florian Philipp
Am 04.12.2012 09:13, schrieb Dustin C. Hatch:
 On 12/3/2012 19:22, Allan Gottlieb wrote:
 I believe several on this list use -sta and know many are running 3.6.x.
 What do you do?  I should add that at present running 3.5.x is not a
 hardship for me.

 I have broadcom-sta working on my notebook with kernel-3.6, using the
 patches in #437898. For convenience, you can find them all in my overlay
 (layman -a dustin).
 
 I am actually having better luck with kernel-3.6 than I did with 3.5
 because of several problems in the wl driver with regard to cfg80211.
 Notably, in 3.5 with cfg80211, dmesg was filled with cannot get rssi
 messages, several per minute. That's gone now and wpa_supplicant
 correctly reports receive signal strength.
 

Do you actually need broadcom-sta anymore? With the recent kernel
updates more chips work with the in-kernel driver (brcmsmac). But the
config option is well hidden (you need to enable BCMA to even see it).

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] intel HD graphics 4000 and viewing DVDs

2012-12-01 Thread Florian Philipp
Am 28.07.2012 10:22, schrieb Florian Philipp:
 Am 27.07.2012 22:57, schrieb Michael Mol:
 On Fri, Jul 27, 2012 at 4:39 PM, Florian Philipp li...@binarywings.net 
 wrote:
 Am 27.07.2012 22:22, schrieb Michael Mol:
 On Fri, Jul 27, 2012 at 4:10 PM, Allan Gottlieb gottl...@nyu.edu wrote:
 I am getting a new laptop. (likely dell 6430).
 The two graphics options are intel HD 4000 and nvidia NVS 5200M.
 Dell is as expected suggesting the 5200M.

 I do not need 3D or fast response.  Dell hinted that DVDs might not play
 with the intel HD 4000.  This seems weird to me as the 4000 is supposed
 to be a big improvement over the 3000 and I can't believe dell or others
 would have sold laptops that can't play dvds

 Any comments or experiences?

 My Duron 750MHz was able to decode DVDs in realtime. After that, all
 you're doing is blitting (or using xv) the frames to the screen. I
 would be absolutely shocked if the Intel HD 4000 GPU couldn't handle
 that basic of a 2D acceleration function.

 Now, DVDs use MPEG2. Blu-Ray uses h.264, which is a much harder beast
 to decode in realtime. It's possible the HD 4000 GPU can't handle
 hardware decode of h.264, but I don't know. I've never looked into it.
 (Software decode of 1080p h.264 on my Phenom 9650 worked somewhat, but
 highly active scenes would cause frame drops.)


 I've experienced issues playing DVDs on fullscreen with the OSS radeon
 driver. Therefore I'm cautious of assumptions that something works
 simply because the input is easy to decode. Upscaling to large displays
 with high resolutions can be an issue.

 I'm not saying the Intel driver cannot handle it. I'm just saying you
 should try it or look for reports.

 How high is 'high' resolution? I was upscaling to 1600x1200 using an a
 Radeon 9600; that card would now be almost ten years old. A bit later,
 I did the same on a 2.4GHz Pentium 4 using an i845-based Intel
 graphics card. Here's the line from lspci, as run in May of 2007:

 00:02.0 VGA compatible controller: Intel Corporation
 82845G/GL[Brookdale-G]/GE Chipset Integrated Graphics Device (rev 01)

 Hardware scaling a 2D image is one of the most trivial
 hardware-accelerated options GPUs perform. If someone had difficulties
 upscaling a 480p (roughly what DVDs are) to 1080p at 24 or 33fps, I
 would be very highly suspicious of a software misconfiguration. That
 kind of scaling should even be comfortably doable in software on any
 modern x86-derived processor. (With the plausible exclusion of the
 Atom CPU)

 
 1920x1080, on-board Radeon HD 4250. I haven't diagnosed it further
 (except of playing around with mplayer2 options) as it was easier to use
 the closed source driver.
 
 Regards,
 Florian Philipp


I realize this thread is pretty stale but since I talked bullshit and
just now realized it, I want to correct myself:

Since updating the kernel to 3.5 forced me to update the X server beyond
1.11 which in turn forced me to update ati-drivers to a version that no
longer supported my Radeon HD 4250, I had to look into my issues with
the open source driver.

It turns out, my problems had two reasons:
- I didn't enable KMS and DRM for radeon in the kernel
- I didn't have x11-drivers/radeon-ucode installed

Both resulted in a fully functioning X server that
- could run glxgears just fine
- could (with some tuning) render videos in DVD quality with opengl output
- was too slow for videos in any higher resolution

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] swap on ssd?

2012-11-26 Thread Florian Philipp
Am 25.11.2012 23:46, schrieb William Kenworthy:
 Has anyone tried swap on ssd?  - has it killed the drive prematurely? -
 any other effects?
 
 I have a system that is maxed with with 4G ram and tends to use swap
 heavily at times which slows things down ... so I am thinking a small
 ssd might help here.
 

You should tell us which model you want to use. In any case, if it is
relatively recent, I don't think you can actually break it with write
cycles anymore unless you keep it 100% busy 24/7.

 Another slower alternative is a usb thumbdrive ... might try that later
 today as I have some around ... again anyone tried this and found
 something unexpected?
 

Thumbdrives have much simpler wear leveling. They also use triple level
cells (TLC) which are even worse than the MLCs found in cheaper SSDs.
Not to forget that USB doesn't support proper DMA and therefore
increases CPU load. Long story short: Swapping on thumbdrives is as fast
as a snail riding a turtle -- but turtles have a longer life span.

Another idea:
You can try to reduce the swap load by using frontswap with zcache. It
compresses memory pages in RAM which would otherwise be swapped. You
still need swap but less often.

Enable
FRONTSWAP
CRYPTO
CONFIG_STAGING
CONFIG_ZCACHE

then add zcache to your boot parameters.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] easy Gentoo tricks

2012-11-26 Thread Florian Philipp
Am 25.11.2012 22:53, schrieb Grant:
 What are your favorite easy Gentoo tricks?  Stuff that makes your system
 a lot better in some way with only a minimal amount of effort.  I just
 discovered one for xfce4:
 
 emerge tumbler
 
 No other config.  Really cool result.
 
 - Grant

cgroups are awesome to keep the system responsive under incredible load
(make -j64 and watching a video in parallel? Sure, why not). I'm still
looking for the best way to set them up, however.

Also, having a KDE setup that is slim enough to work on a second
generation netbook (terrible SSD, 512MB RAM) is something you can
probably not do with any other distribution.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] easy Gentoo tricks

2012-11-26 Thread Florian Philipp
Am 26.11.2012 09:49, schrieb George Karagiannidis:
 On 11/26/2012 10:38 AM, Florian Philipp wrote:
 Am 25.11.2012 22:53, schrieb Grant:
 What are your favorite easy Gentoo tricks?  Stuff that makes your system
 a lot better in some way with only a minimal amount of effort.  I just
 discovered one for xfce4:

 emerge tumbler

 No other config.  Really cool result.

 - Grant
 cgroups are awesome to keep the system responsive under incredible load
 (make -j64 and watching a video in parallel? Sure, why not). I'm still
 looking for the best way to set them up, however.

 Also, having a KDE setup that is slim enough to work on a second
 generation netbook (terrible SSD, 512MB RAM) is something you can
 probably not do with any other distribution.

 Regards,
 Florian Philipp

 
 
 Greetings.

 Philipp, I am currently using XFCE and I would like to switch to KDE,
 but I consider it a bit bloated :S. Do you mind sharing the way you
 setup your KDE?

 regards,
 George Karagiannidis

Well, disabling semantic-desktop is probably the most important step.
The rest is more aggressive than usual disabling of USE-flags and
compiling with -Os.

BTW: Please don't top-post.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


[gentoo-user] Debug memory leaks in X server

2012-11-26 Thread Florian Philipp
Hi list!

I have a suspicion that viewing certain PDFs in okular causes X server
to leak memory. Currently it is using 1.8 GB after 3 days uptime. Has
anyone else observed that? Is there a way to inspect X server's memory
usage?

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Debug memory leaks in X server

2012-11-26 Thread Florian Philipp
Am 26.11.2012 10:56, schrieb Florian Philipp:
 Hi list!
 
 I have a suspicion that viewing certain PDFs in okular causes X server
 to leak memory. Currently it is using 1.8 GB after 3 days uptime. Has
 anyone else observed that? Is there a way to inspect X server's memory
 usage?
 
 Regards,
 Florian Philipp

Okay, I have now a better understanding of my memory issue (no clue
about Mick's CPU issue. Maybe you can post a link to a PDF to demonstrate?):

As it seems, Okular is abusing the X server to share pixmaps between
instances [1]. In theory, this reduces memory consumption and CPU time,
however, there are two issues:
a) Sometimes Okular is leaking allocations.
b) X cannot handle this usage pattern, sometimes leaks memory or cannot
deallocate it because of memory fragmentation [2].

Neither side seems to be willing to fix the issue. For now, my
workarounds will be:
- Playing around with Okular's memory settings to make the issue less
critical.
- Using frontswap and normal swap + high swappiness settings to swap out
the leaked memory.
- Looking for another PDF/djvu/ps viewer.

Maybe Wayland can handle the situation better in a few years.

[1] https://bugs.kde.org/show_bug.cgi?id=177213
[2] https://bugs.launchpad.net/ubuntu/+source/xorg-server/+bug/98783

BTW: Regarding my question for an X memory inspector: x11-misc/xrestop
is the answer.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] SSD configuration

2012-11-25 Thread Florian Philipp
Am 25.11.2012 16:36, schrieb Jacques Montier:
 Hi all,
 
 I bought a 250Go SSD M4 Crucial , read (of course) Gentoo documentation
 and installed the drive on my desktop pc (Asus MB, Intel ie7 and 6Go RAM).
 
 1- Everything seems to work perfectly, but i would like to know if my
 configuration is ok or could be optimized.
 
 /dev/sda1 /boot   ext2
 defaults,noatime,discard1 2

You don't need to specify defaults when there is any other option
present. Defaults is just there so that the column is not empty if you
do not specify any option.

 /dev/sda2 /   ext4
 defaults,noatime,nodiratime,discard 0 1

noatime implies nodiratime. Specifying both is redundant.

 /dev/sda3 /varext4
 defaults,noatime,nodiratime,discard 0 0
 /dev/sdb1   /mnt/donneesntfs-3g 
 auto,uid=jacques,gid=users,umask=0022   0 0
 /dev/sdb2 noneswapsw  
 0 0

Swap on SSD would be faster but I guess you want to avoid the additional
writes.

 /dev/sdb5 /usr/portageext4
 defaults,noatime,nodiratime 0 0
 /dev/sdb6   /var/tmp  ext4
 defaults,noatime,nodiratime 0 0
 /dev/sdb7   /home   ext4  
 defaults,noatime,nodiratime 0 0

For home, auto_da_alloc trades a little performance for additional
security against stupid applications that forget to fsync().

 /dev/sdb8   /mnt/disk_virt  ext4  
 defaults,noatime,nodiratime 0 0


Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] SSD configuration

2012-11-25 Thread Florian Philipp
Am 25.11.2012 17:34, schrieb Jacques Montier:
 2012/11/25 Luis Gustavo Vilela de Oliveira luisgustavo.vil...@gmail.com
 mailto:luisgustavo.vil...@gmail.com
 2012/11/25 Jacques Montier jmont...@gmail.com
 mailto:jmont...@gmail.com
[...]
 2- When booting, BIOS seems to detect the SSD as IDE not SATA ;
 anything wrong ?
 
 
 You should look at the BIOS config, if AHCI is enable.
 
 
 Thank you Luis,
 
 In BIOS, i switched to AHCI instead of IDE Mode, but the system does not
 boot.
 I get kernel panic (No filesystem could mount root...)
 
 My kernel configuration :
 CONFIG_SATA_AHCI=y
 

It is possible that the change switched the device naming, making sda
sdb and vice versa. Try to boot from a live-CD to verify that. You can
also do this to check if you missed a module.

BTW: Please don't top-post, both Luis and Jaques. Put your answers below
the quoted messages (like I did).

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Xorg - RADEON vs VESA

2012-11-24 Thread Florian Philipp
Am 24.11.2012 16:42, schrieb David Relson:
 Greetings,
 
 Last night I had to reboot my box because the screen had gone all
 wonky.  The reboot has resulted in an obviously different font being
 used in terminal windows, emacs, etc, etc.
 
 Comparing Xorg logs from Oct (the previous reboot) to now, Xorg has
 been upgraded from 1.12.2 to 1.13.0.  The logs are similar for approx
 400 lines, then diverge.  Below is shown the beginning of the log
 file differences.
 
[...]
 ** 1.13.0 **
 
  (++) using VT number 7
 
  (II) [KMS] drm report modesetting isn't supported.
[...]

Have you changed the kernel as well?

Enable CONFIG_DRM_RADEON and CONFIG_DRM_RADEON_KMS if you have not.

Regards,
Florian Philipp



signature.asc
Description: OpenPGP digital signature


  1   2   3   4   5   6   7   8   9   10   >