Tell me about OS X (please)

Some of you may know I’m not partial to Apple products. I think there are many benefits to them for many people, but they just ain’t right for me. I knew that OS X was a unix of some flavor, but I assumed that was just under the covers. So, I was very surprised and impressed to hear the answer to a recent Apple question here was

Now you’re talking my language. So, a few questions:
[list=a][li]On the new Apples, do you actually have that sort of console access, and do you really have a full unix that you can do all the typical command line things we unix-heads crave?[/li][li]How do they do the GUI? Is it on top of X Windows?[/li][li]Can you run typical unix applications on OS X? (in terms of both the underlying OS support and GUI support)[/li][li]Can you run typical Apple applications on OS X? (I assume yes, which I assume implies no for the previous question)[/li][li]How much of the experience is identical to the previous Apples (I’m assuming a lot)? Are there new paradigms in the GUI or the mouse (i.e. multiple buttons)? Is there encouraged access to the console, or is this a hidden thing?[/li][li]What prompted this OS change in the first place? It’s always been my understanding that Apples were pretty stable, so I suspect that wasn’t it.[/li][/list=a]Thanks.

You can open a terminal window at any time, and have as many as you want. Think xterm, but prettier.

MacOS X has its own proprietary vector-based graphical rendering system called Quartz. The GUI that runs on this is called Aqua, and is not based on X11. You can run an X-server side-by-side with Aqua if you want to, however, with some third-party add-ons.

Yes. Pretty much anything that will compile on Linux or BSD can be recompiled for OSX. For X-windows based apps you will need an X-server. (XFree86 is available for OSX, I believe.)

Most common Mac apps have been re-released at this point with OSX-native versions, but older ones can be run in the “Classic” environment which runs the old MacOS as a process under OSX. It works pretty well.

It’s pretty different. The fundamental ideas common to Mac and MS GUI’s are basically the same, but the interface will take a bit of getting used to. Access to the lower-level Unix guts of the system is easily available by the aforementioned terminal window, though is not necessary for a casual user.

A few things. The old MacOS was getting old. It is based on a core that was written for the “System 7” release around 1992. There was no true multi-tasking, no true process protection, etc. Unix has had these things for decades. In addition, Apple had acquired NeXT (Steve Jobs helped found it when Apple fired him, then acquired it when they hired him back). NeXT developed a lot of the technology (like Objective C and NetInfo) that found its way into MacOS X, via several failed projects that were going on while Apple was updating and expanding the System 7 core. With new hardware that could run BSD at acceptable speeds, Apple decided to take the NeXT technology, update it, and stick it on top of BSD to make a new OS.

a. yes, it’s called the terminal. It’s an app in the utilities folder, that can be left open or docked. terminal
b. gui structure
c. yes, typical unix apps have precompiled binaries. darwin the bsd variant is still open source
d. yes
e. too much to list in just a short q/a, terminal access is easy enough, multi-button mice are pretty well supported -aftermarket only so far
f. better memory managment and a bunch of other features

Two more links to check out:

fink.sourceforge.net
http://www.apple.com/macosx/x11/

Thanks very much. very interesting and very impressive.

A couple more questions:

[list=a]
[li]Can you run Aqua/Quartz/Darwin and X11 side by side? (also, what exactly does X11 corespond to in the Apple technology?)[/li][li]I see KDE has been released, but I’m not certain if that’s on X11 or Darwin or other? Can you run standard Apple apps on KDE (presumably on Darwin)?[/li][li]If all Apple apps require a GUI and that GUI is Aqua, is X11 really only usable as a second boot option?[/li][li]If you choose to run unix applications X11, is there really anything “Apple” in your environment beyond the hardware?[/li][li]Does Apple intend to do anything to integrate these two windowing systems?[/li][/list=a]
Thanks again.

Hey Bill H., it’s good you’re at least looking into the light! :slight_smile:

Your second part answers, since all the first part answers were good:

a. Yup. Apple calls it X11, and the native window manager is the Quartz window manager. This means your X11 apps look like regular Mac applications. Well, mostly. You can run other Window managers if you want (KDE and Gnome e.g.) but they can interfere with your Mac desktop. If you use the non-Apple X11, you can run in root mode (not “root” user) meaning the WM takes over your screen and you have a full-screen X session. Maybe the Apple distro allows root mode; I’ve not investigated.
b. See above. Also, the libraries seem to be present, meaning KDE apps I’ve tried run okay using the Aqua-WM.
c. No booting necessary. See above answers. The run side-by-side. HECK, I can ssh into my Linux box (formerly XP box) and run remote X sessions right on my Mac desktop (while my wife plays Solitair – Windows remote desktop wouldn’t allow true multi-user.). On that note, you can log into your Mac from another *nix box and run your X11 apps there (not the “native” apps, though).
d. Yeah, the Aqua WM which makes X11 apps “look” much more native than “Classic” apps. Having no more Classic apps, that’s not much of a concern for me.
e. I don’t know where Apple’s going with it – there are rumors that 10.3 will officially integrate them. But, for the time being, the current Apple X11 distribution is very, very well integrated with the rest of the Mac OS.

In short, you’re getting a “real” Unix box that will work much like your other *nix boxes (although my Linux box does have a messy file system structure by default compared to the Mac elegance). That reminds me, the Mac “natively” tries to hide all of that Unixy goodness from you. Check out my outdated Mac printing guide – http://www.balthisar.com/printing. They’re “Unix” instructions for getting printers to work the “Unix way” on pre-10.2 systems – they no longer apply (mostly) for Jaguar. You’ll see how Unixy it really is.

Good luck.

Balthisar wrote

Can you elaborate, or point me somewhere? I like (or at least am familiar with) the unix file structure. In what ways is Mac more elegant?

Could you elaborate a bit on this as well? What sorts of things are hidden? The phrase “hiding for the sake of elegance” makes me nervous.

Also, are SSH or telnet daemons included on the box? I believe my mom has an OS X machine (but lives in another city), and I’d be interested in ssh-ing into it and looking around. How hard would it be for a novice user to enable the ssh daemon?

Also, I assume OS X is restricted to Apples proprietary platform, true?

Thanks again. This is really very eye-opening.

Hi, Bill!

That would be the answer to my question.

I’m a Mac user since…oh, System 3. I don’t know this Unix shit except as I pick it up by a combo of trial and error and curiosity + having heard about things + bugging the shit out of my Unix-cognizant friends.

I think the answer to the question you’re asking is “yeah, it’s real”. My 1998-vintage PowerBook has sendmail operant (and I can utilize it to send outbound emails from Macintosh GUI program Eudora simply by referencing my own IP address as the SMTP Server); I have ssh’d into a Linux box, exported the display back to my own IP, and thereby run Linux GUI apps in an X-Window environment. I have an X-Window environment as a result of having downloaded and installed Fink, then Finked and compiled XFree86. I know some folks have deployed KDE as their X11 GUI, but I am sticking with WindowMaker for the time being. Apple has their own deployment of X11 but I am (again) sticking with XFree86. Fink handles either. From the GUI front end called Fink Commander I can select new available Unix software (command line or X11) and download it simply by clicking “Download Binary” (when available) or “Download Source” (more often). If I download the source, Fink compiles it for me and all I have to do is answer a few questions.

I have an Apache-powered website up and running which connects to a Unix daemon which in turn connects to traditional Macintosh GUI-based database program FileMaker.

MacOS X is young but both Unix and long-term Mac people tend to agree that despite this or that thing that just isn’t there yet, it is is off to a great start. If Apple had simply died off, I probably would have eventually tried Unix. Much better this way. (Would you believe I can still run Macintosh applications designed to run on a Quadra, or Mac IIx, or Mac Plus, even – computers with a Motorola 680x0 processor – in a “Classic” window? Lots of Macintosh backwards compatibility for those of us who have always been Mac folks. At the opposite extreme, you could pretty much ignore the Aqua environment (you can log on to just a command line interface with no Aqua-Mac GUI at all, in fact) and run strictly Unix processes. Most people have one foot solidly in one camp and are exploring the other. (I may not have known the grep command without asking for it but hey, I knew what a PID is and why one would want to know it in order to ask the question in the first place, didn’t I?).

Wish us luck. We hope to be a good thing for Macintosh and for Unix, and indirectly, via the better aspects of market competition and availability of choice and whatnot, for Microsoft operating systems as well.

And if you can afford to get your hands on a Mac, come out and play :slight_smile:

MacOS X gives some prettier names to the directory structure. Apps live in a /Applications directory, users home directories are in /Users (IIRC) and so on. This is pretty easy to get used to. I highly reccomend the ORA book *MacOS X for Unix Geeks. It explains the differences in great detail.

They aren’t really hidden, they’re just not in plain sight. As mentioned, you can do absolutely anything you would expect from the plain terminal window. This lives in the Applications folder under Utilities. Real easy. One thing you’ll need to learn about is the NetInfo configuration manager. This is a NeXT invention that deals with a lot of configuration information for your box and replaces a lot of the familiar /etc/ files. Again, see that book.

SSH is included in the default install. I don’t remember if it’s turned on by default or not. Your mother would have to create a user account (boxes can be set up as either single-user or multi-user, BTW) and then you’d be able to SSH right in with that name and password. The default install creates a single-user system, but multiple users can be easily enabled in the control panel.

Yes. However, Apple’s FreeBSD variant, Darwin, on top of which Apple’s proprietary technology runs, does maintain a working X86 port. There isn’t much there that you don’t already have in plain old FreeBSD, though.

tip #4 has a good description of the file system layout. The O’Reilly books cover the idiosyncracies of the Unix base to OSX pretty well.

I believe so. Admittedly, I am a Unix novice, but ssh access can be toggled from the gui. sysprefs:sharing:firewall

Basically what Apple did with the UNIX file structure, was hide it under the finder.

If you use the GUI, you would have no idea that there is UNIX underneath. Apps are in the Applications folder, home directories are in the Users folder, stuff like that.

If you fire up the terminal though, you will see all of the unix bits in plain sight.

Apple just hides stuff under the GUI for the sake of making it easier for traditional apple users. Unlike microsoft though, Apple doesn’t lock you out of the underpinning OS. If you feel comfortable with the command line, it is all there.

Darwin is the code name that the UNIX base goes by. Quartz is an OpenGL accelerated rendering engine based upon the Adobe PDF Format. Aqua, the Apple user interface runs on top of it.

It is an extremely polished system. I have used Windows, Linux, Classic MacOS, and OS X is hands down the best OS I have used. Stability of Linux, but far more polished than either it, or Windows could hope to be.

Well, this is really something. Thanks to all who’ve responded.

I must say I have a dramatically different opinion about things then I did this morning.

Hi again Bill H.. I’m just writing to say I didn’t ignore you but everyone else answered the points you asked of me.

I’ll clarify one of friedo’s points, though. The Mac OS X system, when installed, sets you up with one GUI “administrator” user. This is “almost” a superuser. There is no root account by default, although it’s simple to enable if you want a root account. Even in the terminal you can sudo su without actually enabling root. There are, though, many other users and groups installed into the system by default. They have their own hidden home folders. These are the typical apache, mysql, and so on users (I know they’re there; I’m just not sure which ones, exactly).

Oh, yeah, even though you didn’t ask, you get Apache, PHP, mySQL, perl, and other goodies built-in. You can upgrade them easily enough, too, if you think you need something more modern (in my case, PHP 4.12 and mySQL was older than I wanted).

Added bonus: of course gcc 3.1 (I think that’s the version) is built in, but you get the entire set of Apple developer tools, too. This is a C/C++/Objective-C/Objective-C++/Java/Swing/AppleScript development system with IDE (of course, if you like the command line, then, well, it’s there). And its free. If you want to program native, Cocoa GUI apps, learning Objective-C is nothing (like all development systems, learning the libraries is the real challenge).