macOS Update: While these instructions still work, there are new posts for recent versions of macOS, the latest being Install Apache, PHP, and MySQL on macOS Mojave.
PHP Update: Mac OS X El Capitan comes pre-installed with PHP version 5.5 which has reached its end of life. After you complete this post, you should upgrade PHP on Mac OS X.
Note: This post is for new installations. If you have installed Apache, PHP, and MySQL for Mac OS X Yosemite, read my post on Updating Apache, PHP, and MySQL for Mac OS X El Capitan.
How can I connect to a remote SQL server using Mac OS X? I don't really need a GUI, but it would be nice to have for the color coding and resultset grid. I'd rather not have to use a VM. Is there a SQL client for Mac OS X that works with MS SQL Server?
Mac OS X runs atop UNIX. So most UNIX software installs easily on Mac OS X. Furthermore, Apache and PHP come packaged with Mac OS X. To create a local web server, all you need to do is configure Apache and install MySQL.
- For Mac OS X: Download FMiner Mac 9.81 (32.1M) Free Trial 15 Days, Easy to Install and Uninstall Completely. Pro and Basic edition are for Windows, Mac edition just for Mac OS 10. Recommended Pro/Mac edition with full features. See edition comparison. Pro and Basic edition is for windows, Mac edition just for Mac OS 10.
- If you want to download the packages directly, see Download ODBC Driver for SQL Server. Microsoft ODBC 17. Use the following commands to install the Microsoft ODBC driver 13.1 for SQL Server on OS X 10.11 (El Capitan) and macOS 10.12 (Sierra).
- Run SQL.Plus and connect using your database credentials and connection string: sqlplus hr/welcome@localhost/orclpdb. Installing Instant Client 11.2 on macOS. Instant Client 11.2 supports macOS X Lion, Mountain Lion and Mavericks. Download the desired Instant Client ZIP files. All installations require the Basic or Basic Light package.
I am aware of the web server software available for Mac OS X, notably MAMP. These get you started quickly. But they forego the learning experience and, as most developers report, can become difficult to manage.
Running Commands
First, open the Terminal app and switch to the
root
user so you can run the commands in this post without any permission issues:Enable Apache on Mac OS X
Verify It works! by accessing http://localhost
Enable PHP for Apache
First, make a backup of the default Apache configuration. This is good practice and serves as a comparison against future versions of Mac OS X.
Now edit the Apache configuration. Feel free to use TextEdit if you are not familiar with vi.
Uncomment the following line (remove
#
):Restart Apache:
You can verify PHP is enabled by creating a
phpinfo()
page in your DocumentRoot
.![Download Download](/uploads/1/2/5/8/125885337/740187855.png)
The default
DocumentRoot
for Mac OS X El Capitan is /Library/WebServer/Documents
. You can verify this from your Apache configuration.Now create the
phpinfo()
page in your DocumentRoot
:Verify PHP by accessing http://localhost/phpinfo.php
Install MySQL on Mac OS X El Capitan
Download and install the latest MySQL generally available release DMG for Mac OS X.
The README suggests creating aliases for
mysql
and mysqladmin
. However there are other commands that are helpful such as mysqldump
. Instead, you can update your path to include /usr/local/mysql/bin
.Note: You will need to open a new Terminal window or run the command above for your path to update.
Finally, you should run
mysql_secure_installation
. While this isn't necessary, it's good practice to secure your database.Connect PHP and MySQL
You need to ensure PHP and MySQL can communicate with one another. There are several options to do so. I do the following:
Additional Configuration (optional)
The default configuration for Apache 2.4 on Mac OS X seemed pretty lean. For example, common modules like
mod_rewrite
were disabled. You may consider enabling this now to avoid forgetting they are disabled in the future.I edited my Apache Configuration:
I uncommented the following lines (remove
#
):If you develop multiple projects and would like each to have a unique url, you can configure Apache VirtualHosts for Mac OS X.
If you would like to install PHPMyAdmin, return to my original post on installing Apache, PHP, and MySQL on Mac OS X.
Find this interesting? Let's continue the conversation on Twitter.
|
Downloading Nmap
Nmap and Zenmap (the graphical front end) are available inseveral versions and formats. Recent source releases and binarypackages are described below. Older version (and sometimes newer testreleases) are available from the dist directory(and really old ones are in dist-old).For the moresecurity-paranoid (smart) users, GPG detached signatures and SHA-1hashes for each release are available in the sigsdirectory (verification instructions). Before downloading, be sure to read the relevant sections for your platform from the Nmap Install Guide. The mostimportant changes (features, bugfixes, etc) in each Nmap version aredescribed in the Changelog. Using Nmap is covered in the Reference Guide, and don't forget to readthe other available documentation, particularly the new book Nmap Network Scanning!
Nmap users are encouraged to subscribe to the Nmap-hackersmailing list. It is a low volume (7 posts in 2015), moderated listfor the most important announcements about Nmap, Insecure.org, andrelated projects. You can join the 128,953 current subscribers (as ofSeptember 2017) by submitting your email address here:
You can also get updates from our Facebook and Twitter pages.
Nmap is distributed with source code under custom license terms similar to (and derived from) the GNUGeneral Public License, as noted in the copyright page.
Microsoft Windows binaries
Please readthe Windows section of theInstall Guide for limitations and installation instructions for theWindows version of Nmap. You can choosefrom a self-installer (includes dependencies and also the Zenmap GUI)or the much smaller command-line zip file version. We support Nmap on Windows 7 and newer, as well as Windows Server 2008 and newer. We also maintain a guide for userswho must run Nmap on earlier Windows releases..
The Nmap executable Windows installer can handle Npcapinstallation, registry performance tweaks, and decompressing theexecutables and data files into your preferred location. It also includes the Zenmap graphical frontend. Skip all thecomplexity of the Windows zip files with a self-installer:
Latest stable release self-installer: nmap-7.91-setup.exe
We have written post-install usageinstructions. Please notify usif you encounter any problems or have suggestions for theinstaller.
For those who prefer the command-line zip files (Installation Instructions; UsageInstructions), they are still available. The Zenmap graphicalinterface is not included with these, so you need to runnmap.exe from a DOS/command window. Oryou can download and install a superior command shell such as thoseincluded with the free Cygwin system.Also, you need to run the Npcapand Microsoft Visual C++ 2013 Redistributable Packageinstallers which are included in the zip file. The main advantage is that these zip files are a fraction of the size of the executable installer:
Latest stable command-line zipfile:nmap-7.91-win32.zip
Linux RPM Source and Binaries
Many popular Linux distributions (Redhat, Mandrake, Suse, etc) usethe RPM package management system forquick and easy binary package installation. We havewritten a detailed guide toinstalling our RPM packages, though these simple commands usually dothe trick:You can also download and install the RPMs yourself:
Latest stable release:
x86-64 (64-bit Linux)Nmap RPM: nmap-7.91-1.x86_64.rpm
x86-64 (64-bit Linux)Ncat RPM: ncat-7.91-1.x86_64.rpm
x86-64 (64-bit Linux)Nping RPM: nping-0.7.91-1.x86_64.rpm
Optional Zenmap GUI (all platforms): zenmap-7.91-1.noarch.rpm
Source RPM (includes Nmap, Zenmap, Ncat, and Nping): nmap-7.91-1.src.rpm
x86-64 (64-bit Linux)Nmap RPM: nmap-7.91-1.x86_64.rpm
x86-64 (64-bit Linux)Ncat RPM: ncat-7.91-1.x86_64.rpm
x86-64 (64-bit Linux)Nping RPM: nping-0.7.91-1.x86_64.rpm
Optional Zenmap GUI (all platforms): zenmap-7.91-1.noarch.rpm
Source RPM (includes Nmap, Zenmap, Ncat, and Nping): nmap-7.91-1.src.rpm
Mac OS X Binaries
Nmap binaries for Mac OS X (Intel x86) are distributed as a disk image filecontaining an installer. The installer allows installing Nmap, Zenmap,Ncat, and Ndiff. The programs have been tested on Intel computersrunning Mac OS X 10.8 and later. See theMac OS X Nmap installpage for more details. Users of PowerPC (PPC) Mac machines, which Apple ceased selling in 2006, should see this page instead for support information.
Latest stable release installer: nmap-7.91.dmg
Latest stable release installer: nmap-7.91.dmg
Source Code Distribution
This is the traditional compile-it-yourself format. The Nmaptarball compiles under Linux, Mac OS X, Windows, and many UNIXplatforms (Solaris, Free/Net/OpenBSD, etc.) It includes Zenmap, theGUI frontend.
Detailed Linux/BSD/Solaris compilation instructions and options are provided here, though this usually does the trick:
Most Windows users install with our Windows executable installer, but we also provide Windows source code compilation instructions.
Most Mac OS X users install with our Mac installer, but we also provide Mac OS X source code compilation instructions.
If you are compiling Nmap anyway, you might prefer to get the very latest code from our SVN source code repository rather than downloading a tarball here.
Latest stable Nmap release tarball: nmap-7.91.tar.bz2 (or gzip compressed)
Other Operating Systems
Many other operating systems support Nmap so well that I have no needto create and distribute binary packages myself. You can choose touse the packages below, or compile the sourcedistribution, which is often newer. We have created installation pages for the following platforms:
Linux (all distributions)
Microsoft Windows
Mac OS X
FreeBSD, OpenBSD, and NetBSD
Sun Solaris
Amiga, HP-UX, and Other Platforms
Linux (all distributions)
Microsoft Windows
Mac OS X
FreeBSD, OpenBSD, and NetBSD
Sun Solaris
Amiga, HP-UX, and Other Platforms
Mac Os Sql Server
Nmap Site Navigation
Sql Server Mac
Intro | Reference Guide | Book | Install Guide |
Download | Changelog | Zenmap GUI | Docs |
Bug Reports | OS Detection | Propaganda | Related Projects |
In the Movies | In the News |