Archive

Archive for the ‘Debian’ Category

A tale of a gillion installs

January 21st, 2014 1 comment

Install number one: LMDE 201303.  I was hoping for the best of both worlds, but I got driver issues instead.  LMDE has known ATI proprietary driver install issues.  I followed the Mint instructions and got it working, then got a blank screen after too much tinkering.  I was surprised that LMDE had this problem since Debian doesn’t, and LMDE should be a more polished version of LMDE.  This wasn’t a big deal, but I decided to give Debian a chance.

Install number two: debian stable (7.3).  The debian website has a convoluted maze of installation links, but it’s still fairly easy to find an ISO for the stable version you need.  I installed from the live ISO using a USB key.  The installation and ATI driver update went smoothly, and I thought all was well at first.  I soon realized that about 50% of reboots failed; the audio driver was the culprit.  I installed the latest driver from Realtec/ALSA and it sort of worked, but I was still getting some crap from # dmesg and the audio would crackle with some files.

LMDE.  I live booted LMDE to see if the same issue existed there and it did.

Time for Mint 16.  As expected everything worked.  Man I really wish Ubuntu hadn’t chosen the dark side – their OS is really good.  All of these distros use ALSA audio drivers, so why is Ubuntu the only one that works?   Kernel versions:

debian stable (7.3):
cat /proc/asound/version
Advanced Linux Sound Architecture Driver Version 1.0.24.
Mint 16:
cat /proc/asound/version
Advanced Linux Sound Architecture Driver Version k3.11.0-12-generic.

One more thing to check.  What kernel version is the real debian testing “jessie” using:

http://packages.debian.org/testing/kernel/linux-image-3.12-1-amd64

LMDE 201303 = 3.2
debian stable 7.3 = 3.2
Mint 16 = 3.11
debian testing “jessie - Jan 2014” = 3.12!

I determined to try debian testing before settling for Mint.  I tried a netinstall from USB key which killed my PC and grub bootloader.  The debian stable live iso usb key decided to stop working as well.   I finally got a real DVD debian stable install to work, changed the repositories to point to “jessie” and upgraded.  I was very surprised to see this worked!   I’m having some problems with bash, but all of my day to day software is up and running.  Nice.

TL;DR: LMDE was using an old kernel so I needed the real debian testing (jessie) to solve my driver problems.

So many flavours – with bonus privacy rant!

January 21st, 2014 1 comment

It’s interesting reading the old Linux Experiment first posts when people were contemplating which distro to install.  It’s been 4.5 years since then and the linux world has evolved.  Most noticeable, was no one talking about Mint!

I was considering three distros for my home PC dual boot:

  1. Debian
  2. LMDE
  3. Mint

I wanted something in the debian family since it seems to be receiving, by far, the most attention.  I expect this also means it gets the most activity and updates.  Ubuntu would probably work the best out of the box, but as you probably already know:

https://en.wikipedia.org/wiki/Unity_%28user_interface%29#Privacy_controversy

Ubuntu’s privacy issues are a deal breaker of course, but they also made me question Mint.  I don’t want to support Ubuntu and I think using Mint would indirectly do that.  Also, Mint does have some minor default search engine sketchyness going on.   I realize that these developers need funding, but I don’t think selling their users’ stats or useage is the way to do it.  I think donations are the way to go and they seem to be working for Wikimedia.  Developing non-essential non-related commercial software in parallel with the OS might be another alternative… hmm, sounds like a slippery slope.

The plan was: Try LMDE first, Debian stable if more stability is needed, and Mint if I got to the point that I just wanted things to work.  Results to follow!

TL;DR:  I planned to install LMDE or Debian, since Ubuntu wants to track me.

Limit Bandwitdth Used by apt-get

October 22nd, 2012 No comments

It’s easy. Simply throw “-o Acquire::http::Dl-Limit=X” in your apt-get command where X is the kb/s you wish to limit it to. So for example let’s say that you want to limit an apt-get upgrade command to roughly 50kb/s of bandwidth. Simply issue the following command:

sudo apt-get -o Acquire::http::Dl-Limit=50 upgrade

Simple right?




I am currently running a variety of distributions, primarily Linux Mint 17.
Previously I was running KDE 4.3.3 on top of Fedora 11 (for the first experiment) and KDE 4.6.5 on top of Gentoo (for the second experiment).
Check out my profile for more information.

Create a GTK+ application on Linux with Objective-C

December 8th, 2010 8 comments

As sort of follow-up-in-spirit to my older post I decided to share a really straight forward way to use Objective-C to build GTK+ applications.

Objective-what?

Objective-C is an improvement to the iconic C programming language that remains backwards compatible while adding many new and interesting features. Chief among these additions is syntax for real objects (and thus object-oriented programming). Popularized by NeXT and eventually Apple, Objective-C is most commonly seen in development for Apple OSX and iOS based platforms. It ships with or without a large standard library (sometimes referred to as the Foundation Kit library) that makes it very easy for developers to quickly create fast and efficient programs. The result is a language that compiles down to binary, requires no virtual machines (just a runtime library), and achieves performance comparable to C and C++.

Marrying Objective-C with GTK+

Normally when writing a GTK+ application the language (or a library) will supply you with bindings that let you create GUIs in a way native to that language. So for instance in C++ you would create GTK+ objects, whereas in C you would create structures or ask functions for pointers back to the objects. Unfortunately while there used to exist a couple of different Objective-C bindings for GTK+, all of them are quite out of date. So instead we are going to rely on the fact that Objective-C is backwards compatible with C to get our program to work.

What you need to start

I’m going to assume that Ubuntu will be our operating system for development. To ensure that we have what we need to compile the programs, just install the following packages:

  1. gnustep-core-devel
  2. libgtk2.0-dev

As you can see from the list above we will be using GNUstep as our Objective-C library of choice.

Setting it all up

In order to make this work we will be creating two Objective-C classes, one that will house our GTK+ window and another that will actually start our program. I’m going to call my GTK+ object MainWindow and create the two necessary files: MainWindow.h and MainWindow.m. Finally I will create a main.m that will start the program and clean it up after it is done.

Let me apologize here for the poor code formatting; apparently WordPress likes to destroy whatever I try and do to make it better. If you want properly indented code please see the download link below.

MainWindow.h

In the MainWindow.h file put the following code:

#import <gtk/gtk.h>
#import <Foundation/NSObject.h>
#import <Foundation/NSString.h>

//A pointer to this object (set on init) so C functions can call
//Objective-C functions
id myMainWindow;

/*
* This class is responsible for initializing the GTK render loop
* as well as setting up the GUI for the user. It also handles all GTK
* callbacks for the winMain GtkWindow.
*/
@interface MainWindow : NSObject
{
//The main GtkWindow
GtkWidget *winMain;
GtkWidget *button;
}

/*
* Constructs the object and initializes GTK and the GUI for the
* application.
*
* *********************************************************************
* Input
* *********************************************************************
* argc (int *): A pointer to the arg count variable that was passed
* in at the application start. It will be returned
* with the count of the modified argv array.
* argv (char *[]): A pointer to the argument array that was passed in
* at the application start. It will be returned with
* the GTK arguments removed.
*
* *********************************************************************
* Returns
* *********************************************************************
* MainWindow (id): The constructed object or nil
* arc (int *): The modified input int as described above
* argv (char *[]): The modified input array modified as described above
*/
-(id)initWithArgCount:(int *)argc andArgVals:(char *[])argv;

/*
* Frees the Gtk widgets that we have control over
*/
-(void)destroyWidget;

/*
* Starts and hands off execution to the GTK main loop
*/
-(void)startGtkMainLoop;

/*
* Example Objective-C function that prints some output
*/
-(void)printSomething;

/*
********************************************************
* C callback functions
********************************************************
*/

/*
* Called when the user closes the window
*/
void on_MainWindow_destroy(GtkObject *object, gpointer user_data);

/*
* Called when the user presses the button
*/
void on_btnPushMe_clicked(GtkObject *object, gpointer user_data);

@end

MainWindow.m

For the class’ actual code file fill it in as show below. This class will create a GTK+ window with a single button and will react to both the user pressing the button, and closing the window.

#import “MainWindow.h”

/*
* For documentation see MainWindow.h
*/

@implementation MainWindow

-(id)initWithArgCount:(int *)argc andArgVals:(char *[])argv
{
//call parent class’ init
if (self = [super init]) {

//setup the window
winMain = gtk_window_new (GTK_WINDOW_TOPLEVEL);

gtk_window_set_title (GTK_WINDOW (winMain), “Hello World”);
gtk_window_set_default_size(GTK_WINDOW(winMain), 230, 150);

//setup the button
button = gtk_button_new_with_label (“Push me!”);

gtk_container_add (GTK_CONTAINER (winMain), button);

//connect the signals
g_signal_connect (winMain, “destroy”, G_CALLBACK (on_MainWindow_destroy), NULL);
g_signal_connect (button, “clicked”, G_CALLBACK (on_btnPushMe_clicked), NULL);

//force show all
gtk_widget_show_all(winMain);
}

//assign C-compatible pointer
myMainWindow = self;

//return pointer to this object
return self;
}

-(void)startGtkMainLoop
{
//start gtk loop
gtk_main();
}

-(void)printSomething{
NSLog(@”Printed from Objective-C’s NSLog function.”);
printf(“Also printed from standard printf function.\n”);
}

-(void)destroyWidget{

myMainWindow = NULL;

if(GTK_IS_WIDGET (button))
{
//clean up the button
gtk_widget_destroy(button);
}

if(GTK_IS_WIDGET (winMain))
{
//clean up the main window
gtk_widget_destroy(winMain);
}
}

-(void)dealloc{
[self destroyWidget];

[super dealloc];
}

void on_MainWindow_destroy(GtkObject *object, gpointer user_data)
{
//exit the main loop
gtk_main_quit();
}

void on_btnPushMe_clicked(GtkObject *object, gpointer user_data)
{
printf(“Button was clicked\n”);

//call Objective-C function from C function using global object pointer
[myMainWindow printSomething];
}

@end

main.m

To finish I will write a main file and function that creates the MainWindow object and eventually cleans it up. Objective-C (1.0) does not support automatic garbage collection so it is important that we don’t forget to clean up after ourselves.

#import “MainWindow.h”
#import <Foundation/NSAutoreleasePool.h>

int main(int argc, char *argv[]) {

//create an AutoreleasePool
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];

//init gtk engine
gtk_init(&argc, &argv);

//set up GUI
MainWindow *mainWindow = [[MainWindow alloc] initWithArgCount:&argc andArgVals:argv];

//begin the GTK loop
[mainWindow startGtkMainLoop];

//free the GUI
[mainWindow release];

//drain the pool
[pool release];

//exit application
return 0;
}

Compiling it all together

Use the following command to compile the program. This will automatically include all .m files in the current directory so be careful when and where you run this.

gcc `pkg-config –cflags –libs gtk+-2.0` -lgnustep-base -fconstant-string-class=NSConstantString -o “./myprogram” $(find . -name ‘*.m’) -I /usr/include/GNUstep/ -L /usr/lib/GNUstep/ -std=c99 -O3

Once complete you will notice a new executable in the directory called myprogram. Start this program and you will see our GTK+ window in action.

If you run it from the command line you can see the output that we coded when the button is pushed.

Wrapping it up

There you have it. We now have a program that is written in Objective-C, using C’s native GTK+ ‘bindings’ for the GUI, that can call both regular C and Objective-C functions and code. In addition, thanks to the porting of both GTK+ and GNUstep to Windows, this same code will also produce a cross-platform application that works on both Mac OSX and Windows.

Source Code Downloads

Source Only Package
File name: objective_c_gtk_source.zip
File hashes: Download Here
File size: 2.4KB
File download: Download Here

Originally posted on my personal website here.




I am currently running a variety of distributions, primarily Linux Mint 17.
Previously I was running KDE 4.3.3 on top of Fedora 11 (for the first experiment) and KDE 4.6.5 on top of Gentoo (for the second experiment).
Check out my profile for more information.

One week, three distributions (Day 7: Conclusions)

October 24th, 2010 No comments

Well it’s been an interesting week. I’ve gotten to try out three new distributions and share my thoughts with everyone here. My original goal was to see which one of these distributions offered the best first impression and declare that one as the ‘winner’. However in actually working my way through these great releases I have changed my mind somewhat.

What makes a great distribution great?

This is a very interesting question that I’m sure would generate a wide array of unique and passionate responses. Some prefer ease of use, while others demand nothing less than complete control over what they can tweak. There are people who swear by using nothing but open source solutions, while others are happy to add proprietary code into the mix as well. This is the great thing about Linux, we get so many choices which means we get to decided what we want.

Unfortunately this has also resulted in a bit of distribution zealotry; like choosing Ubuntu over Fedora, or Arch over OpenSUSE is somehow taking a side in some giant war. Instead of all of the infighting we should be celebrating the fact that when Ubuntu comes out with a new piece of user-friendly software, or Fedora introduces a new awesome technology, we can share and integrate it right into all distributions.

So what makes a great distribution great? A distribution is great because it works for you, it suites your needs, fits your personality and lets you do what you want to do. At the end of the day isn’t that what open source is about?

Final thoughts

OK enough of the preachy writing. I think that all of the distributions I have tested this week were very good. They each embody the spirit of open source in their own little ways.

Kubuntu 10.10

Awards: The most improved release. Most likely to recover lost KDE fans.

I was extremely impressed with this release. The folks over at the Kubuntu project deserve a huge round of applause for their continued work on this often forgotten Ubuntu sibling. This release is unlike any other that I’ve tried from Kubuntu, and I hope it marks a turning point in the distribution’s history. If the next release sees anywhere close to the improvement that this release did it may even unseat Ubuntu as the go to Linux release. If you haven’t tried out this release I urge you to give it a shot.

Ubuntu 10.0

Awards: The most refined. Most likely to be installed on a new Linux user’s computer.

Ubuntu makes a return from its last long-term support (LTS) release with this stellar offering. For a release that is meant to experiment with changes, which might eventually be incorporated into a future LTS release, this version feels as polished as ever. The new theme, font, store and integration features make this an absolutely solid release. If you’re an Ubuntu user I’m sure you have already upgraded. If you develop for a different distribution, this might still be worth looking into if only to steal the good parts for your release of choice. Either way I think this release of Ubuntu marks a whole new level of application integration on the Linux desktop and I am excited to see where they go next with it.

Linux Mint Debian Edition

Awards: The most advanced. Most likely to see the fastest improvement.

For people who have been using Debian for a while now this release will feel right at home. It combines the best parts of Debian testing, modern software, stability and thousands of packages, with the Linux Mint team’s renown ability to iron out the kinks in any Linux distribution. I think that this release will see so much improvement in the next couple of months that it has the potential to steal users away from other rolling release distributions with its easy to use desktop. While this current iteration does have some issues I hardly think that they are anything to run away from. For technical users looking for the newest stuff, while hoping avoiding the vast majority of headaches other distributions can cause, this one is for you.

My Choice

For me personally I have been very happy with Linux Mint 9 and look forward to version 10 when it ships later this year. Until then however I think I will be sticking with the one that most closely resembles my current set up. No not Linux Mint Debian Edition, but Ubuntu 10.10. That being said I do look forward to giving Fedora 14 and Linux Mint 10 a ride soon.




I am currently running a variety of distributions, primarily Linux Mint 17.
Previously I was running KDE 4.3.3 on top of Fedora 11 (for the first experiment) and KDE 4.6.5 on top of Gentoo (for the second experiment).
Check out my profile for more information.

One week, three distributions (Day 6: Linux Mint Debian Edition)

October 23rd, 2010 7 comments

To round out the week I installed the newly released Linux Mint Debian Edition (LMDE). Like the other posts I have made I will walk you through my first impressions as well as the general overall feel of the distribution.

Install

LMDE’s install is something quite different from the experiences I had with Ubuntu 10.10 and Kubuntu 10.10. While it is still a very polished installer (complete with a single slide slide-show even!) it does lack a couple of features that make it far less user friendly. Where the other installers basically held your hand in every way, LMDE requires at least some technical understanding in order to complete. For instance there is no friendly auto-partition step, instead LMDE leaves the user to do it manually with GParted. While hardly the end of the world it is enough of a challenge that you could no longer just hand this disc to your non-technical friend and let them have at it. However once that step is complete the installer is very straight forward and rips through the installation in a matter of minutes.

First boot and drivers (oh my!)

I have to say that my first impression of LMDE was a mixed one. On one hand it spewed text everywhere as it booted, which I assume came from its Debian heritage. On the other hand the boot was ridiculously fast. I know it’s been one of Canonical’s goals to make Ubuntu the fastest booting Linux distribution but I have to say that a stock install of LMDE (and maybe even Debian Testing) will easily give that claim a run for its money.

Once at my desktop I was presented with a very familiar Linux Mint set up. If you were to place this desktop next to Linux Mint’s Ubuntu derivative (Linux Mint 9 for instance) I would be very hard pressed to spot any differences.

Unfortunately one thing that was glaringly missing was the lack of the Ubuntu automatic driver detection and install system jockey. Without jockey I had to resort to Fedora-esque measures in order to install the correct driver which is necessary for correct display and power management on my laptop. For reference here are the steps I took in order to install the proprietary ATI driver and setup my X configuration:

1) Run the following command in order to make sure you have the most recent package list

$ sudo apt-get update

2) You may want to now install all available updates so that we start with the most recent kernel

$ sudo apt-get dist-upgrade

3) Install the kernel headers so that we can configure it to work with the ATI driver

$ sudo apt-get install linux-headers-2.6-$(uname -r | sed ‘s,.*-,,’)

4) Install the ATI driver and control panel

$ sudo apt-get install fglrx-control fglrx-driver

5) From there just follow the instructions on my post here in order to generate the new X configuration file and maybe even fix your vsync issues at the same time.

I have read that jockey is currently being ported and will appear in the LMDE repositories so hopefully this small issue will be solved quickly.

Rolling release = LOTS OF UPDATES

One of LMDE’s big selling points is that it is a rolling release, which means that you will continue to get new packages and updates on your system without having to reinstall at 6 month intervals like some other distributions. Strangely though LMDE does not ship with update checking enabled which I found kind of weird. A quick forced check later and I discovered why the team may have made that choice

That’s right, almost 500 updates… Almost every package on my newly installed machine had to be replaced updated. This is definitely a release for people looking for the newest software but could easily lead to update fatigue for everyone else.

32-bit working system vs PAE kernel broken system

One of the unfortunate things about this release is that it only comes in a 32-bit version. As I run a 64-bit processor with 4GB of RAM it irks me to know that I am not using the full potential of my system. I starting looking into Physical Address Extension (PAE) kernels as a solution to this problem. PAE kernels, for those who don’t know, use a system of memory indirection in order to allow a 32-bit processor access to more than 4GB of mappable memory. In the case of Linux the PAE kernel can map up to 64GB of RAM.

After a bit of googling I stumbled upon instructions to install a PAE kernel by simply installing the linux-image-686-bigmem meta-package. Unfortunately this quick fix, as most often is the case, didn’t exactly turn out well and actually broke my GDM system. Without GDM I was unable to log into my desktop and this experiment came to an end. In the interest of time I decided to just reinstall instead of trying to troubleshoot how to fix what I had inadvertently broken.

Software selection

The software selection in LMDE is impressive and in many ways is what Ubuntu’s used to be. Here you will find (pre-installed) Flash, the Java and Mono runtimes, an MP3 codec and even the Gimp. Everything, like the other Linux Mint releases, is designed to make it so that the user does not have to search for solutions to missing functionality.

Because this is a rolling release it doesn’t really make sense for me to review the included software as much as it does to just mention it. For web browsing LMDE, like Ubuntu, ships with Firefox. To send and receive e-mail it calls upon Firefox’s cousin Thunderbird. Instant messaging is handled by Pidgin and your music collection is controlled by Rhythmbox. F-Spot remains as the photo manager, unlike Ubuntu which replaced it with Shotwell, while Gwibber and Totem round out the release.

Conclusion

Currently Linux Mint Debian Edition is somewhat of an enthusiast’s release. It has the potential to be a great rolling release but it’s pretty obvious that right now it needs some work to get there. For instance, why when I updated my software, did my GDM background change to a Debian one? The team over at Linux Mint knows how to polish a distribution and so I’m confident that they will do the same for Debian Edition.

Pros:

  • Rolling release which means you always have the most recent software
  • Still has that Linux Mint charm to it

Cons:

  • The distribution still needs a bit of polish before I could see myself recommending it to all but seasoned Linux users
  • Being a rolling release might result in update fatigue



I am currently running a variety of distributions, primarily Linux Mint 17.
Previously I was running KDE 4.3.3 on top of Fedora 11 (for the first experiment) and KDE 4.6.5 on top of Gentoo (for the second experiment).
Check out my profile for more information.

One week, three distributions (Day 0)

October 15th, 2010 No comments

With the recent releases of Linux Mint Debian Edition, Ubuntu and Kubuntu 10.10 I am once again starting to feel that need to hop around and try something new out. That’s not to say that my current distribution of choice (Linux Mint 9) is a bad one, quite the opposite in fact. I am however curious to see what these new releases do, well, new. That being said I’ve set myself up a little experiment of sorts: try each distribution for two days each and on the 7th day choose the best from among the three. Now obviously this isn’t a very fair test, 48 hours is hardly enough to definitely test which of these distributions is truly the best. What it will, hopefully, show though is which distribution gives off the best first impression.

So buckle up and stay tuned, this week should hopefully be an interesting one.




I am currently running a variety of distributions, primarily Linux Mint 17.
Previously I was running KDE 4.3.3 on top of Fedora 11 (for the first experiment) and KDE 4.6.5 on top of Gentoo (for the second experiment).
Check out my profile for more information.

lua + nginx + FastCGI on Debian

June 22nd, 2010 2 comments

(This was originally posted here on my personal blog.)

I’ve recently been doing some testing in lua, and have been comparing the results to the EdgeLink Consulting CMS that we’ve designed in PHP. So far this solution is able to serve substantially more requests per second than our current CMS. However, we haven’t really spent much time optimizing the CMS. The goal is to have a working copy first before any optimizations are done. We’ve also been working on some eCommerce modules for the platform.

With all that being said, I’d like to post a quick tutorial on how I got this setup. It was quite the task. Although there was a tutorial I found to do the same task, it was a little bit confusing. My tutorial will have a lot of the same steps, with some minor adjustments. This tutorial is written at an intermediate level. Some trivial steps have been omitted.

NOTE: This has been tested with Debian 5.0.4 (Stable)

  1. Install nginx

    apt-get install nginx

    We’ll have to do some modifications later on to add the FastCGI handler. For simplicity we will keep the web path to “/var/www/nginx-default” and listen on port 8081 in case you have another webserver running on port 80.

  2. Install lua 5.1 (and WSAPI libraries)

    apt-get install lua5.1 liblua5.1-wsapi-fcgi-0 liblua5.1-coxpcall0 liblua5.1-filesystem0

    apt-get install liblua5.1-wsapi-doc

    Can’t do much testing without this. Note: The second line is not necessary if you are running Debian testing, and get the liblua5.1-wsapi-fcgi-1instead.

    EDIT: You’ll notice that I added in liblua5.1-filesystem0. Steve pointed out that there is a bug in liblua5.1-wsapi-fcgi-0. It doesn’t include it as a dependency. He reported this as a bug here, and it was fixed in liblua5.1-wsapi-fcgi-1.

  3. Install spawn-fcgiIf you’re running Debian testing you may be able to get spawn-fcgi through the distribution, however, I just downloaded it and compiled from source.

    wget http://www.lighttpd.net/download/spawn-fcgi-1.6.3.tar.gz
    tar -xzvf spawn-fcgi-1.6.3.tar.gz
    cd spawn-fcgi-1.6.3.tar.gz
    ./configure
    make
    make install

  4. Create a FastCGI Socket

    spawn-fcgi -F 4 -u www-data -s /var/run/nginx-fcgi.sock -P /var/run/nginx-fcgi.pid — /usr/bin/wsapi.fcgi

    For the sake of simplicity, we will just spawn it manually for now. If you’re feeling crafty you can add the above line to the start condition in/etc/init.d/nginx, and the line below to the stop condition. You can add both of them to restart.

    cat /var/run/nginx-fcgi.pid | xargs -n 1 kill

  5. Create a lua file in /var/www/nginx-default/In this tutorial, use hello.lua. You can change this to whatever, you want but just make sure you make the modification in the nginx configuration below as well.
  6. Edit /etc/nginx/sites-available/defaultNow let’s add the code that will point nginx to the correct file. For simplicity, we will simply point it to hello.lua. You can change this to anything, or simply modify the code to accept any *.lua file, as seen in the tutorial listed above. Here is the top of my default file:

    listen   8081 default;
    server_name  localhost;
    access_log  /var/log/nginx/localhost.access.log;

    location / {
    fastcgi_pass    unix:/var/run/nginx-fcgi.sock;
    fastcgi_param   SCRIPT_FILENAME “/var/www/nginx-default/hello.lua”;
    fastcgi_param   PATH_INFO       $request_uri;
    fastcgi_param   QUERY_STRING    $query_string;
    fastcgi_param   REQUEST_METHOD  $request_method;
    fastcgi_param   CONTENT_TYPE    $content_type;
    fastcgi_param   CONTENT_LENGTH  $content_length;
    }

  7. Restart nginx

    /etc/init.d/nginx restart

  8. Visit http://localhost:8081/Congratulations! You should now see hello.lua.

If you have any problems, post in the comments. Stay tuned for more related posts.

Fixing gnustep-devel in Ubuntu 10.04

May 17th, 2010 No comments

When Ubuntu 10.04 was released it represented the most modern incarnation of Canonical’s premier Linux desktop distribution. However not all things were better in this release. For myself I immediately noticed a problem while trying to install the gnustep-devel development libraries for GNUstep and Objective-C. I was greeted with this oh so lovely error message:

Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming.
The following information may help resolve the situation:

The following packages have unmet dependencies:
gnustep-devel: Depends: gorm.app but it is not installable
E: Broken packages

So essentially I was left with the following choice: install the missing Gorm.app package from the repository (which wasn’t there) or don’t install gnustep-devel. Thankfully it was pointed out to me that I could perhaps see if the package still existed in the Debian repository instead. So off to http://www.debian.org/distrib/packages I went and after a quick search I found what I was looking for! I recalled reading somewhere that Ubuntu synchronizes with Debian testing (A.K.A. squeeze) at the start of every round of development, so I figured that would be the best package to grab. A short download and install later Gorm.app was finally on my system. With the dependencies now met it was a breeze to install the rest of the development files using a simple

sudo apt-get install gnustep-devel

And there you have it. By installing a single package from the Debian repository you too can get around the problem. For reference I have also filed a bug report with Ubuntu at Launchpad here.

Originally posted on my personal website here.




I am currently running a variety of distributions, primarily Linux Mint 17.
Previously I was running KDE 4.3.3 on top of Fedora 11 (for the first experiment) and KDE 4.6.5 on top of Gentoo (for the second experiment).
Check out my profile for more information.

How is it doing that?

December 15th, 2009 13 comments

Just about everything that I’ve ever read about media playback on Linux has been negative. As I understand the situation, the general consensus of the internet is that Linux should not be relied on to play media of any kind. Further, I know that the other guys have had troubles with video playback in the past.

All of which added up to me being extremely confused when I accidentally discovered that my system takes video playback like a champ. Now from the outset, you should know that my system is extremely underpowered where high definition video playback is concerned. I’m running Debian testing on a laptop with a 1.73 GHz single-core processor, 758MB shared video RAM, and a 128MB Intel GMA 900 integrated graphics card.

Incredibly enough, it turns out that this humble setup is capable of playing almost every video file that I can find, even with compiz effects fully enabled and just a base install of vlc media player.

Most impressively, the machine can flawlessly stream a 1280x528px 1536kb/s *.mkv file over my wireless network.

As a comparison, I have a Windows Vista machine with a 2.3GHz processor, 4GB of RAM, and a 512MB video card upstairs that can’t play the same file without special codecs and the help of a program called CoreAVC. Even with these, it plays the file imperfectly.

I can’t explain how this is possible, but needless to say, I am astounded at the ability of Linux.




On my Laptop, I am running Linux Mint 12.
On my home media server, I am running Ubuntu 12.04
Check out my profile for more information.