Is there a way to change the torrenting port without restarting QBittorrent?

Linux specific questions, problems.
Post Reply
metricspace
Newbie
Newbie
Posts: 3
Joined: Thu Mar 28, 2024 12:15 pm

Is there a way to change the torrenting port without restarting QBittorrent?

Post by metricspace »

This is it, I basically have a script to enable portforwarding.

The function that does it, natpmpc, changes the port randomly so I have to get the new port, close Qbittorrent, and reopen with the new port using
qbittorrent --torrenting-port="$port" &

Is there a way to change the port on the current session of Qbittorrent, similar as if you changed it in preferences?
chruez007
Newbie
Newbie
Posts: 3
Joined: Sat Apr 20, 2024 5:35 pm

Re: Is there a way to change the torrenting port without restarting QBittorrent?

Post by chruez007 »

Hi i do change the port as follows

curl -i -X POST -d "json={\"listen_port\": $port}" "http://localhost:8080/api/v2/app/setPreferences"
and ensure you have activated
"Bypass authentication for clients on localhost" so your user is permitted to update the port
Post Reply