Bäst just nu: For BDK - Open Ones Eyes
I recently had a problem with a server throwing random kernel panics. I’ll just post the problem and solution here in case anybody else finds it useful.
After about 12-20 hours of heavy system load, the backup server (Ubuntu Server, Precise 12.04.2 LTS) would freeze with a kernel panic. The problem was very reproducible, and would always happen after long periods of heavy load. The system was completely unresponsive, and even SysRQ failed (although this possibly had to do with the system not detecting a new keyboard after the panic).
This was the panic (transcribed):
Kernel panic - not syncing: Attempted to kill init! Pid: 1, comm: init Not tainted 3.2.0-43-generic #68-Ubuntu Call Trace: [<ffffffff81645fb1>] panic+0x91/0x1a4 [<ffffffff8106bf55>] forget_original_parent+0x245/0x250 [<ffffffff8106bf77>] exit_notify+0x17/0x110 [<ffffffff8106c803>] do_exit+0x1f3/0x450 [<ffffffff8106cc04>] do_group_exit+0x44/0xa0 [<ffffffff8107de3c>] get_signal_to_deliver+0x21c/0x420 [<ffffffff81014865>] do_signal+0x45/0x130 [<ffffffff81130000>] ? shmem_fill_super+0x190/0x1f0 [<ffffffff8101ecf6>] ? save_i387_xstate+0xe6/0x230 [<ffffffff81014b15>] do_notify_resume+0x65/0x80 [<ffffffff8165f07c>] retint_signal+0x48/0x8c panic occurred, switching back to text console
The panics started to happen after a system upgrade, so it appeared to be more of a software than hardware problem. We decided to test the memory anyway, but the test was negative even though it memtest86 performed 26 passes.
I was considering reporting this as a bug to the Ubuntu bug tracker, but the next day a new kernel was submitted to the repositories (3.2.0-44). After performing the upgrade, the system has gone four days of heavy load without a hiccup and I consider this problem solved.
"All fashion issues aside–and there are many, of course, because the device looks kind of ridiculous..."
av dentarg
den 31 May 2013 kl 06:02
- Dustin Curtis in his piece about Google Glass
Jag har skrivit en egen Twitterläsare som filtrerar ganska friskt baserat på ett antal parametrar. Om jag laddar om några gånger och väljer ut de som väckte mitt intresse mest såg jag:
Satte 5 av 8 outron i #fantasterna . Betyder det att det var lätta frågor eller att jag var lite duktig?
— Susanne Delastacia (@delastacia) April 1, 2013
Göteborg och Munka-Ljungby i nordvästra Skåne hade de högsta noteringarna i eftermiddags med +9,5 avrundat till +10. Måste ha varit härligt!
— Ulrika Andersson (@Solgudinnan) April 1, 2013
best new feature ever in Chrome Canary.. “Copy as cURL”: bit.ly/10sXlff – copies headers, cookies, etc – epic!
— Ilya Grigorik (@igrigorik) April 1, 2013
Heh, hittade just alternativet “Skattkarta” på Google maps… Möjligtvis som sist på bollen, men kul. Har dock inte hittat pirater än.
— Henrik Perälä (@henrikperala) April 1, 2013
Vill du ta bättre fotografier? Vässa dina kunskaper under våren så att du kan fånga sommarminnena på film –> bit.ly/GTKdZz
— Fotografiska (@Fotografiska) April 1, 2013
Stephen Hawking och Leonard Mlodinow skriver i “The Grand Design”, som jag just börjat läsa, om Thän yttersta frågan. Varför finns vi etc.
— Niklas Hellgren (@oniklasg) April 1, 2013
Kollar #fantasterna lite efter er. Så himla TV4 att göra 10 000-tusenkronorsfrågan, fast med utslagningsmoment.
— Ulrika Good (@ulrikagood) April 1, 2013
Här finns ett antal olika träningsprogram beroende på hur långt man vill klara av att springa efter programmet och hur tränad man är till att börja med, men även en massa annan information: olika former av löpträning (pulsträning, intervaller, backträning, fartlek, distanslöpning) men också diverse annan träning som är lämplig i samband med löpning (styrketräning, stretching, teknikövningar).
Det finns också kapitel om mat och näringslära, utrustning och även mindre trevliga saker som skador man som löpare kan drabbas av och vad man kan göra för att undvika dem men även vad man har för möjligheter till alternativ träning om man väl drabbats.
Det som är lite trist att boken bara med ett par ord (och inte speciellt positivt) nämner barfotalöpning. Det behöver inte nödvändigtvis innebära att man springer helt barfota (vilket inte är praktiskt möjligt under stora delar av året på våra breddgrader) utan även kan betyda att man använder olika varianter av "minimala skor". Själv springer jag (när vädret tillåter) i mina Vibram FiveFingers som bara ger ett tunt lager gummi mellan mig och underlaget, men ingen dämpning (vilket gör att man springer annorlunda).
Ingmarie Nilsson: Löpträning
ICA Bokförlag, 2011
112 sidor
ISBN: 978-91-534-3590-7
Fancontrol not working after resume on Ubuntu
av Erik Forsberg (forsberg)
den 02 March 2013 kl 08:18
Bought a new computer. Had some trouble with the fan controller built into the chassis, so got a couple of PWM fans instead since the motherboard can control 1 CPU and 3 chassis PWM fans.
The BIOS however was a bit limited when it came to how slow you could make the fan run. So turned to the fancontrol package in ubuntu, and after some fiddling it worked as intended, even turning off the case fan when the temperature was below the configured threshold.
However, after suspending then resuming, the fan would go at 100% again, and not spin down. There's a launchpad bug that tells me I'm not the only one with this problem.
Here's a workaround. Create /etc/pm/sleep.d/20_fancontrol with the following contents:
#!/bin/sh
case "${1}" in
resume|thaw)
/usr/sbin/service fancontrol restart
;;
esac
This will restart the fancontrol service after resume, which solves the problem. The fan will run at 100% for a little while at resume, since it takes a couple of seconds before this script is being run.
Uppror blir det dock ändå, fast i mindre skala. Som titeln antyder så ställer kärleken till problem för en del, framför allt i och med att ett snedsteg inte bara händer utan framför allt observeras av helt fel person. Som om huvudpersonerna inte var instabila så att det räckte sedan tidigare, typ.
Det känns som om det här albumet avslutar ett större kapitel. Det slutar med att Rick håller ett tal där han förklarar hur han tänker nu och hur han tänkte tidigare och avslutar med att de är omringade av döda, men att det är gruppen själva som är de levande döda. Återstår att se om det verkligen läggs i en ny växel i nästa volym. Än så länge har jag en liggande oläst, sedan är jag ikapp den svenska utgivningen och får vänta ett tag mellan varje del.
Robert Kirkman: Köttets lustar (The Heart's Desire)
Översättning: Sara Årestedt
Apart Förlag, 2012
opaginerad
ISBN: 978-91-979592-3-0
ZooKeeper failing to elect leader due to initLimit being too small
av Erik Forsberg (forsberg)
den 09 February 2013 kl 19:00
At work, I use Apache ZooKeeper to coordinate a distributed service. I find ZooKeeper very easy to work with and program against, but as all software, it can be troublesome now and then.
I have a 3-node ZooKeeper cluster that was behaving very oddly the other day. It started with one of the nodes going down due to hardware trouble. This is supposed to be no problem since 2/3 nodes are still up and form a quorum. However, the whole service stopped serving clients.
At the time the node that went down crashed, it was the LEADING node of the cluster, with server id being 3. This meant another node needed to be elected as LEADER. The node with server id=2 was elected as leader, but failed to successfully establish leadership with a rather confusing error message in the log (/var/log/zookeeper/zookeeper.log):
2013-02-07 01:42:09,336 - INFO [QuorumPeer:/0:0:0:0:0:0:0:0:2181:QuorumPeer@655] - LEADING
2013-02-07 01:42:09,336 - INFO [QuorumPeer:/0:0:0:0:0:0:0:0:2181:ZooKeeperServer@154] - Created server with tickTime 2000 minSessionTimeout 4000 maxSessionTimeout 40000 datadir /var/zookeeper/version-2 snapdir /var/zookeeper/version-2
2013-02-07 01:42:09,342 - INFO [QuorumPeer:/0:0:0:0:0:0:0:0:2181:FileSnap@82] - Reading snapshot /var/zookeeper/version-2/snapshot.70028d3e5
2013-02-07 01:42:13,407 - INFO [QuorumPeer:/0:0:0:0:0:0:0:0:2181:FileTxnSnapLog@256] - Snapshotting: 70028d3e5
2013-02-07 01:42:23,864 - INFO [LearnerHandler-/10.20.46.90:32845:LearnerHandler@249] - Follower sid: 1 : info : org.apache.zookeeper.server.quorum.QuorumPeer$QuorumServer@7ab2c6a6
2013-02-07 01:42:23,865 - INFO [LearnerHandler-/10.20.46.90:32845:LearnerHandler@273] - Synchronizing with Follower sid: 1 maxCommittedLog =0 minCommittedLog = 0 peerLastZxid = 70028d3cb
2013-02-07 01:42:23,865 - INFO [LearnerHandler-/10.20.46.90:32845:LearnerHandler@357] - Sending snapshot last zxid of peer is 0x70028d3cb zxid of leader is 0x800000000sent zxid of db as 0x70028d3e5
2013-02-07 01:42:47,691 - INFO [QuorumPeer:/0:0:0:0:0:0:0:0:2181:Leader@413] - Shutdown called
java.lang.Exception: shutdown Leader! reason: Waiting for a quorum of followers, only synced with: 2:
at org.apache.zookeeper.server.quorum.Leader.shutdown(Leader.java:413)
at org.apache.zookeeper.server.quorum.Leader.lead(Leader.java:319)
at org.apache.zookeeper.server.quorum.QuorumPeer.run(QuorumPeer.java:658)
Tried googling on this, but didn't get any helpful hits. I tried all kinds of tricks to get the service up, then started looking into the source code, especially the lines that are mentioned in the exception message.
Turns out I had a misconfiguration. In /etc/zookeeper/zoo.cfg there's a parameter initLimit described as follows:
# The number of ticks that the initial # synchronization phase can take initLimit=10
In my setup, I had the default value (10) set for this parameter. Looking at the administrator's guide for the version of zookeeper I'm running, it describes initLimit as follows:
"Amount of time, in ticks (see tickTime), to allow followers to connect and sync to a leader. Increased this value as needed, if the amount of data managed by ZooKeeper is large."
That particular ZooKeeper cluster has several hundred thousand objects, with a database size of roughly 150MiB. I guess that is counted as a large amount of data in ZooKeeper.
I increased my initLimit to 100, which made the problem go away, the server started fine and my cluster was able to go into a healthy state and start serving data again.
What happened here was that the server that was being elected as leader (with server id 2) was elected leader. It started sending a snapshot of the database to its follower (with server id 1), but before that completed and the follower reported itself as ready and following, the initLimit timeout was reached, and the leader thread decided it had to give up, since it was only synced with server id 2 (itself). So increasing initLimit to a value that allowed the snapshot transfer to complete fixed this problem.
Shipping your logs to a central server is usually a good thing to do. For a large number of servers it provides a better overview, and no matter the numbers of servers a secondary log location can be helpful in figuring out why something bad happened to a server.
My two VPS nodes are now using loggly as a remote (TLS) syslog server. I’m even allowed do that for free, as long as I don’t upload more than 200 MB of logs per day, nor want the log data to be retained for more than a week. Not that I would mind paying a bit for a longer retention period. It’s just that their pricing feels a bit steep, given that I currently log less than a megabyte per day.
(Yes, I do realize that I’m not their obvious target audience.)
Already running rsyslog I decided to follow loggly’s rsyslog instructions, which did a pretty good job of explaining the additional configuration needed. The one thing I did miss in those instruction were a discussion on queue setting, which very much will matter when loggly’s servers for one reason or another becomes unavailable. By default rsyslog only queues a limited number of entries in memory, so for additional resilience I explicitly enabled a disk assisted queue, based on the rsyslog reliable forwarding guide.
Want to test the queuing? Just put appropriate iptables rules in place, and then speed up time by using logger(1) to pipe lots and lots of entries into syslog.
All in all, the following loggly specific configuration seems to do the trick for me.
# /etc/rsyslog.d/loggly.conf $DefaultNetstreamDriverCAFile /etc/ssl/loggly/loggly_full.crt $DefaultNetstreamDriverCertFile /etc/ssl/loggly/dummy-halleck.crt $DefaultNetstreamDriverKeyFile /etc/ssl/loggly/dummy-halleck.key $ActionSendStreamDriver gtls $ActionSendStreamDriverMode 1 $ActionSendStreamDriverAuthMode x509/name $ActionSendStreamDriverPermittedPeer *.loggly.com $ActionQueueType LinkedList $ActionQueueFileName loggly $ActionResumeRetryCount -1 $ActionQueueSaveOnShutdown on *.* @@logs.loggly.com:<assigned port>
If you are running Ubuntu, and Launchpad bug #1075901 have yet to be fully fixed, you might manually need to chown syslog:syslog /var/spool/rsyslog/. While you are at it, also install the needed rsyslog-gnutls package.
Worth mentioning is that loggly provides the option of archiving your logs to a S3 bucket. Given my modest log volumes the cost of doing that ought to be pleasantly close to zero.
Will be very interesting to see how reliable this solution turns out to be. The plan is to setup some semi-automated testing, and hopefully have some results to share in a follow-up post, say in a month or two.
My Christmas gift to myself this year turned out to be a YubiKey NEO.
The new feature I myself find most interesting is that the NEO can act as an OpenPGP smartcard. While there is a pretty good introduction in the Yubico blog post YubiKey NEO and OpenPGP I ran into some obstacles getting things running under Ubuntu.
First of all it doesn’t seem like the version of the yubikey-personalization (1.7.0) included in Ubuntu 12.10 recognizes the YubiKey NEO. Without spending to much time on debugging that issue was solved by upgrading to the current yubikey-personalization version, using the Yubico PPA.
Then there was the matter of getting the device permissions right, allowing my non-root user to use/modify the NEO more actively than just having it act as a keyboard (HID), spitting out one time passwords. Turns out that the /lib/udev/rules.d/70-yubikey.rules provided by the current yubikey-personalization (1.11.1) only matches the ATTRS{idProduct} “0010″, which doesn’t apply to the NEO. I solved that by copying the 70-yubikey.rules to /etc/udev/rules.d/, modifying it to instead match ATTRS{idProduct} against “0010|0111″. According to the add udev rules for YubiKey NEO bug report it probably doesn’t hurt to also through the 0110 id into the mix.
Finally I had the fun experience of running into a limitation in the gnome-keyring’s capacity to act as gnupg-agent (Launchpad bug #884856). Any attempt to have GnuPG interact with the NEO smartcard, while using the gnome-keyring gnupg-agent, resulted in a “selecting openpgp failed: unknown command” error. Not finding any cleaner configuration option I resorted to simply removing /etc/xdg/autostart/gnome-keyring-gpg.desktop, resulting in gnome-keyring no longer hijacking the GPG_AGENT_INFO environment variable, instead letting the real gnupg-agent do its thing.
Now I only need to decide to what extent to actually use the OpenPGP smartcard feature. Yet, that’s a whole different blog post.
200g smör
2dl strösocker
4 ägg
3,5dl vetemjöl
En dryg tesked bakpulver
50g suckat
50g röda cocktailbär
50g syltat apelsinskal
Rivet skal från en citron
1,5dl russin
50g hackade nötter
2msk konjak
Rör socker och smör pösigt. Separera äggen i gulor och vita. Rör ner gulorna i smeten. Vispa vitorna till hårt skum.
Blanda mjöl och bakpulver. Blanda i citronskal, cocktailbär, suckat, apelsinskal, russin och nötter. Rör ner i smeten. Tillsätt konjaken och rör ut (1). Vänd ner äggvitan.
Fördela ut smeten i en smörad och brödad form. Grädda i nedre delen av ugne på 180C i 1 timme. Låt kakan vila 10 minuter innan den stjälps upp. När den svalnat, slå i den i folie och låt vila minst tre dagar innan den skärs upp. Servera i tunna skivor.
____
1/ Smeten är god och kan ätas utan tillagning. Håll den borta från barnen, annars blir det ingen kaka.
Upgrading firmware on the Linksys SRW2024 without using the web interface
av tobbez
den 29 November 2012 kl 13:55
This is useful if, for example, the web interface keeps resetting the connections.
Upgrading the firmware requires first updating the boot code, and the regular console in the earlier firware doesn’t have support for flashing the boot code. However, there is a hidden IOS-like cli available, that makes it possible to upgrade the boot code over tftp. An additional benefit is that it is much faster than using xmodem.
The steps
- Setup a tftp server on your machine, serving the files
srw2024_16_boot-101.rfbandls20xx-12230.ros(download from Cisco) - Connect your computer to the switch using ethernet and serial cables.
- Boot the switch.
- Log into the console.
- Press C-z.
- On the new promt, type
lcliand press enter. - To upgrade the boot code, type
copy tftp:///srw2024_16_boot-101.rfb boot - Then upgrade the firmware:
copy tftp:///ls20xx-12230.ros image - Lastly, restart the switch:
reload
That’s it.
As an aside, please note that the web interface only works in Internet Explorer, so if it seems like it doesn’t work, it’s probably because your’re using another browser.
My Master Thesis has now been published and can be found at the LiU Electronic Press archive. I wrote this thesis at my time at ABB Corporate Research in Västerås where I performed research into electric breakdown in transformer oil.
J. Fors, Modeling and OpenFOAM simulation of streamers in transformer oil. Master thesis. Linköping University, 2012. [pdf] [ref]
Electric breakdown in power transformers is preceded by pre-breakdown events such as streamers. The understanding of these phenomena is important in order to optimize liquid insulation systems. Earlier works have derived a model that describes streamers in transformer oil and utilized a finite element method to produce numerical solutions. This research investigates the consequences of changing the numerical method to a finite volume-based solver implemented in OpenFOAM. Using a standardized needle-sphere geometry, a number of oil and voltage combinations were simulated and the results are for the most part similar to those produced by the previous method. In cases with differing results the change is attributed to the more stable numerical performance of the OpenFOAM solver. A proof of concept for the extension of the simulation from a two-dimensional axial symmetry to three dimensions is also presented.
The DGS-3024 does not have a built-in reset function that resets the password, but here’s how you can do it (without contacting the D-Link support).
First, you need to reset the switch to its default settings. This will not touch the user accounts on the switch. It will, however, reset other settings, most importantly the IP address to the defaults (10.90.90.90/24). To reset to default settings, boot the switch and wait until
Please wait, loading runtime image ...................... XX%
is displayed on the serial console, then press Shift-3. After that, press y when asked if you want to load the default configuration.
Note: If you press Shift-3 earlier (during the power on self test), you will just be able to flash the switch, or change the flashing settings.
After that, connect the switch to a computer (using an ethernet cable) and assign it an IP address in the appropriate range (e.g. 10.90.90.1/24).
Secondly, you will need to setup a TFTP server, and in its root put a file named ‘pw.cfg’ containing:
create account admin someuser pass pass
where someuser is the user you want to create, and pass is the password you want for that user. If you use a username that already exists, it won’t work (unless you first delete that user).
Third, you will need to download the MIBs for the DGS-3024 (available here), and unpack them.
Then, use SNMP commands to make the switch download and execute the file you created earlier:
# File type (switch configuration) snmpset -M DGS3024_MIB_20060721/standard/:DGS3024_MIB_20060721/private/ -v2c -c private 10.90.90.90 1.3.6.1.4.1.171.12.1.2.1.1.6.3 i 3 # Type of transfer (?) snmpset -M DGS3024_MIB_20060721/standard/:DGS3024_MIB_20060721/private/ -v2c -c private 10.90.90.90 1.3.6.1.4.1.171.12.1.2.1.1.4.3 i 2 # Filename snmpset -M DGS3024_MIB_20060721/standard/:DGS3024_MIB_20060721/private/ -v2c -c private 10.90.90.90 1.3.6.1.4.1.171.12.1.2.1.1.5.3 s pw.cfg # Transfer direction (download) snmpset -M DGS3024_MIB_20060721/standard/:DGS3024_MIB_20060721/private/ -v2c -c private 10.90.90.90 1.3.6.1.4.1.171.12.1.2.1.1.7.3 i 3 # TFTP server IP (the one you set earlier) snmpset -M DGS3024_MIB_20060721/standard/:DGS3024_MIB_20060721/private/ -v2c -c private 10.90.90.90 1.3.6.1.4.1.171.12.1.2.1.1.3.3 a 10.90.90.1 # Start the transfer snmpset -M DGS3024_MIB_20060721/standard/:DGS3024_MIB_20060721/private/ -v2c -c private 10.90.90.90 1.3.6.1.4.1.171.12.1.2.1.1.8.3 i 3
After running these commands you should immediately be able to login to the switch (using serial or telnet) using the username and password you specified earlier.
Thanks goes to this blog post (in russian), that helped me figure out how to reset the password.
Idag ställdes heeler på MyDog, och vem slår till och vinner BIR som tiomånaders? Jo, Norries kullbror Nicke! Jag måste fnissa lite över det, och över rasens extrema heterogenitet, för att Norrie skulle göra samma bedrift är uteslutet
Tänk att helsyskonen i kullen är så olika! Förvisso sticker ju Norrie ut lite extra med sina paraboler och sin knorr, men han är allt en storlek mindre än de andra hanarna dessutom.
Nåja, vi som inte kan vinna on looks alone får ligga i på andra sätt! Igår mötte jag upp med Anna för lite freestyleträning i ett frostigt Valla. Norrie fick gå med täcke dit för att hålla det varmt åt Zumi, och när jag anlände fick faktiskt Zumi börja träna lite eftersom hon var pigg och glad. När hon plötsligt tappade fokus så knöt jag upp henne, bökade på henne täcket och satte henne på det medtagna pläden så hon skulle hålla värmen, och körde med Norrie istället. Men Zumi är mer frusen än jag kunde föreställa mig – hon frös trots päls, täcke, pläd och solsken! På pluskontot kan dock noteras att hon kunde tänka sig att träna med täcke på, och att dessutom lägga ner lite ordentlig entusiasm i det hela
Sötråttan då! Svansen protesterade lite mot täcket, men hon var glad och pigg och söt som bara Zumi kan vara.
Anna gjorde en hjälteinsats och fotade under träningen, hipp hurra! Somliga andra kom ihåg kameran men hade glömt minneskortet… Så fantastiska bilder av Anna!




Norrie, som fick pausa utan täcke, hade inga direkta problem med kylan, inte ens när han lade sig direkt på det frostiga gräset istället för på pläden. Han, som har så kort päls, borde ju rimligen vara den som fryser, men näääädå.

Vi lade ork och fokus på freestyle, förstås, även om det inte var sådär jättemycket som kändes helt hundra den här gången. När Norrie är lite speedad så flyter han ut lite i både kretsa och gå runt, vilket innebär att det blir svårare för honom att komma in i ett slalom från det. Slalomet i sig fungerade sådär, dessutom, och han var lite ovanligt vimsig på var matte egentligen gjort av leksaken. Summerat så var det inte ett toppenpass rent prestationsmässigt, men toppenpass nontheless tack vare bra träningssällskap med bra idéer!





Idag har vi också fått lite saker gjorda. Vi började med en promenad ute på gräsvägarna i Skorteby, som tyvärr fick ett lite tråkigt slut. När vi kopplat upp alla vovvarna och gått en bit så började Zumi plötsligt halta (VEM om inte Zumi, förstås!), och inte lite heller. Ena bakbenet vägrade hon sätta i, för att sedan sätta i det ett par steg och istället vägra sätta i det andra. Hältan gick sedan tillbaka till det första och hon ömsom hoppade på tre ben, ömsom linkade fram. Patella, tänkte jag som första grej förstås
och sedan köldkramp, men beteendet kändes inte klockrent för något av dem. Efter lite vila hemma så visade hon ingenting på en kort rastning nu på kvällskanten, men jag får hålla koll på de där benen… Förhoppningsvis har hon bara sträckt sig lite, för hon flängde runt en del, men hon har visat obehag på samma ben en gång tidigare, vilket försvann när jag borstade ur snön ur tassen den gången.
Norrie och jag tog oss direkt ut till LHU och lite försenade studsade vi in på avslutningen på valpagilitykursen. Lagom sams, med soffstress och Zumioro, började vi inte sådär superstabilt. Norrie morrade åt höger och vänster (tjoho så konstigt när matte är uppstressad, NOT!) och matte tyckte att han kunde gå och kamma sig. Efter några lagom misslyckade bytesövningar (jag har visst inte lärt honom att springa bort från leksaken och SEDAN till leksaken, så han tar rakaste vägen
) blev det lite teoripaus där knorvhunden somnade i mitt knä och sen lite rastning (där vi återigen blev osams, denna gången över något så fantastiskt som att han inte ville ta en godisbit när han precis slickat på en fläck. Matte arg, Norrie mycket förvirrad…).
Som tur är så slutade vi inte på minus utan jättemycket på plus, för att Anna bad oss att vara demohund för hur man lär in ett bakombyte. Och jajemen, med rätt guidning och med rätt placering av leksak så fattade vi båda två vad vi skulle göra! Usch så bra det kändes
Något som kändes både bra och dåligt var att han morrade till när en hund kom fram till honom och nosade på honom. Dåligt, för att han morrar, bra, för att han lyssnade direkt på att jag sa nej och släppte det helt för att istället fortsätta jobba med mig. Vi behöver nog socialisera det lilla monstret en smula med både hundar och människor misstänker jag…
Det är för övrigt när jag ser Norrie på bild, speciellt på andras bilder, som jag slås av vilka helt galet stora öron han har. Och då menar jag… Galet!

Om ni undrar vad jag gör på bilden egentligen så låser jag upp min telefon med näsan för att slippa ta av mig handskarna
Jag verkar inte fatta att jag redan tagit av mig en handske, dock…
På temat att jag ska lägga energi på att ta hand om mig själv kan vi konstatera att första veckan av det nya året inte riktigt exekverats optimalt, om man uttrycker sig så. Jag har varit jättesömnig hela veckan och ändå inte lagt mig i tid. Mrgh! Imorgon blir det dock lite sovmorgon för hela hamsterkollektivet så vi kommer i fas igen.
Gällande hälsa på ett lite bredare plan slogs jag av en insikt idag. Som ni säkert vet har jag en hel och en trasig hund, om man uttrycker det lite trubbigt. Norrie har hittills inte haft några större hälsomässiga problem mer än en lite strulig mage som är lätt att ta hand om på egen hand (och välja tugg som passar lilla magen bra), medan Zumi sällan hinner vara hemma i mer än en vecka innan hon går sönder på nya innovativa sätt. När jag idag satt och läste om melanom till följd av att vi plötsligt hittat leverfläcksliknande märken i ena ljumsken på Zumi, förstod jag plötsligt två saker – mitt problem att knyta an till Zumi, och obehaget jag känner inför att hälsoundersöka Norrie.
Vi börjar från slutet, med att inte vilja hälsoundersöka Norrie. Känslan av att ha en hund som oftast är hel, utan långa konvalescenttider och där man inte varje dag blir orolig för konstiga symptom är en enorm befrielse. När det blir dags för hälsoundersökningar säger jag potentiellt adjö till den lättnad jag känner i samband med Norrie – han kanske får både en patelladiagnos och ett par dåliga höfter, och då kan det ju till och med vara kört med freestylekarriären. Då blir Zumi den helaste (med fria höfter och armbågar, tjoho!), och hon är inte så mycket att hålla i handen helhetsmässigt
För att komma till Zumi och att jag haft svårt att knyta an till henne, så handlar det väldigt mycket om att hon har varit trasig av och till så många gånger. Jag har inte riktigt vågat tro på att hon blir särskilt gammal, trots att det varit oärftliga småsaker som hon varit trasig med, och vem vågar knyta an ordentligt till en hund som det känns som att man kanske kommer att förlora i förtid? Sen blir vi tightare när hon är frisk, och så blir jag lite avvaktande igen när hon går sönder. Och så har det hållit på. Jag hoppas att de här små fläckarna är ofarliga och att hon inte får problem med narkosen på tisdag – så kanske vi vågar bli ett team ordentligt.


av Leif Nixon (nixon)
den 23 November 2011 kl 10:12
(Jag verkar ha flyttat mitt skrivande mer och mer till Google+, om ni saknat mig...)
Idag borde jag ha pluggat inför en tenta i databasteknik jag skriver
om elva ett par timmar. Det gick sådär. Istället har jag lärt mig
lite (om) Lua & fönsterhanteraren Awesome WM, samt knackat ihop något
jag har saknat sen min KDE-tid - fuzzy clock!
En fuzzy clock skriver ut klockslaget lite ungefär snarare än exakt. I KDE kunde man ställa in graden av detta ungefär, från den givande "Mitt i veckan!" till den nivå som är aktuellt nedan, nämligen femminutersintervall. I detta femminutersintervall går klockan även lite före, vilket är precis vad jag behöver.
Det är ingen avancerad kod precis, och att använda den är desto lättare (själv använder jag den som widget i Awesome WM), typ såhär:
require("fuzzy") time = fuzzy.fuzzy_time() print(time)
Själva såsen också:
local os = { time = os.time, date = os.date } local string = { format = string.format } local math = { mod = math.mod } module("fuzzy") hours = { "ett", "två", "tre", "fyra", "fem", "sex", "sju", "åtta", "nio", "tio", "elva", "tolv" } minutes = { "fem över %s", "tio över %s", "kvart över %s", "tjugo över %s", "fem i halv %s", "halv %s", "fem över halv %s", "tjugo i %s", "kvart i %s", "tio i %s", "fem i %s", "%s" } function round_minute(min) rem = math.mod(min, 5) rounded = min - rem -- Tre minuter in i ett femminutersblock -> gå till nästa block! if rem >= 3 then rounded = rounded + 5 end return rounded end function hour_to_human(hour) if hour > 12 then hour = hour - 12 end if hour == 0 then hour = 12 end return hour end function time_to_human(cur_time) min = cur_time["min"] hour = cur_time["hour"] fuzzy = "" rmin = round_minute(min) if rmin >= 25 then hour = hour + 1 if hour >= 24 then hour = 1 end end cor_hour = hour_to_human(hour) tmin = rmin / 5 if tmin == 0 then tmin = 12 end fuzzy = string.format(minutes[tmin], hours[cor_hour]) return fuzzy end -- Här är magin! function fuzzy_time() cur_time = os.date("*t") return time_to_human(cur_time) end
Använder du Emacs, AUCTeX, reftex och biblatex? Vill du smidigt kunna använda det inbyggda och trevliga stödet (C-c [) för att infoga referenser i din text?
Pejsta in det här på lämplig plats:
(setq reftex-cite-format '((13 . "\\cite[]{%l}") (116 . "\\textcite[]{%l}") (112 . "\\parencite[]{%l}") (97 . "\\citeauthor{%l}") (110 . "\\nocite{%l}")))
Nu kommer Emacs fråga dig om vilken typ av referens du vill infoga, vilket kombinerat med reftexs redan galet trevliga stöd för att infoga referenser kommer göra ditt liv lite trevligare. Lovar.
När vi ändå talar om det här - läs det här inlägget om Emacs & AUCTeX. För du använder väl redan AUCTeX? :)
Ny webbplats för YH-utbildning till Bygglovhandläggare
av Jon Lindholm (lindholm)
den 20 February 2011 kl 21:07
Centrum för arbete och studier i Värmdö har startat Sveriges första yrkeshögskola till Bygglovhandläggare. Jag fick uppdraget att skapa deras nya webbplats. Denna webbplats är tänkt att stå ut lite mer än vad man är van vid för utbildningswebbar.
En mörk bakgrund stöds upp av ett stort bakgrundsfoto tillsammans med starka accentfärger. Sidan är tänkt att vara det första den nye studenten möter och ska då få positiva känslor för utbildningen.
Webbplatsen finns på www.bygglovhandlaggare.se.
Hur Hanbolls-VM misslyckas med konverteringen på sin webb
av Jon Lindholm (lindholm)
den 12 January 2011 kl 22:13
Idag är det vanligt förekommande att man pratar om konvertering inom webbranschen, speciellt när det gäller webbshopar och liknande sidor. Med konvertering menas att man tittar på hur man får besökaren att göra det man tänkt på den specifika webbplatsen. Det kan t.ex. vara att köpa en vara i en webbshop, ladda ner ett program eller liknande. Detta kan egentligen appliceras på alla webbplatser; det finns gott om forskning och studier som visar på hur besökare agerar på en webbplats och vad det är som får denne att genomför ett köp eller om denne inte gör det. Trots detta ser man allt som oftast väldigt dåliga exempel på hur man inte optimerat konverteringsgraden. Ofta är detta kritiska områden som hela företaget får sin inkomst genom.
Jag ska ge ett exempel på några som inte alls tänkt på hur man vill att besökaren ska agera på sidan och därför även gjort ett - hittills - dåligt resultat. Det jag tänker på är Handbolls-VM som har premiär imorgon, bland annat i Linköping, och de säljer dålig med biljetter.
En viktig del för arrangörerna är att sälja biljetter till matcherna, något som inte alls gått så bra i Linköping. Jag kan garantera att man skulle kunna sälja betydlig fler biljetter om man rättade till några stora missar på sin hemsida.
Går man idag in på Handbolls-VMs officiella webbplats och klickar sig fram till "Tickets" hamnar man på denna sida:

Här är information som är helt avgörande och som inte framkommer någon annanstans. Biljetten man köper är en dagbiljett, alltså inte som brukligt att man köper en biljett per match. Denna ytterst viktiga information döljer de alltså i en massiv text utan vidare förklaring. Läser man vidare på hemsidan under "Booking" kan man se att det är tre matcher per dag och ort, således verkar man enbart kunna köpa biljetter till tre matcher och inte bara en, men det är oklart hur det egentligen är.
Jag går in på booking och väljer en match jag vill se.

Ganska naturligt. Jag väljer Island - Japan och klickar på Tickets i högerspalten.
Jag kommer då till denna Ticnet-sida:

Notera att jag klickade på den matchen jag ville se. Här är nästan all information borta om vilken match jag ska få se, nu står det istället tre matcher i liten text under evenemangsbeskrivning. Jag blir konfunderar. Jag klickade ju på Island - Japan. 600kr känns lite dyrt för en sådan match. Hur jag än vänder och vrider på det så kan jag inte hitta biljetten för min match. Jag väljer då att inte köpa någon biljett, alternativt att jag ringer biljettkassan istället.
Några enkla fel de gör:
- Gömmer viktig information i brödtext.
- Många klick för att komma fram till biljettköpet.
- Otydlig information som gör mig som köpare osäker.
- Under booking-sidan "lurar" de mig och tror att jag kan köpa en biljett till enbart en match.
- Man skickas till en Ticnet-sida som inte tydligt visar vad man ska köpa biljett till.
Hur de skulle kunna förbättrat konverteringen
Tydliggöra viktig information som att man köper till tre matcher, och eventuellt förklara varför man inte kan köpa till en match.
Lyfta fram biljettköpet tidigare på hemsidan. Jag borde få upp en tydlig ruta på startsidan som säger något i stil med: Nästa match i Linköping är Island - Japan - köp dagbiljett och få se tre matcher på en biljett. Köp biljett till en match.
Så här skulle det kunna se ut, se högerspalten och jämför med Handbolls-VMs startsida idag (klicka för större):
Ett annat bra exempel är Detroit Red Wings. När man går in på deras hemsida möts du genast av en möjlighet att köpa biljetter till nästa match.
På bara ganska enkla sätt kan man troligtvis öka konverteringen på biljetter och på så sätt få mer publik till sin matcher.
Det har varit lite dåligt med postningar på bloggen, men nu är det i alla fall dags att önska ett Gott Nytt År!
Ett nytt år som är det näst sista på väldigt länge som har en dag där tvåsiffrigt årsnummer, månad och dag i månad alla har samma värde. Efter den 11 november 2011 är det bara 12 december 2012 kvar innan man får vänta ända till den 1:a januari 2101 innan det går igen, och det är fasligt länge.
Hoppas att 2011 eller 0x7DB blir ett minst lika intressant år som 2010!
Vissa kombinationer råkar man bara kombinera, och sen är man fast. Bacon och Broccoli är en sådan kombination. Dessutom låter det trevligt.
Just nu tror jag på leverans i följande ordning.
- Cykel
- Potentiometer
- Hemdisk.
As the crossdev scripts don't really wants to play nice with Paludis the packages have to be "created" manually. This is really a simple procedure as the packages themself already works for different targets, they just need to be told. I got the information on how to do it from the Gentoo wiki.
First one needs a repo for the cross avr chain. We will call it cross-avr. It is created by putting this configuration file in /etc/paludis/repositories:
master_repository = gentoo
format = ebuild
location = /var/paludis/repositories/cross-avr
names_cache = /var/cache/paludis/names
write_cache = /var/cache/paludis/metadata
And to get the files in the repo, make the directory and create symbolink links for the required packages:
mkdir /var/paludis/repositories/cross-avr/{cross-avr,profiles} -p
cd /var/paludis/repositories/cross-avr/cross-avr
ln -s /usr/portage/dev-embedded/avr-libc
ln -s /usr/portage/sys-devel/binutils
ln -s /usr/portage/sys-devel/gcc
ln -s /usr/portage/sys-devel/gdb
The repo also needs to be named and as the category is not in the master tree (portage) it needs to be added to the categories file:
cd ../profiles
echo cross-avr > repo_name
echo cross-avr > categories
Finally we need to tell paludis to use the avr-gcc for the other cross-avr packages, by placing this in /etc/paludis/bashrc
#cross-build avr
if [[ "${CATEGORY}" == "cross-avr" ]]
then
if [[ "${PN}" != "gcc" && "${PN}" != "binutils" ]]
then
CBUILD=${CHOST}
CHOST=avr
CFLAGS="-Os"
fi
fi
Now we have the ("auto-syncing" :D) repo set up!
To make sure that paludis knows about the new packages we run:
paludis --regenerate-installable-cache cross-avr
Next up is the installation. Do a pretend to see what paludis will pull in:
paludis cross-avr/binutils cross-avr/gcc cross-avr/avr-libc cross-avr/gdb -ip
Here it is important to note all the use flags for gcc. My experience is that most of them will break avr-gcc and my recommendation is to turn them all off.
At last we are ready. Start the build and grab a mug of cocoa.
While you wait it may be interesting to know that avr-libc will place the libs in /usr/avr. And if you want to start playing with simavr you need to change AVR_ROOT, in its Makefile.common, to this path. But more on that another time ;)
When the packages are installed you may want to create a symlink in /usr/avr/lib to /usr/x86_64-pc-linux-gnu/avr/lib/ldscripts (substitute architechture as appropriate) because ld will have problems finding the linker scripts otherwise. (/usr/libexec/gcc/avr/ld: cannot open linker script file ldscripts/avr4.x: No such file or directory, Gentoo bug)
Now you can compile your avr projects with avr-gcc! Happy hacking!
Another project of mine that deserved it's own web page.
TV Series List is a poorly named application that keeps track of your TV show watching.
If you start to watch a TV show, it's generally quite easy to remember where you last finished. Unfortunately, TV shows are like the entries in the Eurovision Song Contest: you only realize that you're watching something good, after you've seen the competition. Therefore, it's easy to find yourself in a situation where you've got a huge number of TV shows that you've seen a few episodes of each. And suddenly, remembering where you last left the show becomes an issue.
Sure, you Could just use a text document, but those are easy to mess up by not making sure you're writing on the correct line, by simple arithmetic errors, and frankly, what you're doing is exactly what your computer is good at doing - remembering values, and increasing them every once in a while. And that's where this application comes into the picture.
Start the application. Add your shows. When you've watched an episode, click the episode button. When you've watched a season, click the season button. If you clicked the wrong button, right click, and the number will be decreased instead of increased.
Periodically, press export. Your shows will be saved on a remote server. Import if you change computer or something bad happens to your shows (if you screw up, if your computer dies, or if you just manage to trigger a nasty bug). There's currently not an official server software, nor a well defined synchronization protocol, but you can use http://shell.ryara.net/~tobbez/epmem as a server for now.
TV Series List can be used both as a stand-alone application, and as a panel applet for Gnome panel. If you want to use it as an applet, remember to install it into the same prefix as your bonobo installation (this generally mean that you need to run the configure script as ./configure --prefix=/usr)
TV Series List requires Python and the GTK bindings for Python. If you don't have Python 2.5, you also need to get an ElementTree implementation. If you want to use the panel applet, you also need gnome-python-desktop.
You can download the latest version, 0.93.1, as a source tarball that you install using the regular ./configure && make && make install or you can download it as an Ubuntu package.
If you run Windows, you can download an installer or a zip file - both containing everything you need to run the application. Thanks, tobbez!
You can also check out the development process at GitHub
Tomboy Blogposter is a Tomboy plugin to post notes to a blog from for instance Wordpress, Blogger or LiveJournal, or (hopefully) any other AtomPub enabled website.
Requirements
This plugin requires Tomboy 0.10 or later.
Download/Install in Ubuntu
In Ubuntu Jaunty or later, all you need to do to install is to install tomboy-blogposter from the official repositories.
If you're using an older version than that, or want to make sure you use the latest version, you should add Hanno Stock's PPA and then installing through the regular packaging tools.
Download/Install elsewhere
Download the binary or the source. There's also a git repository (git://github.com/ozamosi/tomboy-blogposter.git) you can pull from.
If you got the binary, you need to put the dll in your $HOME/.tomboy/addins directory, and then activate the plugin in the Tomboy preferences.
The source version uses autotools. To build it, move to the folder where you downloaded the code, and execute$ tar xzf tomboy-blogposter-0.4.4.tar.gzThis will install the plugin for your current user. If you only want to install the plugin globally instead (for all users), instead of executing
$ cd tomboy-blogposter-0.4.4
$ ./configure
$ make
$ make local-installmake local-install, become root and run make install.
Comments, help, suggestions, cursing, etc
Send an email or Jabber message to ozamosi@flukkost.nu (both email and Jabber).
Finding the URL
When you add an account, it will ask you for your AtomPub Service or Collection URL. Here's a short guide on how to find it:
On Wordpress, the URL you want to use is <blog_url>/wp-app.php/posts Note, though, that you need to visit your Wordpress admin panel, and under Settings -> Writing enable the Atom Publishing Protocol before this will work.
For Blogger, you can find the URL by viewing the source to your Blogger blog: it's the address in the <link> tag that has the rel attribute set to service.post. It follows the template http://www.blogger.com/feeds/<blog_id>/posts/default. My blog has id 4164605321218185513, which means my Collection document is http://www.blogger.com/feeds/4164605321218185513/posts/default.
On LiveJournal, the URL is http://www.livejournal.com/interface/atomapi/<username>/post
Anywhere else, you should view the source code, and look near the top for a line that looks like <link rel="service.post" type="application/atom+xml" title="<User-friendly label>" href="<collection_url>" />
Changelog
Version 0.4.4 (2009-04-20)
- Update error handling code in BlogposterWebRequest to not crash when there is no response
- Update GoogleClient to not free the Google login token before it's been saved, preventing freeze and failure
- Move build system to automake
Version 0.4.3 (2008-12-03)
- Change the plugin to make it work with modern versions of Tomboy
- Misc changes to make it easier to create Ubuntu packages (Hanno Stock)
Version 0.4.2 (2008-03-03)
- Fix bug when opening the preferences dialog when not all information is entered
- Fix password encoding issue
Version 0.4.1 (2007-09-19)
- Fix bug when saving passwords from the dialog that pops up when you post
- Fix bug when getting service documents from non-blogger services that use the old namespace
Version 0.4.0 (2007-09-19)
- Migrate from old Plugin to new AddIn framework to make it work with Tomboy >= 0.7.2
- Add an option to post notes as drafts
- Clean up the source a bit
- Use new official APP namespace when possible
- Fix a bug when editing blogs that caused tomboy to crash
- Fix a bug when the service document was password protected
Version 0.3.2
- Autocreate the configuration folder
Version 0.3.1
- Make the enter-password-at-post-time-thingy work at all
Version 0.3.0
- Rename from Tomboy2Wordpress to TomboyBlogposter
- Complete rewrite
- Change protocol from Metaweblog to APP
- Thus, drop XML-RPC library
- Support GoogleLogin and HTTP Basic login methods
- Allow user to add multiple blogs
- Change from GConf to plain XML for account storage
- Don't save passwords in plain text
- Make it possible not to save passwords at all
- Ignore certificates when using HTTPS
Version 0.2.0
- First _working_ release. 0.1.0 broke when you tried to use it according to my instructions. This hopefully doesn't :)
- Make api support less broken. It should be able to handle most more-or-less correct MetaWeblog implementations. Tested with Wordpress and Drupal.
- Add support for multiple blogs on the same account.
- Make it crash Tomboy slightly less frequently.
- Turn big and huge text into <h3> resp <h2>, which should be better from a semantic point of view.
Version 0.1.0
- First public release
- Basic functionality present
The solution is to put the export command in a file called ~/.xprofile
export PATH="/home/thomas/bin:${PATH}:/home/thomas/installs/bin"
(I keep all my user installed apps in ~/installs/bin ;))
Ifall vi nu kommer till ett samhälle där tanken inte längre är fri att tänka, då är det för att folket vill ha det så. Personligen har jag gett upp på att försöka förändra, folket vill uppenbarligen ha det samhälle de har.

Putin sade vid ett tal i Kreml den 14:e Februari att utbyggnaden och moderniseringen av flottan måste fortsätta, han var dock negativ till att skjuta till mer pengar till vissa projekt utan sade att det var viktigt med en stabilfinansiering.
Ett led i satsningen på flottan är den ubåt som sjösattes på onsdagen i Severodinsk. “Yuri Dolgoruky” är av Borei klass och skall bära de nya robotarna “Bulava-M”. I samma klass kommer minst två andra fartyg att byggas vid Sevmash varvet och dessa kommer att heta, “Alexander Nevsky” och “Vladimir Monomakh”.
Ubåten har följande specifikationer:
Längd: 170m
Bredd: 13m
Displacement: 11750-12250 i ytläge och 17000 ton i u-läge.
Hastighet: 29 knop
Besättning: 130 man
Beväpning: 3m14 Bulava-M SS-N-30

3m14 aka Bulava aka SS-N-30 har följande specifikationer:
Längd:12.1 m
Bredd: 2 m
Vikt: 36 ton
Stridsspetsar: 4-6 (10 har antytts)
Rakettyp: 3 steg, fast
Räckvidd: 8-9000 km
Källa: www.rian.ru, www.globalsecurity.org, http://www.missilethreat.com
Ryssland har i dagarna sagt att man skall fortsätta att modernisera och använda SS-18/RS-20 (SATAN), vilket kommer som lite av en överraskning då man håller på att ta fram en ersättare. Anledningen skulle kunna vara att man har haft svårigheter i utvecklingen vilket kommer att fördröja utplaceringen eller att man vill utöka de strategiska robotstyrkorna genom att behålla det äldre systemet parallelt.
Det nya systemet man håller på att ta fram kallas RS-24 och kommer att kunna ha upp till 10 RV, det sades att man bara skulle ha kvar Topol-M samt RS-24, något som nu ändrats i och med att SS-18 behålls.
För mer information om SATAN klicka här
Källa:
www.rian.ru, www.gazeta.ru, www.fas.org
Drivs med Planet!
Senast uppdaterad: 19 June 2013 kl 23:32












