⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 vxw_pt4.html

📁 vxworks 问题解答
💻 HTML
📖 第 1 页 / 共 4 页
字号:
<p><hr WIDTH="50%"><a NAME="4.4-B"></a><p>Q: What is the meaning of all the ftp global variables?<p>A: These are the global variables of the FTP server:<ul><li>ftpdWindowSize: Socket level buffer size for send and receive sides(both).  This can affect TCP window sizes.  I was hoping that increasingthis would help you.</li><li>ftpdTaskPriority: main FTP daemon task priority</li><li>ftpdWorkTaskOptions: task options of each of the spawned worker taskthat actually does file I/O, created by ftpdTask.</li><li>ftpdDebug: Enable this to see some error logging messages</li><li>ftpdWorkTaskStackSize: stack size of worker task</li><li>ftpdWorkTaskPriority: priority of worker task</li></ul>(From: Hwa Jin Bae, hjb@pso.com)<p><hr WIDTH="50%"><a NAME="4.4-C"></a><p>Q: How do I change the priority of the TFTP-task?<p>A: The tftp task is spawned at priority 55, and new incoming connectionare spawned at priority 100, you can change this  through the globalvariable tftpdResponsePriority which is initially set to 100.<br>(From: Stephen Hill, shill@dsl.ftel.co.uk)<p><hr WIDTH="50%"><a NAME="4.4-D"></a><p>Q: Is there source code available for an FTP server?<p>A: Yes, there is an FTP server included in DosFS2. This is in theunsupported sources tree.<p><hr WIDTH="50%"><a NAME="4.4-E"></a><p>Q: How can I enable the debug information of the FTP server?<p>A: Set the global variable ftpDebug to 1 and you should get a lotof information.<p><hr WIDTH="60%"><p><h3><a NAME="4.5"><center>4.5 PPP</center></a></h3><a NAME="4.5-A"></a><p>Q: PPP crashes when I do an FTP-GET from the target with a large number ofsmall files.<p>A: The WRS support told me to use netStackSysPoolShow() whenthe problem appears. It shows the following information :<pre>.../...number of times failed to find space: 1number of times drained protocols for space: 1CLUSTER POOL TABLE                size     clusters  free      usage-------------------------------------------------------------------------------                 512      20        0         21.../...</pre>There was not enought 512 bytes buffers in the network stack.So, I increase this setting (in the Tornado builder, I changesome "define" in the "network buffer initialization" tab).And it seems to work better now.<br>(From: Emmanuel Herbreteau, eherbreteau@sepro-robotique.com)<p><hr WIDTH="60%"><p><h4><a NAME="4.5.1"><center>4.5.1 PPP on Windows 95</center></a></h4><a NAME="4.5.1-A"></a>Q: How do I make a connection between my Windows 95 machine and my targetusing PPP over a null-modem cable?<p>FIRST VERSION. PLEASE SEND COMMENTS!<p>A: Windows 95 does not support a null-modem connection in Dial Upnetworking. To get this working a new device has to be defined. Kevin Wellshas written a device driver to create a null modem connection. I modified thisdriver a bit to get it working with VxWorks. The original page is at<a href="http://www.kevin-wells.com/net/">http://www.kevin-wells.com/net/</a>.Also the documentation for this driver can be found here.<p>Now for the installation under VxWorks.<br>First enable PPP in the configuration. Then download the<a href="VxWorksPPP.inf">driver VxWorksPPP.inf</a>. Install this driver using Modems in the "Control Panel". Select "Add...", on the next screen check the"Don't detect my modem" box. Press "Next" and on that screen select "Have disk...". Now enter the path to where the file VxWorksPPP.inf was put.Now select the right communication port and "Next". Windows will now installthis modem connection. Go to the properties of this modem. Set the rightconnection speed.  Select the "Connection" tab, and then select the"Advanced" menu. Switch off Flow Control. To see if the link is working"Record a log file" can be checked. Now a logfile named "ModemLog.txt"will be generated in your Windows directory. Close all the windows.(This procedure is described in more detail on the site of<a href="http://www.mindspring.com/~kewells/net/">Kevin Wells</a>).<br>Now define a new Dial-up Networking connection using this device. Thephone number is not important, as there is no phone line used but a null-modemcable.  After this connection is defined go to the properties of thisconnection, go to the "Server Type" tab and uncheck everything except TCP/IP.Now go to "TCP/IP Settings". Uncheck everything here also. Also select"Server assigned IP address" and "Server assigned name server address".Close all windows using the "OK" button.<br>Now the PPP server has to be started on VxWorks. This can be doneusing usrPPPInit or pppInit. The first one uses the default parameters,with the second one a configuration can be specified. Here I will usepppInit.<br>First a configuration file has to be defined. The different items canbe found in the VxWorks Network Programmers Guide, chapter 3.4 and Table 3-3.I use the following file (named PPP_OPT on the target):<pre>debugdriver_debugno_papno_chapno_vjlcp_max_configure 10lcp_echo_interval 30lcp_echo_failure 5</pre>The debug lines can be deleted, but are usefull to see that the connectionis working the first time this is done.<br>First the Dial-up Networking connection should be started. When the window"Connecting to ...." appears with the message "Status: Dialing"start the PPP server on the target. This can be done using this commandin the shell:<pre>pppInit(0, "/tyCo/1", "90.0.0.1", "90.0.0.10", 38400, 0, "/D1/PPP_OPT")</pre>This opens a PPP connection on serial port 1, using the address 90.0.0.1 asthe address of the target and 90.0.0.10 as the address of the Windows 95machine. The connection speed is 38400 (this should be the same as the selected speed on the Windows 95 machine) and the option file is "PPP_OPT"on device "/D1".<p>How does this solution work? Windows 95 expects a reply from a modembefore it will start the PPP communication. VxWorks starts the PPPcommunication directly. (This can be observed by starting the PPP serverand watching the data on the serial line). To get Windows 95 to startthe PPP driver the expected reply has been set to "~" (see the VxWorksPPP.inffile for this). This is the first character of the standard connectstring. When VxWorks sends this string it is recognised by Windows 95as a valid connect string, and the PPP driver is started. From then on thecommunication is running between VxWorks and Windows 95.<br>One problem with this solution is that VxWorks has to be sending theconnect string. When VxWorks does not send this string no connection can bemade. That is the reason why first the Dial-up Networking has to bestarted and then pppInit.<br>The "line lcp_max_configure 10" means that VxWorks will be sending10 configuration requests before the PPP server dies. When the startupsequence is used as given in this example this is OK, but when a system hasto monitor the PPP link continuously this value should be increased. I don'tknow if there is a value that means "contious". Otherwise a task shouldmonitor if the PPP server still exists. If not a call to pppInit has to bemade to restart the PPP server.<br>This solution has been found with the help of Stuart Gray and DavidRichards from WindRiver Systems.<p><hr WIDTH="50%"><p><h4><a NAME="4.5.2"><center>4.5.2 PPP on Windows NT</center></a></h4><a NAME="4.5.2-A"></a>Q: How do I make a connection between my Windows NT machine and my targetusing PPP over a null-modem cable?<p>A: There is a document from WindRiver, called WTN50.pdf. This is a Tech Noteand available through WindSurf on the WindRiver website.<p><hr WIDTH="50%"><p><h4><a NAME="4.5.3"><center>4.5.3 PPP on Solaris</center></a></h4><a NAME="4.5.3-A"></a>Q: How do I build a network connection using PPP?<p>A: I managed to get it working on Solaris 8 with PPP, but had to do twothings to get it to work that I didn't have to do on Solaris 2.5.1 (bothas root):<ol><li><code>chmod 666 /tmp/.asppp.fifo</code> (Seems security had been tightened-up.)</li><li><code>ndd -set /dev/ip ip_forwarding 1</code> (IP forwarding was not on by default.)</li></ol>(From: Kurt Lloyd, kplloyd@lucent.com)<p><hr WIDTH="60%"><p><h3><a NAME="4.6"><center>4.6 Sockets</center></a></h3><a NAME="4.6-A"></a><p>Q: When I do a send using a socket connection to a second system, and thissystem crashes, the send still returns OK. How do I detect that the otherside has failed?<p>A: The problem is that this is only detected using a timeout.The default parameters for KEEP ALIVE are set to detect a lostconnection after some ridiculously long time like two hours.   You canchange this time by modifying the values of the variables tcp_keepintvl andtcp_keepidle.   See the manual page for setsockopt under the SO_KEEPALIVEoption.<br>(From: Charles H. Chapman, chc@nasa2.ksc.nasa.gov)<p><hr WIDTH="50%"><a NAME="4.6-B"></a><p>Q: After I used a lot of sockets my system stalls for 10 to 15 seconds.What is causing this delay?<p>A: The odds are that all your sockets are in TIME_WAIT state; each socketthat is in TIME_WAIT hangs onto an mbuf or two until it finally expires andreleases its resources, so the number of mbufs available limits the numberof sockets you can have hanging around.  You'll need to increase the networkmemory pools. You might also care to log into Windsurf and search for thephrase "What is TIME_WAIT?  Bind fails with errno 0x30 = EADDRINUSE" or TSR#152244, which should lead you to a useful document.<br>(From: Dave Korn)<p>See also <TD VALIGN=TOP><A HREF="vxw_pt6.html#6.4-B">6.4-B</A></TD><p><hr WIDTH="60%"><p><h3><a NAME="4.7"><center>4.7 Telnet</center></a></h3><a NAME="4.7-A"></a>Q: How can I use my own command line interface using Telnet, instead of usingthe target shell?<p>A: Ask your local sales representative and he can provide you with sourcecode to a telnet server that supports the target shell and your own customthing. It was a component written by their Israel local office.<br>It's on the FAE FTP site, this is internal and password protected so normal folks can't get to it. If your FAE doesn't know where that is then tell them to go to internal.wrs.com and then follow the links to sales then FAE, after that they can't miss it. <br>It is free and quite small. It worked for us the same day we got it.<br>(From: Serge Blais, blais_serge@yahoo.com)<p><hr WIDTH="50%"><a NAME="4.7-B"></a><p>Q: How can I change the priority of the telnet task?<p>A: Just before the call to telnetInit in prjConfig.c add the line<pre>telnetPriority=XXX</pre>where XXX is the new priority of the telnet task.<p><hr WIDTH="60%"><p><h3><a NAME="4.8"><center>4.8 Other network related questions</center></a></h3><a NAME="4.8-A"></a><p>Q: Does anyone point me in what is needed to support development ofserver/client TCP - BSD stream  sockets applications using  a NT platformwith Microsoft Visual C/C++ (or Visual Studio) ?<p>A: The following is for MFC applications, see below for console (DOS like)apps:<ol><li>In the App-Wizard (when creating the project), make sure you checkthe "include Winsock support" button.</li><li>Add the following to initialize the winsock dll (usually put in theOnInitXXX section) :<pre>//winsock stuff#ifdef WIN32#define WSOCK_VER 1   /* I have no idea what versions are what!                          version 1 seems to work with BSD 4.3                          type calls, ver 2 fails on a lot of                          machines  */WORD wVersionRequested;WSADATA wsaData;int err;     wVersionRequested = MAKEWORD( WSOCK_VER, 0 );     err = WSAStartup( wVersionRequested, &amp;wsaData );    if ( err != 0 )     {        return(1);    }     /* Confirm that the WinSock DLL supports This version */    /* Note that if the DLL supports versions greater    */    /* than WSOCK_VER in addition to WSOCK_VER, it will return */    /* WSOCK_VER in wVersion since that is the version we      */    /* requested.                                        */     if ( LOBYTE( wsaData.wVersion ) != WSOCK_VER ||HIBYTE( wsaData.wVersion) != 0 )     {        return(2);    }#endif</pre></li><li>use all the regular BSD syntax calls.  Look in help if you have   problems (a few deviate slightly).  Also, don't use iocti.  Winsockneeds ioctlsocket:   <pre>#ifdef WIN32    ioctlsocket (fd, FIONREAD, &amp;numbytes);#else    ioctl (fd, FIONREAD, &amp;numbytes);#endif</pre></ol>If using console application, add the winsock lib to your linkersetup (I think it is wsock32.lib) and follow #2 and #3.<br>(From: Christopher A Leddy, caleddy@west.raytheon.com)<p><hr WIDTH="50%"><a NAME="4.8-B"></a><p>Q: Has anyone succeed using an etherInputHook on an END style ethernetdriver?<p>A:  I've noticed on some T2 ENDethernet drivers that the EtherHooks mechanism was disabled, i.e. thehook function simply never gets called.  Two workarounds are possiblefor this: one is to use older BSD-style drivers (yes, this does workwith the new SENS stack for backwards compatibility) and ether hooks,and the other is to implement a "SNARF" protocol which binds above theEND's MUX and in general, provides the same functionality as theetherHooks.<br>The second solution is detailed in the SENS Network Protocol Toolkit.What they don't tell you is that there can be only one snarf protocolactive at one time, and the default VxWorks image already installssuch a protocol for what they call "system-mode debugging". Removethis and using the new method becomes almost as easy as the oldetherHooks.<br>(From: Ran Shalgi, http://www.expand.com)<p><hr WIDTH="50%"><a NAME="4.8-C"></a><p>Q: Is there a TCP dump utility available for VxWorks?<p>A: Take a look at this program. It has been flkoating around for sometime, I don't know the author: <a href="vxsniff.c">vxsniff.c</a><p><hr WIDTH="50%"><a NAME="4.8-D"></a><p>Q: At boottime I get a "dc0 - no carrier" error. What does this mean?<p>A: I had to download the latest driver from WindRiver and make a change tomy sysDec21x40End.c file.  Look for the latest driver releases fromWindSurf (click on download, tornado 2.0 drivers).  That will update yourdriver binary.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -