Jump to content

Maintenance permisos y caches 1.0

Sign in to follow this  

About This File

Peque?o script que como otros nos facilitan la vida

1.-Repara permisos

2.-elimina caches

3.-crea nuevas caches

4.-actualiza update_dyld_shared_cache

Es una versi?n totalmente beta funcional, no me hago responsable de su mal uso

os paso el c?digo applescript si la mejoramos y depuramos mejor comentad:

(*Pedimos usuario y contrase?a y asignamos a las variables*)

property User_Admin : ""

display dialog "Usuario:" default answer User_Admin

set the User_Admin to text returned of the result

property Pass_Admin : ""

display dialog "Contrase?a:" default answer Pass_Admin

set the Pass_Admin to text returned of the result

(*avisamos de un ratito*)

set the_text to ("Este procesa tarda un ratito")

display dialog the_text

(*reparar permisos*)

set permissos_owners to ("chmod -R 755 /System/Library/Extensions ; chown -R root:wheel /System/Library/Extensions &")

do shell script permissos_owners password Pass_Admin user name User_Admin with administrator privileges

(*esperamos 5 segundos*)

do shell script "sleep 5"

(*Variable de comandos eliminamos todos las caches*)

set del_caches to ("rm -R /System/Library/Caches; rm -R /Users/" & User_Admin & "/Library/Caches; rm -R /Library/Caches &")

do shell script del_caches password Pass_Admin user name User_Admin with administrator privileges

(*esperamos 5 segundos*)

do shell script "sleep 5"

(*le decimos al sistema que mapee extensions*)

set touch_extensions to ("touch /System/Library/Extensions &")

do shell script touch_extensions password Pass_Admin user name User_Admin with administrator privileges

(*esperamos 5 segundos*)

do shell script "sleep 5"

set caches_extensions to ("kextcache -system-caches; kextcache -system-prelinked-kernel; kextcache -prelinked-kernel &")

do shell script caches_extensions password Pass_Admin user name User_Admin with administrator privileges

(*esperamos 5 segundos*)

do shell script "sleep 5"

set update_dly to ("update_dyld_shared_cache -force &")

do shell script update_dly password Pass_Admin user name User_Admin with administrator privileges

(*avisamos*)

set the_text to ("Seria conveniente reiniciar, ?desea reiniciar?")

display dialog the_text

set the_text to ("Esperando 10 segundos a que finalize todo")

display dialog the_text

do shell script "sleep 10"

set reboot_system to ("reboot")

do shell script reboot_system password Pass_Admin user name User_Admin with administrator privileges




User Feedback

Recommended Comments

thanks.

@@ Other small script that make our lives easier?

1.-Repair permissions?

2.-delete caches? 3.-creates new caches?

4.-updated update_dyld_shared_cache?

Beta is a fully functional version, I am not responsible for its misuse?

I pass AppleScript code if we improve and we treat best comentad:

Share this comment


Link to comment
Share on other sites

Hola no hay manera me pide user y pongo mi nombre de cuenta y en password idem mi clave ?7

y me sale usuario y contrase?a erronea ?que hago mal?

Share this comment


Link to comment
Share on other sites

En principio tendr?a que funcionar, lo he usado en todos los hakintosh y nunca me fallo, con tu usuario tienes permisos de ADMIN? si te fijas en el c?digo trabaja con shell por lo que si abres un terminal de shell y le das a "sudo" te pide password le metes, si te funciona all? ha de funcionar el script, haz la prueba abre el sheelscript copy/paste y ejecuta, tienes alg?n otro fallo, ya que la ?nica vez que me ha fallado fue por que la instalaci?n tuvo un fallo y los permisos de mi usuario estaban mal, el script est? correcto, eres superuser?

Share this comment


Link to comment
Share on other sites

Gracias ya esta funciona excelente en lion..el problema no era de permisos exactamente era el nombre de user no ponia el nombre completo jejeje !!! ahora si el error era que ponia en minusculas los campos users jejeje

Share this comment


Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Add a comment...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.