mirror of
https://github.com/Ysurac/openmptcprouter-vps-admin.git
synced 2025-03-09 15:40:05 +00:00
Littles fixes
This commit is contained in:
parent
7d5f915c86
commit
9b5aba4a55
1 changed files with 7 additions and 5 deletions
12
omr-admin.py
12
omr-admin.py
|
@ -192,11 +192,13 @@ def mptcp():
|
||||||
scheduler = params.get('scheduler', None)
|
scheduler = params.get('scheduler', None)
|
||||||
syn_retries = params.get('syn_retries', None)
|
syn_retries = params.get('syn_retries', None)
|
||||||
congestion_control = params.get('congestion_control', None)
|
congestion_control = params.get('congestion_control', None)
|
||||||
os.system('sysctl -w net.mptcp.mptcp_checksum='+checksum)
|
if not checksum or not path_manager or not scheduler or not syn_retries or not congestion_control:
|
||||||
os.system('sysctl -w net.mptcp.mptcp_path_manager='+path_manager)
|
return jsonify({'result': 'error','reason': 'Invalid parameters'})
|
||||||
os.system('sysctl -w net.mptcp.mptcp_scheduler='+scheduler)
|
os.system('sysctl -w net.mptcp.mptcp_checksum=' + checksum)
|
||||||
os.system('sysctl -w net.mptcp.mptcp_syn_retries='+syn_retries)
|
os.system('sysctl -w net.mptcp.mptcp_path_manager=' + path_manager)
|
||||||
os.system('sysctl -w net.ipv4.tcp_congestion_control='+congestion_control)
|
os.system('sysctl -w net.mptcp.mptcp_scheduler=' + scheduler)
|
||||||
|
os.system('sysctl -w net.mptcp.mptcp_syn_retries=' + syn_retries)
|
||||||
|
os.system('sysctl -w net.ipv4.tcp_congestion_control=' + congestion_control)
|
||||||
return jsonify({'result': 'done'})
|
return jsonify({'result': 'done'})
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue