Hot answers tagged

4

Booting Ubuntu on a dual boot partition has a similar battery life to OS X, perhaps slightly shorter, due to less efficient optimization for the MacBook Pro's hardware. In a virtual machine, despite lots of "clever" optimizations and CPU hardware virtualization features, there are two complete operating systems, with two kernels, and two display managers* ...


3

Under csh family shells, you'll got your running shell with this command: % echo $shell If csh was run, directly or undirectly, from a Bourne family shell that had its SHELL variable exported, the latter being the common case, the SHELL variable would stay untouched so echo $SHELL will still show the its previous value which would be confusing. This is ...


3

It depends on the shell you are running in. If it is a POSIX confirming shell e.g. bash, ash,ash, sh, and some others e.g. csh, tcsh then echo $0 will return the shell's name e.g. ~ $ bash bash-3.2$ echo $0 bash or ~ $ ksh $ echo $0 ksh However not all shells are POSIX e.g. I used to use ipython shell profile and now fish


2

Yes, running Ubuntu natively (dual booting) may be a better way, but you will lose all "pros" of your MacBook Pro 2015 (Mac OS X). There is another way of "using Ubuntu," which is Docker. I bet you have heard of it, but you may not know that the latest Docker beta uses a native virtualization mechanism, and it does not need VirtualBox, or any other virtual ...


1

I have a (17-inch, early 2006) iMac which, like your Mac, is a 32 bit machine. I downloaded the file Fedora-Live-Workstation-i686-23-10.iso from Fedora. This is the "32-bit 1.3GB Live Image" found at this web page. Next, I burned the file to a RW DVD. I inserted the DVD in my Mac and held down the option key at startup. A DVD icon label "Windows" appeared. ...


1

I see in your question, per the second and third bullet points, you are attempting to boot the USB Flash Drive via UEFI. From 4.2 UEFI boot of USB sticks on How to create and use Live USB There are two MacBook Pro's with Model Number A1150, both having the Model Identifier MacBookPro1,1 with one of the following Processors, Intel Core Duo (T2400, T2500, ...


1

Best I've been able to come up with myself is to write a script that runs iftop -f "dst net REMOTE_IP" -t in the background, redirecting the output, and after a certain timeout kills the process, and then grep/awk my way through the redirected output. Hardly elegant.


1

Another way would be to check which TTY your terminal is attached to and check which shell is running on that tty. Then you could look at the PID (Process ID) and PPID (Parent Process ID) in case your shell has spawned another shell as a child process: MacBook:~$ w 15:16 up 8 days, 16:11, 2 users, load averages: 1.26 1.22 1.24 USER TTY FROM ...


1

I adapted Greg Ercolano's perl script to python script. #!/usr/bin/env python2.7 import subprocess as subp import os.path import sys import re from collections import defaultdict def psaxo(): cmd = ['ps', 'axo', 'ppid,pid,comm'] proc = subp.Popen(cmd, stdout=subp.PIPE) proc.stdout.readline() for line in proc.stdout: yield ...



Only top voted, non community-wiki answers of a minimum length are eligible