[ubuntu-it] Bookmarks che bloccano Chromium/Google Chrome in Unity e non in Kde
pacmoit a gmail.com
pacmoit a gmail.com
Dom 4 Nov 2012 13:43:33 UTC
pacmoit a gmail.com ha scritto:
> Il giorno 03 novembre 2012 17:07, [hidden email] <[hidden email]> ha
> scritto:
>
> Davide Depau ha scritto:
> >
>
> >
> >
> > Secondo me è qualcosa dovuto alla memoria... prova a fare così: apri
> > Gedit (o Kate su KDE), incolli questa roba:
> >
> > #!/usr/bin/env python
> > # *-* coding: utf-8 *-*
> >
> > import subprocess, user, os, time
> > f = open(os.path.join(user.home, "log_memoria.txt"), "a")
> > try:
> > while True:
> > f.write(time.ctime() + "\n" +
> > str(subprocess.check_output(["free", "-m"]).decode()) +
> > "-----------------------------\n")
> > f.flush()
> > time.sleep(3)
> > except KeyboardInterrupt:
> > print "Log salvato in \"{0}\"".format(fname)
> > finally:
> > f.close()
> >
> > e lo salvi nella home con il nome "mem.py". Apri il terminale e digiti
> > "python mem.py", e apri il browser. Quando si è sbloccato il computer,
> > torni al terminale e premi Ctrl+C. Copia il file "log_memoria.txt" che
> > trovi nella home da qualche altra parte, e ripeti l'operazione con KDE
> > (è importante che lo copi da un'altra parte).
> >
> > Poi allega i due file.
> >
>
> Ecco i file allegati !!!
>
>
> Mamma mia hai 16 GB di RAM... togli la swap che non ti serve a niente!
> (anzi ti serve per l'ibernazione, ma solo se ne hai almeno altrettanti
> 16...)
> Comunque, tu parlavi di un'attesa di 5 minuti... in realtà sono solo 2
> (forse meno), nei quali non faccio a meno che notare che all'avvio di
> chromium, oltre ai 4500 MB di memoria (su Unity), se ne aggiungono
> appena 400, mentre su KDE 800 (ma comunque il totale è minore, 4700 mb
> occupati contro i 4900 di Unity).
> Dato che hai 16 GB di ram, non avrei altro da consigliarti, se non
> mandarti uno script modificato che tracci anche altri valori...
> Modifica il file mem.py togliendo tutto e mettendo queste linee, quindi
> ripeti lo stesso procedimento dell'altra volta. Anzi, c'è una piccola
> differenza: dovrai specificare l'interfaccia di rete usata, che puoi
> trovare su Unity nel menu della rete, informazioni, sezione generale,
> interfaccia, e nel plasmoide della rete su KDE. Di solito è wlan0 per la
> rete wifi e eth0 per quella cablata. Quindi il comando sarà "python
> mem.py wlan0" oppure "python mem.py eth0".
> Ecco il codice aggiornato (con font diverso):
>
> #!/usr/bin/env python
> # *-* coding: utf-8 *-*
>
> import subprocess, user, os, time, sys
> try:
> a = sys.argv[1]
> except IndexError:
> print "Uso: python {0} <interfaccia>\n\nDevi specificare
> l'interfaccia di rete usata:\ndi solito è wlan0 per la rete wireless e
> eth0 per quella cablata.\n".format(sys.argv[0])
> raise SystemExit
>
> f = open(os.path.join(user.home, "log_memoria.txt"), "a")
> try:
> while True:
> memory = str(subprocess.check_output(["free",
> "-m"]).decode()).replace("Mem:", " ").replace(" ", "\t",
> 2).split("\n")[0:2]
> print memory
> to_append = "Memoria:\n" + memory[0] + "\n" + memory[1]
> cpu = str(subprocess.check_output("ps aux|awk 'NR > 0 { s +=$3
> }; END {print s}'", shell=True).decode())
> to_append += "\nUtilizzo
> CPU:\n\t{0}%\n".format(cpu.replace("\n", ""))
> r1 = float(subprocess.check_output(["cat",
> "/sys/class/net/{0}/statistics/rx_bytes".format(sys.argv[1])]).decode())
> t1 = float(subprocess.check_output(["cat",
> "/sys/class/net/{0}/statistics/tx_bytes".format(sys.argv[1])]).decode())
> time.sleep(1)
> r2 = float(subprocess.check_output(["cat",
> "/sys/class/net/{0}/statistics/rx_bytes".format(sys.argv[1])]).decode())
> t2 = float(subprocess.check_output(["cat",
> "/sys/class/net/{0}/statistics/tx_bytes".format(sys.argv[1])]).decode())
> to_append += "Rete:\n\tTrasmessi: {0} KB/s\tRicevuti: {1}
> KB/s\n\n".format((t2-t1)/1024, (r2-r1)/1024)
> to_append = "######################## {0}
> #######################\n".format(time.ctime()) + to_append
> f.write(to_append)
> f.flush()
> time.sleep(2)
> except KeyboardInterrupt:
> print "Log salvato in \"{0}\"".format("log_memoria.txt")
> finally:
> f.close()
>
Ecco gli altri file, come vedrai il tempo di attesa è molto più lungo di
2 minuti e supera i 5. Questo perchè con Chromium siamo vicini a 2
minuti di attesa, mentre con Google Chrome superiamo i 5
Ho compresso quello di unity altrimenti non mi veniva passato dalla
lista superando i 40Kb
Intanto grazie !!!
-------------- parte successiva --------------
######################## Sun Nov 4 11:28:12 2012 #######################
Memoria:
total used free shared buffers cached
16017 3450 12567 0 354 1672
Utilizzo CPU:
54.4%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.0 KB/s
######################## Sun Nov 4 11:28:15 2012 #######################
Memoria:
total used free shared buffers cached
16017 3936 12081 0 354 1673
Utilizzo CPU:
460.3%
Rete:
Trasmessi: 10.7470703125 KB/s Ricevuti: 40.7919921875 KB/s
######################## Sun Nov 4 11:28:18 2012 #######################
Memoria:
total used free shared buffers cached
16017 4188 11828 0 354 1684
Utilizzo CPU:
251.6%
Rete:
Trasmessi: 5.541015625 KB/s Ricevuti: 18.51171875 KB/s
######################## Sun Nov 4 11:28:21 2012 #######################
Memoria:
total used free shared buffers cached
16017 4206 11810 0 354 1685
Utilizzo CPU:
200.1%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.0 KB/s
######################## Sun Nov 4 11:28:24 2012 #######################
Memoria:
total used free shared buffers cached
16017 4212 11805 0 354 1684
Utilizzo CPU:
181.1%
Rete:
Trasmessi: 0.36328125 KB/s Ricevuti: 0.154296875 KB/s
######################## Sun Nov 4 11:28:27 2012 #######################
Memoria:
total used free shared buffers cached
16017 4159 11858 0 355 1684
Utilizzo CPU:
168.8%
Rete:
Trasmessi: 1.1298828125 KB/s Ricevuti: 4.677734375 KB/s
######################## Sun Nov 4 11:28:30 2012 #######################
Memoria:
total used free shared buffers cached
16017 4141 11875 0 355 1684
Utilizzo CPU:
161.7%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.08984375 KB/s
######################## Sun Nov 4 11:28:33 2012 #######################
Memoria:
total used free shared buffers cached
16017 4198 11819 0 355 1684
Utilizzo CPU:
156.6%
Rete:
Trasmessi: 0.123046875 KB/s Ricevuti: 0.9375 KB/s
######################## Sun Nov 4 11:28:36 2012 #######################
Memoria:
total used free shared buffers cached
16017 4208 11809 0 355 1684
Utilizzo CPU:
151.9%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.0 KB/s
######################## Sun Nov 4 11:28:39 2012 #######################
Memoria:
total used free shared buffers cached
16017 4207 11810 0 355 1684
Utilizzo CPU:
148.3%
Rete:
Trasmessi: 0.318359375 KB/s Ricevuti: 0.3037109375 KB/s
######################## Sun Nov 4 11:28:42 2012 #######################
Memoria:
total used free shared buffers cached
16017 4177 11840 0 355 1684
Utilizzo CPU:
145.2%
Rete:
Trasmessi: 0.087890625 KB/s Ricevuti: 0.146484375 KB/s
######################## Sun Nov 4 11:28:45 2012 #######################
Memoria:
total used free shared buffers cached
16017 4233 11784 0 355 1685
Utilizzo CPU:
162.3%
Rete:
Trasmessi: 0.234375 KB/s Ricevuti: 1.92578125 KB/s
######################## Sun Nov 4 11:28:48 2012 #######################
Memoria:
total used free shared buffers cached
16017 4219 11797 0 355 1685
Utilizzo CPU:
195.7%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.0 KB/s
######################## Sun Nov 4 11:28:51 2012 #######################
Memoria:
total used free shared buffers cached
16017 4216 11801 0 355 1685
Utilizzo CPU:
161%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.0 KB/s
######################## Sun Nov 4 11:28:54 2012 #######################
Memoria:
total used free shared buffers cached
16017 4218 11799 0 355 1687
Utilizzo CPU:
151.1%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.05859375 KB/s
######################## Sun Nov 4 11:28:57 2012 #######################
Memoria:
total used free shared buffers cached
16017 4219 11798 0 355 1688
Utilizzo CPU:
145.5%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.0 KB/s
######################## Sun Nov 4 11:29:01 2012 #######################
Memoria:
total used free shared buffers cached
16017 4219 11798 0 355 1688
Utilizzo CPU:
141.6%
Rete:
Trasmessi: 0.2578125 KB/s Ricevuti: 0.2578125 KB/s
######################## Sun Nov 4 11:29:04 2012 #######################
Memoria:
total used free shared buffers cached
16017 4221 11796 0 355 1688
Utilizzo CPU:
139%
Rete:
Trasmessi: 0.31640625 KB/s Ricevuti: 1.09765625 KB/s
######################## Sun Nov 4 11:29:07 2012 #######################
Memoria:
total used free shared buffers cached
16017 4221 11795 0 355 1688
Utilizzo CPU:
136.4%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.0 KB/s
######################## Sun Nov 4 11:29:10 2012 #######################
Memoria:
total used free shared buffers cached
16017 4223 11794 0 355 1688
Utilizzo CPU:
135%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.0 KB/s
######################## Sun Nov 4 11:29:13 2012 #######################
Memoria:
total used free shared buffers cached
16017 4222 11794 0 355 1688
Utilizzo CPU:
133.5%
Rete:
Trasmessi: 0.421875 KB/s Ricevuti: 0.87890625 KB/s
######################## Sun Nov 4 11:29:16 2012 #######################
Memoria:
total used free shared buffers cached
16017 4224 11793 0 355 1688
Utilizzo CPU:
132.4%
Rete:
Trasmessi: 0.10546875 KB/s Ricevuti: 0.2197265625 KB/s
######################## Sun Nov 4 11:29:19 2012 #######################
Memoria:
total used free shared buffers cached
16017 3664 12353 0 355 1676
Utilizzo CPU:
128.4%
Rete:
Trasmessi: 1.78125 KB/s Ricevuti: 1.0576171875 KB/s
######################## Sun Nov 4 11:29:22 2012 #######################
Memoria:
total used free shared buffers cached
16017 3638 12379 0 355 1676
Utilizzo CPU:
27.1%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.08984375 KB/s
######################## Sun Nov 4 11:29:25 2012 #######################
Memoria:
total used free shared buffers cached
16017 3627 12390 0 355 1676
Utilizzo CPU:
25.8%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.08984375 KB/s
######################## Sun Nov 4 11:29:28 2012 #######################
Memoria:
total used free shared buffers cached
16017 3705 12312 0 355 1748
Utilizzo CPU:
25%
Rete:
Trasmessi: 0.0 KB/s Ricevuti: 0.08984375 KB/s
######################## Sun Nov 4 11:31:26 2012 #######################
Memoria:
total used free shared buffers cached
16017 4370 11647 0 358 2040
Utilizzo CPU:
51.5%
Rete:
Trasmessi: 7.12109375 KB/s Ricevuti: 118.536132812 KB/s
######################## Sun Nov 4 11:31:29 2012 #######################
Memoria:
total used free shared buffers cached
16017 4853 11164 0 358 2043
Utilizzo CPU:
390.8%
Rete:
Trasmessi: 9.2314453125 KB/s Ricevuti: 25.146484375 KB/s
######################## Sun Nov 4 11:31:32 2012 #######################
Memoria:
total used free shared buffers cached
16017 5018 10999 0 358 2054
Utilizzo CPU:
204.7%
Rete:
Trasmessi: 2.6796875 KB/s Ricevuti: 3.306640625 KB/s
######################## Sun Nov 4 11:31:35 2012 #######################
Memoria:
total used free shared buffers cached
16017 5019 10997 0 358 2054
Utilizzo CPU:
144%
Rete:
Trasmessi: 0.61328125 KB/s Ricevuti: 1.1845703125 KB/s
-------------- parte successiva --------------
Un allegato non testuale è stato rimosso....
Nome: log_memoria.unity.txt.zip
Tipo: application/zip
Dimensione: 2430 bytes
Descrizione: non disponibile
URL: <https://lists.ubuntu.com/archives/ubuntu-it/attachments/20121104/cb44300d/attachment.zip>
Maggiori informazioni sulla lista
ubuntu-it