GoogleCloudPlatform / GoogleCloudPlatform/gsutil

Multiprocessing "Permission Denied" error when using pyenv on Ubuntu

Open
#995 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
918
Forks
335
PR merge metrics
No merged PRs in 30d

Description

I installed gsutil through the cloud sdk apt package for ubuntu 18.04, and I'm trying to use gsutil with a pyenv python version. I get a lot of these errors (although the commands seem to still work):

```
File "/home/sabu/.pyenv/versions/3.7.7/lib/python3.7/multiprocessing/process.py", line 297, in _bootstrap
self.run()
File "/home/sabu/.pyenv/versions/3.7.7/lib/python3.7/multiprocessing/process.py", line 99, in run
self._target(*self._args, **self._kwargs)
File "/home/sabu/.pyenv/versions/3.7.7/lib/python3.7/multiprocessing/managers.py", line 589, in _run_server
server = cls._Server(registry, address, authkey, serializer)
File "/home/sabu/.pyenv/versions/3.7.7/lib/python3.7/multiprocessing/managers.py", line 145, in __init__
self.listener = Listener(address=address, backlog=16)
File "/home/sabu/.pyenv/versions/3.7.7/lib/python3.7/multiprocessing/connection.py", line 438, in __init__
self._listener = SocketListener(address, family, backlog)
File "/home/sabu/.pyenv/versions/3.7.7/lib/python3.7/multiprocessing/connection.py", line 581, in __init__
self._socket.bind(address)
PermissionError: [Errno 13] Permission denied
```

@houglum you seemed to mention this might happen if a user had multiple versions of python installed [in this comment](https://github.com/GoogleCloudPlatform/gsutil/issues/576#issuecomment-470737729)? These errors don't happen if I use the system python3, but I'd like to avoid that if possible, since it's behind the latest security point release.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.