Debian upgrade from lenny to squeeze and default shell

All of you who are planning an upgrade from Debian lenny to squeeze should take into consideration that Squeeze is using another default shell – “dash”. So make sure all your scripts created with #!/bin/sh are working on the new shell or just change the symlink for /bin/sh to bash.

I have encountered this problem while upgrading a whole bunch of servers and when I run the deployment scripts created with /bin/sh they didn’t work. It took me quite a while to figure it out, so I’m sharing this to others who might run into the same situation.

Or make sure you read all the screens when you upgrade and don’t change default shell to dash. Keep bash.

26/01/2012 at 17:34 Leave a comment

80.000

Nu a aparut nici un greieras inca in interior, nimic nu s-a miscat de la locul lui, scaunele inca nu s-au lasat. Daca povestea cu consumul de ulei nu ar mai fi continuat m-as fi incadrat intre clientii multumiti ai marcii.

Din pacate continua si nici macar service-urile germane nu au putut face nimic cu asta. Scrie in cartea de service (chiar si in cea germana) ca poate consuma pana la 1 litru la 1000 de km. Nu e chiar atat de mare consumul dar totusi, as fi preferat 1 litru la 10.000. In fine, sa fie asta singurul motiv pentru care deschid capota, in afara de completarea lichidului de parbriz. Problema a fost adresata la dealearul local, care au sunat la reprezentanta Germana de unde am primit acelasi raspuns. Chiar si la marele salon am primit acelasi raspuns de la departamentul de Suport Clienti.

Comportamentul a ramas impecabil, drumul pe autostrada e o placere, iar 3-4 ore de condus fara pauza trec fara sa simti vreo durere de spate. As zice totusi ca suportul lombar nu e chiar pozitionat corect pentru europeni, sau poate sunt eu prea scund. Pasagerii nu s-au plans inca de lipsa de spatiu (nu ca s-ar simti mai putin spatiu cu inaintarea in kilometri), sistemul de sunet functioneaza fara pacanituri (desi am auzit ca unele au probleme la capitolul asta) iar tapiteria nu s-a uzat inca.

Despre motor ce sa zic, isi face treaba, la fel ca si cutia, si nu consuma prea multa benzina. Media a fost 7.7 litri/100 km in ultimii 10.000 km. Nici consumabile prea multe nu a uzat, doar un set de placute spate pe la vreo 70k km, in afara de schimbul de ulei si filtre.

As fi avut numai cuvinte de lauda daca nu era problema cu uleiul, dar m-am invatat sa traiesc si cu asta. Poate la facelift au rezolvat problema asta.

La 60.000 nu am apucat sa scriu un mic review, asa ca ultimul articol e de pe la 40.000 aici.

21/12/2011 at 15:42 Leave a comment

warning: setlocale: LC_CTYPE: cannot change locale (UTF-8)

Do you get this error when trying to autocomplete a command using TAB on Ubuntu 10.04?

Here is a quick solution for getting rid of this:

Edit /etc/default/locale and add the following line:

LC_ALL=”en_GB.UTF-8″

If you don’t want to reboot the server, then issue the following command:

export LC_ALL=”en_GB.UTF-8″

01/11/2011 at 15:29 Leave a comment

debian-sa1 fails after update

Here is a quick solution for fixing the cron error:

command -v debian-sa1 > /dev/null && debian-sa1 1 1 (failed)

Edit /etc/default/sysstat on the line SA1_OPTIONS=”-d”, changing “-d” with ”-S DISK”

This is because some sadc options were renamed in the recent version.

28/07/2011 at 11:00 Leave a comment

Restarting nagios from puppet on Debian

If you’re struggling with writing a puppet module for nagios client then here is a line you need to add to your service definition:

hasstatus  => false,

Without this puppet will try to start nrpe every time unless restarting it.

Here is the complete definition:

service { "nagios-nrpe-server":
        name       => "nagios-nrpe-server",
        ensure     => running,
        enable     => true,
        hasstatus  => false,
        pattern    => "/usr/sbin/nrpe",
        require    => Package["nagios-nrpe-server"],
        subscribe  => [Package["nagios-nrpe-server"], File["/etc/nagios/nrpe.cfg"] ],
    }

22/07/2011 at 12:26 1 comment

Virtualbox ACPI Shutdown on Ubuntu Lucid Lynx

If you have already installed Virtualbox additions to your Ubuntu 10.04 guest and when you click ACPI Shutdown nothing happens, then you must install the package that contains the scripts for handling many ACPI events:

apt-get update

apt-get install acpi-support

13/02/2011 at 15:04 Leave a comment

Proftpd on amazon ec2

Installing proftpd on an amazon ec2 instance is not rocket science, but after installing you need to configure it to work correct.Because amazon ec2 instances use an internal IP address as their ethernet interface address, proftpd needs to be configured for passive FTP.

First, you need to apply for an Elastic IP address which you will allocate to your instance. This will be the IP address that will be show to the world.

Second step is to configure the firewall properly for that instance. Go to the “Security group” assigned to the instance and add the following rules:

  • Connection Method: Custom
  • Protocol: TCP
  • From Port: 20
  • To Port: 21
  • Source (IP or group): 0.0.0.0/0 (that is, if you want to permit to the whole internet to access your ftp server; if not, replace this with the IP address or class that you want to give access to your ftp server)

We need to add another rule for the passive ports that will be used by proftpd:

  • Connection Method: Custom
  • Protocol: TCP
  • From Port: 49152
  • To Port: 65535
  • Source (IP or group): 0.0.0.0/0

Now, go to your machine end edit /etc/proftpd/proftpd.conf and add the following lines:

PassivePorts 49152 65535

MasqueradeAddress  your_elastic_ip_address

Restart proftpd and enjoy:

/etc/init.d/proftpd restart

02/02/2011 at 22:43 2 comments

Vmware server 2 performance problems

The only settings that had any effect on my system were taken from this link:

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=844

11/09/2010 at 18:26 Leave a comment

Solution for error: /usr/bin/mandb: can’t set the locale; make sure $LC_* and $LANG are correct

Cron sends an email every day with the errors that were in the jobs processed. I got this one:

/etc/cron.daily/man-db:
/usr/bin/mandb: can’t set the locale; make sure $LC_* and $LANG are correct
Here is the solution. You need to generate locales for your $LANG defined in this file: /etc/environment. Here is how mine looks:
LANG=”en_GB.UTF-8″
PATH=”/opt/ruby-enterprise/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin”
The locale generated for the system is in this file: /etc/default/locale.
So, run dpkg-reconfigure locales and choose en_GB.UTF-8, disable all others, in the next screen choose en_GB.UTF-8 as default, and this should solve the problem.

27/08/2010 at 10:54 2 comments

Error when installing gem on debian lenny

Got this eror when trying to install a ruby gem?

ERROR:  could not find gem “your_gem” locally or in a repository

Then your rubygems most probably is outdated. I spent couple of hours searching the internet for a solution regarding this problem and found anything then what I needed. Finally I found the solution: update rubygems.

Dowload rubygems and rubygems1.8 packages from debian backports:

cd /tmp

wget http://backports.mithril-linux.org/pool/main/libg/libgems-ruby/rubygems1.8_1.3.4-1~bpo50+1_all.deb

wget http://backports.mithril-linux.org/pool/main/libg/libgems-ruby/rubygems_1.3.4-1~bpo50+1_all.deb

dpkg -i /tmp/rubygems1.8_1.3.4-1~bpo50+1_all.deb

dpkg -i /tmp/rubygems_1.3.4-1~bpo50+1_all.deb
After this you can go on installing your gem.

26/08/2010 at 17:31 Leave a comment

Older Posts


 

January 2012
M T W T F S S
« Dec    
 1
2345678
9101112131415
16171819202122
23242526272829
3031  

Follow

Get every new post delivered to your Inbox.

Join 31 other followers