Setting up Mac OS X for remote inventory ---------------------------------------- (It is recommended to copy and paste commands for the Terminal!) 1. Open the link https://prism.akvelon.net:8441/inventory/ 2. Download GetInventoryMac.sh 3. Create working folders: mkdir ~/TNI mkdir ~/TNI/Send 4. Move the GetInventoryMac.sh file to the ~/TNI/ folder mv ~/Downloads/GetInventoryMac.sh ~/TNI/ 5. Set file permissions: chmod +x ~/TNI/GetInventoryMac.sh 6. We start collecting information: ~/TNI/GetInventoryMac.sh 7. Check that the file %Hostname%_%MacAddress%.inv has appeared in the ~/TNI/Send folder ls ~/TNI/Send 8. Send a letter with your local IP address to bdc.it@akvelon.com system administrators to confirm its successful operation. 9. Next, you need to add the file to startup or scheduler and check its operation. The solution depends on the frequency of reboots/re-logins in the OS: if you reboot/relogin at least once every 1-2 weeks, then it is preferable to add it to startup (9.1.1-9.1.8), otherwise configure the scheduler (9.2.1-9.2.6). If you make the wrong choice, then be prepared that you will be periodically asked to run the script manually. ###logon script ### 9.1.1. Launch Automator from Applications 9.1.2. Create a new application: File > New, type Application 9.1.3. Add Action from Library Utilities - "Run Shell Script" 9.1.4. Copy the contents of ~/TNI/GetInventoryMac.sh into the script window 9.1.5. Save as Logon_TNI.app on Desktop 9.1.6. Open System Preferences > User & Groups > Login Items 9.1.7. Add Logon_TNI from Desktop 9.1.8. Reboot the computer and send a letter with your local IP address to bdc.it@akvelon.com system administrators to confirm its successful operation. ### cron ### 9.2.1. Create and open the ~/.crontab file: touch ~/.crontab open -e ~/.crontab 9.2.2 Add to the end of the file: 0 10 * * 1-5 ~/TNI/GetInventoryMac.sh Comment. You can edit the script launch time according to your work schedule, but we must assume that the script runs successfully at least once a week. 9.2.3. Add a task: crontab ~/.crontab 9.2.4. Let's check that everything worked: crontab -l 9.2.5. Reboot 9.2.6 A week later we send a letter with your local IP address to bdc.it@akvelon.com system administrators to confirm its successful operation.