так и не получилось
ФР подключен к кассе по PPP. Его адрес: 192.168.250.2
Касса на линуксе.
Код:
ppp0 Link encap:Point-to-Point Protocol
inet addr:192.168.250.1 P-t-P:192.168.250.2 Mask:255.255.255.255
UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1500 Metric:1
RX packets:17 errors:0 dropped:0 overruns:0 frame:0
TX packets:21 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:3
RX bytes:2823 (2.7 Kb) TX bytes:2344 (2.2 Kb)
При выполнении команды:
Код:
curl --connect-timeout 10 --max-time 20 --trace-ascii "/tmp/000/e1.TXT" -F "xml_file=@/tmp/000/fr.xml" http://192.168.250.2:6667 -o "/tmp/000/r1.XML"
операция вылетает по таймауту, ответа CURL не получает:
Код:
curl: (28) Operation timed out with 0 out of -1 bytes received
В логах ФР:
Код:
20-12-2017 12:19:03.744: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:03.772: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:03.800: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:03.827: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:03.855: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:03.883: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:03.911: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:03.939: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:03.967: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:03.994: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.022: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.050: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.078: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.106: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.133: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.161: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.188: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.216: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.244: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.272: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.300: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.327: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.355: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.383: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.411: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.438: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.466: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.494: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.522: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.549: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.577: 0x730ff410: WARNING: transport_tcp: read() failed
20-12-2017 12:19:04.578: 0x730ff410: WARNING: transport_tcp: CListenServer::handleReadyReadTransportExtMode() - read timeout exceeded
20-12-2017 12:19:04.590: 0x730ff410: INFO: POS_CONTROLLER: POS=>KKT "<?xml version="1.0" encoding="UTF-8"?> <ArmRequest> <RequestBody> <ProtocolLabel>OFDFNARMUKM</ProtocolLabel> <ProtocolVersion>10.10</ProtocolVersion> <RequestId>{48b9bd0c-a368-4aab-83ec-ba393e90d194}</RequestId> <DateTime>2017-12-20 08:37:20</DateTime> <Command>2</Command> </RequestBody> <RequestData> <![CDATA[]]> </RequestData> </ArmRequest> --curlHqU53MphNa9v0ffsT4F8uj21Fwj--"
20-12-2017 12:19:04.601: 0x730ff410: INFO: POS_CONTROLLER: POS=>KKT {48b9bd0c-a368-4aab-83ec-ba393e90d194} EXTCMD_POS_GETSTATUS(0x2) - processing started
20-12-2017 12:19:04.602: 0x730ff410: INFO: POS_CONTROLLER: POS=>KKT {48b9bd0c-a368-4aab-83ec-ba393e90d194} EXTCMD_POS_GETSTATUS(0x2) - processing finished
20-12-2017 12:19:04.610: 0x738ff410: INFO: MACRO_CONTROLLER: --- cmd[646] m_cmdCode="ARMCMD_MACRO_GETSTATUS(0x6008)" m_params="" process begin
20-12-2017 12:19:04.623: 0x74aff410: INFO: FN_CONTROLLER: --- CFNController::cmdProcess() - cmd[647] m_cmdCode="ARMCMD_FN_STATUS(0x2008)" m_params="" process begin
20-12-2017 12:19:04.650: 0x74aff410: INFO: FN_CONTROLLER: fnstatus = 3
20-12-2017 12:19:04.650: 0x74aff410: INFO: FN_CONTROLLER: --- CFNController::cmdProcess() cmd[647] m_cmdCode="ARMCMD_FN_STATUS(0x2008)" m_params="" process end
20-12-2017 12:19:04.662: 0x738ff410: INFO: MACRO_CONTROLLER: --- cmd[646] m_cmdCode="ARMCMD_MACRO_GETSTATUS(0x6008)" m_params="" process end
20-12-2017 12:19:04.674: 0x730ff410: INFO: POS_CONTROLLER: --- cmd[649=>646] m_cmdCode="ARMCMD_MACRO_GETSTATUS_RESPONSE(0x6009)" m_params="" CPOSController::cmdProcess() begin
20-12-2017 12:19:04.676: 0x730ff410: INFO: POS_CONTROLLER: KKT=>POS {48b9bd0c-a368-4aab-83ec-ba393e90d194} EXTCMD_POS_GETSTATUS_RESPONSE(0x3) - response to send(str): size(str)=1475 size(bin)=1475 data(str)="<?xml version="1.0" encoding="UTF-8"?><ArmResponse><ResponseBody><ProtocolLabel>OFDFNARMUKM</ProtocolLabel><ProtocolVersion>10.10</ProtocolVersion><RequestId>{48b9bd0c-a368-4aab-83ec-ba393e90d194}</RequestId><Result>0</Result><ErrorCategory>0</ErrorCategory><ErrorSource>FN_CONTROLLER</ErrorSource><ErrorCode>0</ErrorCode><ErrorDescription></ErrorDescription><Command>3</Command></ResponseBody><ResponseData><![CDATA[<ArmGetStatus><LastCommand>0</LastCommand><LastCommandStatus>0</LastCommandStatus><LastCommandExecTime>5</LastCommandExecTime><NetworkInterface>eth0 MAC=B8:27:EB:92:4B:07 IP=,ppp0 MAC= IP=192.168.250.2</NetworkInterface><PaperWidth>54</PaperWidth><KKTFWVersion>008.19.308</KKTFWVersion><FNStatus><LifePhase>3</LifePhase><CurrentDocType>0</CurrentDocType><CurrentDocData>0</CurrentDocData><ShiftState>0</ShiftState><StatusNeedChange>0</StatusNeedChange><StatusEndingResource>0</StatusEndingResource><StatusOverflow>0</StatusOverflow><StatusOverdueSending>0</StatusOverdueSending><LastDocDateTime></LastDocDateTime><LastDocNumber>82824</LastDocNumber><FactoryNum>8710000100447708</FactoryNum><ExpirationDate>2018-06-27 00:00:00</ExpirationDate><FWVersion>fn_v_1_0</FWVersion></FNStatus><OFDStatus><ExchangeStatus>0</ExchangeStatus><MessageReadStarted>0</MessageReadStarted><QueueLength>0</QueueLength><FirstQueueDocNumber>0</FirstQueueDocNumber><FirstQueueDocDateTime></FirstQueueDocDateTime></OFDStatus></ArmGetStatus>]]></ResponseData></ArmResponse>"
20-12-2017 12:19:04.678: 0x730ff410: INFO: POS_CONTROLLER: KKT=>POS {48b9bd0c-a368-4aab-83ec-ba393e90d194} EXTCMD_POS_GETSTATUS_RESPONSE(0x3) - SUCCESS: response sent
20-12-2017 12:19:04.679: 0x730ff410: INFO: POS_CONTROLLER: --- cmd[649=>646] m_cmdCode="ARMCMD_MACRO_GETSTATUS_RESPONSE(0x6009)" m_params="" CPOSController::cmdProcess() end
Возникают какие-то ошибки чтения, затем команда обрабатывается успешно. ФР генерит ответ, но CURL его не получает.
Помогите, куда копать?