Set Startup Disk script

I am trying to use automator to execute either a UNIX command or apple script to change the startup disk volume on the local computer. My university wants us to allow teachers to change to the backup volume without giving them the admin password. They want me to put on the desktop an automator application that when double clicked will change the startup disk volume and restart the machine without having to type in the admin password.
Thanks Mike

See this script:
A script for restarting the computer using a specified installation of Mac OS X:
on page:
http://www.macosxautomation.com/applescript/uiscripting/index.html
Perhaps you could change the permission on the bless command. Do not know.
You could add the user to the sudoers file and grant permission to use bless as a regular user.
For this type of question, you best ask over in the hard core unix forum:
http://discussions.apple.com/forum.jspa?forumID=735
Macintosh-HD -> Applications -> Utilities -> Terminal
/usr/sbin/bless
for cryptic details...
man sudoers
/private/etc/sudoers

Similar Messages

  • Using ARD through automator application to set startup disks

    I am attempting to create an automator application/workflow that sets the startup disk of a group of remote computers and then restarts the machines. I also need to make sure that it does not pop up on the screen to enter an admin password as my university's policy is that no teachers or students have access to the password.
    My current unix command I send to the machines is
    do shell script “bless -mount /Volumes/DiskName/ -legacy -setBoot -nextonly” password “yourPassword” with administrator privileges
    do shell script “shutdown -r now” password “yourPassword” with administrator privileges
    When I send that a dialog box pops up asking for and admin password. Wondering where I am going wrong. Any input would be much appreciated

    In ARD use the Manage menu to set startup disk...
    You can force a restart and no password is required.

  • NetRestore doesn't set startup disk

    I have set up an disk image and NetInstall using NetRestore Helper, and placed the data (.nbi folder and .dmg file) in what I think is the correct place on the server. The server is running Server 10.5.x, and the image is built with 10.4.11. Using NetRestore from the client works fine until the end of the process where I get the following error: "The target disk could not be found, probably because asr failed to remount it. The restore may have failed."
    When I reboot the Mac it comes up with a flashing question mark. If I then boot from a CD or external drive however, I can go and set the startup disk to be the internal drive, and the Mac then boots and has the image installed correctly. What to I need to change to get NetRestore to set the startup disk correctly?

    Welcome to iDVD Discussions.
    Preview doesn't normally show problems. This could be a media issue. Does the DVD play the same way in your Mac and DVD player?
    Suggest you create a disc image and then burn the DVD. File/Save as Disc Image...
    http://docs.info.apple.com/article.html?path=iDVD/6.0/en/18.html
    http://www.kenstone.net/fcphomepage/image_to_diskstone.html
    This will isolate any encoding/burning issues you may encounter. Once the disc image is created, double-click the .img and burn the virtual disc that should appear on your desktop, using Toast to burn the DVD. Disk Utility to burn the .img file. Usually, you can select a burning speed in Disk Utility.
    There are variations to this process based on which OS X you are using...
    Open Disk Utility (in Utilities folder in Applications folder), click on the virtual disc (maybe the .img) in the left-hand window. Click the Burn icon. A new window should drop down and your SuperDrive tray will open after clicking the Burn icon. Insert a recordable DVD. (Verbatim DVD-R preferred by me.) Click the Close button. Wait. Select a burn speed. If you hold your mouse cursor over the pop-up it says: "Select a slower speed to work around burn failures," so select 4x or slower for best results. Then click the Burn button.
    -->If the virtual disk selection won't allow you to click the Burn icon, use the .img file instead. This may have changed in 10.3.9 and did change in Tiger.
    Also, you can use DVD Player to play the virtual disk to check your iDVD project before burning to DVD. Launch DVD Player. File/Open VIDEO_TS (Open DVD Media... in Player 4.6). Find the VIDEO_TS folder and open that. (The audio folder is for DVD-Audio disks.)
    http://docs.info.apple.com/article.html?artnum=93006

  • How do I set the Startup Disk to Boot Camp via ARD

    All,
    I typically use ARD and Set Startup Disk to image and reconfigure our lab computers (http://support.apple.com/kb/HT2789) via a network image, namely DeployStudio.  This works well.  Now I want to be able to set it to a local disk to boot into Windows 7 which we have setup with Boot Camp.  I get nothing but Failed responses.  I am hoping it is a matter of what name or format I need to use. 
    I have tried:
    BOOTCAMP
    Windows
    Windows on BOOTCAMP
    None of these work.  HELP!
    These are iMac 21.5's running 10.6.8.  ARD is 3.5.1.  Same for clients.

    have you considered using Send Unix Command to set boot Volume?
    For instance if you have "Macintosh HD" and "Boot Camp". And you wanted to set the boot volume to "Boot Camp". You could try sending the unix command, as root:
    bless -mount /Volumes/Boot\ Camp -setBoot
    After setting this, if you reboot, the computer should boot to the Boot\ Camp volume. But One the computer boots to windows, getting them to boot back to the mac os x is going to be a whole other story.
    FYI if your boot camp volume is labeled "Untitled" then you would send the unix command, as root, bless -mount /Volumes/Untitled -setBoot.

  • HD drive can't be recognized as bootable startup disk

    Hi
    I am using a MacBook with snow leopard. The HD is almost full, so I install new bigger HD. I used disk utility to restore the new disk from the old disk.
    But the mac can't recognize the new disk as bootable startup disk. I get nothing when try to set startup disk in "System Preferences". There is only "Network Startup" option is available.
    Every time start, I need to press the "Option" when I turn it on, and select the disk manually.
    What should I do? Is there a configuration file so I can set the disk to be the startup disk?

    Nihao GuoGuo & welcome to discussions.
    Your new HD needs to be set for 'GUID' before it can function as a boot drive on an Intel machine - this means for use with Snow Leopard, which requires an Intel processor, the disk must have a 'GUID primary partition map'.
    You should use the version of Disk Utility that is supplied with SL (/Applications/Utilities folder) and reformat the drive if you want to use it with your current configuration. When reformatting, create at least one partition (primary) and enable the GUID option at that time.
    Without this particular configuration, the drive will not be able to perform as a boot drive with an Intel based computer and OS X 10.6.x

  • Boot camp no longer on startup disk bless tool unable to set boot disk

    iOS 10.6.8  boot camp no longer on startup disk msg says 'bless tool unable to set boot disk'

    solved my own problem. a simple restart did the trick.

  • Help: Premiere is making my startup disk full, but I set everything to go on an external hard drive.

    The iMac I am using is for the sole purpose of editing and nothing else. I have no idea what is making my startup disk full, and I can not locate the files that are filling the startup disk except the fact that it is telling me I am running out of space. The startup disk is a 250GB SSD, the second internal drive is 1 TB HDD. All of my premiere and video files are loaded ton a 4TB G-RAID.

    Do you have your projects set to use a drive other than startup?
    My 3 hard drives to edit AVCHD are configured as...
    1 - 320Gig Boot for Win7 64bit Pro and ALL program installs
    2 - 320Gig data for Win7 paging swap file and video project files
    When I create a project on #2 drive, the various work files follow,
    so my boot drive is not used for the media cache folders and files
    3 - 1Terabyte data for all video files... input & output files

  • I have a windows 7 dvd in the drive and the mac is set to launch from the dvd drive. How do I change the startup disk?

    I have a windows 7 dvd in the drive and the mac is set to launch from the dvd drive. How do I change the startup disk?

    Hold the option key at startup and when you get to the boot panel select your Mac OS drive.

  • How do I set up an external hard drive as startup disk?

    How do I set up an external hard drive as startup disk?

    Install OS X onto the external drive. Then:
    Boot Using OPTION key:
      1. Restart the computer.
      2. Immediately after the chime press and hold down the
          "OPTION" key.
      3. Release the key when the boot manager appears.
      4. Select the external disk's icon from which you want to boot.
      5. Click on the arrow button below the icon.

  • Can I set up a startup disk for another computer?

    My mom has an iMac and apparently the internal disk has failed. Starts up with the disk and question mark, and running the Disk Utility can't access or format it.
    I was going to get an external disk for her to use as a startup disk and was wondering if I can set it up from my computer then send it to her to use with hers. I have an iBook G4 and it would be much easier for me to connect the new drive to my computer, install Mac OS X on it, set up accounts, then install updates. I have DSL and she has dialup, so downloading updates on her system literally takes all night.
    I guess I'm wondering if the installer gears the system to work with the hardware it's being run on, or if it doesn't really matter.
    Thanks for any input.
    Dan

    Dan:
    Welcome to Apple Discussions.
    If your Mom's computer supports Firewire, and meets the minimum system requirements for Tiger or the minimum system requirements for Panther depending on which system you plan to install, it should be fine. In terms of the legality, I am not sure if having the system installed on an external HDD runs afoul of the Software License Agreement which statesThis License allows you to install and use one copy of the Apple Software on a single computer at a time. This License does not allow the Apple Software to exist on more than one computer at a time...On the other hand if you Mom has the install disk and just can't get it on the internal HDD, there should be no problem.
    Please don't hesitate to post back with further questions.
    Good luck.
    corneliius

  • Set NetBoot as Startup disk

    Hello,
    was wondering if anyone knew if it is possible to use a command line to set NetBoot disk as the startup disk.
    thanks,
    Nils

    Try the instructions on this page for your specific issue.
    (16066)

  • MacPro with10.7.3. running a Python script in terminal I see a : "There is no more application memory available on your startup disk". Python uses 10G of 16G RAM and  VM =238G with 1TB free. Log: macx-swapon FAILED - 12. It only happens with larger inputs

    On my MacPro with10.7.3. while running a Python script in terminal, after a while, in several hours actually,  I see a system message for the Terminal app: "There is no more application memory available on your startup disk". Both RAM and VM appear to be fine at this point, i.e. Python uses only 10G of 16G RAM and  VM =238G with ~1TB free. Log reads: " macx-swapon FAILED - 12" multiple times. Furthermore, other terminal windows can be opened and commands run there. It only happens with larger inputs (text files), but with inputs that are about half the size everything runs smoothly.  So the issue must be the memory indeed, but where to look for the problem/fix?

    http://liulab.dfci.harvard.edu/MACS/README.html
    Have you tried with the --diag flag for diagnostics? Or changing verbose to 3 to show debug messages? Clearly one of three things is happening;
    1. You ARE running out of disk space, but once it errors out the space is reclaimed if the output file is deleted on error. When it fails, does your output have the content generated up to the point of termination?
    2. The application (Terminal) is allocated memory that you are exceeding
    3. The task within Terminal is allocated memory that you are exceeding
    I don't know anything about what this does but is there a way to maybe run a smaller test run of it? Something that takes 10 minutes? Just to see if it works.

  • Startup disk setting ignored if starting from off iMac

    In order to speed up the performance of my system (2008 iMac 2.8 Core 2 Duo - 24 inches running Yosemite (10.10.2), I have tried to start running my system off of a spare SSD in a Firewire 800 Enclosure.  Works fine when I start the computer off of a restart, but when I shut down the system and then start it up again, the iMac automatically appears to revert to the slower, internal HD.  System preferences always indicates that the external SSD is the start up disk.  No problems show up when running disk utility.  Any ideas as to how to solve this problem?

    That info is held in PRAM, so the first obvious thing to try is zapping it, and you might as well zap NVRAM at the same time. Shut down (not just a re-boot). Start up while holding down the 4 keys: Command, Option, P, R, releasing them when you hear the third 'boing'. Check Sys Prefs > Startup Disk.

  • Windows set as Default Startup Disk; How to Escape?

    My kids have been using our IMac with Windows for several years now. No problems at all.
    But today, they went into system prefs in OSX, and (!!!) selected the Windows partition as the startup disk!
    So Windows XP is booted, regardless of our attempts to escape ... (option key, PRAMzap).
    How can we get that Imac back on OSX ??
    This is an early public beta version of Bootcamp (don't see any 'bootcamp control panel' or icon on bottom right screen).

    Thanks for your suggestions - I've now tried those startup methods but (to my endless dismay) the IMac starts up Windows regardless.
    It seems like the IMac disregards these startup shortcuts when a Windows partition is selected as startup disk?
    To recap, WindowsXP boots even when holding down command-X, or CTL, or T, or Option, or PRAMzap, or Shift.
    I'm holding the Option key (yes, wired keyboard) from before powerup and all during the boot.
    Also I tried to boot from OSX disk (holding down C-key) but that likewise failed. It then took Windows a much longer to boot (as was also the case when I tried command-X).
    Can I, while running Windows, install the bootcamp stuff needed so that I have access to the Mac-disk in the Windows control panels? If so, what should I install?

  • Get name of startup disk JS

    I've got an applescript that get's the name of the startup disk using
    set macname to get name of startup disk
    I'm wondering if the same can be done in a javascript that runs in InDesign CS3....
    I need to make the scripts work across platforms and am new to Java Scripting.
    Thanks in advance for any feedback.....

    Hi Kasyan!
    This is a very old thread, but I came accross it while searching for a solution to put the name of my startup disk in front of a file path in the "ancient" notation where the folder hierarchy is represented with a ":" devider istead of the "/".
    For all lurkers here:
    When exporting to fixed layout EPUB using the epubFixedLayoutExportPreferences in InDesign CC 2014, you sometimes need this "ancient" notation when working on a Mac. In the epubFixedLayoutExportPreferences you can assign an array of file paths to external CSS and JS files. And these file paths are in the notation:
    "NameOfTheDisk:NameOfFolder:NameOfOtherFolder:external.css"
    Instead of:
    "/NameOfFolder/NameOfOtherFolder/external.css"
    If you do the folder devider with "/" and the root is simply written as a "/" at start of the file path, the export will fail to include the external CSS and JS files.
    See this thread in the Adobe InDesign EPUB Forum for example:
    Script EPUB export not including JS/CSS with epubFixedLayoutExportPreferences
    So let me thank you for this AppleScript snippet to get the name of the startup disk!!!
    I have added some lines of code to get the name of the InDesign app more accurately equal of its version number.
    I've tested this on my MacBook with OSX 10.7.5. Hope, that the AppleScript part will not break on later instances of Mac OSX.
    Here your code with my small addition:
    //Kasyan Servetsky
    //https://forums.adobe.com/message/2336686#2336686
    //Some small addition by Uwe Laubender
    var myDisk = GetStartUpDisk();
    $.writeln("The name of my start up disk is: \"" + myDisk + "\"");
    function GetStartUpDisk() {
        //Get the name of the application for Mac users:
        var myAppName = decodeURI(File(app.fullName).name).replace(/\.app$/,"");
        if (File.fs == "Macintosh") {
            var myScript = 'tell application \"Finder\"\r'
            myScript += 'set myStartUpDisk to get name of startup disk\r';
            myScript += 'end tell\r';
            /* CHANGED LINE: I replaced the original line (now commented out) with a more general approach */
            /* myScript += 'tell application \"Adobe InDesign CS' + ((parseInt(app.version.substr(0, 1)) - 2) + "") + '\"\r'; */   
            myScript += 'tell application \"'+myAppName+'\"\r';
            myScript += 'tell script args\r';
            myScript += 'set value name \"myScriptArgument\" value myStartUpDisk\r';
            myScript += 'end tell\r';
            myScript += 'end tell\r';
            app.doScript(myScript, ScriptLanguage.applescriptLanguage);
            var myStartUpDisk = app.scriptArgs.getValue("myScriptArgument");
        else if (File.fs == "Windows")  {
            var myStartUpDisk = String(Folder.system).charAt(1);
        return myStartUpDisk;
    Hm, now the question is: How can I get the name of a disk, that is not the startup disk?
    Could one of the AppleScripters here in the forum comment on that?
    All the best to you, Kasyan!
    Uwe

Maybe you are looking for

  • How to insert multiple rows in same table at once

    hi , How can I insert more than one row in the same database table on single submit button. (i am using the ADF , EJB and Toplink for this example.) EMPLOYEEand DEPARTMENT tables will hold a common coloum deptno The method I have tried is as follows.

  • Loosing Network on Peripherals

    Hello, I had a bad day, technology wise, and lost internet connection for most of the day. I am running a Mac Mini with Time Capsule connected to a cable modem for my Wi Fi. This has been just peachy and I got it back up with little stress this morni

  • Customer details

    i would like to send the material to one address A1 and send the bill to one address A2. but both are same customer number 1000 under one sales area. my question is can we create two address (shiping address and billing address) for one customer numb

  • Solaris 8 dual boot with win2k

    do i need to create 2 primary partition disks or can place either one on a logical partition on an extended dos partition? if i do need to create 2 primary partitions.. how do i do it??

  • What will happen if I try to install Fireworks on a 1024x768 display?

    I noticed the system requirements said 1280x1024, while the other CS5 apps merely recommend a screen that big and have 1024x768 as their stated minimum screen resolution.