EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  <20072008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  <20072008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: softioc crashes CAS (gateway) when using port number in EPICS_CA_ADDR_LIST
From: Dirk Zimoch <[email protected]>
To: Emmanuel Mayssat <[email protected]>
Cc: TechTalk EPICS <[email protected]>
Date: Mon, 15 Oct 2007 10:04:02 +0200
Hi Emmanuel

That works indeed!

When EPICS_CAS_BEACON_ADDR_LIST is set to a proper value (the broadcast address) before the ioc is started, the ioc does not crash the gateway any more.

Jeff, can you please have a look at the CAS? It should not be that easy to crash a server with unexpected or malformatted requests. A server should never blindly trust anything coming over the network.

Best regards,
Dirk


Emmanuel Mayssat wrote:
The first thing I would try is to set EPICS_CAS_BEACON_ADDR_LIST...
There was just a thread about this last week ;-)

http://www.aps.anl.gov/epics/tech-talk/2007/msg01150.php

If you use ports in EPICS_CA_ADDR_LIST (client search request), you will
need to set EPICS_CAS_BEACON_ADDR_LIST (server beacon) manually.

I think the problem you are experimenting is that the beacons are sent
to the same port where search requests only are expected.
EPICS_CAS_BEACON_ADDR_LIST default to EPICS_CA_ADDR_LIST if not set.
Check the server configuration (EPICS_CAS_* envvars) in the channel
access reference manual for more info.

Let us know if it worked!

--
Emmanuel




On Fri, 2007-10-12 at 14:19 +0200, Dirk Zimoch wrote:
Hi Jeff and others,

I see strange crashes of the CA gateway which probably originate in the CAS code.

If I use an explicit port in EPICS_CA_ADDR_LIST like this

EPICS_CA_ADDR_LIST="gateway:5066"

and then start a softioc running a record with an INP link to a record behind the gateway (running on that port), the gateway starts printing errors and refuses to handle any more requests. It has to be restarted.

The gateway prints:

CAS: CAS Request: ? on pc3853.psi.ch:38210: cmd=13 cid=0 typ=11 cnt=5064 psz=0 avail=81818260

Oct 12 14:01:36 !!! Errlog message received (message is above)
bad request code=13 in DG

Oct 12 14:01:36 !!! Errlog message received (message is above)
filename="../../../../src/cas/generic/st/casDGIntfOS.cc" line number=498
protocol from client was invalid unexpected problem with UDP input from "pc3853.psi.ch:38210"


Oct 12 14:01:36 !!! Errlog message received (message is above)
CAS: CAS Request: ? on pc3853.psi.ch:38210: cmd=13 cid=0 typ=11 cnt=5064 psz=0 avail=81818260


Oct 12 14:01:36 !!! Errlog message received (message is above)
bad request code=13 in DG

Oct 12 14:01:36 !!! Errlog message received (message is above)
filename="../../../../src/cas/generic/st/casDGIntfOS.cc" line number=498
protocol from client was invalid unexpected problem with UDP input from "pc3853.psi.ch:38210"


Oct 12 14:01:36 !!! Errlog message received (message is above)
....

However, a simple caget works without problems, at least before the softioc crashes the gateway.


I tried 3.14.8 and 3.14.9 on the ioc side. The gateway runs with some pre-3.13.9 CVS snapshot. But I also tried it with the 3.14.9 libraries.


BTW: I could not recompile the gateway with 3.14.9, because the function epicsNTOH16 does not exist any more. I had to trick the 3.14.9 libraries into the gateway's library search path.

Please, don't remove API functions when changing Channel Access!

Any idea?
Dirk




-- Dr. Dirk Zimoch Paul Scherrer Institut, WBGB/006 5232 Villigen PSI, Switzerland Phone +41 56 310 5182

References:
softioc crashes CAS (gateway) when using port number in EPICS_CA_ADDR_LIST Dirk Zimoch
Re: softioc crashes CAS (gateway) when using port number in EPICS_CA_ADDR_LIST Emmanuel Mayssat

Navigate by Date:
Prev: Re: fedora core 7 medm (was >> Re: MEDM compile - update :) Heinrich du Toit
Next: Re: vxWorks network problem on MVME2700 Martin L. Smith
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  <20072008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: softioc crashes CAS (gateway) when using port number in EPICS_CA_ADDR_LIST Emmanuel Mayssat
Next: fedora core 7 medm (was >> Re: MEDM compile - update :) Mauro Giacchini
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  <20072008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 10 Nov 2011 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·