View Full Version : Run Terminal Command as root on Startup

Aug 2, 2012, 01:06 AM
Hi guys,

Can anyone help me run a terminal command at startup, but as the root user, in 10.8? I have recently bought an OCZ SSD that is having trouble with Mountain Lion, but have found a temporary workaround, that involves deleting a file between one boot and the next. (see here (http://www.ocztechnologyforum.com/forum/showthread.php?103522-Mountain-Lion-Boot-issues-Octane-Petrol-OctaneS2&p=746778&viewfull=1#post746778))

The command I need to run is as follows, and as stated I would like to run this at startup.

sudo rm -f /private/var/db/BootCache.playlist

I can enter the password if need be, but would obviously prefer I didn't have to.

Thanks in advance.

Aug 2, 2012, 01:25 AM
Apparently you can use visudo to edit /etc/sudoers to add your own user to Sudo. Probably a bad idea though.