Hi I am following the instruction from https://tensorflow.github.io/serving/setup
to install TensorFlow Serving dependencies on my Mac OS X
with the following command:
$ sudo apt-get update && sudo apt-get install -y
build-essential \ curl \ libcurl3-dev \ git \ libfreetype6-dev \ libpng12-dev \ libzmq3-dev \ pkg-config \ python-dev \ python-numpy \ python-pip \ software-properties-common \ swig \ zip \ zlib1g-devPassword:
Got the following error message:
_sudo: apt-get: command not found_
Can use brew to do the above instead of apt-get? Or it's better to download apt-get for my Mac, then use it to do the installation?
Thanks
Hi,
The install instructions are specific to Linux. Mac is not supported. Some adventurous people have installed TensorFlow Serving on their Macs. Homebrew https://brew.sh is what most seem to prefer to install packages on the Mac. It is the package manager that I feel most comfortable to not mess my Mac up.
At least in my case I use Docker for Mac for some development, but do most development running Linux (Mostly Ubuntu) with VirtualBox on my Mac. I keep several disposable VMs for various projects. I like the idea of not polluting my Mac OS with too much development cruft.
Thanks @mountaintom!
thanks @mountaintom for sharing
First post to Github... Anyways, I've been getting _sudo: apt-get: command not found_ .
I'm running Yosemite 10.10.5 and have tried to download various Frameworks for python using _sudo_ through my terminal as well as trying to download IDEs.. I keep getting _sudo: apt-get: command not found_ .
Any idea what could be causing this??
Hi,
apt-get is intended for installing packages on Linux systems. Homebrew is the equivalent for the Mac. It looks like Mac installs are still not officially supported; but some people have been successful in installing on their Macs. I checked to see what I could find regarding Mac installs, and it looks like people are using the Bazel source install. To install the prerequisite they are using Homebrew. Additionally, you will need to install Xcode. The following issue pops up repeatedly https://github.com/tensorflow/serving/issues/389 , however the issue may have been resolved.
It would be nice if someone who has done a Mac install would share how they did it, and if there is a better/easier way than what I'm describing here.
To get apt-get on the mac, You'll want the Fink package.
What I don't know is what are the distinctions/differences between Fink (apt-get), MacPorts (port), and Homebrew, these days.
Hi
It seems like Fink is needed when getting apt-get on Mac,
to do that, you may need to download Xquartz and fink
But sadly, I failed and got the ERROR: Can't create symlink /sw2/fink/10.13 from terminal
and couldn't find a way to solve that :( I am wondering if anyone knows...
The error happens because the binary you are trying to call from command line is only part of the current user's PATH variable, but not a part of root user's PATH.
You can verify this by locating the path of the binary you are trying to access. In my case I was trying to call "bettercap-ng". So I ran,
$ which bettercap-ng
output: /home/user/work/bin/bettercap
I checked whether this location is part of my root user's PATH.
$ sudo env | grep ^PATH
output: PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin
So sudo cannot find the binary that I am trying to call from commandline. Hence returns the error command not found.
You can direct sudo to use the current user's PATH when calling a binary like below.
$ sudo -E env "PATH=$PATH" [command] [arguments]
In fact, one can make an alias out of it:
$ alias mysudo='sudo -E env "PATH=$PATH"'
It's also possible to name the alias itself sudo, replacing the original sudo.
Please refer to this video for step by step solution
@mountaintom Hi, can you please tell how did you get the apt-get command running through a virtual box. I tried using Homebrew but it doesn't help.
Thanks.
Hi,
Any one got a solution to "sudo: apt-get: command not found" for linux.
Would be a great help.
Regards,
Mahantesh
Most helpful comment
Hi,
The install instructions are specific to Linux. Mac is not supported. Some adventurous people have installed TensorFlow Serving on their Macs. Homebrew https://brew.sh is what most seem to prefer to install packages on the Mac. It is the package manager that I feel most comfortable to not mess my Mac up.
At least in my case I use Docker for Mac for some development, but do most development running Linux (Mostly Ubuntu) with VirtualBox on my Mac. I keep several disposable VMs for various projects. I like the idea of not polluting my Mac OS with too much development cruft.