Opened 7 years ago

Last modified 6 months ago

#2740 new enhancement

Schedule different torrc options (e.g. bandwidth) at different times

Reported by: chiiph Owned by: chiiph
Priority: Medium Milestone: Vidalia: 0.3.x
Component: Archived/Vidalia Version:
Severity: Normal Keywords:
Cc: nickm Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

Migrated from old trac:

"I would imagine that more people would end up sharing if there were some more customizable features

For example a limit of what times would be allocated to sharing and limits for different times of different days

I have an on peak, I would think about sharing 1 GB on that, and 75GB on my off peak

It is very simple and practical to implement"

Child Tickets

Change History (12)

comment:1 Changed 7 years ago by arma

Summary: More managable sharing optionsSchedule different torrc options (e.g. bandwidth) at different times

comment:2 Changed 7 years ago by arma

See also
https://trac.torproject.org/projects/tor/wiki/TheOnionRouter/CronBandwidthLimit
and
https://trac.torproject.org/projects/tor/wiki/TheOnionRouter/BandwidthLimitChangeController
and
#1730.

One challenge here is that with Mike's bandwidth measurement scripts, we measure each relay every couple of days. So we will end up assigning one bandwidth weight even if its rate limit changes. See #2550 there. But I think that's torflow's problem, not Vidalia's problem, so it's no reason to avoid a feature like this.

comment:3 Changed 7 years ago by Bry8Star

A few network traffic flow bandwidth Scheduling command options or features for both Tor and Vidalia would be highly welcome and expected by us all.

When a home computer user returns to home, lets say, around evening, from then and before midnight, if the network bandwidth (KiloBytes/seconds , or, MegaBytes/seconds) usage can be kept at a minimum level, then many user would prefer to use it as a "relay", at least as a 'middleman' relay.

A nice GUI interface can be implemented in vidalia, a graphical table which has minimum 24 columns for the 24 hours in each day, and a minimum 7 rows for the seven days (monday, tuseday, wednesday, ...) of week. By default bandwidth usage should be kept at some minimum level, so each cell/box in that table will show 'L' to signify that its in a 'Limited' bandwidth usage mode in that hour/time range. When clicked on a cell/box in that table, then that hour/time mode will change from 'L' to 'F', to set a 'Full' bandwidth usage mode, if clicked again then a "NR" will be showed to set "No Relay" mode, or "RO" (Relay Off) mode/period of time, at least those 3 modes are necessary. Then at least 2 text fields to specify : "Max Bandwidth(KB/s)" & "Limited Banwidth(KB/s)" numbers.

During a discussion in irc channel on this subject, 'arma' said, the windows port/edition of tor currently (Mar 15, 2011) does not understand the 'hup' signal to restart tor. So that needs to be fixed.

The user 'grey' said : a windows NET stop [service]
NET start [servoce]
NET pause/continue
can/may be used.

A portable perl (like, Strawberry Perl) can be used to run the perl script mentioned by 'arma', in windows too, then a windows batch can be used to run that script through perl for now, before a GUI is made, if the windows tor at least able to handle such scheduling options.

Without breaking the existing tor 'circuits', if the Tor can be commanded to lower the bandwidth usage, then that would be an awesome feature.

comment:4 in reply to:  3 Changed 7 years ago by arma

Replying to Bry8Star:

During a discussion in irc channel on this subject, 'arma' said, the windows port/edition of tor currently (Mar 15, 2011) does not understand the 'hup' signal to restart tor. So that needs to be fixed.

That can't be fixed -- it's a problem with Windows. Fortunately, Vidalia doesn't need signals to make Tor reload, since it uses the control port to speak to Tor.

The user 'grey' said : a windows NET stop [service]
NET start [servoce]
NET pause/continue
can/may be used.

Also probably not what we want, a) since Tor is typically started by Vidalia, not as a service, and b) since again Vidalia gets to use the control port.

A portable perl (like, Strawberry Perl) can be used to run the perl script mentioned by 'arma', in windows too, then a windows batch can be used to run that script through perl for now, before a GUI is made, if the windows tor at least able to handle such scheduling options.

Yes, that should work right now, but it will take some playing around with the scripts. You'll want to tell Vidalia to pick a particular control password for Tor (see Vidalia's Advanced window), and then you'll need to teach your script that password.

comment:5 Changed 7 years ago by chiiph

Milestone: Vidalia-0.3.X

comment:6 Changed 7 years ago by Neo139

+1
I currently have a middle node at home donating 20% of my bandwidth. I used to increase % before going to sleep. I would like to donate 95% of my bandwidth at the times I'm sleeping.
Hope this get implemented soon

comment:7 Changed 7 years ago by karsten

Cc: nickm added
Component: VidaliaTor Relay

Tomás and I wondered if this feature should be implemented in Vidalia or in tor. Similar to the accounting stuff, tor could have a configuration option for scheduling daytime and nighttime bandwidth limits, or even something more customizable.

I'm changing this to component Tor Relay, so that Nick sees it. If it's a stupid idea and it should remain a Vidalia ticket, please someone change it back.

comment:8 Changed 7 years ago by Sebastian

I think this is a perfect idea for a controller, not for Tor itself. The controller will have all the Ui challenges associated with it, and since tor already supports this via changing config and HUP, I don't think we have to majorly complicate the configuration options to support this via torrc

comment:9 in reply to:  8 Changed 7 years ago by chiiph

Replying to Sebastian:

I think this is a perfect idea for a controller, not for Tor itself. The controller will have all the Ui challenges associated with it, and since tor already supports this via changing config and HUP, I don't think we have to majorly complicate the configuration options to support this via torrc

I agree. But the thing we also consider is that this would be a nice feature to have regardless of the controller used.

comment:10 Changed 7 years ago by nickm

My main reason for thinking that this belongs outside of Tor proper is that I've got no idea where it would ever end. Scheduling is complex, and the range of things that you might want to schedule in Tor is pretty huge.

comment:11 Changed 6 years ago by nickm

Component: Tor RelayVidalia

comment:12 Changed 6 months ago by teor

Severity: Normal

Set all open tickets without a severity to "Normal"

Note: See TracTickets for help on using tickets.