| OS X - Operating System General OS operation information and support |
| Post Reply | New Thread | Subscribe |
|
|
Thread Tools |
![]() Member Since: Jan 03, 2012
Posts: 6
![]() |
Hi,
For some reason some terminal commands which I assume should be working by default are not working, including: netstat and lsof. I am running on Snow Leopard, 10.6.8. I guess this might have something to with the terminal commands file? Any suggestions would be greatly appreciated. Thanks, Dan |
| QUOTE Thanks | |
![]() Member Since: Mar 17, 2008
Location: Tucson, AZ
Posts: 6,588
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Mac Specs: 2008 and 2011 15" mbps, late 11 iMac, iPhone 4s, and too many ipods and other stuff
|
mike This machine kills fascists Got # ? phear the command line! |
| QUOTE Thanks | |
![]() Member Since: Mar 17, 2008
Location: Tucson, AZ
Posts: 6,588
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Mac Specs: 2008 and 2011 15" mbps, late 11 iMac, iPhone 4s, and too many ipods and other stuff
|
mike This machine kills fascists Got # ? phear the command line! |
| QUOTE Thanks | |
![]() Member Since: Jan 03, 2012
Posts: 6
![]() |
Last edited by danj35; 01-03-2012 at 09:10 AM. |
| QUOTE Thanks | |
![]() Member Since: Mar 17, 2008
Location: Tucson, AZ
Posts: 6,588
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Mac Specs: 2008 and 2011 15" mbps, late 11 iMac, iPhone 4s, and too many ipods and other stuff
|
They SHOULD be installed by default. I'm not aware of any method of installing them manually. I don't believe that either require xCode to be installed.
mike This machine kills fascists Got # ? phear the command line! |
| QUOTE Thanks | |
![]() Member Since: Mar 17, 2008
Location: Tucson, AZ
Posts: 6,588
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Mac Specs: 2008 and 2011 15" mbps, late 11 iMac, iPhone 4s, and too many ipods and other stuff
|
Was this a new install? Used computer? etc?
could try a sudo find / |grep lsof and see it it's just in an oddball location I suppose mike This machine kills fascists Got # ? phear the command line! |
| QUOTE Thanks | |
![]() Member Since: Mar 17, 2008
Location: Tucson, AZ
Posts: 6,588
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Mac Specs: 2008 and 2011 15" mbps, late 11 iMac, iPhone 4s, and too many ipods and other stuff
|
Sure, you can simply add the directory to your path. You'd just need to add something like
export PATH=/path/to/commands:$PATH to your .profile or .bashrc , etc then restart your terminal login mike This machine kills fascists Got # ? phear the command line! Last edited by vansmith; 01-03-2012 at 10:02 AM. Reason: Disabled smileys so the command appears properly ;) |
| QUOTE Thanks | |
![]() Member Since: Oct 19, 2008
Location: Ottawa
Posts: 15,453
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Mac Specs: 2012 13" MBP (2.5 i5, 8GB)
|
I've no idea why this would have happened (why these binaries are in non-standard directories). I wonder how much is in non-standard locations...
Out of curiosity, where did you end up finding these tools? Important Links: Community Guidelines : Use the reputation system if you've been helped. M-F Blog :: Write for the blog :: M-F IRC Channel - Chats every Sunday at 8PM EST. |
| QUOTE Thanks | |
|
Member Since: Feb 26, 2010
Location: Rocky Mountain High, Colorado
Posts: 2,116
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Mac Specs: 1.8 GHz i7 MBA 11" OSX 10.8.2
|
Are they executable? i.e.
Code:
ls -l netstat -r-xr-xr-x 1 root wheel 218752 Jul 20 16:30 netstat* So they do have to be in the Path as dysfunction mentions, but they also have to be executable. Code:
chmod 555 netstat |
| QUOTE Thanks | |
![]() Member Since: Oct 19, 2008
Location: Ottawa
Posts: 15,453
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Mac Specs: 2012 13" MBP (2.5 i5, 8GB)
|
The export command will only work for the session. You need to add that to your .bash_profile in your home directory such that the path is added every time you open up Terminal.
I don't understand why you have a /usr/tbin directory. Do you have /usr/sbin? If not, it's possible that sbin was moved to tbin (for whatever reason). Important Links: Community Guidelines : Use the reputation system if you've been helped. M-F Blog :: Write for the blog :: M-F IRC Channel - Chats every Sunday at 8PM EST. |
| QUOTE Thanks | |
![]() Member Since: Mar 17, 2008
Location: Tucson, AZ
Posts: 6,588
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Mac Specs: 2008 and 2011 15" mbps, late 11 iMac, iPhone 4s, and too many ipods and other stuff
|
Yes, if you have a .bash_profile you need to use that. If you don't, it should pick up .profile. Sounds like you have a .bash_profile.
mike This machine kills fascists Got # ? phear the command line! |
| QUOTE Thanks | |
| Post Reply | New Thread | Subscribe |
| Thread Tools | |
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
|
|
|
|
|||||||
Thread |
Thread Starter |
Forum |
Replies |
Last Post |
| Automatically save log files of terminal sessions | Stubaan | OS X - Apps and Games | 3 | 04-02-2013 11:24 AM |
| Terminal Won't Open | icefall5 | OS X - Operating System | 7 | 08-25-2010 08:26 AM |
| isight isn't working at all whatsoever! Help? | Dejerademy | Apple Notebooks | 1 | 07-01-2010 10:48 AM |
| Automated Terminal Commands | sarahsboy18 | OS X - Operating System | 3 | 09-09-2005 07:39 PM |
| useful terminal commands | moz | Switcher Hangout | 4 | 06-24-2005 11:06 AM |
All times are GMT -4. The time now is 09:07 AM.
Powered by vBulletin