aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: RESOLVED - Default Port=-1 for amuleweb corresponds to TCP port 65535  (Read 4595 times)

Pitxyoki

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 40

When doing a fresh install of amuled + amuleweb, issuing these commands is enough to get amuleweb up and running:
Code: [Select]
$ amuled --ec-config
$ amuleweb --write-config
$ amuleweb
On the guide at the wiki, there is information on how to set the passwords using parameters to these commands, but there is nothing relating to the port that amuleweb should be listening to.
This gets configured by default as -1 on the remote.conf file. On older versions this meant "use the same port as amuled uses for EC minus 1". On more recent versions (since about 2.2.1 or so), this means "use port 65535", which you can only find out using netstat or by a big guess.

On that wiki page, there is even this:
Quote
Go to the web address http://hostname:4711, where hostname is the name of the computer running amuleweb and 4711 is the port amuleweb is using. In most cases this should be http://localhost:4711.
Well, this was what happened in most cases, but when the -1 meant "EC port -1". Now in most cases it's 65535 (coincidentally or not, the last usable TCP port).

I believe this should be documented somewhere (if it already is, where?) and/or the default should be altered to a different port. Or perhaps (I would prefer if) you could bring the old behaviour of "EC port -1" back.
« Last Edit: January 09, 2010, 06:03:42 AM by Kry »
Logged

GonoszTopi

  • The current man in charge of most things.
  • Administrator
  • Hero Member
  • *****
  • Karma: 169
  • Offline Offline
  • Posts: 2685
Re: Default Port=-1 for amuleweb corresponds to TCP port 65535
« Reply #1 on: March 06, 2009, 10:41:17 PM »

I have to say, you're getting this wrong but you're right.

The port value -1 has never meant "EC port -1", its real meaning was "ask remote core for the port". But since default EC port is 4712 and default webserver port is (should be) 4711, I see why you got it wrong.

However, somewhere in time this behaviour was changed and -1 has no special meaning anymore. It is treated literally and converting it to a 32-bit unsigned value yields 65535.
Logged
concordia cum veritate

Pitxyoki

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 40
Re: Default Port=-1 for amuleweb corresponds to TCP port 65535
« Reply #2 on: March 06, 2009, 11:43:15 PM »

...then please don't make -1 the default port for amuleweb when generating it's config automatically!
Logged

wuischke

  • Developer
  • Hero Member
  • *****
  • Karma: 183
  • Offline Offline
  • Posts: 4292
Re: Default Port=-1 for amuleweb corresponds to TCP port 65535
« Reply #3 on: March 07, 2009, 09:46:11 AM »

Quote
It is treated literally and converting it to a 32-bit unsigned value yields 65535.
I can't resist on this one...:D
Logged

GonoszTopi

  • The current man in charge of most things.
  • Administrator
  • Hero Member
  • *****
  • Karma: 169
  • Offline Offline
  • Posts: 2685
Re: Default Port=-1 for amuleweb corresponds to TCP port 65535
« Reply #4 on: March 07, 2009, 11:20:56 PM »

 
Quote
It is treated literally and converting it to a 32-bit unsigned value yields 65535.
I can't resist on this one...:D
You won, it's 16-bit. :/
Logged
concordia cum veritate

Pitxyoki

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 40
Re: Default Port=-1 for amuleweb corresponds to TCP port 65535
« Reply #5 on: January 09, 2010, 01:39:38 AM »

If I were able to edit my posts, I'd add a nice "RESOLVED" tag to this one.
But I can't.  :-[

Anyway: this bug is resolved as of aMule 2.2.6.
Logged