Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Mac OS X > root's path

root's path
Thread Tools
rw
Mac Enthusiast
Join Date: Dec 2000
Location: Kirkland, WA, USA
Status: Offline
Reply With Quote
Jan 20, 2003, 08:53 AM
 
While using Fink, I got this message:

NB: root's PATH should usually contain /usr/local/sbin, /usr/sbin and /sbin.

So, without enabling root, how do I find out what root's PATH variable actually contains?
     
Mac Elite
Join Date: Dec 2001
Location: Atlanta, GA, USA
Status: Offline
Reply With Quote
Jan 20, 2003, 10:20 AM
 
Just do:

Code:
sudo su -
Enter your password when prompted, and you'll have a shell running as root with the root users' environment. Then just do

Code:
env | grep PATH or echo $PATH
to see the path.

I'm not sure though why you're seeing that from fink.

FYI, my root users' path is unchanged from the default and is:

Code:
PATH=/bin:/sbin:/usr/bin:/usr/sbin
Mac Pro 2x 2.66 GHz Dual core, Apple TV 160GB, two Windows XP PCs
     
Junior Member
Join Date: Jan 2003
Location: Calif, USA
Status: Offline
Reply With Quote
Jan 21, 2003, 08:42 PM
 
off topic, but :

why is it that apple doesn't allow you to log in as root like on a normal linux box? Any reason we can't have a root user to log into os X as root? Or do i just not know how?

also, is there a way to boot into command line only?
Proof is an idol before which the mathematician tortures himself.
-Sir Arthur Eddington
----------------------------
800iBook | 384 | 12.1in | Jag
     
Mac Enthusiast
Join Date: Sep 2000
Location: New York, NY USA
Status: Offline
Reply With Quote
Jan 21, 2003, 08:49 PM
 
Root comes disabled in OS X as a security measure. You can turn it on using the NetInfo manager app in the Utilities folder.

IIRC, there's some key combination you can hold down at boot to boot into console mode. Don't remember it, but I'm sure someone'll post it.
     
Junior Member
Join Date: Jan 2003
Location: Calif, USA
Status: Offline
Reply With Quote
Jan 21, 2003, 11:26 PM
 
so uh... how do I activate root user in netinfo?
Proof is an idol before which the mathematician tortures himself.
-Sir Arthur Eddington
----------------------------
800iBook | 384 | 12.1in | Jag
     
Mac Elite
Join Date: Aug 2001
Location: Australia
Status: Offline
Reply With Quote
Jan 22, 2003, 01:40 AM
 
Originally posted by ickettpe:
so uh... how do I activate root user in netinfo?
Goto Domain Menu, inside that security, and then enable root.

As for starting as cli, you can only do single user mode.

I think it's command+s when starting up
     
Mac Enthusiast
Join Date: Jul 2002
Location: Leiden, Netherlands
Status: Offline
Reply With Quote
Jan 22, 2003, 05:55 AM
 
Originally posted by justinkim:
Root comes disabled in OS X as a security measure. You can turn it on using the NetInfo manager app in the Utilities folder.

IIRC, there's some key combination you can hold down at boot to boot into console mode. Don't remember it, but I'm sure someone'll post it.
Where you thinking verbose mode , ie V ?
     
Mac Enthusiast
Join Date: Jul 2002
Location: Leiden, Netherlands
Status: Offline
Reply With Quote
Jan 22, 2003, 05:57 AM
 
Originally posted by ickettpe:
off topic, but :

why is it that apple doesn't allow you to log in as root like on a normal linux box?
Because when root is enabled, it's easier to gain power on your machine. Most machine being connected to the net, and most mac users being non geeks it's normal for Apple do diseable root.

Your account can trash the kernel. Root can.
     
Addicted to MacNN
Join Date: Jun 1999
Location: Las Vegas, NV, USA
Status: Offline
Reply With Quote
Jan 22, 2003, 08:56 AM
 
As for starting as cli, you can only do single user mode.
Not so. You can get to to a command line interface from the GUI by typing >console into the login window's username field. Then hit return.

If you don't have text fields for username and password, but instead use pictures, then at the login window hit the down arrow to highlight a user picture, then hit option-return. This will bring up the username and password fields. Then >console as before.

When you are done in the CLI, type exit and you'll be back at the login window.

Chris
     
rw  (op)
Mac Enthusiast
Join Date: Dec 2000
Location: Kirkland, WA, USA
Status: Offline
Reply With Quote
Jan 22, 2003, 08:26 PM
 
This is off the new topic of enabling root, but I wanted to thank Arkham_c for solving my original problem re Fink.
     
Mac Elite
Join Date: Dec 2001
Location: Atlanta, GA, USA
Status: Offline
Reply With Quote
Jan 23, 2003, 08:54 AM
 
Originally posted by rw:
This is off the new topic of enabling root, but I wanted to thank Arkham_c for solving my original problem re Fink.
Glad to be of assistance.
Mac Pro 2x 2.66 GHz Dual core, Apple TV 160GB, two Windows XP PCs
     
Mac Elite
Join Date: Nov 2001
Status: Offline
Reply With Quote
Feb 14, 2003, 06:51 AM
 
how do i add a directory to my path?
     
Mac Elite
Join Date: Dec 2001
Location: Atlanta, GA, USA
Status: Offline
Reply With Quote
Feb 14, 2003, 12:48 PM
 
Originally posted by ShotgunEd:
how do i add a directory to my path?
It depends if you use a C-shell (csh, tcsh) or a Bourne shell (sh, bash, ksh, zsh). If you're using a c-shell, you should switch , but seriously...

cshell:

setenv PATH "$PATH:newdirectory"

bourne shell:
PATH="$PATH:newdirectory"
export PATH

(some of the better bourne shells will also allow this):
export PATH="$PATH:newdirectory"

If you want to add it permanently so it's already there when you open a new shell/terminal, you can do so in the appropriate resource file in your home directory depending on your shell (.bashrc, .tcshrc, etc). Read the man page on your shell to find the name of the config resource file for your shell.

Everyone has a favorite shell, and OSX comes with most of them. Personally, I use bash.
Mac Pro 2x 2.66 GHz Dual core, Apple TV 160GB, two Windows XP PCs
     
Fresh-Faced Recruit
Join Date: Sep 2002
Status: Offline
Reply With Quote
Feb 14, 2003, 04:46 PM
 
I am having this problem. How do I fix it? Is there another site that is better for getting advice on these things?
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 07:32 PM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2