Posts de Janeiro, 2007

h1

(English) Ubuntu 6.10 + ATI Radeon + XGL + Beryl

27 Janeiro 2007

Hi there,

In order to help the international comunity that find my site using search engines, I will post here the English version of my Ubuntu 6.10 + ATI Radeon + XGL + Beryl tutorial.

This is the way that I found to XGL + Beryl work on my Ubuntu 6.10 (Edgy Eft) with ATI Radeon 9200, but I belive that this tutorial works for any ATI video card. The fglrx is not supported and need to be removed.

Well, enough talking, let’s get to work!

1- INSTALLING XGL AND GRAPHIC ACCELERATOR

1.1- Disable “Composite”

Open a terminal and do the following:
sudo gedit /etc/X11/xorg.conf

Add these lines at the end:
Section "Extensions"
Option "Composite" "0″
EndSection

1.2 – Enable the aditional repositories

Open sources.list this way:
sudo gedit /etc/apt/sources.list

look for these lines:
#deb http://security.ubuntu.com/ubuntu edgy-security main restricted
#deb-src http://security.ubuntu.com/ubuntu edgy-security main restricted

and remove the “#”. Close it and save.

1.3 – Finishing the video driver installation

Do the following in a terminal, this will update your distribution, install the restricted modules for your kernel, the “fglrx” ATI driver and configure your xorg.conf to use the new driver.

sudo apt-get update
sudo apt-get install linux-restricted-modules-$(uname -r)
sudo apt-get install xorg-driver-fglrx
sudo depmod -a
sudo aticonfig –initial
sudo aticonfig –overlay-type=Xv

With this done, you can restart your system and the ATI driver will be working.

2- INSTALLING THE FREE DRIVER OF ATI

2.1- Removing the “fglrx” from ATI

Now that we installed the drivers, we need to remove it! We installed “fglrx” to make the right adjustments to the xorg.conf. To remove the drivers, we need to open Synaptic and remove every package with “fglrx” and “linux-restricted-modules”.

But, if any device that you have needs the restricted modules, an alternative is to only deactivate the fglrx (if you don’t need it, jump to the next step):

run:
sudo gedit /etc/default/linux-restricted-modules-common

in the bottom, find:
DISABLED_MODULES=""

and change to:
DISABLED_MODULES="fglrx"

2.2- Installing the free drivers of ATI:

Open the terminal and just:
sudo apt-get install xserver-xorg-video-ati

2.3- Editing xorg.conf

To activate the driver, with the already configured xorg.conf with the “fglrx” driver, just look on your xorg.conf for the section Device and change the string on the line Driver to “radeon”. In my case, the section Device will be:

Section "Device"
Identifier "ATI Technologies, Inc. RV280 [Radeon 9200 SE]"
Driver "radeon"
BusID "PCI:1:0:0"
Option "UseFBDev" "true"
Option "EnablePageFlip"
Option "ColorTiling"
EndSection

Restart and now you will have the free ATI driver working.

3 – INSTALLING XGL AND BERYL.

3.1 – Adding the repository

Open and edit sources.list with:
sudo gedit /etc/apt/sources.list

and add the following:
deb http://www.beerorkid.com/compiz edgy main-edgy
salve e feche.

Download the key and add it doing this:
wget http://www.beerorkid.com/compiz/quinn.key.asc -O - | sudo apt-key add -

Update your apt-get:
sudo apt-get update

3.2 – Downloading the packager

Downloading the packages for XGL and Beryl:
sudo apt-get install xserver-xgl libgl1-mesa xserver-xorg libglitz-glx1 beryl beryl-core beryl-manager beryl-plugins beryl-plugins-data beryl-settings emerald emerald-themes

4- CREATING A SESSION FOR XGL

Ok, all done! But wait, now we need to add a session for XGL on your Ubuntu.

4.1 – Creating a initialization script

Make a new file:
sudo gedit /usr/bin/startgnomexgl.sh

and we add:
#!/bin/sh
Xgl -fullscreen :1 -ac -accel glx:pbuffer -accel xv:pbuffer &
sleep 2
export DISPLAY=:1
exec gnome-session

and make it executable with:
sudo chmod +x /usr/bin/startgnomexgl.sh

4.2 – Adding the session to your login at GDM – GNOME Display Manager

run:
sudo gedit /usr/share/xsessions/xgl.desktop

in the file, paste the following:
[Desktop Entry]
Encoding=UTF-8
Name=Xgl
Comment=Start an Xgl Session
Exec=/usr/bin/startgnomexgl.sh
Icon=
Type=Application

save and close it.

5 – TESTING

Now it good to go! Close your session and in the login screen click in “Options” and “Choose Session…”. Choose XGL and start.

If your Gnome looks “old”, without style, run “gnome-settings-daemon”. To start Beryl, run “beryl-manager”. If you see the Beryl splash screen, congratulations!

I hope this english version of my tutorial help you to install XGL/Beryl! Sorry for any possible english mistakes. If you have some comment about the tutorial (or maybe about my english!), I will be happy to hear it.

See ya!

- Ivan Odintsoff

h1

Comandos básicos de Linux

9 Janeiro 2007

Olá novamente.E venho de novo com mais um tutorialzinho, desta vez mais basico, de Linux. Sei lá, vendo o ”sucesso” que fez meu tutorial (ou “O passo-a-passo de como eu consegui botar o Beryl para funcionar no Ubuntu”) eu acabei me empolgando e decidi neste post em ajudar com o conhecimento que tenho de Linux (embora ele seja médio) as pessoas que estão iniciando no Linux.

E inicio isso com algo que algumas pessoas me pedem, uma listazinha de comandos
básicos do Linux (modo Texto/Shell, claro). Vou fazer, quando possível, uma analogia entre o comando Linux e algum possivel equivalente do “Prompt de Comando” do Windows/MS-DOS para aqueles que estão migrando do Windows para o Linux.

Observação: A Shell do Linux diferencia letras maiúsculas de minúsculas. O arquivo “Teste” é diferente de ”teste”.
Portanto, deve se digitar os comandos e seus parametros da forma que aparecem.
Entre colchetes estão os argumentos necessários, lembre-se que não deve se incluir os colchetes no comando, eles são somente para melhor vizualização.

Então, vamos a um breve resumo de alguns comandos que considero básicos:

  • ls
    mostra o conteúdo do diretório atual. Equivalente ao “dir” do DOS.
    Alguns dos parametros importantes (devem seguir o comando, Ex: ls -a):
    -a : exibe todos arquivos/diretorios, incluindo ocultos (que iniciam com . )
    -l : exibe em formato lista
    -R : lista subdiretórios recursivamente
    -S : Ordena de acordo com o tamanho dos arquivos
  • cd [diretório]
    Abre o diretório especificado. Para ir para sua pasta pessoal, basta digitar “cd”. Mesma função que “cd” do Windows/DOS.
  • mkdir [diretório]
    Cria um diretório com o nome especificado. (“md” do Windows).
  • cp [origem] [destino]
    Copia o arquivo “origem” para o “destino” indicado. (“copy” do Windows).
  • mv [origem] [destino]
    Move “origem” para o diretório de “destino”.
  • rmdir [diretório]
    Remove o diretório especificado, desde que ele esteja vazio.
  • rm [parametros] [arquivo]
    Exclui o arquivo especificado. Alguns parametros úteis são:
    -i : Pede confirmação antes de excluir qualquer arquivo/diretório.
    -r : Remove diretórios e seus conteúdos recursivamente.
  • cat [arquivo]
    Exibe o conteúdo do arquivo. Equivalente ao comando “type” do Windows/DOS.
  • clear
    Limpa a tela. Como “cls” no prompt do comando do Windows.
  • df
    Mostra partições/dispositívos montados e seu uso.
  • du [diretório]
    Mostra espaço ocupado por determinado diretório.
  • free
    Mostra quantidade de memória RAM e Swap livre.
  • chmod [quem]=[permisões] [arquivo]
    Altera as permissões de arquivos e diretórios. Ele garantem a [quem] as determinadas [permisões] ao [arquivo] especificado. Onde:
    [quem] pode ser:
    u : o usuário a quem pertence o arquivo.
    g : o grupo a quem pertence o arquivo.
    o : outros usuários.
    a : todas as opções acima.

    [permisões] podem ser:
    r : permisão para ler o arquivo (r de read)
    w : permisão para escrever no arquivo (w de write)
    x : permisão para executar o arquivo (x de eXecute).

  • file [arquivo]
    Mostra informações sobre o tipo do arquivo.
  • find [diretório] [parâmetro] [termo]
    O comando find serve para localizar informações. Para isso, deve-se digitar o comando seguido do diretório da pesquisa mais um parâmetro (ver lista abaixo) e o termo da busca.name : busca por nome
    type : busca por tipo
    size : busca pelo tamanho do arquivo
    mtime : busca por data de modificação
  • grep [palavra] [arquivo ou grupos de arquivos]
    Busca pela palavra especificada nos arquivos desejados. Pode-se usar ele em conjunto com um outro comando (Ex: ls) para filtrar seu resultado, bastando usar o “pipe” ( | ). Exemplo: ls | grep teste irá mostrar todas as linhas do comando “ls” que contem a palavra “teste”, ou seja, todos os arquivos que contenham a palavra “teste” em seu nome.
  • ps
    Lista processos em execução. O argumento mais utilizado é “aux”, que faz o ps listar todas as informações sobre todos os processos executados.
  • kill [PID]
    Mata o processo do PID especificado. Para saber o PID de um processo, utilize o comando “ps” descrito acima.
  • killall [nome do processo]
    Mesmo que o kill, mas mata o processo do nome especificado, sem precisar do PID.
  • useradd [usuário]
    Adiciona usuário especificado.
  • userdel [usuário]
    Remove o usuário.
  • passwd
    Altera sua senha. Para um administrador mudar a senha de um usuário, basta digitar passwd seguido do nome do usuário desejado.
  • shutdown [argumento] [tempo]
    Reinicia ou desliga o computador.
    -r : reinicia o computador
    -h : desliga o computadorSe no local do tempo for especificado a palavra “now”, ele irá desligar/reiniciar imediatamente.
  • cal
    Exibe um calendário.
  • date
    Exibe data e hora atual.

Acredito que seja o suficiente, talvez com o tempo eu vá editando e adicionando outros comandos que ache necessário. Em breve pretendo fazer um post melhor descrevendo o uso dos compactadores tar e gzip. Até breve!