my life

day to day

Archive for the 'uncategorized' Category

nvidia-glx: Depends: nvidia-kernel-100.14.19 but it is not installable

Thursday, November 1st, 2007

If you get this error running

apt-get install nvidia-glx
, then it’s time to upgrade your nvidia-kernel drivers and try again.

add to del.icio.us    add to technorati favs   email this

WordPress database error: [Table 'wp_terms' doesn't exist]

Monday, October 15th, 2007

After a recent upgrade of Wordpress on Debian, my blog started spewing these errors everywhere, despite having run the upgrade script. The problem is that there are 2 upgrade scripts. Why they don’t both get executed is beyond me.

To fix it, run http://example.com/wordpress/wp-admin/upgrade.php (Not, http://example.com/wordpress/upgrade.php, which you’ve already run).

Then, be a Good Samaritan, and help fix the 19,500 blogs broken by this error.

add to del.icio.us    add to technorati favs   email this

Symfony + Propel AUTO_INCREMENT offset

Friday, September 28th, 2007

There’s no way to natively setup the starting offset for AUTO_INCREMENT columns in propel. Ideally, you would just set autoIncrement=”100000″ for an offset of 100000, but unfortunately they expect a boolean argument. To get around this, edit data/sql/sqldb.map and add an entry contrib.sql=propel and edit a file in data/sql/contrib.sql.

Add the following to the file:

ALTER TABLE example_table_1 AUTO_INCREMENT = 100000; ALTER TABLE example_table_2 AUTO_INCREMENT = 100000;

Then rerun 
symfony propel-insert-sql
. WARNING: this will ofcourse dump ALL of your data.

add to del.icio.us    add to technorati favs   email this

Debian NFS HOWTO

Saturday, September 8th, 2007

apt-get install nfs-common nfs-kernel-server /etc/init.d/nfs-kernel-server restart

configure mout points in /etc/exports and when done, run

exportfs -a

If you are using ACLs, make sure you add the acl option to the exported filesystem options in exports.

add to del.icio.us    add to technorati favs   email this

Debian apt-get update fails with NO_PUBKEY A70DAF536070D3A1

Saturday, September 8th, 2007

Reading package lists… Done W: GPG error: http://ftp.debian.org etch Release: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY A70DAF536070D3A1 NO_PUBKEY B5D0C804ADB11277 W: GPG error: http://security.debian.org etch/updates Release: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY A70DAF536070D3A1 W: You may want to run apt-get update to correct these problems

Just run…

gpg --keyserver wwwkeys.eu.pgp.net --recv-keys A70DAF536070D3A1 gpg --keyserver wwwkeys.eu.pgp.net --recv-keys B5D0C804ADB11277 gpg --armor --export A70DAF536070D3A1 | apt-key add - gpg --armor --export B5D0C804ADB11277 | apt-key add -

add to del.icio.us    add to technorati favs   email this

PropelException: No connection params set for propel

Friday, August 17th, 2007

I upgraded to a newer version of Symfony today (v1.0.6) and had a hell of time getting the trivial task of connecting to the database working.

I was able to obtain a connection, by doing


$databaseManager 
= new sfDatabaseManager();
$databaseManager->initialize();
$con $databaseManager->getDatabase('propel');


but that’s not the ideal way, and not the way symfony gets the database handle.


$con 
Propel::getConnection('propel');
on the otherhand throws an excpetion.

Fatal error: Uncaught exception ‘PropelException’ with message ‘No connection params set for propel’

First, it was important to check that config/schema.xml is correct

<database name=”propel” defaultIdMethod=”native”>

And that config/databases.yml has a connection profile for propel

All that was good. But for some reason sfPropelAutoload was not geting loaded.

If I manually included it


include './lib/symfony-1.0.7/lib/addon/propel/sfPropelAutoload.php'It was clearly listed in the autoloader.yml


it would work, but still not desirable.

The following was in my autoloader config,

propel_addon: name: propel addon files: Propel: %SF_SYMFONY_LIB_DIR%/addon/propel/sfPropelAutoload.php

but it still wouldn’t load my sfPropelAutoload class. Adding the following made it start working…

symfony_orm: name: symfony orm classes files: Propel: %SF_SYMFONY_LIB_DIR%/addon/propel/sfPropelAutoload.php Criteria: %SF_SYMFONY_LIB_DIR%/vendor/propel/util/Criteria.php SQLException: %SF_SYMFONY_LIB_DIR%/vendor/creole/SQLException.php DatabaseMap: %SF_SYMFONY_LIB_DIR%/vendor/propel/map/DatabaseMap.php

add to del.icio.us    add to technorati favs   email this

Symfony - No package found for database “” in generated-schema.xml

Friday, August 17th, 2007

I was getting this error today on a new Symfony project. The problem was that I had defined the schema in the schema.xml file, but there was a conflicting schema.yml file that sat empty. Removing (

rm -f config/schema.yml
fixed my problems and propel-build-model + propel-build-sql succeeded.
Execution of target “sql-template” failed for the following reason: /home/eosterman/metaphr/trunk/lib/symfony-1.0.6/lib/vendor/propel-generator/build-propel.xml:187:1: No package found for database “” in generated-schema.xml. The propel.packageObjectModel property requires the package attribute to be set for each database. [phingcall] /home/eosterman/metaphr/trunk/lib/symfony-1.0.6/lib/vendor/propel-generator/build-propel.xml:187:1: No package found for database “” in generated-schema.xml. The propel.packageObjectModel property requires the package attribute to be set for each database.

add to del.icio.us    add to technorati favs   email this