Nervousness-induced Stupidity

Last Friday (6/27) I had an interview for my entrance exam for a scholarship program over Skype. And I kind of failed it, quite miserably I have to admit. The pace of the interview was so nervous-inducingly fast.
  • I forgot my registration number for the test,
  • I forgot what RISC stands for, it's reduced instruction-set computer anyway,
  • I couldn't even said that RISC uses fewer clock cycle(s) per instruction compared to "de facto" standard of x86 processor architecture family which belongs to CISC architecture: complex instruction-set computer,
  • I couldn't clearly explain my internship experience (which could be strong point in the interview)--even I mention the organization's name wrong in English,
  • I showed how little my experience with FPGA by saying the furthest I had gone with it is merely dumb stopwatch, 
  • I showed how lame my experience in programming in assembler language,
  • I spoke gibberish thing like: I love being in a team, which has no real implication IRL,
  • I brought up non-technical issues on something in which we hope such issue won't happen related to its technical implementation,
  • I was pausing mid-sentence... over and over again,
  • I was sure my voice wasn't audibly illegible,
  • ... and all other silly mistakes I did unawarely
The only thing I was confident about is when I said "I'd definitely do".
...I was just panicking like stupid, definitely.

iptables: transition intrapositioned to extrapositioned negation

Just today when I was writing iptables rule for my lab's gateway which (sadly) still have to rely heavily on IPv4 NAT (network address translation), it spew something cute when I put such rule:

# iptables -t nat -A POSTROUTING -s 192.168.0.0/25 -d ! 192.168.0.0/24 -o br1 -j MASQUERADE
The rule tells iptables to masquarade packets originating from 192.168.0.0/25 which destination isn't within 192.168.0.0/24 (my lab has two gateways for each /25 subnet, fyi).

It said:
Using intrapositioned negation (`--option ! this`) is deprecated in favor of extrapositioned (`! --option this`).

The rule still worked just fine. But as a good guy, let's adhere to the current standard (which is assumed to be 'more correct' :D )
# iptables -t nat -A POSTROUTING -s 192.168.0.0/25 ! -d 192.168.0.0/24 -o br1 -j MASQUERADE

vsftp: anonymous can do 'em all

I need quick vsftpd config to allow anonymous user to anything on my ftp server, I wouldn't need security/auth this time.

anon_root=/home/liyan/ristie
anon_mkdir_write_enable=YES
anon_other_write_enable=YES
anon_upload_enable=YES
anon_world_readable_only=YES
anonymous_enable=YES
listen=YES
listen_port=21
local_enable=NO

write_enable=YES

Spring the daemon up and you're good to go.

Qt 4.8 is better than Qt 5.x

I am currently helping a friend doing project on Qt and OpenCV. There're some problem I encounter regarding library dependencies:

I can't build newer OpenCV (2.4.9) against  libavutil.so.52 (ffmpeg-2.1.4), therefore I resorted to Slackbuild's prebuilt OpenCV 2.4.5

I can't compile sanely valid Qt program OpenCV 2.4.5 on Qt 5.2. Which in turn becase OpenCV 2.4.5 is build around Qt 4 (4.8 most likely). I hate this dependency hell.

So here I am, reverting back to Qt 4.8. Good thing Slackware64-current's is Qt 4.8.2.

libsecret: udev getting pwn'd

My filemanager (pcmanfm) just stopped recognizing newly plugged-in USB flashdrives after I upgraded from Slackware64-14.0 to Slackware64-14.1 (it's actually Salix64 anyway). Running /usr/libexec/gvfs-udisks2-volume-monitor told me that libsecret is missing.

# installpkg libsecret-0.15-x86_64-1.txz
simply solved the problem.

Yet, I found the library's name (libsecret) is quite weird, up to par with libconfuse.

/usr/bin/nc: cpi

This band (netcat) is wickedly sick, releasing their album (Cycles per Instruction) as Linux kernel module!

The approach is pretty simple:
#include "../netcat.h" 
#define NETCAT_CPI_TRK1_LEN 624344 
struct netcat_track netcat_cpi_trk1 = { 
    .name = "Interrupt 0x7f", 
    .len = NETCAT_CPI_TRK1_LEN, 
    .data = { 
         #include "trk1data.h" 
    } 
};

It (the C header file) is actually a wavefile , you can redirect it to media player just as normal I/O operation. Just like silly "Hello world!" kprintf from kernel demo program you used to write on Intro to *NIX Operating System lecture.

Anyway, I am quite afraid there will be path issue between this netcat and the legitimate netcat.


Ganglia: gmond "Error creating multicast server"

Computers without IPv4 default gateway will likely force gmond (Ganglia monitor daemon) to spew something like this upon start.
Error creating multicast server mcast_join=239.2.11.71 port=8649 mcast_if=NULL family='inet4'. 
Exiting.

bubby (here) suggested to add static route to fix this problem, worked like a charm.
# route add -host 239.2.11.71 dev eth0

The guys at UCSF suggested the similar approach, though to quite-unrelated problem on multihomed computers here and here.

Building ganglia 3.7.0: ck

I was building ganglia 3.7.0 when suddenly this particular error message sprung out:

checking for CK... no
configure: error: Package requirements (ck) were not met:

No package 'ck' found

Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.

Alternatively, you may set the environment variables CK_CFLAGS
and CK_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.


Google showed up unrelated hits if you put ck library, duh!

It's actually ConcurrecyKit: concurrency primitives, safe memory reclamation mechanisms and non-blocking data structures designed to aid in the research, design and implementation of high performance concurrent systems.

--I mistook it with ConsoleKit and actually did this shameless thing:
# ln -s /usr/lib64/pkgconfig/ck-connector.pc /usr/lib64/pkgconfig/ck.pc

Some software engineers, especially related to high-performance parallel-concurrent system, really lack the taste of name-picking for their library.

.profile

It's definitely way too late. There's a server in my lab in which I've got my account there for over 2 years already, got .bashrc from my laptop there as long as the account.

It wasn't until today that I finally run:
ln -s .bashrc .profile
so that .bashrc is loaded every SSH login. Poor me.

USB Flash Boot Frenzy: Puppy Linux (2)

I always carry a flash drive consisting of several live Linux distros, of of them is Puppy Linux as I wrote previously here. But once the flash drive get congested with files, Puppy's kernel (and initrd) take too long to find it's squashfs.

The solution is simply to pass extra parameters to the kernel:
kernel /puppy/vmlinuz
append initrd=/puppy/initrd.gz pmedia=usbhd pupsfs=sdb1:/puppy/puppy_slacko_5.6.0.sfs

Make sure the path for squashfs image is correct otherwise you'll likely to get kernel panic.

libConfuse ?

When I was about to build ganglia to monitor my small Beowulf cluster, a single dependency tickled my mind:

libConfuse

It's a nice parser, yet why with this name?
libConfuse was called libcfg before, but its name was changed to not confuse itself with other similar libraries.
Then why not, "libnotconfuse" or "libdontconfuse"? :D
 __________
edit: Then it started to confuse me a bit:
/usr/lib64/gcc/x86_64-slackware-linux/4.7.1/../../../../x86_64-slackware-linux/bin/ld: /usr/local/lib/libconfuse.a(confuse.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC /usr/local/lib/libconfuse.a: could not read symbols: Bad value

  D'oh!

narcissus@angstrom-distribution

narcissus took my breath away when I opened the webpage for the first time. I was literally crying knowing the first device listed is XScale PXA27*-based A780.

PXA is sure none to compare against today's SoCs, but somehow they showed me better constraint-aware design and lean userland implementation.

Meanwhile I've got to play with those cubieboard2 and Rapsberry Pi in my desk. :D

Parallel Monte Carlo on Beowulf Cluster

My project on parallel computing went quite well.

I implemented 3-dimension embarassingly pleasingly parallel Monte Carlo integration on Beowulf cluster consisting of mainly 6 units i3-540/550 and 10 units 10 E7500 for some extra experiments.


The project code is montice.
The paper (Indonesian): here.


I used Darren Wilkinson's blog which is great reference material with some basic benchmark (here), in which his result showed poor figures due to most likely memory bottleneck on his i7-940XM (which is quite insane CPU on a laptop).

The speedup on 6 units i3 is here:

As the figure shows, single/core dual core performs just ideal and multithreading (3 or 4 cores for each box) only shows 70% performance improvement over the single/dual core operation.

Overheat: daily routine

I forgot to connect CPU fan on my laptop and kept doing my daily routines: browsing, chatting, watching anime, downloading stuff, and remote-controlling an instance of kvm on my lab server. I didn't notice it was overheating up until I felt a little bit audio-video delay on the anime.



Yeah, Crestline-Merom is definitely versatile.

Qt4.x -> Qt5.x: Painful transition

I've been a qt-fanboy since quite some time. When Qt5 is released, I was a happy guy: downloading its evaluation release, trying QML and those swish-swingy widgets for the new UI system, and such.

But lately, it's been more hassle than fun. There are some major programs I use frequently which drove me insane regarding Qt4 to Qt5 transition:
  1. mathgl. Though being just ordinary OpenGL based plotting library, its unclear reason to depend on certain version's (Qt4) of QWidget makes it unusable with Qt5 although no major difference on both version which could render mathgl unable to work.
  2. VLC. I love this media player because of its just-work design. Again, because of dependecy issue on Qt4 I can't compile this against Qt5. Luckily last September they released this version which work with Qt5, yay!!
  3. qbittorrent. Some people has worked on it, though the patches weren't merged to upstream. Wish it'll merged by version 3.1.0.
  4. cmake. Still no FindQt5 module, enough said.
Luckily, things for engineering/scientic computing (mostly plotting graphs) which I need most as university student like qwt, qwtplot3d, qwtpolar isn't so much version dependent, so I could still sleep well.

C/C++



Enough said.

Paper Balancing

If balancing things on cat is already too mainstream, I've got some stupid doing here in my side: balancing paper. It's some Qt development worksheet I was working on.

 
--sorry for the blurry image

   
side perspective

Onani Master Kurosawa

Onani Master Kurosawa. Just great!



The manga tells the many sides of adolescence: bullying, friendship, (first) love, and socio-sexual gratification. Kurosawa Kakeru managed to change his anti-social facade to warm-loving personality. Blah, I'm just speechless.

 Definetely, better love story than Twilight!

my github account

Just got my github account around a week ago (for hosting my embarrassingly parallel computing codes).
jendralhxr@github

 I still don't have Facebook account, yay! I'm free!

Laptop default display (frame buffer) output

Several days ago, my laptop did something awful to me, it defaulted to use VGA1 (display with D-SUB adapter) rather than LVDS1 (laptop's screen), even before X! (runlevel 3). Apparently something is wrong about frame buffer config (or ACPI).

Adding:
video=LVDS1:e acpi=force
to kernel arguments parameters (quite) solved the problem, the mis-configured display happened much less frequently :D