Questions about the command line and other Unix-like aspects of Mac OS X, including the Mach/BSD-based kernel and FreeBSD-based userland. You may want to consider using Ask Different instead.

learn more… | top users | synonyms (1)

1
vote
1answer
20 views

how to change git path?

So I just installed the latest git, with the official mac installer. I'm on Mavericks. Sadly, git --version is still git version 1.9.3 (Apple Git-50) and which git gives me: /usr/bin/git ...
2
votes
1answer
63 views

bash find: get directory of found file

I have a parent folder named "parent_folder" with a lot of subfolders, in these subfolders is a file named "foo.mp4". I can find these files easily by doing this: mymacbook:parent_folder username$ ...
3
votes
3answers
84 views

Get modification date that can be used with touch -m

I need to get the modification date of a file so that I can set it on other files using touch -m. stat or perl -le 'print((stat shift)[9])' Didn't return what I wanted. I think that you are supposed ...
1
vote
2answers
31 views

Why does terminal say I have mail every time I open it?

I am using OSX 10.9.5 Whenever I open a terminal, it says something like: Last login: Wed Jan 21 10:29:13 on ttys002 You have mail. What mail is it talking about ? If I open the mail app, I have ...
0
votes
0answers
15 views

Can't boot into slackware installer

Can't boot into Slackware installer, I get stuck in this: The last line I see is: mousedev: PS/2 mouse device common for all mice I tried a external Keyboard with Mouse (Cordless but at least ...
0
votes
0answers
10 views

Mac OS X package installer generation/building on Ubuntu 14.04

I'm implementing a building server for an application that will run on Android, Linux and Mac OS X. I already have in place the scripts for apks and debs generation and I need to do the same for Mac ...
3
votes
1answer
52 views

Mac OS X combine cp and cat to sequentially copy and rename files in list

I am using a MacBook Pro OS X 2013 model. I have a list of filenames in a text file named list.txt separated by line breaks list.txt exactly like this, but this list is going to be long e.jpeg ...
1
vote
0answers
16 views

Same Swap Partition in Multi Boot [closed]

I have a Macbook Pro with 256 GB of space and 8GB of RAM. and I want to make a multi boot like: Mac OS X 120 GB Windows 8.1 30 GB Ubuntu 14.04.1 30 GB Debian 7.7 25GB Arch Linux 15 GB COMMON ...
0
votes
0answers
18 views

httpd -k stop/ start not working OS X

GE-Erics:~ eric$ httpd -k stop AH00548: NameVirtualHost has no effect and will be removed in the next release /private/etc/apache2/extra/httpd-vhosts.conf:19 AH00112: Warning: DocumentRoot ...
0
votes
1answer
71 views

Using the cURL command, how does one fetch stock data which comes back *without* commas and spaces?

What can I add to the below script so that it fetches the stock data and brings it back WITHOUT any commas and spaces? For example GOOG Outstanding shares is 675,000,000. I desire the output of ...
2
votes
0answers
38 views

Increase SSH ConnectTimeout greater than 60 seconds

I don't seem to be able to increase the SSH connection timeout much beyond a minute: $ date; ssh home-qnap -o ConnectTimeout=7200; date Wed 14 Jan 2015 15:23:32 AEDT ssh: connect to host home-qnap ...
0
votes
1answer
28 views

How do I mount an SD card?

My SD card will suddenly not automount. It works on another Mac. Can someone provide a solution to mount with Terminal? $ diskutil list /dev/disk2 #: TYPE NAME ...
2
votes
1answer
58 views

How can I change “Mount Point” that has been changed to normal?

previously I has been trying to install Kali Linux on my usb. Now here is the problem, I have used the command sudo dd if=kali.dmg of=/dev/rdisk1 bs=512k which I think it changed or replaced my ...
1
vote
2answers
44 views

Locked out of my own mac terminal?

So recently, some of my friends had been tampering with my files and data through terminal, so I decided to secure it by doing two things: First, I added the following to my ~/.bash_profile for ALL ...
2
votes
1answer
21 views

How to upgrade File::Path on my Mac OS X as a non-root user

My mac machine is quite old (Mac OS X 10.6.8) and I have a question on how to upgrade a perl module File::Path. I mostly compile my LaTeX document using latexmk which is basically a perl script. It ...
2
votes
1answer
20 views

on osx vim 7.3 set number set relative number not working

I'm using OSX Mavericks. Using VIM 7.3, I can't seem to get the "hybrid" line numbers to work. I was reading a tutorial stating that if both set number and set relativenumber were included in the ...
0
votes
1answer
46 views

Can't concat file paths, permission denied

I can't realize why if I just try to concat some file paths (without opening the files), I get "permission denied": #!/bin/bash if [ "$#" -eq 1 ]; then path1= "./src/$1" path2= ...
3
votes
3answers
110 views

For some IPs, ping -c 4 -W 1 ip | cat does not output anything until ping has finished, whereas it does for others

Why do $ ping -c 4 -W 1 127.0.0.1 | cat and $ ping -c 4 -W 1 1.1.1.1 print their output immediately, whereas $ ping -c 4 -W 1 1.1.1.1 | cat prints nothing for four seconds, then prints all ...
0
votes
0answers
13 views

Including Directories in Locate on Mac OS X

Can anybody shed light on which directories OS X decides to put in the locate database and which it decides to omit? It's pretty clear that ~/Library is out - which others? And how do I modify this ...
1
vote
0answers
29 views

Unable to create a configuration directory for [FishShell] Please set the $XDG_CONFIG_HOME variable

I'm getting this error when starting fishshell: melanie:~ melanie$ fish fish: Unable to create a configuration directory for fish. Your personal settings will not be saved. Please set the ...
1
vote
1answer
35 views

Recover partitions Mac OS internal hd

I booted to a live ubuntu USB, wanting to delete partitions on an SD card, and ended up deleting all my partitions on my mac book pro's internal hd. I have already tried gpart (which gets stuck at ...
4
votes
6answers
642 views

grep invading my ps [duplicate]

When I'm checking for some process, I usually write ps aux | grep myprocess And sometimes I get the output of eimantas 11998 0.0 0.0 8816 740 pts/0 S+ 07:45 0:00 grep myprocess if ...
3
votes
1answer
39 views

Mount USB on Read-Only filesystem

I've got a damaged Mac filesystem, and in single-user mode the command mount -uw / fails (error is something like SATA warning: Enable auto-activate failed). However, I don't need the whole filesystem ...
5
votes
1answer
184 views

How to persist ulimit settings in OSX Yosemite?

Previous question about doing this on Mavericks is here and the answers there don't seem to work on Yosemite. I want to enable core dump generation by default upon reboot. Executing ulimit -c ...
2
votes
0answers
30 views

What are the benefits of using Tmux at all times? [closed]

I have been using the terminal for all of my local work, and have only been using tmux when I am ssh'd onto another machine and want to make sure I don't lose work if the connection closes. A software ...
0
votes
1answer
130 views

Problems booting Kali Linux 1.0.9a 64 bit on Macbook Pro

I have a mid 2009 Macbook Pro that I am trying to dual boot OS X and Kali Linux on. I replaced my optic drive with my old HDD and replaced my HDD with an SSD. OS X and my apps are running off of the ...
0
votes
0answers
14 views

Accessing xfig from x11 fails

I am trying to get access to xfig from x11 on my mac to draw some diagrams and including them in latex, but it shows the following error bash-3.2$ xfig dyld: Library not loaded: ...
0
votes
2answers
274 views

How to install Broadcom BCM4360 on debian on Macbook pro

I'm trying to install the wireless drivers because my macbook pro does not have a ethernet port, then I mount the 3 debian isos like local repositories to install the almost all of dependeces. So, ...
1
vote
1answer
23 views

Accounting for “missing memory” from sysctl

I'm on OS X Yosemite, ran this code: unsigned long num_; sysctl((int[]){CTL_HW, HW_PHYSMEM}, 2, &num_, &len, NULL, 0); printf("AMT MEM: , %lu\n", num_); and getting back 140735340871680 ...
-1
votes
2answers
15 views

OSX bash. grep for string “--version=”

How can I search for string --version= using grep in OSX bash? When I try something like this: grep -rI --exclude-dir=out "--version=" . I get grep: option `--version' doesn't allow an argument ...
2
votes
2answers
86 views

Output of stat on OSX

I want to use the stat command to get information on a file. I did this: Josephs-MacBook-Pro:Desktop Joseph$ echo 'hello' > info.txt Josephs-MacBook-Pro:Desktop Joseph$ stat info.txt 16777220 ...
2
votes
0answers
26 views

X forwarding from a mac to Linux fails

I have been having problems recently while trying to ssh into linux servers (Ubuntu 14.04) from my mac (OSX Yosemite 10.10). This used to work fine until my latest update, where I systematically get a ...
1
vote
1answer
39 views

Is there a /dev/pts alternative on Mac OSX?

I'm attempting to determine how many terminal windows are open, as described in this Q&A answer. However there doesn't seem to be a /dev/pts on Mac OSX. Is there an alternative to this?
1
vote
0answers
40 views

Tmux hangs on first start

I am running Tmux on a OSX (brewed tmux), and everytime I boot my computer, the first time I start tmux, it hangs. Doing a CTRL + T to check it's SIGINFO, gives me "waiting..". To fix this, I need to ...
4
votes
1answer
154 views

Untar a specifc folder within tar.gz

How do I untar/uncompress a specific folder within a tar.gz using the terminal/commandline (Ubuntu 14.04 (Trusty Tahr))? Precise: -file.tar.gz -- folder1 -- folder2 How to extract... ... ...
2
votes
0answers
35 views

“login -qf” as root results in “Login incorrect” error

I'm trying to install pow on an OS X machine.* Some of pow's components have to run as root, so part of the setup process involves running an installation script with sudo. The problem is, this setup ...
2
votes
1answer
33 views

Can't use `od` command with directories

I'm trying to use the od command in a directory in OSX but it doesn't proceed and it results in the error message: od: .: Is a directory Could you please help me with it or any equivalent command? ...
2
votes
1answer
26 views

How to make PATH variable exports on MacOSX persistent?

I do export http_proxy=http://proxy:8080 export ALL_PROXY=$http_proxy on my Mac. Brew for instance relies on these settings. How can I make these settings stick between power cycles? Is this the ...
0
votes
1answer
31 views

Installing PHP on OS X. Syntax errors?

When installing OS X on Yosemite with curl -s http://php-osx.liip.ch/install.sh | bash -s 5.6, I get the following: **** [WARNING] Detected OS X Yosemite 10.10. As this is quite new, there may be ...
1
vote
6answers
129 views

How to convert dashed string to spaces and caps?

Given the string foo-bar, what is a good way to convert it to Foo Bar? Using Bash, OSX.
0
votes
0answers
42 views

Why do I get a “preauth required” error when I set “require-preauth = false” in krb5.conf?

On an OS X machine, I'm trying to get a kerb ticket on my organization's kerberos realm. I grabbed a copy of krb5.conf from a Linux machine to make sure my kerberos configuration was correct. I tried ...
1
vote
1answer
108 views

MacOS X Mavericks running VirtualBox cannot communicate with Linux VM

I have a MacOS X Mavericks host running Vagrant using VirtualBox as a provider. I have experienced several times that with different VMs (particularly Ubuntu Linux VMs) after the first time the VM is ...
0
votes
0answers
24 views

Why are some processes “killable” by pkill but not killall?

I had over 20 instances of httpd (apache) processes running, so I decided to shutdown these. Normally I use killall, But when I typed killall httpd it just said: No matching processes belonging to ...
1
vote
2answers
44 views

SSH Tunneling Through a Firewall to a Cluster

I work at a university but I often work remotely. There is a cluster computer at the university that I need to be able to interact with, but its behind a firewall. Let's call the firewall F and the ...
1
vote
1answer
27 views

Symlink all files in a directory with the entire directory tree

Right now I use this ln -s /dir/* /dir2/ Which will symlink everything, but I have to go inside the dir and make a new directory because the folders are also symlinked (this is expected). So here ...
0
votes
1answer
43 views

Is hardware helping reducing crashes of OS X? [closed]

I am taking an OS course this semester, and we mentioned that device drivers can cause about 85% of crashes(for Windows). My understanding is that: since many personal computers are configured with a ...
1
vote
2answers
53 views

Compare directory trees regarding file name (and size and date)

I want to check the results of a restore from backup. This is, because TimeMachine on MacOS gives me some weird errors and warnings and I want to make sure, everything is in its place again after ...
1
vote
2answers
80 views

How to execute Mach-O 32-bit C++ program on Linux?

I want to execute a program (which I know was written in C++), but I get this error: zsh: exec format error: ./myProgram Output of file myProgram: myProgram: Mach-O i386 executable My system is ...
0
votes
0answers
48 views

How to troubleshoot: “X11 connection uses different authentication protocol.”

I start an ssh session with localbox % ssh -vvv -Y remotebox 2>debug_ssh_log ...which succeeds. Then I try to run xlogo on remotebox, but the command fails immediately, and the following lines ...
0
votes
1answer
43 views

.bash_history keeps truncating

My .bash_history keeps truncating even though I set: export HISTSIZE= export HISTFILESIZE= On my .bash_profile. Im not sure when it happens but it might happen when I logout or shut down my ...