niedziela, 24 października 2010

MacBook Pro 2010 + OpenMPI + o2 stick

One of the first thing after switching to MacOSX was to install all developer tools I use in my work -- having Vim already installed, I had to set up my localhost cluster with OpenMPI and HDF5. Well, standard compilation (after installing gcc4.6 with iso_c_bindings in Fortran) was not a problem. The problem was running it when connected to the Internet with my o2 stick. I searched a little Uncle G. for (openmpi + ppp0), found this thread: http://www.open-mpi.org/community/lists/users/2007/05/3306.php. OpenMPI simply freezes (or hangs) when connected to modem, I don't why, right now I don't have time to do more research on this topic. But I applied a solution: In openmpi-mca-params.conf (system-wide or user's) type:

oob_tcp_exclude="ppp0"

cross fingers and...

Welcome from Node 0
Welcome from Node 1
Welcome from Node 2
Welcome from Node 3

sobota, 31 lipca 2010

Drupal7. I'm impressed. I'm confused

I use Drupal. It's my tool for content managment on the web. I started with D5, extensively used D6, and testing upcoming D7 (as time of writing D7-alpha6). Over 50 modules included, CCK, ImageCache in core. Many user-interface improvement, installing modules and themes with the web interface. New default theme. Sqlite support. Menus reorganized. Admin interface reorganized.

In its current stage still feels incomplete. I'm not complaing, I'm really impressed of the work od Drupal Developers. But, personally, as a Drupal user, I miss such small things, that I will have to setup by self with help of external modules:

-- features of BetterFormats (the most)
-- some small ThemeAPI improvements, like overriding "submitted by" message within the template.php. This is especially useful when you want to create a theme containing only css file and template.php file -- yes, it is possible to create such theme, but you cannot override "submitted stuff" (maybe I will create or search for a module or sth)

There are of course, as of alpha stage, many minor things to improve. But as for now, new Drupal major release will be a huge step forward in cms world. Well, right now, after clean and standard installation of D7, the only thing I have to do is to install Views, Markdown and Colorbox modules. Do you feel the difference? (tip: in D6: Views, CCK, Imagefield, Imagecache, Markdown, Colorbox, Contact etc.)

And I have some small D8 list...

-- BetterFormats fully in core
-- NodeHierarchy2 instead of Book
-- Blog/Forum turned into content types integrated with Views
-- Yes, Views in core.

Edit:
At beta-1 stage, I'm really impressed -- it is a huge improvement in webdevel/admin :D

niedziela, 21 marca 2010

Reklama



No tak - to znalazłem pod artykułem http://wiadomosci.onet.pl/1601713,240,1,szatan_niestety_istnieje,kioskart.html

Ciekawe, nie?

sobota, 13 marca 2010

Logitech M505 @Gentoo

Well, I needed new mouse, so I bought Logitech M505 (wireless with unified adapter). In the user guide we read:

Side-to-side scrolling (...) This function doesn't work on Linux.

Well, actually, it works. What distribution they used for tests?

piątek, 5 marca 2010

o2 Prepaid ZTE MF100 @Gentoo

Well, I cannot live without Internet... So the first thing I did in Paderborn was to search for any Internet provider -- thus I found o2 prepaid offer pretty enough to try. It tooks me last 3 days...

Let's begin.
Forget about windows stuff -- the stick will work (sometimes), the software sucks, it differs from the included handbook, and you will get your hair off trying to figure out how it really works.

Let's try Ubuntu. First of all, the stick is recognized as a cd-rom (surprise!). After searching a lot, you can find usb_modeswitch utilty. Don't use it. You don't have to. Just eject (not unmount) the device. After a few seconds, you will see modem connection configuration screen. You run it by 4-click method, put the pin code and pray -- yes, I manage it to work only once. Surprised?

Now the funny thing. I don't want to use Ubuntu. And Windows XP on my VirtualBox at all. So I needed to find a way to connect with this o2 stick on my Gentoo box.

I don't want to describe step by step configuration -- you will find a lot of similar solutions on the web. Let me describe only some specific things:

1) using wvdial I have:

[Dialer o2]
Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
Modem Type = Analog Modem
Phone = *99#
ISDN = 0
Username = ;
Init1 = ATZ
Password = ;
Modem = /dev/ttyUSB2
Baud = 9600
Stupid Mode = 1

[Dialer pin]
Init3 = At+CPIN=[yourpin]
Modem = /dev/ttyUSB2

2) steps to connect to the Internet:
- put your stick in
- wait
- try to eject proper device: /dev/sr0 or so
- wait, in a few seconds the modem will appear
- now run wvdial pin to unlock the modem
- wait for green light from the modem
- try wvdial o2

If success, the modem will connect, ppp0 will get dns servers etc. etc.

You don't need to even edit /etc/conf.d/net etc. Just use wvdial.

For those who want to digg deeper: the device is ZTE MF100, with lsusb it is recognized as 19d2:2000, and after eject: 19d2:0031.

Now I need to create a script to do all the stuff automagically:)

poniedziałek, 22 lutego 2010

Warszawska Karta Miejska

Gdyby kto pytał i szukał: Aplet do projektowania spersonalizowanej warszawskiej karty miejskiej działa tylko pod > IE7 z najnowszym flashem. Gratulujemy wykonania. Dla zatwardziałych Linuksiarzy, potrzeba maszyny wirtualnej z Windowsem w celu wykonania takiej karty i odstawienia w kąt wszelkich przeglądarek (Firefox, Opera, Chrome). Pod Firefoxem na Windowsie też nie działa. Tyle powiem.

piątek, 19 lutego 2010

Mandelbrot. My own. My first


This one was generated by 8 processor working in a MPI Task Farm model. The code, Mechanic is a part of my PhD. For testing purpose I created small module which computes Mandelbrot fractal. The code will be committed soon, check git.astri.umk.pl for updates.

czwartek, 4 lutego 2010

The Man or the Nothing Box

What was the first? The man or the nothing box?

If the God is a woman, it means, that very important functionality of man's mind is not documented. If the God is man, it means, that he didn't have to document it at all!

wtorek, 19 stycznia 2010

Firefox background position SOLVED

Allright, here is a problem:
You want to have background image specifically positioned on your page. CSS works in IE, Safari, Chrome etc. But not in Firefox. An example problem was on mechanics.astri.umk.pl, which I develop. I want to have background image (with well known Lorem Ipsum) positioned just before the logotype. The logotype has almost 400px padding-top.

The solution is here:

.front #branding{
padding: 300px 0 50px 0;
background: #000;
background-image: url(images/mechanics2010-front.png);
background-repeat: no-repeat;
background-position: left 100px; //important: pixels at the end (I think)
}

Voila! Now, the site looks similar in almost every webrowser.

poniedziałek, 18 stycznia 2010

Wchodzi mechanik do manekina

Wchodzi mechanik do manekina:
Dzięsiątka wytrawna z sosem pomidorowym proszę!

(z pamiętnika Czarka Migaszewskiego)

sobota, 14 listopada 2009

Frappe Killer

Ha! Now it's time for something useful:) The Frappe Killer drink.

Ingredients:
  • Cold Milk
  • IceCoffee (i.e. Nescape Frappe or so)
  • Malibu

Fill the glass or shaker whatever proportions you like, mix them and that's it!

Now sit down and drink. If You can stand up then, take another Frappe Killer.

Enjoy!

niedziela, 8 listopada 2009

Shift-Enter never ever

Allright, there is one special keyboard shortcut in word processors, such as OOWriter or Word, which makes me angrrry: SHIFT-ENTER. It creates a soft-linebreak, without paragraph break (hard-linebreak), which in most cases is a total distaster when preparing a document to print. When you turn on view of non-printing chars, you will see soft-linebreak as a down-left-arrow, similar to the arrow of an ENTER key. Hard-linebreak shows up as a reversed P.

The problem is, when user uses SHIFT-ENTER to create line breaks, and not an ENTER. Then you'll have many many soft-linebreaks to remove. Doing it by hand is a simple, but time wasting task. Fortunately we have a Find&Replace tool in OOwriter which will help us.

What we have to do?
1) Open Find&Replace tool
2) Show more options
3) Use regular expressions
4) In "Find" put '\n' (without quotes)
5) In "Replace to" put '\n' (without quotes)
6) Replace all. And THAT'S IT! All SHIFT-ENTER breaks will turn to hard linebreaks.

Uff. Then I have more time for coffee breaks:)

wtorek, 13 października 2009

Restoring /home

Ok, here is what I've done to restore my /home partition.

What was the problem?
All of partitions where successfully mounted except one -- the /home. It looked as a total disaster, because I didn't have a recent backup. Remember! Always do a backup of your important data.

I use reiser3 type partition, and we have excellent tools such a resierfsprogs to manage such partitions. Because first error came from bad superblock, I did:
reiserfsck --restore-sb /dev/hda8

then

reiserfsck --check /dev/hda8

and the partition looked ok. Tried to mount it. Couldn't.
Ok, few minutes of googling, tried upgrading reiserfsprogs to 3.21 (gentoo machine) and did:
reiserfsck --restore-tree

Went for a tea. Another tea, meet some friends, came back home, and voila! Tried to mount /home. Mounted successfull.

Then, plugged in external drive, and did a backup with rsync.

This should save me some time next time...

środa, 23 września 2009

Drupal 7 and Gentoo

I was wondering about huge changes in Drupal core, so I tried to install D7 development 9 (September 15th). However, the documentation of D7 doesn't currently describe few issues you may encounter when using Gentoo.

Remember: You have to enable these USE flags for dev-lang/php: pdo, json, filter if you want to properly set up D7 and test its new features:)

Edit:
If You want install D7 with sqlite database support You need to enable "sqlite" flag as well.

Wow, D7 works with sqlite!

poniedziałek, 24 sierpnia 2009




It looks great. It runs fast. Faster than Firefox and Opera. Comparable to Arora. The development version of Google Chrome for Linux, which I installed today and work in it all day without a crash or other browsing problems.

I spent most of my day work on the Internet. Working with websites, searching for information etc, thus I need my main web browser to be fast, efficient, powerful and good-looking. I like Opera for its design, but its heavy. I like FF because of capability of extending its functionality by add-ons, and for great add-ons like Web Developer and AdBlock/NoScript. But it's heavy and slows down and look ugly in default configuration (I reconfigured the skin etc., but it is not the way). I track the development of Arora, which runs in a second, looks simple, but still, has some lacks and currently I cannot work on it as a webdeveloper.

When I first use GoogleChrome on my VirtualBox with WinXP I was amazed. Fast and well-looking, I discovered then themes. Today I installed the developer snapshot and worked all day. It has built-in webdeveloper tools, maybe not so great like FF add-on mentioned above, but it is usefull. Currently there is no stable flash support, but it is a matter of coding time;) . Minimalistic, great design, fast engine, runs in a second too:) For a web developer it is a good alternative for FF/Opera.

It was just a good day without spending time on arguing with FF or Opera. Just try it:)

sobota, 15 sierpnia 2009

Ubuntu 9.04, I'm impressed

Ok, my friends are scared when I tell them about Linux. Probably because they've seen my Gentoo box with Enlightenment17, where almost nothing works like they expect.

Ok, I've set up my Gentoo box to suit up only my needs. Thus, I don't have automatic mount, music/video players which looks similar to popular apps, even my Desktop look great, but this is strange... So, where do You have StartMenu?

Ok, I've observed Ubuntu for some time, I tried install it on my laptop almost 3 years ago, but it failed on X configuration. I've tried then several Linux distributions, and only on Gentoo I've managed everything to work OK. And Gentoo suits my needs, administration, package managment and philosphy. I'm not tired about compilations of software. This is my choice. And I'm happy with my Linux box, even I have to mount usb sticks manually, even I don't have F-spot or Digikam for managing my pictures (and I do a lot of pictures), even I use Xmms2 for managing my music and Smplayer for videos. Even, I use everyday command line. This is the most production suite I've ever found, and I will not change it to something else...

Just, I'm only waiting for stable and full operational E17 and one photo managment app without KDE or Gnome dependencies. I believe, it's just a matter of coding time.

Thus, I'm impressed of first look on Ubuntu 9.04. I downloaded live cd and unpack it. Because my CD doesn't work at all, I tried to manual add to my grub.conf entries with Ubuntu-Live, reboot the machine and try it. Just try it. I didn't want any effort to put it working. I gave it a chance. And I'm impressed. Again.

Everything just works. Out-of-the-box. Do you know what it means? It means, that any person without any knowledge about computers, and Linux, will find Ubuntu user-friendly. Just imagine:

  • Graphical interface works, not to mention, that Compiz effects work too
  • Automounting usb sticks works, not to mention, Ubuntu will ask what I want to do, i.e. if I put my photocard it will ask if I want to import photos to F-spot
  • Detecting mp3-players. Works too. However, mp3 is not supported, but two clicks and I can listen to my favourite music in RhythymBox, even Jamendo works!
  • Alright, now the crash test - the network. And I'm impressed again. Ethernet connection works, Ubuntu will notify if the cable has been plugged or not. Ok, that was easy. Time for wireless. I have an IPW2200 card with light-button. I push the button. Orange led lights up. Ubuntu notifies me about working card. I have only to put my password to the network. Have I written I'm impressed?

Remembering all stuff I had to do with Fedora/Debian and finally Gentoo 2 years ago, and my happinnes of making orange led working I can say, and I'm sure I'm right, that Ubuntu 9.04 is one of the easiest operating systems on that planet. Installing it on your hard drive will be easier than installing Windows Vista and you'll have after the installation, desktop ready to work. OpenOffice suite, Firefox, music and video player, email app, some games, photo managment app, network connection apps, cd/dvd recorder app and much more. For Linux geeks -- suspending and CPU-scaling works out-of-the-box. What do you want more?

I don't want to change my Gentoo with E17 to Ubuntu, but for you, if you don't have time for setting up operating system, and you want it to just works, I recommend you Ubuntu 9.04 or Fedora 11. Next time, I'll try Fedora 11 and Kubuntu 9.04.

Edit:
Kubuntu seems to be not-finished, at least for events notifying. KDE Plasma effects work very good, but first contact was not so easy as with Ubuntu. It is not intuitive where to click to find my usbstick! And Amarok didn't search for propertiary codecs...

poniedziałek, 1 czerwca 2009

Lorem Ipsum

And another blog about completely nothing has just landed.