Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] Question about port already in use

The error message "Could not connect to TraCI server" only comes after the second failed connection attempt. It would guess that  traci.connect (or traci.start) is called repeatedly with argument numRetries=1.

Am Do., 11. Apr. 2019 um 04:34 Uhr schrieb <21_lahm@xxxxxxxxxxxxx>:
Hi, Jakob,

Thanks for your reply. Now what is confusing me is the sudden abort of sumo as shown in the attachment. The program written in python runs SUMO in Ubuntu. After running about 600 simulations, the program has stopped suddenly. There are no warnings or bugs shown, just "Retrying in 1 seconds" and "Retrying in 1 seconds". I suspect this is caused by the port already in use. But it seems not since there is no related error message.

Best, 

Yu Tang


-----原始邮件-----
发件人:"Jakob Erdmann" <namdre.sumo@xxxxxxxxx>
发送时间:2019-04-09 21:49:22 (星期二)
收件人: "Sumo project User discussions" <sumo-user@xxxxxxxxxxx>
抄送:
主题: Re: [sumo-user] Question about port already in use

if you are using the python client, a free socket port should be automatically obtained when calling traci.start().
If you are using the C++ client, you can use the method getFreeSocketPort() from src/foreign/tcpip/socket.h

regards,
Jakob

Am So., 7. Apr. 2019 um 20:43 Uhr schrieb <21_lahm@xxxxxxxxxxxxx>:

Hi guys,

I am running a bunch of simulation with the help of traci. But sometimes the program is forced to stop due to the error "Error: tcpip::Socket::accept() Unable to create listening socket: Address already in use Quitting (on error)."

My question is whether the program can automatically handle with the error and find the appropriate port.

Can anybody help me with this problem?

Thank you.

Yu Tang
_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/sumo-user
_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/sumo-user

Back to the top