Skip to content
This repository has been archived by the owner on Oct 30, 2018. It is now read-only.

OSX10.10.2 atcd can not work with error NotImplementedError: darwin backend is not implemented! #68

Closed
boxerxing opened this issue Mar 25, 2015 · 4 comments
Labels

Comments

@boxerxing
Copy link

I download and install ATC according to the readme file block in step run atcd with following issue:Traceback (most recent call last):
File "/usr/local/bin/atcd", line 13, in
runner.run()
File "/usr/local/lib/python2.7/site-packages/atcd/scripts/runner.py", line 34, in run
initialize_thrift()
File "/usr/local/lib/python2.7/site-packages/atcd/scripts/runner.py", line 27, in initialize_thrift
AtcdThriftHandlerTask.factory().register()
File "/usr/local/lib/python2.7/site-packages/atcd/AtcdThriftHandlerTask.py", line 203, in factory
'{0} backend is not implemented!'.format(os_name.lower())
NotImplementedError: darwin backend is not implemented!

I use two ways install thrift but always got the same error above.
brew install thrift and git clone source code
hope you give me some advance.

@chantra
Copy link
Contributor

chantra commented Mar 25, 2015

Hi @boxerxing
thank you for reporting this. Unfortunately, we only support Linux for now.

The darwin backend could be implemented, but this is not yet on the roadmap. If you want to give it a try, PRs are welcome :) .
I believe pf can provide the same functionality on MacOSX/BSD, but I have not really given it a look.

Also, mind that ATC must run on a gateway, so to be able to have ATC to shape you traffic, it should be routing the traffic of the devices you want to shape the traffic for.

If you want to fiddle with ATC, you can run it in a VM though as explained in http://facebook.github.io/augmented-traffic-control/docs/contributing.html

This is mainly use for developing on ATC and/or testing, but that can give you a good overview on how it works.

@boxerxing
Copy link
Author

@chantra thank you for your help.I'll try it on ubuntu 13.04 system but Django and MySQL always apt-get failed... I hope use ATC on iPhone between OSX .

@boxerxing
Copy link
Author

Great!,The ATC env is build done,but i have another problem,After i config both files ("atcui/settings.py" and "atcui/urls.py") as your doc,then i run "sudo atcd" under virtual env,but the atcd server couldn't be luanched with issue: (Could you help me ? i do sudo atcd --atcd-eth0 failed like this.)
INFO:AtcdVService.AtcdNBServerTask:AtcdNBServerTask Server Started on 127.0.0.1:9090
CRITICAL:AtcdVService.AtcdLinuxShaper:One of the following interfaces does not exist: eth1, eth0
ERROR:sparts.tasks:Error creating task, AtcdLinuxShaper
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/sparts/vtask.py", line 313, in init
t.initTask()
File "/usr/local/lib/python2.7/dist-packages/atcd/backends/linux.py", line 48, in initTask
super(AtcdLinuxShaper, self).initTask()
File "/usr/local/lib/python2.7/dist-packages/atcd/AtcdThriftHandlerTask.py", line 220, in initTask
self._links_lookup()
File "/usr/local/lib/python2.7/dist-packages/atcd/backends/linux.py", line 65, in _links_lookup
raise Exception(msg)
Exception: One of the following interfaces does not exist: eth1, eth0
ERROR:AtcdVService:Unexpected Exception during init
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/sparts/vservice.py", line 268, in _runloop
instance._createTasks()
File "/usr/local/lib/python2.7/dist-packages/sparts/vservice.py", line 167, in _createTasks
self.tasks.init()
File "/usr/local/lib/python2.7/dist-packages/sparts/vtask.py", line 332, in init
len(exceptions))
Exception: Unable to start service (1 task start errors)
INFO:AtcdVService:Received graceful shutdown request
DEBUG:AtcdVService:VService Active. Awaiting graceful shutdown.
INFO:AtcdVService:Waiting for tasks to shutdown gracefully...
DEBUG:AtcdVService:Waiting for <atcd.AtcdDeviceTimeoutTask.AtcdDeviceTimeoutTask object at 0x183b050> to stop...
DEBUG:AtcdVService:Waiting for <atcd.backends.linux.AtcdLinuxShaper object at 0x1838310> to stop...
DEBUG:AtcdVService:Waiting for <atcd.AtcdDBQueueTask.AtcdDBQueueTask object at 0x18383d0> to stop...
DEBUG:AtcdVService:Waiting for <atcd.AtcdThriftHandlerTask.AtcdNBServerTask object at 0x17ebed0> to stop...
INFO:AtcdVService:Instance shut down gracefully

@chantra
Copy link
Contributor

chantra commented Mar 26, 2015

@boxerxing
atcd needs to run on a device that routes traffic. To do that, it needs 2 interfaces:

Exception: One of the following interfaces does not exist: eth1, eth0
ERROR:AtcdVService:Unexpected Exception during init

Typically, one of the network interface is connected to your internal network (can be configured with --atcd-lan and defaults to eth1) and one is connected to your uplink to the internet (--atcd-wan and defaults to eth0)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants