-1

I want to start a python server when raspberry pi reboots. I have written in this file sudo nano /home/pi/.bashrc my python3 command to start the .py script, but every time raspberry pi reboots the terminal shows me:

[Errno 98] Address already in use. 

When I run pgrep python3, it shows that I already have a python process running.

Mario
  • 1,631
  • 2
  • 21
  • 51
  • Does this answer your question? [python socket.error: \[Errno 98\] Address already in use](https://stackoverflow.com/questions/17780291/python-socket-error-errno-98-address-already-in-use) – Tomer Shetah Oct 03 '20 at 22:13

1 Answers1

0

There are two python processes attempting to use the same port. You have to change the configuration of either one of them to use a different port so both of them can start. How you do this depends on your exact invocation, for illustration look at this flask invocation:

flask run --port=5001
oschlueter
  • 2,596
  • 1
  • 23
  • 46