Search Results: "ed"

14 July 2010

Scott Kitterman: No, it s not a bug in my site

I maintain a Sender Policy Framework (SPF) record testing tool. If you happen to use it and it says your record isn t valid, your first action should not be to email me and ask if it s a bug in the tool. That is all.

Julien Valroff: Back to Adobe Flash Player

After 4 weeks using exclusively Gnash as flash player, I have switched back to Adobe Flash Player. Though I had found workarounds for major video sites (including Youtube and DailyMotion), I have had a lot of issues with musical websites, most of them being still designed in Flash . To use Adobe Flash Player on my amd64 desktops, I have used Bart Marten s workaround described in the Debian wiki. It works fine though the player randomly crashes on some websites, and the browser needs to be restarted so that it works again. This 4-week experience was fine, but I am a little bit puzzled that there is still no usable free flash player. Hopefuly, things will improve over time the sooner, the better!

Felipe Sateler: Getting pulseaudio to work on 32-bit apps on a 64-bit system

To get pulseaudio working on 32bit apps you need to do a little bit of work, because of bugs 543448. First, install lib32asound2-plugins, and then get the needed libs from the 32bit debian. Using zsh, this can be done:
ldd /usr/lib32/alsa-lib/libasound_module_pcm_pulse.so   grep 'not found' \
	  awk ' print $1 '   xargs dlocate   cut -f1 -d:   sort -u   \
	while read name; do \
		apt-cache show $name   grep Filename: \
			  cut -f2 -d:   sed -e 's/_amd64/_i386/' \
			  xargs -l -I' ' \
			     wget http://ftp.cl.debian.org/debian/' '
		dpkg -x $ name _* $ name 
		sudo cp -i $ name /**/lib/* /usr/lib32
	done
Iterate a few times, since missing deps are found incrementally. After there are no missing libs (check with the ldd command above), you are done.

13 July 2010

Sylvain Le Gall: Project children has forked

The new project shares the same code base, but this branch is a total rewrite of the project children. Clementine is born on 8th July 2010, at 12:01 Paris time. She is now at home with her mother, father and brother. She is very peaceful and hardly cry once or twice in a day: at bath time and around 5am for her night lunch. Clementine by Bernard Le Gall I will probably lack of time in the coming month. Expect some delays with the OCaml forge, other OCaml projects I maintain and my OCaml Debian packages.

DebConf team: Debian Day at DebConf10 (Posted by Michael Schultheiss)

Debian Day will take place on the first day of DebConf10, Sunday, August 1, 2010 from 10:00 AM to 6:40 PM at Columbia University, New York City, New York. We would love to see you join us at Debian Day. Registration is required but is free. If you are not already registered for DebConf10, please send an e-mail with your intent to attend to debianday@debconf.org. Debian Day and DebConf10 are going to be great. We re looking forward to seeing you in New York on August 1! More information on Debian Day is available at DebianDay.org. the DebConf team

Luciano Bello: /home/duijvestijn

I have a new guest in my apartment. Give a warm welcome to the Adrianus Johannes Wilhelmus Duijvestijn s spirit. Thanks a lot to Bartu and Rezlaj, who carried out the necessary seance that make this possible. The complete photo set is here. If you do not have the slightest idea of what I m talking about, take a look to Wikipedia or my previous post (Spanish only). (esta entrada tambi n est disponible en Espa ol)

Christoph Berg: Cool Unix Features: date -d @

I've always been annoyed about how hard it is to convert seconds-since-epoch to strings. I've always been using "date -d '1970-01-01 + 1234 sec'", but as it turned out, that's wrong because it uses the wrong timezone. Luckily, there's a slick replacement:
$ date -d '@1234'
Do 1. Jan 01:20:34 CET 1970
The right version of the "long" version is:
$ date -d '1970-01-01 UTC + 1234 sec'
Do 1. Jan 01:20:34 CET 1970

Fathi Boudra: What s going on in Debian Qt world?

Qt 4.7.0 beta 2 and Qt Creator 2.0.0 have been released upstream. There s some
noticeable changes in our Qt packages compared to Qt 4.6.x series:
- legacy Qt Assistant (ADP) is removed
- new Qt declarative module is introduced
- Qt Multimedia and Qt Webkit aren t being built anymore In case your package depends on the deprecated Qt Assistant, it is still being
shipped in a separated Qt Assistant compatibility package called
qt-assistant-compat. Qt Multimedia is now shipped from Qt Mobility API instead of Qt. The module has
been renamed to Qt Mobility MultimediaKit. Qt Mobility delivers a set of APIs
for mobile device functionality. Qt WebKit is shipped standalone, separated from Qt. Hopefully, it will make
Qt WebKit security support easier. There are also a new component in the family: Qt Messaging Framework (QMF).
The Qt Messaging Framework, QMF, consists of a C++ library and daemon server
process that can be used to build email clients, and more generally software
that interacts with email and mail servers. Finally, I have started to ship a snapshot of a new Phonon backend: Phonon VLC,
one backend to rule them all ! All the packages can be found in Debian Experimental repository, except
Qt Simulator, a simulator for Qt applications running on Nokia devices.
This package should land soon in Debian archives. I encourage you to try building your Qt applications against these packages and
please, report any bugs you encounter. Enjoy. http://packages.qa.debian.org/q/qt4-x11.html
http://packages.qa.debian.org/q/qtcreator.html
http://packages.qa.debian.org/q/qt-assistant-compat.html
http://packages.qa.debian.org/q/qtmobility.html
http://packages.qa.debian.org/q/qtwebkit.html
http://packages.qa.debian.org/q/qmf.html
http://packages.qa.debian.org/p/phonon-backend-vlc.html
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=587759

12 July 2010

Thorsten Glaser: On ASLR (Address Space Layout Randomisation)

I ve got some interesting results using r1.1 of an example test programme (r1.2 got cleaned up and more output) on various systems, regarding ASLR. The 1.1 revision tests everything mksh R40+ will use (except there will probably no larger than page sized allocations) for its LCG PRNG. On OpenBSD (MirBSD, rieBSD) malloc(3) uses in fact mmap(2), which is randomised. (Though -pie doesn t yet work as it s supposed to.) Some OSes are better than others but look for yourself. (Read on to continue, not part of the RSS for size reasons. This wlog entry may be updated with bumped date unperiodically.)

Ross Burton: Tasks 0.18 (and 0.17)

Whilst Tasks isn't exactly under active development, I'm still maintaining it because I actually use it (unlike certain other projects, ahem). So, Tasks 0.18 is released. Tarballs and more information as usual are available at the Pimlico Project web site. In related news, we're slowly migrating over to the GNOME infrastructure. We've migrated the source code, next up is the tarballs and bugzilla.

Christine Spang: downloading a directory via HTTP with wget

From the department of things-that-I-know-are-possible-but-can-never-remember-how-to-do-so-hey-I-read-the-manpage-and-now-I'm-blogging-it, I bring you "downloading a directory of photos from a website":
 wget --recursive http://example.com/photos/some-event/ --no-directories --directory-prefix <local-folder-name> --accept JPG,RW2
I always remember wget --recursive (or wget -r for short), but that produces an annoying tree of directories starting with the website's domain and working its way up to the directory you actually want. In the command above, --no-directories removes the tree, and --directory-prefix tells wget to put the downloaded files somewhere that's not the current working directory. The --accept option tells wget to discard files with extensions other than those mentioned, so your downloaded directory is not cluttered with webserver-generated files like index.html if you don't want it to be. Here's the short version, since the long version is nice to remember but not so nice to type:
wget -r http://example.com/photos/some-event/ -nd -P <local-folder-name> -A JPG,RW2

Clint Adams: No raffle ticket winner

Things not to do if you want to be a good person: One of my readers writes in that ve thinks that an egomaniac I may have mentioned previously would get upset about a perceived lack of proper attribution because ve views vis bit of code like vis offspring. This causes me to immediately have flashbacks of poor parenting in public. Many times I have seen adults pay no attention to their children who are misbehaving, perhaps smearing chocolate on a stranger's dress or gnawing on a stranger's leg, and if such a victim either attempts surrogate parenting by kicking ver in the teeth or petitioning the parent to do something about ver, said parent will become very angry and indignant that anyone would impugn vis skills or dedication. So when I see some coder not patch vis buggy code for over three years, yet still find enough time to be a sanctimonious prick and think that ve has the right to tell people how ve should be treated and how the code should be modified by others, I think there are better ways to view that metaphor. On the other hand, I don't know any parents who neglect their kid for 3 years and then still want to actively direct childrearing, unless perhaps they're paying a governess.

Matthew Garrett: Power management at Plumbers

I'm running a power management track at the Linux Plumbers Conference again this November. Unlike most conferences which focus on presenting completed work, Plumbers is an opportunity to focus on unsolved problems and throw around as many half-baked solutions as you want in order to try to find one that seems to stick. The suspend/resume problem in Linux is mostly solved[1], which means that it's time for us to focus on runtime power management and quality of service.

This has been an especially interesting year in the field. We've landed the infrastructure for generic runtime power management, glued that into PCI and started implementing that at the driver level. pm_qos is being reworked to improve performance and scalability as we start seeing more drivers that need to express their own constraints. And, of course, we had the wakelock/suspend blockers conversation that didn't end in a terribly satisfactory manner, although Rafael is now working on an implementation that presents equivalent functionality with a different userspace API. Runtime full-system suspend isn't solved yet either - the current cpuidle-based solution doesn't work well on multicore systems. And maybe we could be more aggressive still by looking at reclocking more system components on the fly even if the existing interfaces don't allow that. Do we have all the hooks we need to identify which system resources are being used? Are we doing the best we can in terms of avoiding trading off performance for power savings?

So if you'd like to talk about any of these things, or if there's any other problems that you don't think have been solved yet, head on over to the call for submissions and help make sure that we can make Linux the most power-efficient OS possible.

[1] Yes, some machines are broken, but those tend to be individual weird bugs which we're gradually tracking down rather than fundamental issues in our core code, so they're not really in the scope of Plumbers

Craig Small: Manually calculating process times

Most of the time you can trust the times you see in programs such as ps and top within Linux, but there are those other times where you just want to check what is going on.

First up, if you're using a FreeBSD system and the procps Linux tools, you're out of luck because a lot of the procfs is broken. You're almost guaranteed to get wierd results.

Jiffies and Hertz
The first thing to find is your jiffies. This is the number of clock ticks per second. There are two main ways of doing it.

The first, and more difficult way is to add up the cpu numbers in /proc/stat, divide it by the first number in /proc/uptime and divide it by the number of cpus.

My cpu line in /proc/stat looks like:
cpu 1267430 145826 552700 137029699 905086 8295 17885 0 0

and my /proc/uptime is:
695317.99 1370303.58

I've got 2 cpus on this system so the calculation is:

(1267430 + 145826 + 552700 + 137029699 + 905086 + 8295 + 17885 + 0 + 0 ) / 695317.99 / 2
which equals 100.

The second way is to use getconf, with the command "getconf CLK_TCK" which again on this system gives you 100.

We call this value "Hertz" and is usually 100 or 1024 though for some architectures it is other values.

Start Time
For each process the procfs has the start time, but it is expressed as the number of jiffes since the computer was booted. If we want to know the real "wall clock" time a process is started we have to start with number of seconds since epoch (for example using the time() function) subtract the number of seconds since the computer was booted and add the process start time from procfs.

The seconds since boot is the first value in /proc/uptime:
696141.85 1371857.53

The 22nd item in a procfs PID stat file is the number of jiffes since boot when the process started. We have to divide it by Hertz to calculate the number of seconds.
27139 (bash) S 11942 27139 27139 34821 5200 4202496 5500 25537 0 14 40 16 18 15 20 0 1 0 69446639 23433216 1378 18446744073709551615 4194304 5082140 14073724008 6512 140737240085456 140127945249678 0 65536 3686404 1266761467 0 0 0 17 1 0 0 0 0 0

To get the start time, take the current time, subtract the boot time and add the process start time.
perl -e '$nowstr = localtime(time() - 696141.85 + 69446639 / 100); print $nowstr, "\n";
Mon Jul 12 22:20:07 2010

Unless you are very quick, you will have to take a few seconds off because the time() function will be now, while the values from the proc files will be a few seconds earlier as it takes time for you to cut and paste.


<script defer="defer" src="http://static.zemanta.com/readside/loader.js" type="text/javascript"></script>
1

Matt Zimmerman: Read, listen, or comprehend: choose two

I have noticed that when I am reading, I cannot simultaneously understand spoken words. If someone speaks to me while I am reading, I can pay attention to their voice, or to the text, but not both. It s as if these two functions share the same cognitive facility, and this facility can only handle one task at a time. If someone is talking on the phone nearby, I find it very difficult to focus on reading (or writing). If I m having a conversation with someone about a document, I sometimes have to ask them to pause the conversation for a moment while I read. This phenomenon isn t unique to me. In Richard Feynman s What Do You Care what Other People Think?, there is a chapter entitled It s as Simple as One, Two, Three where he describes his experiments with keeping time in his head. He practiced counting at a steady rate while simultaneously performing various actions, such as running up and down the stairs, reading, writing, even counting objects. He discovered that he could do anything while counting to [himself] except talk out loud . What s interesting is that the pattern varies from person to person. Feynman shared his discovery with a group of people, one of whom (John Tukey) had a curiously different experience: while counting steadily, he could easily speak aloud, but could not read. Through experimenting and comparing their experiences, it seemed to them that they were using different cognitive processes to accomplish the task of counting time. Feynman was hearing the numbers in his head, while Tukey was seeing the numbers go by. Analogously, I ve met people who seem to be able to read and listen to speech at the same time. I attributed this to a similar cognitive effect: presumably some people speak the words to themselves, while others watch them. Feynman found that, although he could write and count at the same time, his counting would be interrupted when he had to stop and search for the right word. Perhaps he used a different mental faculty for that. Some people seem to be able to listen to more than one person talking at the same time, and I wonder if that s related. I was reminded of this years later, when I came across this video on speed reading. In it, the speaker explains that most people read by silently voicing words, which they can do at a rate of only 120-250 words per minute. However, people can learn to read visually instead, and thereby read much more quickly. He describes a training technique which involves reading while continuously voicing arbitrary sounds, like the vowels A-E-I-O-U. The interesting part, for me, was the possibility of learning. I realized that different people read in different ways, but hadn t thought much about whether one could change this. Having learned a cognitive skill, like reading or counting time, apparently one can re-learn it a different way. Visual reading would seem, at first glance, to be superior: not only is it faster, but I have to use my eyes to read anyway, so why tie up my listening facility as well? Perhaps I could use it for something else at the same time. So, I tried the simple technique in the video, and it had a definite effect. I could feel that I wasn t reading in the same way that I had been before. I didn t measure whether I was going any faster or slower, because I quickly noticed something more significant: my reading comprehension was completely shot. I couldn t remember what I had read, as the memory of it faded within seconds. Before reaching the end of a paragraph, I would forget the beginning. It was as if my ability to comprehend the meaning of the text was linked to my reading technique. I found this very unsettling, and it ruined my enjoyment of the book I was reading. I ll probably need to separate this practice from my pleasure reading in order to stick with it. Presumably, over time, my comprehension will improve. I m curious about what net effect this will have, though. Will I still comprehend it in the same way? Will it mean the same thing to me? Will I still feel the same way about it? The many levels of meaning are connected to our senses as well, and the same idea, depending on whether it was read or heard, may not have the same meaning to an individual. Even our tactile senses can influence our judgments and decisions. I also wonder whether, if I learn to read visually, I ll lose the ability to read any other way. When I retrained myself to type using a Dvorak keyboard layout, rather than QWERTY, I lost the ability to type on QWERTY at high speed. I think this has been a good tradeoff for me, but raises interesting questions about how my mind works: Why did this happen? What else changed in the process that might have been less obvious? Have you tried re-training yourself in this way? What kind of cognitive side effects did you notice, if any? If you lost something, do you still miss it? (As a sidenote, I am impressed by Feynman s exuberance and persistence in his personal experiments, as described in his books for laypeople. Although I consider myself a very curious person, I rarely invest that kind of physical and intellectual energy in first-hand experiments. I m much more likely to research what other people have done, and skim the surface of the subject.)

Andreas Schuldei: Spotify on Linux

After several years of only having Windows and Mac clients, we at Spotify are really excited to release a qt-based Linux desktop client. The port was quite smooth after all the work we ve done for other platforms that we ve developed (iPhone, Android, several set-top boxes with Linux, Symbian, etc).

Being the Debian shop we are, we packaged it right away and are now happy to provide the client as a deb. It is regularly auto-built and tested by all our developers working on debian (and even ubuntu) whenever they want to listen to one or more of our 8*10^6 tracks. (One lonely fedora college prepared a rpm, too! Its not up yet, though.)

Add this to your sources.list files and aptitude install spotify-client-qt to check it out:

deb http://repository.spotify.com stable non-free

There is some additional infrastructure in the package spotify-client-gnome-support (same repository) so that you can click on links to open tracks, interact with Facebook and other, useful websites etc.

As we haven t found a reliable way to display ads yet, this version is only available to Spotify Premium subscribers.

Additional information about the archive key etc can be found here: http://www.spotify.com/se/download/previews/.

Russell Coker: Tracking down Write/Execute mmap() calls with LD_PRELOAD

One of the access controls in SE Linux is for execmem which is used to stop processes from creating memory regions that are writable and executable (as they make it easier to compromise programs and get them to execute supplied code). When the SE Linux audit log tells you that a program is attempting such access it s sometimes difficult to discover where in the code such an access occurs, for example if you have a large code base and mmap() is called in many places it can be difficult to determine which one is the culprit. Especially if you have a source package that contains multiple binaries that use a common shared library and you don t know which bits of library code are called by each executable. To solve this problem in the case of freshclam to provide extra information for Debian bug report #588599 [1] I wrote the following little shared object which can be compiled with gcc -shared -g -fPIC mmap.c -o mmap.so and used with LD_PRELOAD=./mmap.so whatever . Then when the program in question (or any non-SUID program it executes) calls mmap() with both PROT_EXEC and PROT_WRITE set the program will abort. If you run this through gdb then the program will break and you will get a back-trace of the function calls that led to the undesired mmap(). One thing to note is that this method only catches direct calls to a library function outside libc. When the libc code calls the library function (EG all the fwrite() etc code that calls mmap()) the LD_PRELOAD hack won t catch it. Thanks to Keith Owens for pointing this out. #include <dlfcn.h>
#include <stdio.h>
#include <sys/mman.h>
#include <stdlib.h>
#undef NDEBUG
#include <assert.h> void *libc6 = NULL; void *(*real_mmap)(void *, size_t, int, int, int, off_t); void do_init()

libc6 = dlopen("libc.so.6", RTLD_LAZY RTLD_GLOBAL);
if(!libc6)

printf("Aieee\n");
exit(1);

real_mmap = (void * (*)(void *, size_t, int, int, int, off_t))dlsym(libc6, "mmap");
void *mmap(void *addr, size_t length, int prot, int flags, int fd, off_t offset)

if(!real_mmap)
do_init();
assert(!(prot & PROT_EXEC) !(prot & PROT_WRITE));
return real_mmap(addr, length, prot, flags, fd, offset);

Gerfried Fuchs: On Becoming a MOTU

Working on and for Debian for the whole millennium already it would had been hard to not notice Ubuntu through the times. Given that fixing bugs in the package is in the interest of all involved parties I started to get curious for the packages I maintain in Debian what users of Ubuntu might have filed against them. Given that a fair amount of those actually do also apply to Debian I started to fix them too. Though, some bug status isn't able to use as an outsider, and given my approach to perfection not wanting to have packages in a bad shape in a release I started to dig a bit further into the procedures and applied to be accepted as a Ubuntu Developer, more specifically as a MOTU, which gives me the possibility to directly ask for syncrequest instead of having to go through a sponsor, or set wontfix status for bugreports in my packages that simply doesn't make sense to get implemented. Last week I got accepted into that state and I'd like to thank for all the nice and encouraging feedback along the path (including some "What? I thought you were MOTU since ages already??" responses). Let's see how much I really need it, my approach is rather to reduce Ubuntu diffs instead of having to work on them. I though understand that at times close to the releases there can be a need for them, as can be seen in that the package I have to put most effort into (wesnoth-1.8) has a Ubuntu diff in the last lucid release. And because Ubuntu already is in DebianImportFreeze I did a syncrequest for gitolite. Thanks for accepting me so quickly and rather bureaucratic! And no, Laney, I won't give the talk tomorrow because of this just on my own. ;)

Chris Lamb: 10K Challenge: Week 1

Wasn't the best start this week, unfortunately.
http://chris-lamb.co.uk/wp-content/2010/10k_schedule_1.png

11 July 2010

Petter Reinholdtsen: Idea for storing LTSP configuration in LDAP

Vagrant mentioned on IRC today that ltsp_config now support sourcing files from /usr/share/ltsp/ltsp_config.d/ on the thin clients, and that this can be used to fetch configuration from LDAP if Debian Edu choose to store configuration there. Armed with this information, I got inspired and wrote a test module to get configuration from LDAP. The idea is to look up the MAC address of the client in LDAP, and look for attributes on the form ltspconfigsetting=value, and use this to export SETTING=value to the LTSP clients. The goal is to be able to store the LTSP configuration attributes in a "computer" LDAP object used by both DNS and DHCP, and thus allowing us to store all information about a computer in one place. This is a untested draft implementation, and I welcome feedback on this approach. A real LDAP schema for the ltspClientAux objectclass need to be written. Comments, suggestions, etc?
# Store in /opt/ltsp/$arch/usr/share/ltsp/ltsp_config.d/ldap-config
#
# Fetch LTSP client settings from LDAP based on MAC address
#
# Uses ethernet address as stored in the dhcpHost objectclass using
# the dhcpHWAddress attribute or ethernet address stored in the
# ieee802Device objectclass with the macAddress attribute.
#
# This module is written to be schema agnostic, and only depend on the
# existence of attribute names.
#
# The LTSP configuration variables are saved directly using a
# ltspConfig prefix and uppercasing the rest of the attribute name.
# To set the SERVER variable, set the ltspConfigServer attribute.
#
# Some LDAP schema should be created with all the relevant
# configuration settings.  Something like this should work:
# 
# objectclass ( 1.1.2.2 NAME 'ltspClientAux'
#     SUP top
#     AUXILIARY
#     MAY ( ltspConfigServer $ ltsConfigSound $ ... )
LDAPSERVER=$(debian-edu-ldapserver)
if [ "$LDAPSERVER" ] ; then
    LDAPBASE=$(debian-edu-ldapserver -b)
    for MAC in $(LANG=C ifconfig  grep -i hwaddr  awk ' print $5 ' sort -u) ; do
	filter="( (dhcpHWAddress=ethernet $MAC)(macAddress=$MAC))"
	ldapsearch -h "$LDAPSERVER" -b "$LDAPBASE" -v -x "$filter"   \
	    grep '^ltspConfig'   while read attr value ; do
	    # Remove prefix and convert to upper case
	    attr=$(echo $attr   sed 's/^ltspConfig//i'   tr a-z A-Z)
	    # bass value on to clients
	    eval "$attr=$value; export $attr"
	done
    done
fi
I'm not sure this shell construction will work, because I suspect the while block might end up in a subshell causing the variables set there to not show up in ltsp-config, but if that is the case I am sure the code can be restructured to make sure the variables are passed on. I expect that can be solved with some testing. :) If you want to help out with implementing this for Debian Edu, please contact us on debian-edu@lists.debian.org. Update 2010-07-17: I am aware of another effort to store LTSP configuration in LDAP that was created around year 2000 by PC Xperience, Inc., 2000. I found its files on a personal home page over at redhat.com.

Next.

Previous.