Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

ntpd under OSX UNIX
This one comes from a message posted by "Fred" to OmniGroup's "Mac OS X Admin" mailing list. He notes that if you open OSX's Date and Time system preferences panel and specify a time server to be used to keep the system clock synchronized, the built-in copy of ntpd will be started locally, which will enable other machines on the network to get correct time from your OSX machine.
  Post a comment  •  Comments (3)  
  • Currently 1.78 / 5
  You rated: 3 / 5 (9 votes cast)
[16,836 views]  View Printable Version
Enabling anonymous FTP UNIX
Anonymous FTP allows guests to access your machine in a limited manner, to either upload or download files. You can put FTP links on web pages that connect the users directly to your anonymous site; it's a convenient way of giving them easy downloads.

Read on for step-by-step directions on how to set this up on your machine. Before proceeding with this one, you should be comfortable at the command line, and probably have at least some knowledge of users, groups, and permissions in UNIX.
read more (458 words)   Post a comment  •  Comments (26)  
  • Currently 2.78 / 5
  You rated: 4 / 5 (9 votes cast)
[53,796 views]  View Printable Version
Mac vs. UNIX line breaks UNIX
If you're having trouble getting something to work right, and that something is based on a text file (for example, a Perl CGI script or a page of HTML), make sure you don't have any hidden Mac line breaks (also called line endings) in the file!

If you installed or modified the file using a GUI-based tool, there's a chance you accidentally inserted Mac line breaks. I know (from personal experience!) that Mac line breaks can make both Perl scripts and static HTML pages non-functional if they show up in the wrong spot. Read the rest to see how to find and remove the line breaks...
read more (141 words)   Post a comment  •  Comments (19)  
  • Currently 2.43 / 5
  You rated: 5 / 5 (7 votes cast)
[86,079 views]  View Printable Version
How to compile a UNIX app for X UNIX
[Editor's note: Please see the comments for some useful suggestions]

I have been having some nagging difficulties compiling c code into X ... Can any one explain the full path to doing this this successfully ?

I mean this must be one of the most appealing aspects of OS X, the ability to run any shell based unix app.....if you could get it to actually work.... :-(

I keep getting the compiler demanding a machine type when using the ./configure command. However when I specify a system like BSD, Darwin, PPC or whatever nothing seems to work. A typical result is:
read more (70 words)   Post a comment  •  Comments (6)  
  • Currently 2.13 / 5
  You rated: 5 / 5 (8 votes cast)
[11,661 views]  View Printable Version
Learn Perl UNIX
Open the Terminal and type
man perl
There's practically a textbook on how to use Perl.
  Post a comment  •  Comments (0)  
  • Currently 1.67 / 5
  You rated: 2 / 5 (9 votes cast)
[4,571 views]  View Printable Version
A 'nicer' nice UNIX
For those not familiar with it, the unix commands nice and renice can be used to alter the priorities (think percentage of CPU time) given to running tasks. However, like many UNIX commands, they are not 'user friendly' by any stretch. First you need to do a ps to see what's running, and then you need to remember the command syntax to change the values.

I spotted a thread on the Mac OS X Forums that discussed this very topic. Forum user "Iambob" took it upon himself to write a GUI wrapper for nice, which would present all the jobs with their current priorities, and allow easy tweaking of the values. Quite logically, he named his program nicer.

You can find nicer here, and I must say it's a very useful progam. There's some work he'd like to do relative to optimization, but the basic functionality is there, and it's basically self-explanatory: double-click a process to change its priority. It takes a while to launch, but don't worry, it's not crashing your OS.

I think this program is a great example of what we'll see as we progress towards OS X 1.0: GUI wrappers around the core UNIX commands to make them more useful to the typical Mac user. Thanks, IamBob!

[Editor's note: Version 1.0 of nicer is now available at the above link!]
  Post a comment  •  Comments (2)  
  • Currently 1.83 / 5
  You rated: 1 / 5 (12 votes cast)
[6,752 views]  View Printable Version
How to upgrade Apache UNIX
OS X PB ships with version 1.3.12 of the Apache web server. If you'd like to run the latest release (1.3.14), there's a good article on explaining how to do so.

Their instructions leave you with two Apache installs, in case you want to revert to the prior version.
  Post a comment  •  Comments (1)  
  • Currently 2.00 / 5
  You rated: 4 / 5 (10 votes cast)
[10,279 views]  View Printable Version
Viewing preference files UNIX
If you're curious to see how preferences are stored in OS X, you can use the command "defaults." To see which programs the system knows about, type
defaults domains
in a terminal session. This will list (in a not very elegant way) every application for which the system has stored preferences.

To view the prefs for a certain application, just type
defaults read [appname]
where [appname] is a name as specified in the output of the first command. For example,
defaults read
will show your Finder preferences. You can also (as the tips on changing the dock elsewhere on macosxhints demonstrate) change preference values with
defaults write...
However, this is not recommended unless you really know what you're doing! Most apps, of course, give you full access to their settings from within the program, which is the preferred way to go about changing them!

A good reading of "man defaults" is also suggested before you change anything!
  Post a comment  •  Comments (0)  
  • Currently 1.89 / 5
  You rated: 3 / 5 (9 votes cast)
[5,404 views]  View Printable Version
Color-coded 'ls' output UNIX
Some variants of UNIX offer a 'color' option on the ls (directory list)command; OS X doesn't by default.

Chen Jake Zhou has made a version of ls with the color option available on his site.

The program can be downloaded and installed as with any OS X program, but then you'll have to make it executable from a terminal session...
chmod +x ls
...from within the directory where the 'new' ls is installed. You can then test the output by typing...
./ls --color
...from within that same directory. If you like the output, and want to make it permanent, then Read the Rest of this hint for detailed instructions.
read more (186 words)   Post a comment  •  Comments (6)  
  • Currently 2.00 / 5
  You rated: 5 / 5 (10 votes cast)
[47,956 views]  View Printable Version
mount points UNIX
[Editor's note: See the comments for discussion on this doesn't appear there's a resolution, at least in the PB]

Can someone tell me how to get macosx to mount secondary (slave) hardrive on first IDE chain to mount point /User/. So user homes is on one drive and system on other.
  Post a comment  •  Comments (2)  
  • Currently 2.30 / 5
  You rated: 5 / 5 (10 votes cast)
[5,347 views]  View Printable Version