lxdm (LXDE) not starting at boot

January 6th, 2012 by Leandro Del Teso

I’ve just found the solution for this that’s been bodering me for the last month or so. I filled up a bug at launchpad that contains all the info: https://bugs.launchpad.net/ubuntu/+source/lxdm/+bug/912772

After digging around I found that the upstart job /etc/init/lxdm.conf ran and stopped inmmediatly. A couple of weeks later (BTW, upstart debug log sucks!), I found that in this file there’s a condition that checks the content of /etc/X11/default-display-manager (line 28) and expects to found “/usr/sbin/lxdm”. In my case, the content of the file was “lxdm” therefore the condition was not satisfied and lxdm failed to start (actually it was being forced to stop).

After changing the content of /etc/X11/default-display-manager to “/usr/sbin/lxdm”, lxdm (LXDE) started to work at boot time showing login screen as expected.

 





Script to install NVIDIA drivers on Linux

July 16th, 2011 by Leandro Del Teso

If you ever struggled with the installation of the NVIDIA drivers on Linux (or Debian using this) then you should definitely check this out!

Really interesting, simple and useful script to install proper NVIDIA drivers on your Linux box.

http://smxi.org/docs/sgfxi-manual.htm

Simply run:

cd /usr/local/bin && wget -Nc smxi.org/sgfxi && chmod +x sgfxi && sgfxi

as root user (or with sudo) and the script will automatically decide which version to install and will set up the xorg.conf file for you. It also works with other graphics cards manufacturers.





java.io.FileNotFoundException: /usr/lib/libnss3.so error on Debian Wheezy

July 16th, 2011 by Leandro Del Teso

 


Edit:
this should have been fixed by http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=634058

 

 

I came across this error the other day running a java application on Debian Wheezy:

java.security.ProviderException: Could not initialize NSS
at sun.security.pkcs11.SunPKCS11.<init>(SunPKCS11.java:201)
at sun.security.pkcs11.SunPKCS11.<init>(SunPKCS11.java:103)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:532)
at sun.security.jca.ProviderConfig$3.run(ProviderConfig.java:262)
at sun.security.jca.ProviderConfig$3.run(ProviderConfig.java:244)
at java.security.AccessController.doPrivileged(Native Method)
at sun.security.jca.ProviderConfig.doLoadProvider(ProviderConfig.java:244)
at sun.security.jca.ProviderConfig.getProvider(ProviderConfig.java:224)
at sun.security.jca.ProviderList.getProvider(ProviderList.java:232)
at sun.security.jca.ProviderList.getIndex(ProviderList.java:262)
at sun.security.jca.ProviderList.getProviderConfig(ProviderList.java:246)
at sun.security.jca.ProviderList.getProvider(ProviderList.java:252)
at java.security.Security.getProvider(Security.java:473)
at jd.http.XTrustProvider.install(XTrustProvider.java:70)
at jd.http.Browser.init(Browser.java:1317)
at jd.update.Main.main(Main.java:119)
Caused by: java.io.FileNotFoundException: /usr/lib/libnss3.so
at sun.security.pkcs11.Secmod.initialize(Secmod.java:186)
at sun.security.pkcs11.SunPKCS11.<init>(SunPKCS11.java:197)
… 18 more
ERROR Could not initialize NSS

Apparently an update broke the configuration of the OpenJDK installation. So to fix it I had to manually edit the file /etc/java-6-openjdk/security/nss.cfg:

name = NSS
#nssLibraryDirectory = /usr/lib
nssLibraryDirectory = /usr/lib/i386-linux-gnu
nssDbMode = noDb
attributes = compatibility

Commenting out the highlighted orange line and adding the highlighted green line. The reason of it is that OpenJDK has split this configuration according to the box architecture (see https://bugs.launchpad.net/ubuntu/+source/nss/+bug/778726). However on my box it failed updating the reference to the new location of the libnss3.so file (I am on Debian Wheezy which is not stable yet so I guess something went wrong).





Listen to Arctic Monkeys’ new album: Suck it and see

May 30th, 2011 by Leandro Del Teso

Check the newest album by Arctic Monkeys Suck it and see, 1 week ahead to release.

http://www.guardian.co.uk/music/musicblog/2011/may/30/arctic-monkeys-suck-it-and-see

 





Spreading LXDE

April 30th, 2011 by Leandro Del Teso

The “Lightweight X11 Desktop Environment” is an extremely fast-performing and energy-saving desktop environment. (…) LXDE uses less CPU and less RAM than other environments. It is especially designed for cloud computers with low hardware specifications, such as, netbooks, mobile devices (e.g. MIDs) or older computers. LXDE can be installed with many Linux distributions including Ubuntu, Debian and Fedora. It is the standard for Knoppix and lubuntu. LXDE also runs with OpenSolaris and BSD. (…)The source code of LXDE is licensed partly under the terms of the the General Public License and partly under the LGPL.

 

I have it installed in an old Pentium 4 with 1.5GB of RAM and it works smoothly and flawlessly. If you need a lightweight desktop environment or want to try something different or you are simply tired of KDE an Gnome, well LXDE is a great alternative.

 

Check it out at: http://www.lxde.org





Linux: high CPU usage while playing music

April 21st, 2011 by Leandro Del Teso

If you have high CPU usage while playing music (or using the sound card) this could be related to the sample rates of the sound card and your current alsa/pcm/dmix configuration. Probably your card is set to 48kHz and the music file is at 44.1kHz (or vice-versa) and this is making the CPU to re-sample from one to another unnecessarily therefore the high CPU usage.

I was able to solve this by setting my ~/.asoundrc config file to:

pcm.!default {
    type plug
    slave.pcm {
        type dmix
	ipc_key 1024
	slave {
		pcm "hw:0,0"
		rate 44100
	}
    }
}

This caused my CPU usage to drop from ~30-40% to 2-4%.

.

.

Source: http://blog.sarine.nl/2008/12/21/dmix-the-pain-or-mpd-high-cpu-usage/





xfburn: CD/DVD burner for Linux

April 20th, 2011 by Leandro Del Teso

xfburn is a great front-end tool for writing CD/DVD. Simple and very useful.

Check it out at http://www.xfce.org/projects/xfburn





Restore deleted folder in SVN after commit

January 29th, 2011 by Leandro Del Teso

If you delete a remote folder in SVN accidentally it gets tricky to restore it back. This can happen by commiting an unwanted deletion. So, basically, what you have to do is:

  • Create a working copy of the deleted folder’s parent. You can use -N parameter that indicates “No checkout”. This will prevent from actually downloading any code. Run:

svn co -N SVN_PARENT_URL .

  • Get a copy of the deleted folder from the revision before the deletion. Run:

svn copy SVN_PARENT_URL/DELETED_FOLDER_NAME@REV DELETED_FOLDER_NAME

  • Commit to HEAD. This will actually commit a new revision with the contents of the revision before the deletion. Therefore restoring the “original” folder. Run:

svn commit -m “Restoring” DELETED_FOLDER_NAME


Source: http://www.freshblurbs.com/svn-restore-deleted-folder-revision

.





Search, learn, practice and become a rock star

December 29th, 2010 by Leandro Del Teso

For all of you wannabe rockers out there, check out this site. Free and accurate tabs: http://www.songsterr.com

Some of the songs I checked out:

Incubus – Consequence

Incubus – A crow left of the murder

Arctic Monkeys – Teddy picker

The Beatles – Don’t let me down





Squirrel SQL: Universal SQL Client

November 13th, 2010 by Leandro Del Teso

Squirrel SQL (http://www.squirrelsql.org/) is an open-source software developed with Java to manage databases. This means:

  • you can control as many DBs as JDBC drivers exists out there (MySQL, Oracle, Postgresql, etc, etc.)
  • you can run it in Linux, MacOS, Windows, etc, etc.
  • it’s free.

Check complete features and screenshots here.





Spreading Firefox

November 4th, 2010 by Leandro Del Teso

Spread Firefox Affiliate Button





Applause for Blender: Sintel Open Movie

October 2nd, 2010 by Leandro Del Teso

Another fantastic production of the Blender Foundation. Sintel Open Movie is a newly premiered film developed with Blender 3D and other open-source tools.

Discover & enjoy it now: http://www.sintel.org/





YoFrankie!, another good initiative for linux gaming.

July 20th, 2010 by Leandro Del Teso

YoFrankie! is a game developed and funded by The Blender Foundation (and the community) in other to enhance Blender’s gaming capabilities; and design and implement new features. As a result of the development of this game, all the features developed within the project are now available in new versions of Blender, the 3D software.

It is very interesting the history behind the Blender project. I recommend you check it out. It is one (of many) success cases in Open Source development.





Monkey Island Mania!

July 9th, 2010 by Leandro Del Teso

Monkey Island is back…and back for good! It seems that there’s a Monkey Island mania out there. And I think it’s great! In the previous post I wrote a year ago, LucasArts was announcing the re-make of “The Secret Of Monkey Island”. Well, not only that re-make was launched but also they made a re-make of “Monkey Island 2: LeChuck’s Revenge”. And it is available now.

 

 

On the other hand, Telltale Games launched a NEW Monkey Island game called “Tales of Monkey Island”. Brought to us in five “short” chapters instead of a “long” game, as it’s usual for the company. They have all been released now and I must say they highly exceeded my expectations. Bringing a new, fun, playable and state-of-the-art Monkey Island game to life. This might be the result of being developed by a company founded by ex-LucasArts employees.

 

 

I think it’s great that Monkey Island is back. It is one of my favourite games of all times. I love adventure games, They were gone for a little while; replaced by action games like shooters (i.e: Counter Strike) or sports games (i.e: Need for Speed). I hope this will help moving the direction of game companies towards developing Adventure-like games.

 

 

Links:

http://www.lucasarts.com/games/monkeyisland/

http://www.lucasarts.com/games/monkeyisland2/

http://www.telltalegames.com/monkeyisland





World Of Goo: an excellent game available for Linux

May 28th, 2010 by Leandro Del Teso

World of Goo is an addictive, state-of-the-art, smooth and pleasant to the eye game. Plus, it is available for Linux natively!!! Plus it is only U$D20.-

Check it out here:

http://2dboy.com/games.php

I hope companies start believing there is a “Linux game market” out there waiting and wanting games to run natively.





Apache Cassandra with Java

May 6th, 2010 by Leandro Del Teso

Excelent tutorial for Apache Cassandra by Ronald Mathies of Sodeso.

Edit: links are dead :(





Phase Relationships in the Standardization Process

April 13th, 2010 by Leandro Del Teso

A bit sarcastic yet almost-always-true article written by James Gosling in 1990 (20 years ago), about politics in the software development industry.

http://nighthacks.com/roller/jag/resource/StandardsPhases.html

Enjoy!





How to remove .svn directories recursively

April 10th, 2010 by Leandro Del Teso

Just type this in your console:

rm -rf `find . -type d -name .svn`






Anemic Domain Models

February 13th, 2010 by Leandro Del Teso

A post by Martin Fowler that talks about a very common and used way of defining the domain layer and service layer in an application.

http://www.martinfowler.com/bliki/AnemicDomainModel.html





Mic not working with C-Media soundcard and Ubuntu Karmic 9.10

February 4th, 2010 by Leandro Del Teso

The problem was that this on-board sound card is surround and, when in surround mode, the mic mini-plug input becomes Center /LFE output.

I fixed it this way:

1) Open “alsamixer”
2) Go to “Mic-In Mode” bar
3) Check that in “Item” (top-left corner), it reads “Mic-In Mode [Mic-In]”
4) If not (probably “Mic-In Mode [Center/LFE Output]“) hit up/down arrow keys until “Mic-In Mode [Mic-In]” is selected.
5) Check that mic is not muted. Go to “Mic” bar and check that it is not muted “Mic [Off]“. If it is, hit M key, you’ll get “Mic” only.

That should be it.