Debian: dist-upgrade sarge to etch

Lo so ora c’è Lenny ma a volte capita che alcuni clienti stiano ancora su vecchie release e che abbiano bisogno di qualche feature in piu’ disponibile nelle versione successiva.

Ecco come fare un salto di release in piena tranquillità.

Per prima cosa sulla Sarg aggiornare all’ultimo patchlevel usando i nuovi repository in /etc/apt/source.list:

##SARGE (Oldstable)
deb http://archive.debian.org/debian/ sarge main contrib non-free
deb-src http://archive.debian.org/debian/ sarge main contrib non-free

##SECURITY UPDATES (Sarge)
deb http://archive.debian.org/debian-security/  sarge/updates main contrib non-free
deb-src http://archive.debian.org/debian-security/ sarge/updates main contrib non-free

A questo punto:

apt-get update
apt-get dist-upgrade
reboot

Ora commentiamo i repository di Sarg ed aggiungiamo quelli di Etch:

deb http://debian.fastweb.it/debian/ etch main non-free
deb-src http://debian.fastweb.it/debian/ etch main non-free

deb http://security.debian.org/ etch/updates main contrib
deb-src http://security.debian.org/ etch/updates main contrib

Poi:

apt-get update
apt-get dist-upgrade NB: Non fate riavviare il servizio ssh che potrebbe non tornare su!!!

Ora installate il nuovo kernel:

apt-get install linux-image-2.6-686

Ed infine:

reboot

Io l’ho fatto di Venerdì 17 e l’ho riavviato alle 17.17 e la macchina è tornata su!!!!

Firefox 3: ottimizzare il DB ( Linux e Mac )

Come ha già detto Gioxx è possibile ottimizzare i DataBase SQLite usati da Firefox 3.x per avere un avvio piu’ veloce del browser.

Gioxx ha descritto su come farlo in Windows, io vi mostrerò come farlo su Mac e Linux.

Per prima cosa chiudete firefox, non deve assolutamente essere in esecuzione!
Ora potete aprire un Terminale ed entrare nel vostro profilo:

Linux: ~/.mozilla/firefox/xxxxxxxx.default/
Mac: ~/Library/Application Support/Firefox/Profiles/xxxxxxxx.default/

Switch@bimbo:~$ cd Library/Application\ Support/Firefox/Profiles/xxxxxxxx.default/

Switch@bimbo:~/Library/Application Support/Firefox/Profiles/xxxxxxxx.default$ ls -lah *.sqlite
-rw-r–r–@ 1 Switch  staff   7,0K 19 Mag  2008 content-prefs.sqlite
-rw-r–r–@ 1 Switch  staff   511K 16 Lug 08:49 cookies.sqlite
-rw-r–r–@ 1 Switch  staff   203K 15 Lug 22:14 downloads.sqlite
-rw-r–r–@ 1 Switch  staff   3,0K  3 Lug 21:09 dta_queue.sqlite
-rw-r–r–@ 1 Switch  staff   119K 15 Lug 22:02 formhistory.sqlite
-rw-r–r–@ 1 Switch  staff   2,0K 11 Giu 10:22 permissions.sqlite
-rw-r–r–@ 1 Switch  staff    17M 16 Lug 08:45 places.sqlite
-rw-r–r–@ 1 Switch  staff   2,0K 29 Mar  2008 search.sqlite
-rw-r–r–@ 1 Switch  staff    70K 16 Lug 08:07 signons.sqlite
-rw-r–r–@ 1 Switch  staff   4,0M 15 Giu  2008 urlclassifier2.sqlite
-rw-r–r–@ 1 Switch  staff   2,0K 18 Ott  2008 webappsstore.sqlite

Ora useremo il comando VACUUM di sqlite3 per ottimizzare il db

Switch@bimbo:~/Library/Application Support/Firefox/Profiles/xxxxxxxx.default$ for F in *.sqlite; do sqlite3 $F “VACUUM”; done

Switch@bimbo:~/Library/Application Support/Firefox/Profiles/xxxxxxxx.default$ ls -lah *.sqlite
-rw-r–r–@ 1 Switch  staff   7,0K 16 Lug 08:58 content-prefs.sqlite
-rw-r–r–@ 1 Switch  staff   373K 16 Lug 08:58 cookies.sqlite
-rw-r–r–@ 1 Switch  staff   157K 16 Lug 08:58 downloads.sqlite
-rw-r–r–@ 1 Switch  staff   3,0K 16 Lug 08:58 dta_queue.sqlite
-rw-r–r–@ 1 Switch  staff    47K 16 Lug 08:58 formhistory.sqlite
-rw-r–r–@ 1 Switch  staff   2,0K 16 Lug 08:58 permissions.sqlite
-rw-r–r–@ 1 Switch  staff   6,5M 16 Lug 08:58 places.sqlite
-rw-r–r–@ 1 Switch  staff   2,0K 16 Lug 08:58 search.sqlite
-rw-r–r–@ 1 Switch  staff    69K 16 Lug 08:58 signons.sqlite
-rw-r–r–@ 1 Switch  staff   2,7M 16 Lug 08:58 urlclassifier2.sqlite
-rw-r–r–@ 1 Switch  staff   2,0K 16 Lug 08:58 webappsstore.sqlite

L’esempio è su un Mac ma è esattamente uguale a Linux, cambia solo il percorso del profilo.

In alcune distribuzioni Linux, sqlite3, non è presente per cui dovete scaricarlo dai repository ufficiali della vostra distro.

Come potete notare il DB piu’ “ciccione” di 17MB è stato compresso fino a 6,5MB per cui piu’ del 50%!

Un po’ di me


Omar on Twitter Omar on Facebook Omar on LinkedIn

Eventi


    ..Coming Soon..

Qualche foto da Flickr

Calendar

July 2009
M T W T F S S
« Jan   Aug »
 12345
6789101112
13141516171819
20212223242526
2728293031