Monday, December 18, 2006

3:30 doorbell

It was a pretty good night today. I went sleeping and fell asleep about 2 AM (nothing unusual for me). Suddenly, a doorbell rang. Once again. Huh, wtf? I got up and go near the window to see, what happens and to get known what's the clock. It was 3:30 AM and my neighbour stand in front of the house.

"What do you need", I asked. "Could you please wake up your father. Our furnace is out of order and I want it to work", was the answer. Hm, wake up my father? Ok, let's try. Sure, he didn't want to get up, so I must deal with that. I arrange them a meeting in the afternoon and kick him away.

He was going to work (a bus driver) and wanted my father to repair it afternoon. Do these people think, that everybody is woken at the time, they getting up? Why didn't he wait till afternoon (he came at 1 PM again)?

Thursday, December 14, 2006

Broken usb ports on laptop

My father bought an USB extension cord. Good, but the metal is too close to the plastic part in the connector. Both me and him tried to push it into the USB cage, but with no effect, but side effect – we pushed 2 of 4 metal connectors (inside the cage) in 2 of 4 cages, so that no device worked in them from that moment.

We decided to disassemble the notebook, unscrewed about 20 screws and after an hour we were in (this piece is interestingly assembled). Fortunately it was correctable by pushing the connectors up inside the cages and pressing them from the back (inside part of the chasis) to their default position.

NEVER try to push anything into the USB cage not even with minimal force.

Tuesday, December 05, 2006

Exams are coming

Who is looking forward to them?

Me :D!

Playing with AVR

I've bought Attiny2313 chips (8-bit RISC) and created simple programmer connected to my ntb's parallel port. It's easy to use and easy to program – I use avrdude for programming.

After some playing with blinking LED on the one of the outputs, I've decided to construct something bigger. I had an old LED display from old clock, so I started to write digital clock :). To complete my toughts I also needed 4 NPN transistors, some 10k and 220Ω resistors and crystal with a pair of condensators.

The result is simple, 2 timers, one overflows each 500ms with 9.216 Mhz crystal – for colon blinking and time computing, the latter display numbers on the display (each time, one anode output is on and bound cathodes are 0 or 1 depending on nums arrays in the code.

Let me note, that the display has weird wiring, both right and left couples are bounded each together, so you will need to recompute nums arrays, if you want to use my code :).

Phantom driver

I've finally done phantom driver, at least the first release. It took me some time to go through the Kabi's code and libraries, but It's done and ready to go.

Today I put a doxygen comments to the library header file to describe interface. The only remaining thing now is to cope with overheating and checking big force, which was done in kernelspace in previous version. It should be augmentation only by few lines of code to avoid problems and the driver will be safer.

Wednesday, October 18, 2006

NFS issue

After some delay I'm back again. I've compiled and installed a new (2.6.19-rc2) kernel. After reboot it works correctly. Almost. One exception occured, nfs remote mounted filesystem with home dirs is still mounting read only even if it is tell to mount it read-write.

I tried to find out the reason and with some help from nfs folks I investigated, that homes and user directories are mounted from same disk partition with one substantial difference: there is a read-only protection of exported /usr and true rw access for /home dirs.

The new code sets first mount options even to the second, third etc. mountpoint if they are on the same disk part on the server. The caveat is, that this is visible only in /proc/mounts, not in /etc/mtab (what mount outputs).

This disk partition is ugly for this purpose, because subtree checking has to be enabled due to security (otherwise anybody has access to mentioned /usr part), but it's not so good option for so much changing files, which surely are in home directories.

Wednesday, October 11, 2006

My family's health

I've just returned from floorball and my ankle is slightly twisted. The pain has gone, however it will hurt for a month or so. Ouch.

Despite it isn't the worst thing. My nephew caught a cold and has to be at home instead of learning in the school. He is interested in the school-life so much – his first year and he is ill, bad luck.

Nevertheless, there is even worse thing to write. My second nephew is with his mother, my sister, in the hospital. He fell down from his bike, stops breathe and nobody was able to wake him up for a short while. This had happened some times before this accident, but he had woken himself after being in syncope for a while. This simply happens to some children, they are so angry because of the fall, so they don't breathe and faint, then the brain starts to control the heart and lungs properly again. My sister had this syndrome when she was a child. Genes.

His parents decided to do something and he is connected to some devices (such as EKG, EEG et al.) and has to be there till Thursday.

Sunday, October 08, 2006

Music player

Today (according to the last post) I've decided to use something other than bmpx. For some hours I've used xmms, but it sucks. No support of gnome. I remembered, that I'd read about some server/daemon music player on Jan Kasprzak's blog long long time ago. But what was the player's name? I had no clue.

I tried to go through his blog again with nothing in return. Suddenly, the idea came. Use google, dude! Yup, it gave me a good result of that what I wanted (using "site:" notation). Music Player Daemon. I grabbed a last version and made rpm packages with some .spec parts from livna orginal srpms.

Now I use it and I'm totally happy. It sits on tcp port 6600 and the protocol is text-based. Everybody might write his own client – there are many clients to choose from. I personally use mpc in text mode (and for key-bindings) and gmpc in gnome graphics. I'm going to write dbus client, but I have to wait for listen interface, that would be implemented shortly.

Friday, October 06, 2006

Bmpx is a piece of shit?

I have been using xmms, then bmp, then bmpx. xmms was the best, but is intended for old libraries (I prefer gtk+) and is not-mondern-designed (old libraries, plugins, no dbus et al). bmp was not so bad, but it's discontinued. I decided to try something new some time ago, so I chose bmp-successor: bmpx. It uses gtk2, dbus and hal libs, perfect.

Version 0.2x is poor comparing by functionality, but works. I hoped they will improve this in next releases and will continue in winamp-styled player – very bad hope. What the hell did they do in the 0.3x series? Non-stability, slowness, absolutely no options, stupid library, no shuffle, no repeat, no more dbus control (such in 0.2x versions), no winamp-style, there is just simple window with 6 tabs (library, radios, play queue); blaaah. What is the player like this for? They change all including appearance and functionality in the player per release – they may do that yet another time and they'll loose everybody, who use it for the time being.

Thursday, October 05, 2006

Filesystem crash

On one of my boxes ext3 filesystem went down during updating system by yum. This appeared in log:

EXT3-fs error (device hda2): ext3_free_blocks_sb: \
bit already cleared for block 747938
Aborting journal on device hda2.
ext3_abort called.

with further info including – it was remounted to read-only mode and was slightly inconsistent. I reported this (a little bit freaky) to lkml and rebooted to correct the filesystem.

I tried to boot to single user mode, but fedora was (properly) faster and tried to check the root before I was able to log in. In spite of that it cannot correct it, so it gave me a shell to do-it-on-your-own. Ok, I ran fsck on root partition, it found some bad links, orphaned entries and block mismatches. Fsck was able to correct all those errors, then I checked S.M.A.R.T. output (with nothing suspicious) and rebooted.

Second phase of recovery began now. Rpm database and updated files needed to be corrected. Only 10 packages (including glibc libraries) were updated and the last one (the most affected) was gnome-vfs2. I removed all updated packages (there were both updated version and old versions) and verified if installed packages were allright, some was, some wasn't. Doesn't matter, I updated it again by yum, this time it went through successfully. Next nice experience :) – it works for now (not first, not last crash, since I use a -mm tree).

P.S. Jiri Kosina wrote on lkml list that he expereinced similar problems, so we will see if this is bug or not.

Monday, October 02, 2006

Linux is like a wigwam. No windows(TM), no gates, apache inside.

I had to repost this ;).

Monday, September 25, 2006

Installing Linux from scratch (cont.)

Today, I tried it, and it doesn't work. It works everywhere, but the hardware, where it should be connected.

I had several ideas what to do. Either I hunt out some PCI graphic card and keyboard with DIN connector or null-modem cable to connect it to other PC by serial (rs232) port. First I did the latter. I have a friend, who lent me a null-modem cable without data flow control pins connected (just RXD, TXD, ground and other two I can't remember now). Cable was long only 25 cm (approx. 1 ft), so he lent me a cord extension set with male-female connectors. Nice. The first thing I want to know if wiring is OK. One windows station and one linux. I ran hyperterminal on Windows and send data from linux. Nothing came, weird. I investigated, that the cord extension set wires bad pins.

I needed to know if at least the null-modem cable is allright. I made loopback COM1-COM2, ran 2 hyperterminals and after 3 tries I understood, that I hadn't switched off flow control. Doesn't matter. It worked from that timestamp.

The problem was with router. Nothing appeared on the hyperterminal console, just x sign just after I switched the power on. Strange, maybe grub can't initialize itself – I am going to enable serial support in grub tomorrow to see what happens. I'll have to disassemble the router to get the disk out again (I had to do this to provide console= kernel parameters), write configuration file and assemble the router back.

For the time being I still have no PCI graphic card, so the former thought I had in the beginning won't be perhaps realized, although it may be desirable.

Freecom DVB-T under linux

My friend bought a Freecom DVB-T reciever and apply me to make it working under Linux operating system.

I asked him to put the usb device into the slot to see what Vendor and Product ID it is. I found out by lsusb command it has 14aa:0225 IDs. I started to investigate which driver could take control of that device, unfortunately there was no such driver in vanilla kernel.

Ok, he has kubuntu 6.06 installed, so I compiled a little bit altered vanilla kernel with make-kpkg and he installed it and rebooted. Unfortunately changes from v4l tree, that I used didn't helped, there were some unresolved symbols, so I decided to compile clean vanilla and install modules from v4l snapshot. Yup, this worked (I was able to load those modules). The driver requested firmware and the device switched to warm state with product ID 0226.

The rest was on him, he tried to scan with absolutely nothing in return. He tried hard. No way. He forgot to change the location of search. He changed it and he stopped to communicate with me, because he is watching TV all the day 8-). Nice co-work.

Furthermore, remote controller works better than in Windows and he is very glad.

Installing Linux from scratch

Heh, I have a hard-disk from my router here with idea to install there some later system (Mandrake 8 was there with absolutely no support nowadays). I put the disk in my local linux (Fedora Core rawhide – devel) installation, wiped and created partitions with fdisk, made filesystems and the work might start.

I was lazy to write boot image from CD/DVD to a disk partition as usual and reboot ;), so I mounted its root partition, made lib and bin dirs, copy bash, all ldd bash libraries plus some other stuff such as ls, mkdir, rpm (with libraries) and so on. I had iso of the distribution on my laptop, I exported it by nfs to here. Here I loop-mounted it to created mnt/fc dir and chrooted into this new root with shell and mounted iso.

I had a small system with almost nothing, I thought, I need to expand it, so I inited rpm database – rpm --initdb and started to install yum with all what it needs as dependecies from mounted iso. About 30 packages were needed to be installed (very long command line). Now I set a new yum repository pointing to a mounted iso up and run yum install whatever-I-needed. The final step was to setup daemons and finally grub. One well-aimed grub-install and the system was ready to boot, I rebooted.

Fine, just some misspells in /etc/fstab, otherwise OK. I tried all servers it would serve (httpd, dhcpd, named, sshd, proftpd) and it worked, also network was okay, so I am looking forward to try it back in the server tomorrow – there is no monitor and keyboard. I hope it'll work (I'm a little bit naive, I know).

Sunday, September 24, 2006

Playing with Vista RC1

Vista RC1 is out for some time and the first computer (with directx 9 graphic card) with Vista preinstalled came to me today. Cool. First impression is the system is cool, at least skin seems to be very impressive. Fine. I started to work with that, mainly system configuration.

I don't know why did they change almost everything including configuration and control panel, strange – I was unable to find network configuration for a long time for example. Nevermind, we have to get used, but why the hell does it ask when changing some system settings if I really know what am I doing (continue-cancel question)? Aaargh. It can be switched off in user profiles, but what is that for (i.e. what kind of security enhancement? every user will click on continue, doesn't he)?

After configuration of network I can finally test Internet Explorer. That nice thing with tabbed browsing hangs in 5-10 minutes intervals. When you click on something in domain (mainly the menu on the left), it does nothing – Loading...; Done, no change, as if you never clicked. I had to copy and paste that address into address bar and click on go-to. IE7 needs much work and is still not eligible to be a superb web-browser like Firefox or Opera are, blaah. Furthermore IE wasn't able to open, I really don't understand why. When I tested it on laptop the domain worked.

If Microsoft is prepared to release final version of this piece of *), I have to utter the system is not ready until SP1 is released. System behaves strange in some situations, we can call it Microsoft Hell for the time being.

*) whatever you want

Monday, September 18, 2006

School begins

School started to exist for me today. I have 68 credits in enrolled subjects and need to reduce them to about 35.

I'm so tired after the first school day, it was exhausting. I hope it'll be better in next days to choose right subset from courses.

Saturday, September 16, 2006

Suffering with WXP

Okay, the first post and I'm going to object. Windows is the Evil(TM). Period. Grrr.

The story started by notebook coming to me to install HP drivers for a brand new bought printer. Ok, I inserted shipped CD and started with installation process. In the middle it stalled and nothing was going to happen. Reboot. Hard. Again, the very same issue. Hm, windows reinstall came on my mind.

So I inserted WXP home edition CD and started reinstall process. Installation has been done and the new system boots, nice. Let's use hangs about a minute after logon (let me clarify, what do I mean by hangs in this case: mouse is moving, _some_ apps may be executed, no answer to ctrl-alt-del, ctrl-alt-esc keys, no response to clicks of mouse on start menu, i. e. explorer.exe hangs plus some other parts of system).

Fine, I agreed, no SP2+connection to Internet, it's error-prone, nevermind. I'll reinstall it again with no connection to the Net and installing SP2 right after reinstallation. No way, it didn't help!

It may be a hardware error, appeared on my mind. I downloaded and burned memtest86+ and tried it out. No error for a couple of hours, weird. Then, I'd test harddisk. I used for this smartctl from Fedora 5 rescue CD. I ran short S.M.A.R.T. with no negative results. I tried also a long one, no results too (and also no records in log).

It almost excluded HW failure, but I found out, that it recovers in 30 minutes or so and the system is usable again for a while. I let it update by Microsoft updates and it succeeded. The situation after this big update is a little bit better, but it still hangs, however for much more shorter times. Ok, I installed rest of software back, also the HP driver and returned the notebook back. I want to Kill Bill.