Tomk Mac OS

(UPDATE 04/11/2011 – Corrected error with sparseimage. Should be sparsebundle. Directions corrected.)

Download and Install Tomcat. For academic learning, I recommend “zip' (or 'tar.gz') version, as you. With the latest version of SCCM 1511, many admins will be tempted to move to latest operating system and SQL versions. Considering Windows Server 2008 R2 and SQL 2008 R2 are already on extended support and the way SCCM 1511 is designed for future upgrades, it can be good time to do a SCCM 1511 migration with the latest OS and SQL.

Note: These directions will not work with Mac OS X Lion as Apple has removed the necessary components to allow this functionality to work.

In today’s how-to, we’re going to setup Time Machine for a Mac client with the backups being stored on Windows Home Server 2011. These same steps should work with Small Business Server 2011 Essentials and Storage Server 2008 R2 Essentials as well. (P.S. If after reading this, and you agree with me that setup could be easier, go here and vote.)

Step 1: Create shared folder on server

  • From a Windows PC with the Connector installed or using Remote Desktop Connection for Mac, connect to your server and launch the Dashboard.
  • Click the Shared Folders and Hard Drives tab
  • Click Add a Folder, and fill in the details then click Next
  • Click Specific People, and then assign Read/Write permissions to the user account you wish to use on your Mac.
  • Click Add Folder,and then when the process is finished, click Close.

Step 2: Enable Network Volume Support and create SparseBundle file

  • On each Mac that you wish to back up, go to the Applications folder, then Utilities, then open Terminal and type the following command then press Enter.
    • defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1
  • We need to determine the MAC address of the Ethernet port (en0) to properly create the sparsebundle file. (NOTE: Even if you are using a wireless connection to backup, you MUST use the MAC address of the Ethernet port.) To do so, in the same Terminal window, type ifconfig and press Enter. Look for the line starting with en0, and then look just below that for the line starting with ether and make note of the address on that line.
  • Now we will create the sparsebundle file that Time Machine will use. In the same Terminal window, type the following command and press Enter. (NOTE: For the hard drive size, it needs to be the size of your hard drive. If you have a 160GB hard drive, then it will be ‘-size 160G’.)
    • hdiutil create –size <Hard Drive size>G –fs HFS+J –volname “<computername> Backup” <computername>_<MACAddress>.sparsebundle
      • Replace <Hard drive size> with the size of your hard drive
      • Replace <computername> with the name of your computer (Can be found in System Preferences –> Sharing) (Note: You may want to change the name to make it something short and simple.)
      • Replace <MACAddress> with the MAC Address you made note of in the previous step, leave out the colons in the address

Step 3: Copy Sparsebundle to server and enable Time Machine

  • Close Terminal, then go to the Go menu and click Connect to Server, and type in smb://<ip address or name of server>, then press Enter. Choose the Shared Folder you created and click OK.
  • Browse to the location that the sparsebundle file was created in. This will most likely be the root of your user folder. (/users/<your username/)
  • Drag this sparsebundle file to the shared folder on the server
Mac os for windows 10Tomk

Tom Macon

  • After the file finishes copying, open System Preferences, and then click Time Machine
  • Click Select Disk and select the shared folder on your server
  • When prompted, enter the user name and password you wish to use and click Connect.
  • A countdown of 120 seconds should begin, and then once that countdown finishes, your backup should commence.

Congratulations! You’ve just configured Time Machine with Windows Home Server 2011.

The Servlet 4.0 specification is out and Tomcat 9.0.x does support it. Time to dive into Tomcat 9.

Prerequisite: Java

Since OS X 10.7 Java is not (pre-)installed anymore, let’s fix that by installing a Prebuilt OpenJDK Binary. Easy to follow details about how to install OpenJDK are available here. Anyway, after opening the Terminal app,

hopefully shows something like this:

Whatever you do, when opening Terminal and running ‘java –version’, you should see something like this, with a version of at least 1.8.x I.e. Tomcat 9.x requires Java 8 or later.

Tom Macrosky

sudo is a program for Unix-like operating systems, allowing you to run programs with the security privileges of another user (normally the superuser, or root). Since we are creating directories, outside of your home folder, administrator right are required. I.e., when executing sudo you will be asked to enter your password; and your Mac User account needs to be an ‘Admin’ account.

JAVA_HOME is an important environment variable, not just for Tomcat, and it’s important to get it right. Here is a trick that allows me to keep the environment variable current, even after a Java Update was installed. In ~/.zshrc, I set the variable like so:

Installing Tomcat

Tomk Mac Os X

Here are the easy to follow steps to get it up and running on your Mac

  1. Download a binary distribution of the core module: apache-tomcat-9.0.40 from here. I picked the tar.gz in Binary Distributions Core section.
  2. Opening/unarchiving the archive will create a new folder structure in your Downloads folder: (btw, this free Unarchiver app is perfect for all kinds of compressed files and superior to the built-in Archive Utility.app)
    ~/Downloads/apache-tomcat-9.0.40
  3. Open the Terminal app to move the unarchived distribution to /usr/local like so:
    sudo mkdir -p /usr/local
    sudo mv ~/Downloads/apache-tomcat-9.0.40 /usr/local
  4. To make it easy to replace this release with future releases, we are going to create a symbolic link that we are going to use when referring to Tomcat (after removing the old link, you might have from installing a previous version):
    sudo rm -f /Library/Tomcat
    sudo ln -s /usr/local/apache-tomcat-9.0.40 /Library/Tomcat
  5. Change ownership of the /Library/Tomcat folder hierarchy:
    sudo chown -R <your_username> /Library/Tomcat
  6. Make all scripts in Tomcat’s ./bin folder executable:
    sudo chmod +x /Library/Tomcat/bin/*.sh

Tomcat 9.x

Starting and stoping Tomcat works with executing the provided scripts, like so:
/Library/Tomcat/bin/startup.sh
/Library/Tomcat/bin/shutdown.sh

Tomk Mac Os Downloads

Finally, after your started Tomcat, open your Mac’s Web browser and take a look at the default page: http://localhost:8080