This is me, Wu!
June 2013
Sun Mon Tue Wed Thu Fri Sat
            1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30            
About
This site is an effort to share some of the base knowledge I have gathered through all this years working with Linux, FreeBSD, OpenBSD, Python or Zope, among others. So, take a look around and I hope you will find the contents useful.
Recent Entries
Recent Comments
Re: Soekris BIOS upgrade using MacOSx Snow Leopard(Daniel Kühl : 06/09 05:55)
Re: Hey there!(betabug : 05/26 11:55)
Re: Why I don't have nor a Twitter neither a Facebook account(ben : 05/22 02:53)
Re: Hey there!(r0sk : 05/08 00:45)
Re: Hey there!(Juanjo : 05/07 18:44)
(sharmila : 02/01 10:17)
Re: Restoring your Desktop folder in Ubuntu(sharmila : 01/31 11:46)
Re: PostgreSQL database migration, the SQL_ASCII to UTF8 problem(P.V.Anthony : 10/23 08:18)
Re: Changing GTK themes in OSx(Harjoven : 10/10 02:33)
Re: PostgreSQL database migration, the SQL_ASCII to UTF8 problem(Kingsley : 09/19 04:17)
Recent Trackbacks
Categories
OpenBSD (8 items)
BSD (0 items)
FreeBSD (18 items)
Linux (3 items)
Security (3 items)
Python (18 items)
Zope (13 items)
Daily (138 items)
e-shell (9 items)
Hacks (13 items)
PostgreSQL (3 items)
OSX (7 items)
Nintendo DS (0 items)
enlightenment (0 items)
Apache (3 items)
Nintendo Wii (1 items)
Django (23 items)
Music (12 items)
Plone (7 items)
Varnish (0 items)
Lugo (2 items)
Sendmail (0 items)
europython (7 items)
Cherokee (1 items)
self (1 items)
Nature (1 items)
Hiking (0 items)
uwsgi (0 items)
nginx (0 items)
Archives
Links

Syndicate this site (XML)

RSS/RDF 0.91

07 mayo
2013

Hey there!

Yes, I'm still alive.

Hey there!

Wow, look at the date of my last post... 06/11/2011, that was like 548 days ago!

Well, I'm still alive, as you can see, but I've been way too busy to write stuff publicly here in the blog (I've been writing some tweets from time to time here though).

Too many things happened during the past few months to be able to write about them all here. One of the main reasons I did stop writing stuff here is that my workload increased a lot, and the other one is that I've a daughter now. Probably you can imagine how much life has changed for me.

I can't tell you how many times I've thought "wow, I should write something in my blog about this" during those 548 days. Really, that happened a lot.

So, here I am, taking 5 minutes to say hello. Let's hope I can be back to this healthy habit of writing about what happens to me everyday.

Hi! I'm glad to be back!

Posted by wu at 16:23 | Comments (3) | Trackbacks (0)
06 noviembre
2011

Arduino Barcamp 2011, Ordes

Talking, learning and doing things with arduino for a whole day

Yesterday was indeed a good day, and a long day too. I woke up at 08:00 (being my soul completely exhausted, as I got to bed around 3:00 the night before) and I met @r0sk, @MarcosBL, @mameyugo and @apvila30 at 08:45 to get on the road again on our way from Lugo to Ordes, where an Arduino Barcamp was being prepared by our friends of the Inestable Linux User Group.

The Barcamp started at 10:00, and we arrived a little bit later (around 10:20 or so), because we had some trouble finding the place.

The first thing that did struck me was the ammount of people attending the Barcamp, a lot more than expected. The guys from the Inestable lug said we were about 70 people in there, amazing (even more because they were expecting around 15 people or so).

You can get an idea on how much people we were just taking a look at these pictures:

Everybody was listening carefully to the first talk of the day. It was crowded during @TCRobotics's talk about Orugas, his personal project using arduino and some robotics knowledge

After meeting some of the Inestable guys (like @nikageek) we attended the first two talks of the day. First one covering basic knowledge about electronics and the second one showing some aspects of the programming language you can use to communicate/interact with your Arduino board. Both talks were performed by Jose [1] from the Inestable lug.

Then we had a coffee break (about 45 minutes or so). Perfect time to met some old friends like @toniousli or @javier_fazouro and talk about different ideas and projects using arduino boards.

The barcamp was talking place in "A casa da cultura", property of the Ordes city council, a nice place with plenty of room and some really nice paints outside:

This was painted on a wall opposite the place where the barcamp was taking place. I found it amazing Another paint, this one was near what seemed to be a kindergarten or something like that.

Back inside the talks room, @TCRobotics led a workshop about setting up the development environment you need to play with arduino, that is, downloading and installing the software from http://arduino.cc and teaching us how to use the environment, where are the docs, etc.

r0sk had his own arduino board with him, so we were able to have some fun Lot of people attending @TCRobotics' workshop

In the picture on the left you can see @r0sk playing with his arduino board. It seems he was having some fun ;P

After a break for lunch two groups of people were formed. One of the groups was attending @TCRobotics' talk about Orugas, his personal project that consist on a rover-like robot that can be controlled using a Wii nunchuk (in a previous version) or a PlayStation2 (in its latest version). He also showed us a video of one of the first versions of the project, where the robot was able to move by itself, recognizing objects and obstacles.

It was really interesting to hear how this kind of projects are done, understanding the whole process, the problems you can find and how you can solve them with a bit of imagination and thinking.

I got a seat quite close to @TCrobotics while he was talking about Orugas Orugas v2.5, we were able to take a look at it quite closely

The Orugas project involves much more stuff, like lasers, proximity sensors, etc. If you want to learn more, just visit Alex blog: http://tcrobotics.blogspot.com

Orugas v2.5, that's what you can do with an arduino board and some time, imagination and patience Another shot of the version 2.5 of the Orugas robot

The other group was attending a talk about arduino's XBee shield, a small board that adds wireless communication support to your arduino board. Oscar (one of the guys behind Bricogeek) gave this talk (sorry, I've no pictures of this talk). Another good talk.

The Barcamp finished near 21:00, or at least we left it at that time (I'm quite sure some people keep talking and sharing experiences and thoughts for some more time).

It was really a good experience. The only thing I'd missed was a real workshop, like the one I attended some months ago in Santiago, where there was a table, some arduino boards and material and both people willing to learn and people willing to teach, something more like a jam session. That would be really amazing, but I understand that being 70 people that would be almost imposible.

Don't misunderstand me, it was great and I enjoyed every single talk during the barcamp, I'm just giving an idea for the next-to-be arduino barcamp (as I'm quite sure there is going to be a next one soon).

We got back in the car and drove our way back to Lugo, arriving at 23:00 or so. We had dinner in one of the usual places (dotmas) and then I came back home BUT @r0sk, @MarcosBL and @mameyugo had other plans... They went to @MarcosBL's place and they kept themselves busy during the night, until they published this video in youtube:

[ no-comments ]

Oh!, I almost forgot, you can take a look at the pictures I took visiting this album.

[1]anyone has Jose´s blog/twitter/whatever urls?

Posted by wu at 23:48 | Comments (0) | Trackbacks (0)
18 agosto
2011

How to install a patched uwsgi package in FreeBSD

and how to do it cleanly, so you can keep track of later updates

What I'm going to explain in this post is not uwsgi-specific, you can follow this intructions to install patched versions of any package available in the FreeBSD ports collection.

In my case, I needed a patched version of the uwsgi package because I found a bug on my current version (0.9.8) that was already fixed in the -current/trunk version of uwsgi, but it hasn't been backported to any stable release yet (hopefully it will be in 0.9.8.4).

So, to fix the bug I needed the latest -current/trunk code or the latest stable release (0.9.8.3) + the needed patch.

Installing -current/trunk means compiling the sources and installing the binaries by myself, which will lead to some problems next time I had to upgrade the packages and ports in that server, so it seemed like a much better option to install the latest stable version using the ports tree. Anyway, I still would need to apply the patch to the 0.9.8.3 sources before installing... this is what I've done to add the patch cleanly.

I ran all the commands as root, if needed use sudo or some other tool to gain root privileges in order to use the ports tree.

First I got the sources of uwsgi using the ports tree:

# cd /usr/ports/www/uwsgi
# make fetch

That saved the source tarball into /usr/ports/distfiles:

-rw-r--r--  1 root  wheel  351168 Jul 23 06:28 /usr/ports/distfiles/uwsgi-0.9.8.3.tar.gz

Then I extracted the sources:

# make extract

That extracted the sources into /usr/ports/www/uwsgi/work/:

drwxr-xr-x  18 root  wheel  3072 Aug 18 15:47 work/uwsgi-0.9.8.3/

At this point we have two options, we could download an already existing patch or we can generate the patch ourselves. In my case, I generated the patch manually because the already existing patch didn't work.

To generate the patch I renamed the file that was going to be patched:

# cd work/uwsgi-0.9.8.3/
# mv plugins/python/wsgi_headers.c plugins/python/wsgi_headers.c.orig

Then I downloaded a copy of the patched version of the file:

# fetch -o plugins/python/wsgi_headers.c "http://projects.unbit.it/uwsgi/export/ddccfbda7423c8a61f178ba5b1526872d38cc285/plugins/python/wsgi_headers.c"

And finally I generated the patch:

# diff -ruN plugins/python/wsgi_headers.c.orig plugins/python/wsgi_headers.c > ../../files/patch-wsgi_headers.c

As explained in the patching section of the FreeBSD porters handbook:

"Each patch you wish to apply should be saved into a file named patch-* where * indicates the pathname of the file that is patched, such as patch-Imakefile or patch-src-config.h. These files should be stored in PATCHDIR (usually files/, from where they will be automatically applied. All patches must be relative to WRKSRC (generally the directory your port's tarball unpacks itself into, that being where the build is done)."

Once the patch was created, I cleaned up the work directory:

# make clean

And finally I install the new uwsgi package:

# make install clean

The bug was fixed and everything is running smoothly now.

Just some final considerations:

  • If you would like to know if your patch was applied properly, check the output of make install, you should see something like:

    ===>  Patching for uwsgi-0.9.8.3_1
    ===>  Applying FreeBSD patches for uwsgi-0.9.8.3_1
    

    Any errors that could have happened while applying the patch would be logged there.

    You can build the package before installing it too:

    # make
    

    and then you can check the file that should be patched (in this example it was /usr/ports/www/uwsgi/work/uwsgi-0.9.8.3/plugins/python/wsgi_headers.c) to see if it has been patched properly before proceeding with make install.

  • Remember that before installing the new package, you will have to delete the old one, use pkg_delete or make deinstall to do it.

  • In this case, the patch will be imported into the next uwsgi release (0.9.8.4) and so it will be available by default in the next upgrade of the uwsgi port, but, if you think that the patch will not be available directly from the official sources of the project, you should contact the author of the FreeBSD port and tell him/her about the patch and how you could help importing it into the ports tree. You can read more about this in the FreeBSD porters handbook.

Posted by wu at 18:31 | Comments (0) | Trackbacks (0)
25 julio
2011

How to get more followers in twitter during this summer

Probably not a *new* idea, but I think it is a funny way to get them

UPDATE

And indeed it wasn't an original idea at all, this afternoon I've discovered that my friend r0sk did something like that some days ago, here you have the proof:

http://yfrog.com/khl5hpsj

OLD POST

Get more followers on twitter, writing your ID on the sand when you are on the beach

I'm sure I'm not the first one that cames up with this idea, but I think it is funny enough to share it with all of you.

Some days ago, while having a walk by the sea, I found some stuff written on the sand. I kept walking and suddendly I thought:

"Hey!, wouldn't it be a good idea if I just write my twitter ID on the sand, leaving it there for everyone to find it?"

I know... probably 90% of the people will have no idea what would be the meaning of that, but that 10% would be worth the effort.

The rules:

  1. Choose a place that is not visible for everyone. This way, the people that would find it will read the ID, thinking about what it would be (obviously, people with a twitter account will understand what it is)
  2. Try to write the ID on wet sand, the ID will be more readable. Of course, wet sand means that the sea will cover the ID sooner or later, it would be a good idea to keep an eye on it and write it again later.
  3. Take some pictures of the writing and the place where you'd written it and put them on your blog. Don't show clearly where it is, but take some shots and spread the word/idea.

Action shot

An *action shot* of my twitter ID written on the sand on a beach located in the north of Galicia

Posted by wu at 11:56 | Comments (0) | Trackbacks (0)
20 julio
2011

Change by popular demand

this was the first change to this blog layout in years!

Just a quick post, because I think it deserves it.

For the first time in years, I've made a change to the layout of this blog. As you can notice, now the SouthPark-style character is located on the left sidebar, instead the top-right corner of the page.

This has been a request I've received multiple times since I moved my old blog to COREBlog+the new layout, because the character was making some texts difficult to read.

This morning, my friend saad told me:

09:59:32     saad | I admit that while I still grab e-shell's RSS feeds
09:59:44     saad | I no longer go read your posts
10:01:55     saad | as I am annoyed by the South Park like character that follow my scrolling
10:01:55     saad | given that I like scrolling down and reading from the beginning
10:01:55     saad | only to find that the SP char is the bg of text and thus make it impossible to read

"WTF!" - I thought - "how could it be that a friend of mine is not reading my blog anymore because of that!"

So I've moved the SP character a bit. I hope all of you will like this little change.

Posted by wu at 10:27 | Comments (0) | Trackbacks (0)
18 julio
2011

We've a new website at Codigo23

and it rocks!

The index page of the new codigo23.net site

As I've told you some weeks ago in my summary of the first three months of 2011 I've been quite busy since the beginning of the year. Things hadn't change too much the past three months and that's the reason for this low-posting period (again).

One of the projects I spent most of my time working on was the new Codigo23 website. For the past few years we had a coming soon page, buf finally we found the time to finish the new site contents. Once the contents were ready, we packed them in a not-so-complex website powered by Python, django and some Mako templates. The design was made by Sond3 , a design and web development company from Lugo.

The new site contains information about the different kind of services provided by the company, from software development to servers and networks management, security services or python-related training.

We are working in an open source section, that will contain source code, snippets and many more things, including full source code access to projects released by the company. A papers section is almost ready too, there we are going to publish manuals, articles and how-to documents to share our knowledge base with the community.

We are open! (TM)

Right now it is available only in spanish, but we are working on the english and galician versions (I hope they will be available soon).

Continue reading "We've a new website at Codigo23"
Posted by wu at 10:10 | Comments (0) | Trackbacks (0)
17 julio
2011

Arduino, first contact

and I swear I liked it!

Two days ago I went to Santiago to attend the Artropocode Meeting, an event for people from both the Open/Free Software and Art/Design/Multimedia worlds to meet, talk and share ideas, experiences and knowledge.

First reason for me to be there was the fact that a friend of mine was involved in the event organization, second reason was that the first day was focused mainly in the arduino project.

For those of you who don't know about it, Arduino is an open-source electronics prototyping platform based on flexible, easy-to-use hardware and software. It's intended for artists, designers, hobbyists, and anyone interested in creating interactive objects or environments (extracted from their website, http://arduino.cc).

First time I heard about arduino was during europython2010, when Ian Ozsvald showed us his headroid, a face-tracking robot. I thought it was totally awesome and I added a reminder for myself to check about that arduino thing later.

Since then I've read some stuff about the project and I've seen a lot of amazing things people do with arduino hardware, but I never had the chance to play with it by myself.

So, this was the perfect opportunity!

The meeting started with a talk by Filipe Valpereiro from the spacebits project. If you don't know the spacebits project, you should take a look at their website (http://spacebits.eu) and see the amazing things they are capable of.

Filipe talking about the SpaceBits project

Basically, they were able to send a hand-made shuttle up to near 40Km from the ground. Within that shuttle there were some cameras that were recording the whole thing. Just go check their website and play some videos, you will get truly amazed.

Filipe told us about the idea behind their project, how they started working on it, how they did what they do and we watched some amazing videos.

When the talk was over, Filipe sets a workshop so we all could play with some arduino boards and learn a lot.

Continue reading "Arduino, first contact"
Posted by wu at 13:13 | Comments (0) | Trackbacks (0)