maybe:
-d ip:port:reconnect_time
-d ip:port:10

after 10 seconds reconnect to ser2net

this is like a failsafe (let's think we remove the ethernet cable -
like remove a serial cable) owserver don't stop
the problem: tcp/ip call us that host/port is down (somethink like
/dev/ttyS0 don't exists)
a reconnect could help us... we don't need a bash script with a do while forever
maybe using microseconds
10.5 seconds for example is usefull
let's think a hearthbeat (ha) linux cluster where IP change from a
computer to another, there's a time from changing from a computer to
another, a reconnect time is usefull if we lost connection...
no problem if we can't do it, but if we can why not put on owserver




2011/1/26 Roberto Spadim <[email protected]>:
> could we implement a reconnect?
> for example the socket at ser2net is closed, or not openned the
> owserver stop. could it reconnect?
>
>
>
>
> [root@SPADIM bin]# ./owhttpd -p=10000 -d 172.16.0.201:3333 --foreground 
> --debug
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(75) Avahi support:
> libavahi-client loaded successfully
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(77) Avahi library
> function found: avahi_client_errno
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(78) Avahi library
> function found: avahi_client_free
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(79) Avahi library
> function found: avahi_client_new
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(80) Avahi library
> function found: avahi_client_get_domain_name
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(81) Avahi library
> function found: avahi_entry_group_add_service
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(82) Avahi library
> function found: avahi_entry_group_commit
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(83) Avahi library
> function found: avahi_entry_group_is_empty
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(84) Avahi library
> function found: avahi_entry_group_new
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(85) Avahi library
> function found: avahi_entry_group_reset
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(87) Avahi library
> function found: avahi_service_resolver_free
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(88) Avahi library
> function found: avahi_service_resolver_new
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(89) Avahi library
> function found: avahi_service_browser_free
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(90) Avahi library
> function found: avahi_service_browser_new
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(102) Avahi support:
> libavahi-common loaded successfully.
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(104) Avahi library
> function found: avahi_simple_poll_free
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(105) Avahi library
> function found: avahi_simple_poll_get
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(106) Avahi library
> function found: avahi_simple_poll_loop
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(107) Avahi library
> function found: avahi_simple_poll_new
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(108) Avahi library
> function found: avahi_simple_poll_quit
>  DEBUG: ow_avahi_link.c:OW_Load_avahi_library(109) Avahi library
> function found: avahi_strerror
>   CALL: ow_parsename.c:FS_ParsedName_anywhere(91) path=[]
>  DEBUG: owlib.c:SetupTemperatureLimits(79) Globals temp limits 0C
> 100C (for simulated adapters)
>  DEBUG: ow_ds9097U.c:DS2480_initialize_repeatedly(265) Attempt #0 to
> initialize the DS9097U
>  DEBUG: ow_net_client.c:ClientAddr(83) IP address=[172.16.0.201] port=[3333]
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
>  DEBUG: ow_ds9097U.c:DS2480_initialize_repeatedly(265) Attempt #1 to
> initialize the DS9097U
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
>  DEBUG: ow_ds9097U.c:DS2480_initialize_repeatedly(265) Attempt #2 to
> initialize the DS9097U
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
>  DEBUG: ow_ds9097U.c:DS2480_initialize_repeatedly(265) Attempt #3 to
> initialize the DS9097U
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
>  DEBUG: ow_ds9097U.c:DS2480_initialize_repeatedly(265) Attempt #4 to
> initialize the DS9097U
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
>  DEBUG: ow_ds9097U.c:DS2480_initialize_repeatedly(265) Attempt #5 to
> initialize the DS9097U
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
>  DEBUG: ow_ds9097U.c:DS2480_initialize_repeatedly(265) Attempt #6 to
> initialize the DS9097U
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
>  DEBUG: ow_ds9097U.c:DS2480_initialize_repeatedly(265) Attempt #7 to
> initialize the DS9097U
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
>  DEBUG: ow_ds9097U.c:DS2480_initialize_repeatedly(265) Attempt #8 to
> initialize the DS9097U
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
>  DEBUG: ow_ds9097U.c:DS2480_initialize_repeatedly(265) Attempt #9 to
> initialize the DS9097U
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
>  DEBUG: ow_ds9097U.c:DS2480_detect(248) Could not initilize the
> DS9097U even after several tries
> CONNECT: owlib.c:SetupSingleInboundConnection(119) Cannot detect
> DS2480 or LINK interface on 172.16.0.201:3333.
>  DEBUG: ow_net_client.c:ClientAddr(83) IP address=[172.16.0.201] port=[3333]
> CONNECT: ow_net_client.c:ClientConnect(143) [Connection refused] Socket 
> problem
> DEFAULT: owlib.c:SetupSingleInboundConnection(128) Cannot detect
> DS9097 (passive) interface on 172.16.0.201:3333.
> DEFAULT: owlib.c:LibStart(54) No valid 1-wire buses found
>  DEBUG: owhttpd.c:ow_exit(48) ow_exit 1
>
>
>
>
> 2011/1/26 Paul Alfille <[email protected]>:
>> RELEASE NOTES OWFS 2.8p6
>>
>> 1. DS2436 Automatic lock handling for memory access
>> 2. DS2436 Counter support
>> 3. DS2450 8bit support
>> 4. OW-SERVER-ENET telnet support complete.
>> 5. LINK over serial, telnet (ser2net) and LinkHub-E
>> 6. DS9097U (DS2480B based) support in serial and telnet (ser2net)
>> 7. DS9097 (passive) supprt in serial and ser2net
>> 8. HA5 fixes -- works with checksum mode.
>> 9. Simultaneous fixes from Jim Kuszmir
>>
>> Typical use of ser2net:
>> sudo ser2net -C "3333:telnet:0:/dev/ttyUSB0:9600 1STOPBIT 8DATABITS remctl"
>>
>> Then use 3333 or host:3333 instead of /dev/ttyS0
>>
>> ------------------------------------------------------------------------------
>> Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
>> Finally, a world-class log management solution at an even better price-free!
>> Download using promo code Free_Logger_4_Dev2Dev. Offer expires
>> February 28th, so secure your free ArcSight Logger TODAY!
>> http://p.sf.net/sfu/arcsight-sfd2d
>> _______________________________________________
>> Owfs-developers mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>>
>>
>
>
>
> --
> Roberto Spadim
> Spadim Technology / SPAEmpresarial
>



-- 
Roberto Spadim
Spadim Technology / SPAEmpresarial

------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________
Owfs-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/owfs-developers

Reply via email to