luni, 9 mai 2011

Wireless driver and suspend

I was having problems with my wireless card when resuming from suspend. The download speed topped somewhere around 200 Kb/s whereas usually I had at least 2 Mb/s.
Rebooting the system restored the proper speed, so it was clear the suspend has something to do with it.
The solution that worked for me: I've put in /etc/pm/config.d/config this line:
SUSPEND_MODULES="ath9k"
Where ath9k is my wireless driver.
If /etc/pm/config.d/config doesn't exist, just create it and add that line (changing ath9k with whatever driver is bothering you while suspending)

duminică, 1 mai 2011

[arch] Adobe Flash x64 on Arch

The flash plugin from the Arch repository doesn't work really well on a 64 bit system (at least for me), being started within a plugin wrapper.

I tried the latest beta flash plugin form, and so far it is very stable.

To manually install the flash player use the following script:


#!/bin/sh
wget http://download.macromedia.com/pub/labs/flashplayer10/flashplayer10_2_p3_64bit_linux_111710.tar.gz -O flash.tar.gz
mkdir -p ~/.mozilla/plugins
tar -xvzf flash.tar.gz
mv libflashplayer.so ~./mozilla/plugins
rm flash.tar.gz
echo -n "Flash plugin updated"
exit 0
Hope this helped

vineri, 29 aprilie 2011

[arch] Configure CPU frequency scaling

You don't usually use your CPU at it's maximum frequency. When you install Arch, being such a malleable distribution, you don't get a CPU frequency scaler by default.

Modern CPU have frequency scaling, which means that you can configure the OS to speed up the CPU only when it needs to. This saves power and your CPU won't produce unnecessary heat.

In this article I will show you how to configure CPU Frequency scaling as a daemon, so that it starts at boot time. Note that you won't have GUI controls like gnome applets. For those please consult the link at the end of the article.

To enable frequency scaling in Arch you need to install cpufreq-utils
pacman -S cpufrequtils
After that you need to load the appropriate driver for you hardware:

  • acpi-cpufreq for Intel CPU's 
  • powernow-k10 for AMD
If these don't work for you (probably older hardware, please consult the Arch wiki for further details).

So as root:
modprobe acpi-cpufreq
Now CPU frequency scaling is enabled in you system.

Next you need to select a scaling governor. Most people go for ondemand and this is the one I will use:
modprobe cpufreq_ondemand

Just loading the kernel module isn't enough. You need to activate it in the cpufreq daemon's configuration. For this edit /etc/conf.d/cpufreq and enable your desired CPU scaling governor.

After this start the cpu scaling daemon with:
/etc/rc.d/cpufreq start

CPU scaling is now configured.

To retain these settings after a reboot edit your
/etc/rc.conf and add your  CPU scaling driver and governor to MODULES so it looks like this:

MODULES=(acpi-cpufreq cpufreq_ondemand fuse [other kernel modules])

and activate the cpufreq daemon:

DAEMONS(dbus networkmanager [other daemons] @cpufreq )

Hope this helped !


CPU Frequency Scaling [Arch Wiki]

joi, 28 aprilie 2011

[arch] Fix upside down camera in Skype

On my laptop(an Asus K52F)  the integrated webcam works out of the box in applications such as Cheese.
But when it comes to Skype, the image is upside down.

To fix this you need to install lib32-libv4l from AUR.

yaourt -S lib32-libv4l
After this create /usr/local/bin/skype with the following contents:


#!/bin/bash
LD_PRELOAD=/usr/lib32/libv4l/v4l1compat.so
export LD_PRELOAD
exec /usr/bin/skype
exit 0
And now you can launch Skype from your desktop environment and use your webcam properly.

Why it works? It has to do with the PATH environment variable.
 As /usr/local/bin precedes /usr/bin, when the system looks for "skype" it finds it in /usr/local/bin.

In the script above we specified the absolute path to the skype executable so that it knows it's not the same file ( if you would only put skype in there it would enter an infinite cycle)

miercuri, 27 aprilie 2011

Moving to Arch

After almost 4 years with Ubuntu (or other spins such as Kubuntu) and with the upcoming horror named Unity I've decided to move to ArchLinux.

Everyday I was finding myself typing in a
sudo apt-get update && sudo apt-get upgrade -y
and had a lot of PPAs so moving to a rolling release distro made sense.

I've installed  Arch x64 on my laptop and have only good things to say.
Arch detected all my hardware ( integrated webcam and microphone (which didn't work in Ubuntu 10.10!) wireless card and so on) and worked like a charm.

I am currently using GNOME3 as my desktop environment.


ArchLinux

Ubuntu

GNOME

miercuri, 23 martie 2011

Pinned tabs

Ca tot s-a lansat Firefox 4.0, am dat peste o chestie misto pentru tab-uri, numita pinned tabs.
La fel ca si taskbar-ul din Windows 7, si in browser poti sa-ti pui aplicatiile preferate sa se incarce automat si sa nu ocupe spatiu alocat unui tab normal.

Asa poti sa seta ca la pornirea browser-ului sa fie pornit automat GMail, facebook sau orice alt site web.

Treaba asta vad ca merge si pe Firefox 4 si pe Chrome 10 (stable la momentul de fata) .

Totul e gata integrat in browser, nu ai nevoie de alte extensii.





sâmbătă, 22 ianuarie 2011

Tomato

Am schimbat firmware-ul de la router-ul meu din DD-WRT in Tomato. Se simte deja diferenta. QoS-ul este mult mai bun cu Tomato, nu mai mi se blocheaza routerul si download-urile de pe torrente nu-mi sufoca toata banda de net.

Interfata de administrare este mult mai "curata" decat cea al DD-WRT-ului, continand doar setarile de bun simt pentru un home-router.

Are functii de DHCP, WDS, Bandwidth monitoring, Port Forwarding, setarea puterii de transmitere a antenei, Access Restriction.

Interfata face uz de Ajax, deci dupa modificarea unor setari paginile nu trebuiesc reincarcate (si nici routerul rebootat)

Pentru acasa/ birou mic Tomato is the way to go.

Tomato - site oficial