***ANSI connection via socket

Hi
I need help!!
How can i establish an ANSI connection via socket??? because the server dont let me connect with a VT100 connection

The book Core Java 2 from Sun has a good discussion on that.
There is a thread in The Water Cooler titled YAT which is a
discussion of that book. Read through it (there are about 3400+ posts).
They should have it. It would take too long for me to re-search my book.
Do a search on the Java site for ANSI or Character Map, you
will probably find documentation and tutorials on it.
Let me know if you can't find them.

Similar Messages

  • Macbook can't connect via L2TP but can via PPTP. iPhone can connect to both

    So I've been banging my head up against the wall for the better part of this morning trying to figure this out. Just as a note, I'm 3000 miles from my house and server, but I do have access to it for the time being via PPTP.
    Before I left, I verified that I could connect with L2TP on my iphone's 3G network. I was also able to connect at the airport on my Macbook using L2TP. Sometime overnight something changed, and I can't figure out what. I noticed that my phone dropped it's VPN connection saying something like "the connection to the server dropped unexpectedly" or such. After that, I was unable to connect over L2TP on my macbook or iphone. On a whim I tried connecting over PPTP which worked! But only on my macbook. Again on a whim I tried to connect via L2TP on my iphone, and it worked?! I rinsed, lathered and repeated that process over and over again and confirmed that I could only connect over L2TP on my iPhone after connecting on my macbook over PPTP. Also, on my iphone, if I stored the password it wouldn't authenticate (probably not related).
    As of this moment I am connected using L2TP on my iphone for the last hour, using it to successfully stream Pandora across US borders, but can't sustain a PPTP connection on my macbook for longer than 10 mins. And I still can't connect over L2TP. So that said here are the client and server logs (ips, domains and usernames masked....) Server and clients are in different timezones:
    *Macbook when trying to connect via L2TP:*
    Mon Dec 21 12:30:32 2009 : L2TP connecting to server 'nnn.nnn.nnn' (xxx.xxx.xxx.xxx)...
    Mon Dec 21 12:30:32 2009 : IPSec connection started
    Mon Dec 21 12:30:32 2009 : IPSec phase 1 client started
    Mon Dec 21 12:30:42 2009 : IPSec connection failed
    *Server Log for the above transaction:*
    NO RECORD
    *Macbook when trying to connect via PPTP:*
    Mon Dec 21 12:49:44 2009 : PPTP connecting to server 'nnn.nnn.nnn' (xxx.xxx.xxx.xxx)...
    Mon Dec 21 12:49:44 2009 : PPTP connection established.
    Mon Dec 21 12:49:45 2009 : Using interface ppp0
    Mon Dec 21 12:49:45 2009 : Connect: ppp0 <--> socket[34:17]
    Mon Dec 21 12:49:48 2009 : MPPE 128-bit stateless compression enabled
    Mon Dec 21 12:49:49 2009 : route_interface: write routing socket failed, File exists. (address xxx.xxx.xxx.0, mask 255.255.255.0, interface ppp0, host 0).
    Mon Dec 21 12:49:49 2009 : local IP address xxx.xxx.xxx.233
    Mon Dec 21 12:49:49 2009 : remote IP address xxx.xxx.xxx.109
    Mon Dec 21 12:49:49 2009 : primary DNS address xxx.xxx.xxx.109
    Mon Dec 21 12:49:49 2009 : secondary DNS address xxx.xxx.xxx.109
    Mon Dec 21 12:49:49 2009 : pptpwaitinput: Address added. previous interface setting (name: en1, address: xxx.xxx.xxx.6), current interface setting (name: ppp0, family: PPP, address: xxx.xxx.xxx.233, subnet: 255.255.255.0, destination: xxx.xxx.xxx.109).
    *Server Log for the above transaction:*
    2009-12-21 09:49:44 PST Incoming call... Address given to client = xxx.xxx.xxx.233
    Mon Dec 21 09:49:44 2009 : Directory Services Authentication plugin initialized
    Mon Dec 21 09:49:44 2009 : Directory Services Authorization plugin initialized
    Mon Dec 21 09:49:44 2009 : PPTP incoming call in progress from 'xxx.xxx.xxx.xxx'…
    Mon Dec 21 09:49:44 2009 : PPTP connection established.
    Mon Dec 21 09:49:44 2009 : using link 1
    Mon Dec 21 09:49:44 2009 : Using interface ppp1
    Mon Dec 21 09:49:44 2009 : Connect: ppp1 <--> socket[34:17]
    Mon Dec 21 09:49:44 2009 : sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x206a2bb5> <pcomp> <accomp>]
    Mon Dec 21 09:49:45 2009 : rcvd [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4b8d229c> <pcomp> <accomp>]
    Mon Dec 21 09:49:45 2009 : lcp_reqci: returning CONFACK.
    Mon Dec 21 09:49:45 2009 : sent [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0x4b8d229c> <pcomp> <accomp>]
    Mon Dec 21 09:49:47 2009 : sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x206a2bb5> <pcomp> <accomp>]
    Mon Dec 21 09:49:48 2009 : rcvd [LCP ConfAck id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x206a2bb5> <pcomp> <accomp>]
    Mon Dec 21 09:49:48 2009 : sent [LCP EchoReq id=0x0 magic=0x206a2bb5]
    Mon Dec 21 09:49:48 2009 : sent [CHAP Challenge id=0x7f <3b77645a35056d6f176a3d4302524136>, name = "OSXServer.kimnet"]
    Mon Dec 21 09:49:48 2009 : rcvd [LCP EchoReq id=0x0 magic=0x4b8d229c]
    Mon Dec 21 09:49:48 2009 : sent [LCP EchoRep id=0x0 magic=0x206a2bb5]
    Mon Dec 21 09:49:48 2009 : rcvd [LCP EchoRep id=0x0 magic=0x4b8d229c]
    Mon Dec 21 09:49:48 2009 : rcvd [CHAP Response id=0x7f <51f69894a74fc550cf12b270ceb43da90000000000000000d7a8e304c6080e5d0315a47e9783a4 8ce2ae8fdb00671adc00>, name = "nnnnnnnn"]
    Mon Dec 21 09:49:48 2009 : sent [CHAP Success id=0x7f "S=09A448E00B717E032D200EAEFA793E57AF9B9676 M=Access granted"]
    Mon Dec 21 09:49:48 2009 : CHAP peer authentication succeeded for nnnnnnnn
    Mon Dec 21 09:49:48 2009 : DSAccessControl plugin: User 'nnnnnnnn' authorized for access
    Mon Dec 21 09:49:48 2009 : sent [CCP ConfReq id=0x1 <mppe +H -M +S -L -D -C>]
    Mon Dec 21 09:49:48 2009 : rcvd [CCP ConfReq id=0x1 <mppe +H -M +S -L -D -C>]
    Mon Dec 21 09:49:48 2009 : sent [CCP ConfAck id=0x1 <mppe +H -M +S -L -D -C>]
    Mon Dec 21 09:49:48 2009 : rcvd [CCP ConfAck id=0x1 <mppe +H -M +S -L -D -C>]
    Mon Dec 21 09:49:48 2009 : MPPE 128-bit stateless compression enabled
    Mon Dec 21 09:49:48 2009 : sent [IPCP ConfReq id=0x1 <addr xxx.xxx.xxx.109>]
    Mon Dec 21 09:49:48 2009 : sent [ACSCP ConfReq id=0x1]
    Mon Dec 21 09:49:49 2009 : rcvd [IPCP ConfReq id=0x1 <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
    Mon Dec 21 09:49:49 2009 : ipcp: returning Configure-NAK
    Mon Dec 21 09:49:49 2009 : sent [IPCP ConfNak id=0x1 <addr xxx.xxx.xxx.233> <ms-dns1 xxx.xxx.xxx.109> <ms-dns3 xxx.xxx.xxx.109>]
    Mon Dec 21 09:49:49 2009 : rcvd [IPV6CP ConfReq id=0x1 <addr fe80::0217:f2ff:fec8:ef86>]
    Mon Dec 21 09:49:49 2009 : Unsupported protocol 0x8057 received
    Mon Dec 21 09:49:49 2009 : sent [LCP ProtRej id=0x2 80 57 01 01 00 0e 01 0a 02 17 f2 ff fe c8 ef 86]
    Mon Dec 21 09:49:49 2009 : rcvd [IPCP ConfAck id=0x1 <addr xxx.xxx.xxx.109>]
    Mon Dec 21 09:49:49 2009 : rcvd [LCP ProtRej id=0x2 82 35 01 01 00 04]
    Mon Dec 21 09:49:49 2009 : rcvd [IPCP ConfReq id=0x2 <addr xxx.xxx.xxx.233> <ms-dns1 xxx.xxx.xxx.109> <ms-dns3 xxx.xxx.xxx.109>]
    Mon Dec 21 09:49:49 2009 : ipcp: returning Configure-ACK
    Mon Dec 21 09:49:49 2009 : sent [IPCP ConfAck id=0x2 <addr xxx.xxx.xxx.233> <ms-dns1 xxx.xxx.xxx.109> <ms-dns3 xxx.xxx.xxx.109>]
    Mon Dec 21 09:49:49 2009 : ipcp: up
    Mon Dec 21 09:49:49 2009 : l2tpwaitinput: Address added. previous interface setting (name: en0, address: xxx.xxx.xxx.109), current interface setting (name: ppp1, family: PPP, address: xxx.xxx.xxx.109, subnet: 255.255.255.0, destination: xxx.xxx.xxx.233).
    Mon Dec 21 09:49:49 2009 : found interface en0 for proxy arp
    Mon Dec 21 09:49:49 2009 : local IP address xxx.xxx.xxx.109
    Mon Dec 21 09:49:49 2009 : remote IP address xxx.xxx.xxx.233
    Mon Dec 21 09:49:49 2009 : pptpwaitinput: Address added. previous interface setting (name: en0, address: xxx.xxx.xxx.109), current interface setting (name: ppp1, family: PPP, address: xxx.xxx.xxx.109, subnet: 255.255.255.0, destination: xxx.xxx.xxx.233).
    Mon Dec 21 09:49:49 2009 : rcvd [IP data <src addr xxx.xxx.xxx.233> <dst addr 255.255.255.255> <BOOTP Request> <type INFORM> <client id 0x08000000010000> <parameters = 0x6 0x2c 0x2b 0x1 0xf9 0xf>]
    Mon Dec 21 09:49:49 2009 : sent [IP data <src addr xxx.xxx.xxx.109> <dst addr xxx.xxx.xxx.233> <BOOTP Reply> <type ACK> <server id 0xc0a8016d> <domain name "nnn.nnn.nnn">]
    *Server Log for iPhone L2TP login:*
    2009-12-21 09:52:38 PST Incoming call... Address given to client = xxx.xxx.xxx.202
    Mon Dec 21 09:52:38 2009 : Directory Services Authentication plugin initialized
    Mon Dec 21 09:52:38 2009 : Directory Services Authorization plugin initialized
    Mon Dec 21 09:52:38 2009 : L2TP incoming call in progress from 'xxx.xxx.xxx.xxx'...
    Mon Dec 21 09:52:38 2009 : L2TP received SCCRQ
    Mon Dec 21 09:52:38 2009 : L2TP sent SCCRP
    Mon Dec 21 09:52:38 2009 : L2TP received SCCCN
    Mon Dec 21 09:52:38 2009 : L2TP received ICRQ
    Mon Dec 21 09:52:38 2009 : L2TP sent ICRP
    Mon Dec 21 09:52:38 2009 : L2TP received ICCN
    Mon Dec 21 09:52:38 2009 : L2TP connection established.
    Mon Dec 21 09:52:38 2009 : using link 0
    Mon Dec 21 09:52:38 2009 : Using interface ppp0
    Mon Dec 21 09:52:38 2009 : Connect: ppp0 <--> socket[34:18]
    Mon Dec 21 09:52:38 2009 : sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x6b3541df> <pcomp> <accomp>]
    Mon Dec 21 09:52:38 2009 : rcvd [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x24ff54dc> <pcomp> <accomp>]
    Mon Dec 21 09:52:38 2009 : lcp_reqci: returning CONFACK.
    Mon Dec 21 09:52:38 2009 : sent [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0x24ff54dc> <pcomp> <accomp>]
    Mon Dec 21 09:52:39 2009 : rcvd [LCP ConfAck id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x6b3541df> <pcomp> <accomp>]
    Mon Dec 21 09:52:39 2009 : sent [LCP EchoReq id=0x0 magic=0x6b3541df]
    Mon Dec 21 09:52:39 2009 : sent [CHAP Challenge id=0x6d <4322331b3d22406914173d5e0d176c29>, name = "nnn.nnn.nnn"]
    Mon Dec 21 09:52:39 2009 : rcvd [LCP EchoReq id=0x0 magic=0x24ff54dc]
    Mon Dec 21 09:52:39 2009 : sent [LCP EchoRep id=0x0 magic=0x6b3541df]
    Mon Dec 21 09:52:39 2009 : rcvd [LCP EchoRep id=0x0 magic=0x24ff54dc]
    Mon Dec 21 09:52:39 2009 : rcvd [CHAP Response id=0x6d <f46ecd855c624eef611f02096c87d7650000000000000000f7430743bc328cbca68540408d0103 2e0a60fb95fcc2b83600>, name = "xxxxxxx"]
    Mon Dec 21 09:52:39 2009 : sent [CHAP Success id=0x6d "S=0A046B9F1C59085076A8F2B736929E19391BDC4B M=Access granted"]
    Mon Dec 21 09:52:39 2009 : CHAP peer authentication succeeded for xxxxxxx
    Mon Dec 21 09:52:39 2009 : DSAccessControl plugin: User 'xxxxxx' authorized for access
    Mon Dec 21 09:52:39 2009 : sent [IPCP ConfReq id=0x1 <addr xxx.xxx.xxx.109>]
    Mon Dec 21 09:52:39 2009 : sent [ACSCP ConfReq id=0x1]
    Mon Dec 21 09:52:40 2009 : rcvd [IPCP ConfReq id=0x1 <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
    Mon Dec 21 09:52:40 2009 : ipcp: returning Configure-NAK
    Mon Dec 21 09:52:40 2009 : sent [IPCP ConfNak id=0x1 <addr xxx.xxx.xxx.202> <ms-dns1 xxx.xxx.xxx.109> <ms-dns3 xxx.xxx.xxx.109>]
    Mon Dec 21 09:52:40 2009 : rcvd [IPV6CP ConfReq id=0x1 <addr fe80::8948:cf2a:8334:7077>]
    Mon Dec 21 09:52:40 2009 : Unsupported protocol 0x8057 received
    Mon Dec 21 09:52:40 2009 : sent [LCP ProtRej id=0x2 80 57 01 01 00 0e 01 0a 89 48 cf 2a 83 34 70 77]
    Mon Dec 21 09:52:40 2009 : rcvd [IPCP ConfAck id=0x1 <addr xxx.xxx.xxx.109>]
    Mon Dec 21 09:52:40 2009 : rcvd [LCP ProtRej id=0x2 82 35 01 01 00 04]
    Mon Dec 21 09:52:40 2009 : rcvd [IPCP ConfReq id=0x2 <addr xxx.xxx.xxx.202> <ms-dns1 xxx.xxx.xxx.109> <ms-dns3 xxx.xxx.xxx.109>]
    Mon Dec 21 09:52:40 2009 : ipcp: returning Configure-ACK
    Mon Dec 21 09:52:40 2009 : sent [IPCP ConfAck id=0x2 <addr xxx.xxx.xxx.202> <ms-dns1 xxx.xxx.xxx.109> <ms-dns3 xxx.xxx.xxx.109>]
    Mon Dec 21 09:52:40 2009 : ipcp: up
    Mon Dec 21 09:52:40 2009 : pptpwaitinput: Address added. previous interface setting (name: en0, address: xxx.xxx.xxx.109), current interface setting (name: ppp0, family: PPP, address: xxx.xxx.xxx.109, subnet: 255.255.255.0, destination: xxx.xxx.xxx.202).
    Mon Dec 21 09:52:40 2009 : found interface en0 for proxy arp
    Mon Dec 21 09:52:40 2009 : local IP address xxx.xxx.xxx.109
    Mon Dec 21 09:52:40 2009 : remote IP address xxx.xxx.xxx.202
    Mon Dec 21 09:52:40 2009 : l2tpwaitinput: Address added. previous interface setting (name: en0, address: xxx.xxx.xxx.109), current interface setting (name: ppp0, family: PPP, address: xxx.xxx.xxx.109, subnet: 255.255.255.0, destination: xxx.xxx.xxx.202).

    I'm having similar issues but not much luck getting any answers. I made a similar post here - maybe something in there will help you.
    One thing I have been able to pinpoint is that the MobileMe Back To My Mac service was causing quite a few issues with being able to connect to the VPN. Once I turn off the service, connection seems to work fine. Although, once I'm connected, I cannot access file sharing. Still waiting for some answers on that.

  • Connect via SQL*Plus taking more time in Oracle 11 than in 10

    Oracle Version
    Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
    PL/SQL Release 11.2.0.3.0 - Production
    CORE    11.2.0.3.0      Production
    TNS for IBM/AIX RISC System/6000: Version 11.2.0.3.0 - Production
    NLSRTL Version 11.2.0.3.0 - Productioncurrently migrating from
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
    PL/SQL Release 10.2.0.4.0 - Production
    CORE    10.2.0.4.0      Production
    TNS for IBM/AIX RISC System/6000: Version 10.2.0.4.0 - Productio
    NLSRTL Version 10.2.0.4.0 - ProductionOS is AIX 5.3 for Oracle 10 and AIX 6.1 for Oracle 11.
    We are currently in the process of migrating some applications from Oracle 10 to 11. Our admins have setup a new development system for us with an Oracle 11 instance. Regarding performance the new system behaves more or less the same than our old, e.g. when executing SQLs we notice hardly any performance differences and those we find are slightly in favour of the new system.
    But now we discovered that the time it takes to establish a database connection via SQL*Plus is longer on the Oracle 11 system. Running the following code
    sqlplus -s user/pw@database <<END
    quit
    ENDa thousand times takes ~60s under Oracle 10 but ~140s under Oracle 11. This may not seem much but we are running a test framework consisting of a bunch of shell scripts where several thousand connections are openend via SQL*Plus to execute some SQLs, so that even this small time difference results in rather huge difference in total runtime. The SQLs themself require roughly the same time in both databases, as already mentioned above they are in fact slightly faster in Oracle 11.
    To analyze the time difference I ran a trace for the connect with the following parameters in sqlnet.ora
    TRACE_LEVEL_CLIENT=4
    TRACE_UNIQUE_CLIENT=ONand found out that there is a time difference of about 70ms during the connect handshake:
    Oracle 10
    [22-MAR-2013 12:13:09:595] nscon: doing connect handshake...
    [22-MAR-2013 12:13:09:595] nscon: sending NSPTCN packet
    [22-MAR-2013 12:13:09:621] nscon: got NSPTRS packet
    [22-MAR-2013 12:13:09:621] nscon: sending NSPTCN packetOracle 11
    (1) [22-MAR-2013 12:15:26:812] nscon: doing connect handshake...
    (1) [22-MAR-2013 12:15:26:812] nscon: sending NSPTCN packet
    (1) [22-MAR-2013 12:15:26:906] nscon: got NSPTRS packet
    (1) [22-MAR-2013 12:15:26:906] nscon: sending NSPTCN packetUnder Oracle 10 there are 26ms between sending the NSPTCN packet and getting the NSPTRS packet, whereas under Oracle 11 this takes 94ms. I ran the trace again, this time with
    TRACE_LEVEL_CLIENT=16and got the following results for the critical interval:
    Oracle 10:
    [22-MAR-2013 13:17:37:638] nscon: sending NSPTCN packet
    [22-MAR-2013 13:17:37:638] nspsend: entry
    [22-MAR-2013 13:17:37:638] nspsend: plen=218, type=1
    [22-MAR-2013 13:17:37:638] nttwr: entry
    [22-MAR-2013 13:17:37:638] nttwr: socket 9 had bytes written=218
    [22-MAR-2013 13:17:37:638] nttwr: exit
    [22-MAR-2013 13:17:37:638] nspsend: packet dump
    <<packet dump removed>>
    [22-MAR-2013 13:17:37:638] nspsend: 218 bytes to transport
    [22-MAR-2013 13:17:37:638] nspsend: normal exit
    [22-MAR-2013 13:17:37:638] nscon: exit (0)
    [22-MAR-2013 13:17:37:638] nsdo: nsctxrnk=0
    [22-MAR-2013 13:17:37:638] nsdo: normal exit
    [22-MAR-2013 13:17:37:638] nsdo: entry
    [22-MAR-2013 13:17:37:638] nsdo: cid=0, opcode=68, *bl=512, *what=9, uflgs=0x0, cflgs=0x3
    [22-MAR-2013 13:17:37:638] nsdo: rank=64, nsctxrnk=0
    [22-MAR-2013 13:17:37:638] nsdo: nsctx: state=2, flg=0x4005, mvd=0
    [22-MAR-2013 13:17:37:638] nsdo: gtn=10, gtc=10, ptn=10, ptc=2011
    [22-MAR-2013 13:17:37:638] nscon: entry
    [22-MAR-2013 13:17:37:638] nscon: recving a packet
    [22-MAR-2013 13:17:37:638] nsprecv: entry
    [22-MAR-2013 13:17:37:638] nsprecv: reading from transport...
    [22-MAR-2013 13:17:37:638] nttrd: entry
    [22-MAR-2013 13:17:37:665] nttrd: socket 9 had bytes read=8
    [22-MAR-2013 13:17:37:665] nttrd: exit
    [22-MAR-2013 13:17:37:665] nsprecv: 8 bytes from transport
    [22-MAR-2013 13:17:37:665] nsprecv: tlen=8, plen=8, type=11
    [22-MAR-2013 13:17:37:665] nsprecv: packet dump
    [22-MAR-2013 13:17:37:665] nsprecv: 00 08 00 00 0B 00 00 00  |........|
    [22-MAR-2013 13:17:37:665] nsprecv: normal exit
    [22-MAR-2013 13:17:37:665] nscon: got NSPTRS packetOracle 11
    (1) [22-MAR-2013 13:33:40:504] nscon: sending NSPTCN packet
    (1) [22-MAR-2013 13:33:40:504] nspsend: entry
    (1) [22-MAR-2013 13:33:40:504] nspsend: plen=205, type=1
    (1) [22-MAR-2013 13:33:40:504] nttwr: entry
    (1) [22-MAR-2013 13:33:40:504] nttwr: socket 8 had bytes written=205
    (1) [22-MAR-2013 13:33:40:504] nttwr: exit
    (1) [22-MAR-2013 13:33:40:504] nspsend: packet dump
    <<packet dump removed>>
    (1) [22-MAR-2013 13:33:40:505] nspsend: 205 bytes to transport
    (1) [22-MAR-2013 13:33:40:505] nspsend: normal exit
    (1) [22-MAR-2013 13:33:40:505] nscon: exit (0)
    (1) [22-MAR-2013 13:33:40:505] snsbitts_ts: entry
    (1) [22-MAR-2013 13:33:40:505] snsbitts_ts: acquired the bit
    (1) [22-MAR-2013 13:33:40:505] snsbitts_ts: normal exit
    (1) [22-MAR-2013 13:33:40:505] nsdo: nsctxrnk=0
    (1) [22-MAR-2013 13:33:40:505] snsbitcl_ts: entry
    (1) [22-MAR-2013 13:33:40:505] snsbitcl_ts: normal exit
    (1) [22-MAR-2013 13:33:40:505] nsdo: normal exit
    (1) [22-MAR-2013 13:33:40:505] nsdo: entry
    (1) [22-MAR-2013 13:33:40:505] nsdo: cid=0, opcode=68, *bl=2048, *what=9, uflgs=0x0, cflgs=0x3
    (1) [22-MAR-2013 13:33:40:505] snsbitts_ts: entry
    (1) [22-MAR-2013 13:33:40:505] snsbitts_ts: acquired the bit
    (1) [22-MAR-2013 13:33:40:505] snsbitts_ts: normal exit
    (1) [22-MAR-2013 13:33:40:505] nsdo: rank=64, nsctxrnk=0
    (1) [22-MAR-2013 13:33:40:505] snsbitcl_ts: entry
    (1) [22-MAR-2013 13:33:40:505] snsbitcl_ts: normal exit
    (1) [22-MAR-2013 13:33:40:505] nsdo: nsctx: state=2, flg=0x4005, mvd=0
    (1) [22-MAR-2013 13:33:40:505] nsdo: gtn=10, gtc=10, ptn=10, ptc=8155
    (1) [22-MAR-2013 13:33:40:505] nscon: entry
    (1) [22-MAR-2013 13:33:40:505] nscon: recving a packet
    (1) [22-MAR-2013 13:33:40:505] nsprecv: entry
    (1) [22-MAR-2013 13:33:40:505] nsprecv: reading from transport...
    (1) [22-MAR-2013 13:33:40:505] nttrd: entry
    (1) [22-MAR-2013 13:33:40:618] nttrd: socket 8 had bytes read=8
    (1) [22-MAR-2013 13:33:40:618] nttrd: exit
    (1) [22-MAR-2013 13:33:40:618] nsprecv: 8 bytes from transport
    (1) [22-MAR-2013 13:33:40:618] nsprecv: tlen=8, plen=8, type=11
    (1) [22-MAR-2013 13:33:40:618] nsprecv: packet dump
    (1) [22-MAR-2013 13:33:40:618] nsprecv: 00 08 00 00 0B 00 00 00  |........|
    (1) [22-MAR-2013 13:33:40:618] nsprecv: normal exit
    (1) [22-MAR-2013 13:33:40:618] nscon: got NSPTRS packetAny ideas what could be the reason for this time difference? Something in our network configuration or something else?

    With local connections - I do not think a TCP packet send from an IP to the same IP, leaves the interface as an actual wire protocol/signal. If I'm correct, then running local connection tests will be mostly useless in checking the actual network infrastructure.
    Tests 3 and 4 should be showing the same connection times as the same physical network infrastructure is used - only the direction is reversed in the tests.
    I would assume that port settings on the switches and interface settings on the routers treat packets equally in both directions between 2 servers. But this could in part explain the problem if this is not the case. In a case of a router for example, the 1st test's ingress interface is the egress interface of the 2nd test (and vice versa). Configurations can differ substantially between interfaces on the same router. Likewise if there is a firewall - as different rule sets are applied in each test and these rule sets could differ.
    So I would not be too quick to state that this is definitely not a network problem. But I agree that based on the small percentage difference (assuming comparable tests), it does not look like a network issue.
    The next step is to determine what the delay is between the listener accepting the client connection, and the connection being serviced by a dedicated server process.
    This will require listener tracing - tracing the time from when the listener accepted the connection (and parsed the TNS connection string), to handing off the connection to the dedicated server process.
    As a comparison test, you can also test shared server connections. Dispatcher processes (of the db instance) register themselves with the listener. The shared server client hand off is thus done to an existing server process - no need for the Listener to make a kernel call to load and initialise an executable image.
    Shared connections are typically faster than dedicated connections in this respect.
    If there is a major time difference, then it means some kind of issue with the listener dealing with dedicated servers as oppose to dispatcher hand off's. As both connections would have had very similar network transit time - which means the connection time difference is related directly to dealing with a dedicated server connection request and hand off.
    You can also substitute the oracle executable with a wrapper - and troubleshoot the actual dedicated server startup. I've only done this with Oracle XE 10.2 though and with local IPC connections. Unsure how robust this will be for testing purposes via TCP using 11g.

  • Connect Via RMI To A Remote Service?

    Has anyone connected, via RMI, to a remote service within an application module? Currently this seems to wreak havoc upon all future and current ORMI communication to and from the application server in which a model is deployed (or at least within a container). Does anyone have any idea on how to do this correctly?
    -Brian
    When a connection is initiated I get the following stack trace:
    oracle.jbo.JboException: JBO-29000: Unexpected exception caught: java.security.AccessControlException, msg=access denied (java.net.SocketPermission ifd01-d.syd.nighthawkrad.net resolve)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.dispatchMethod(AbstractRemoteApplicationModuleImpl.java:6301)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.executeMethod(AbstractRemoteApplicationModuleImpl.java:6503)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processSvcMsgRequest(AbstractRemoteApplicationModuleImpl.java:4744)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processSvcMsgEntries(AbstractRemoteApplicationModuleImpl.java:4995)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.readServiceMessage(AbstractRemoteApplicationModuleImpl.java:4176)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processMessage(AbstractRemoteApplicationModuleImpl.java:2255)
         at oracle.jbo.server.ApplicationModuleImpl.doMessage(ApplicationModuleImpl.java:7509)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.sync(AbstractRemoteApplicationModuleImpl.java:2221)
         at oracle.jbo.server.remote.ejb.ServerApplicationModuleImpl.doMessage(ServerApplicationModuleImpl.java:79)
         at oracle.jbo.server.ejb.SessionBeanImpl.doMessage(SessionBeanImpl.java:474)
         at sun.reflect.GeneratedMethodAccessor15.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.evermind.server.ejb.interceptor.joinpoint.EJBJoinPointImpl.invoke(EJBJoinPointImpl.java:35)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.TxBeanManagedInterceptor.invoke(TxBeanManagedInterceptor.java:53)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.StatefulSessionEJBObject.OC4J_invokeMethod(StatefulSessionEJBObject.java:840)
         at RemoteQCServicesAppModule_StatefulSessionBeanWrapper226.doMessage(RemoteQCServicesAppModule_StatefulSessionBeanWrapper226.java:1902)
         at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.evermind.server.rmi.RmiMethodCall.run(RmiMethodCall.java:53)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)
    ## Detail 0 ##
    java.security.AccessControlException: access denied (java.net.SocketPermission ifd01-d.syd.nighthawkrad.net resolve)
         at java.security.AccessControlContext.checkPermission(AccessControlContext.java:264)
         at java.security.AccessController.checkPermission(AccessController.java:427)
         at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
         at java.lang.SecurityManager.checkConnect(SecurityManager.java:1031)
         at java.net.InetAddress.getAllByName0(InetAddress.java:1117)
         at java.net.InetAddress.getAllByName0(InetAddress.java:1098)
         at java.net.InetAddress.getAllByName(InetAddress.java:1061)
         at java.net.InetAddress.getByName(InetAddress.java:958)
         at java.net.InetSocketAddress.<init>(InetSocketAddress.java:124)
         at java.net.Socket.<init>(Socket.java:178)
         at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:22)
         at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:128)
         at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:569)
         at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:185)
         at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:171)
         at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:306)
         at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
         at net.nighthawk.ifd.client.communications.Communications.updateFaxViewerRMIServer(Communications.java:156)
         at net.nighthawk.talon.model.bc.autorad.QCServicesAppModuleImpl.sendReport(QCServicesAppModuleImpl.java:5560)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.dispatchMethod(AbstractRemoteApplicationModuleImpl.java:6279)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.executeMethod(AbstractRemoteApplicationModuleImpl.java:6503)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processSvcMsgRequest(AbstractRemoteApplicationModuleImpl.java:4744)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processSvcMsgEntries(AbstractRemoteApplicationModuleImpl.java:4995)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.readServiceMessage(AbstractRemoteApplicationModuleImpl.java:4176)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processMessage(AbstractRemoteApplicationModuleImpl.java:2255)
         at oracle.jbo.server.ApplicationModuleImpl.doMessage(ApplicationModuleImpl.java:7509)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.sync(AbstractRemoteApplicationModuleImpl.java:2221)
         at oracle.jbo.server.remote.ejb.ServerApplicationModuleImpl.doMessage(ServerApplicationModuleImpl.java:79)
         at oracle.jbo.server.ejb.SessionBeanImpl.doMessage(SessionBeanImpl.java:474)
         at sun.reflect.GeneratedMethodAccessor15.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.evermind.server.ejb.interceptor.joinpoint.EJBJoinPointImpl.invoke(EJBJoinPointImpl.java:35)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.TxBeanManagedInterceptor.invoke(TxBeanManagedInterceptor.java:53)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.StatefulSessionEJBObject.OC4J_invokeMethod(StatefulSessionEJBObject.java:840)
         at RemoteQCServicesAppModule_StatefulSessionBeanWrapper226.doMessage(RemoteQCServicesAppModule_StatefulSessionBeanWrapper226.java:1902)
         at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.evermind.server.rmi.RmiMethodCall.run(RmiMethodCall.java:53)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)

    Has anyone connected, via RMI, to a remote service within an application module? Currently this seems to wreak havoc upon all future and current ORMI communication to and from the application server in which a model is deployed (or at least within a container). Does anyone have any idea on how to do this correctly?
    -Brian
    When a connection is initiated I get the following stack trace:
    oracle.jbo.JboException: JBO-29000: Unexpected exception caught: java.security.AccessControlException, msg=access denied (java.net.SocketPermission ifd01-d.syd.nighthawkrad.net resolve)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.dispatchMethod(AbstractRemoteApplicationModuleImpl.java:6301)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.executeMethod(AbstractRemoteApplicationModuleImpl.java:6503)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processSvcMsgRequest(AbstractRemoteApplicationModuleImpl.java:4744)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processSvcMsgEntries(AbstractRemoteApplicationModuleImpl.java:4995)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.readServiceMessage(AbstractRemoteApplicationModuleImpl.java:4176)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processMessage(AbstractRemoteApplicationModuleImpl.java:2255)
         at oracle.jbo.server.ApplicationModuleImpl.doMessage(ApplicationModuleImpl.java:7509)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.sync(AbstractRemoteApplicationModuleImpl.java:2221)
         at oracle.jbo.server.remote.ejb.ServerApplicationModuleImpl.doMessage(ServerApplicationModuleImpl.java:79)
         at oracle.jbo.server.ejb.SessionBeanImpl.doMessage(SessionBeanImpl.java:474)
         at sun.reflect.GeneratedMethodAccessor15.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.evermind.server.ejb.interceptor.joinpoint.EJBJoinPointImpl.invoke(EJBJoinPointImpl.java:35)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.TxBeanManagedInterceptor.invoke(TxBeanManagedInterceptor.java:53)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.StatefulSessionEJBObject.OC4J_invokeMethod(StatefulSessionEJBObject.java:840)
         at RemoteQCServicesAppModule_StatefulSessionBeanWrapper226.doMessage(RemoteQCServicesAppModule_StatefulSessionBeanWrapper226.java:1902)
         at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.evermind.server.rmi.RmiMethodCall.run(RmiMethodCall.java:53)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)
    ## Detail 0 ##
    java.security.AccessControlException: access denied (java.net.SocketPermission ifd01-d.syd.nighthawkrad.net resolve)
         at java.security.AccessControlContext.checkPermission(AccessControlContext.java:264)
         at java.security.AccessController.checkPermission(AccessController.java:427)
         at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
         at java.lang.SecurityManager.checkConnect(SecurityManager.java:1031)
         at java.net.InetAddress.getAllByName0(InetAddress.java:1117)
         at java.net.InetAddress.getAllByName0(InetAddress.java:1098)
         at java.net.InetAddress.getAllByName(InetAddress.java:1061)
         at java.net.InetAddress.getByName(InetAddress.java:958)
         at java.net.InetSocketAddress.<init>(InetSocketAddress.java:124)
         at java.net.Socket.<init>(Socket.java:178)
         at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:22)
         at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:128)
         at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:569)
         at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:185)
         at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:171)
         at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:306)
         at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
         at net.nighthawk.ifd.client.communications.Communications.updateFaxViewerRMIServer(Communications.java:156)
         at net.nighthawk.talon.model.bc.autorad.QCServicesAppModuleImpl.sendReport(QCServicesAppModuleImpl.java:5560)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.dispatchMethod(AbstractRemoteApplicationModuleImpl.java:6279)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.executeMethod(AbstractRemoteApplicationModuleImpl.java:6503)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processSvcMsgRequest(AbstractRemoteApplicationModuleImpl.java:4744)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processSvcMsgEntries(AbstractRemoteApplicationModuleImpl.java:4995)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.readServiceMessage(AbstractRemoteApplicationModuleImpl.java:4176)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.processMessage(AbstractRemoteApplicationModuleImpl.java:2255)
         at oracle.jbo.server.ApplicationModuleImpl.doMessage(ApplicationModuleImpl.java:7509)
         at oracle.jbo.server.remote.AbstractRemoteApplicationModuleImpl.sync(AbstractRemoteApplicationModuleImpl.java:2221)
         at oracle.jbo.server.remote.ejb.ServerApplicationModuleImpl.doMessage(ServerApplicationModuleImpl.java:79)
         at oracle.jbo.server.ejb.SessionBeanImpl.doMessage(SessionBeanImpl.java:474)
         at sun.reflect.GeneratedMethodAccessor15.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.evermind.server.ejb.interceptor.joinpoint.EJBJoinPointImpl.invoke(EJBJoinPointImpl.java:35)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.TxBeanManagedInterceptor.invoke(TxBeanManagedInterceptor.java:53)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
         at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:69)
         at com.evermind.server.ejb.StatefulSessionEJBObject.OC4J_invokeMethod(StatefulSessionEJBObject.java:840)
         at RemoteQCServicesAppModule_StatefulSessionBeanWrapper226.doMessage(RemoteQCServicesAppModule_StatefulSessionBeanWrapper226.java:1902)
         at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.evermind.server.rmi.RmiMethodCall.run(RmiMethodCall.java:53)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)

  • Whats the difference between sending messages via socket and MQs?

    Whats the difference between sending messages via socket and MQs?

    Soph wrote:
    Whats the difference between sending messages via socket and MQs?With JMS (and the like) your application uses a socket to connect to a central server called a "*Message Broker*". Over this connection it can send or receive messages.
    A Message Broker is somewhat analogous to a database server. Multiple clients connect to it to exchange messages. As with a database a client first establishes a connection, then requests specific facilities like subscriptions.
    It creates a strong decoupling between sender and receiver and handles stuff like allowing multiple receivers for the same message, queuing of messages for applications not currently running and so on.
    (And don't worry, you can get perfectly good message brokers for free such as openMQ and activeMQ.)

  • How to send connection via packet ?

    hi *,
    when client connect to server , i want to save the connection from client ,
    but how can i send the connection via DataoutputStream to other client ?
    Socket = ServerSocket.accept();
    //when i accept the connect
    DataOutputStream out = new DataOutputStream(ServerSocket.getOutputStream());
    out.write??(Socket)???
    //how to send the connection to other client via DataOutputStream???

    bobby92 wrote:
    hi *,
    when client connect to server , i want to save the connection from client ,
    but how can i send the connection via DataoutputStream to other client ?
    Socket = ServerSocket.accept();
    //when i accept the connect
    DataOutputStream out = new DataOutputStream(ServerSocket.getOutputStream());
    out.write??(Socket)???
    //how to send the connection to other client via DataOutputStream???
    The client already knows about the connection (since it connected to the server). I don't know what problem you are trying to solve, but it sounds like you want to give the client som kind of id, and store the connections in a map on the server, and use the client id as key in the map.

  • [Solved] irexec: could not connect to socket

    I am trying to start irexec via .xinitrc which has worked fine for me pre-systemd, but now I am getting the following error:
    irexec: could not connect to socket
    irexec: no such file or directory
    Lirc is running fine, remote works in mythtv.
    Here's my .xinitrc
    cat ~/.xinitrc
    #!/bin/sh
    # ~/.xinitrc
    # Executed by startx (run your window manager from here)
    # exec gnome-session
    # exec startkde
    # exec startxfce4
    # ...or the Window Manager of your choice
    #exec xterm
    #start irexec
    irexec &
    #exec /usr/bin/xbmc &
    #turn off screensaver
    xset s off -dpms
    #start xfce4
    exec startxfce4
    and my lirc
    cat /usr/lib/systemd/system/lirc.service
    [Unit]
    Description=Linux Infrared Remote Control
    [Service]
    ExecStartPre=/usr/bin/ln -sf /run/lirc/lircd /dev/lircd
    ExecStart=/usr/sbin/lircd --pidfile=/run/lirc/lircd.pid
    Type=forking
    PIDFile=/run/lirc/lircd.pid
    [Install]
    WantedBy=multi-user.target
    and my /etc/conf.d/lircd.conf
    cat /etc/conf.d/lircd.conf
    # Parameters for lirc daemon
    LIRC_DEVICE="/dev/lirc0"
    LIRC_DRIVER=""
    LIRC_EXTRAOPTS=""
    LIRC_CONFIGFILE=""
    I tried starting irexec via systemd, too, but that did not work either:
    sudo systemctl status irexec.service
    irexec.service - IR Exec
    Loaded: loaded (/usr/lib/systemd/system/irexec.service; enabled)
    Active: inactive (dead) since Sun 2013-04-21 20:17:11 CST; 1s ago
    Process: 459 ExecStart=/usr/bin/irexec --daemon (code=exited, status=0/SUCCESS)
    Apr 21 20:17:11 frontend systemd[1]: Starting IR Exec...
    Apr 21 20:17:11 frontend systemd[1]: Started IR Exec.
    cat /usr/lib/systemd/system/irexec.service
    [Unit]
    Description=IR Exec
    After=lirc.service
    Wants=lirc.service
    [Service]
    ExecStart=/usr/bin/irexec --daemon
    Type=forking
    [Install]
    WantedBy=multi-user.target
    Any help or pointers will be much appreciated.
    Last edited by dafrizz (2013-06-08 23:58:25)

    Thanks for your help so far. I thought it was the other way around, my mistake,
    Still no luck, now I get the following:
    sudo systemctl start irexec
    Job for irexec.service failed. See 'systemctl status irexec.service' and 'journalctl -xn' for details.
    sudo systemctl status irexec
    irexec.service - IR Exec
    Loaded: loaded (/etc/systemd/system/irexec.service; enabled)
    Active: failed (Result: timeout) since Sat 2013-06-08 16:16:17 CST; 10s ago
    Process: 11748 ExecStart=/usr/bin/irexec (code=killed, signal=TERM)
    Jun 08 16:14:47 frontend systemd[1]: Starting IR Exec...
    Jun 08 16:16:17 frontend systemd[1]: irexec.service operation timed out. Terminating.
    Jun 08 16:16:17 frontend systemd[1]: Failed to start IR Exec.
    Jun 08 16:16:17 frontend systemd[1]: Unit irexec.service entered failed state.
    sudo journalctl -xn
    -- Logs begin at Sat 2013-04-20 18:36:51 CST, end at Sat 2013-06-08 16:16:44 CST. --
    Jun 08 16:15:41 frontend sudo[11759]: pam_unix(sudo:session): session closed for user root
    Jun 08 16:16:17 frontend systemd[1]: irexec.service operation timed out. Terminating.
    Jun 08 16:16:17 frontend systemd[1]: Failed to start IR Exec.
    -- Subject: Unit irexec.service has failed
    -- Defined-By: systemd
    -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
    -- Documentation: http://www.freedesktop.org/wiki/Software/systemd/catalog/be02cf6855d2428ba40df7e9d022f03d
    -- Unit irexec.service has failed.
    -- The result is failed.
    Jun 08 16:16:17 frontend systemd[1]: Unit irexec.service entered failed state.
    Jun 08 16:16:17 frontend sudo[11745]: pam_unix(sudo:session): session closed for user root

  • Receiving Image via socket and creating via byte[]...

    Hi Folks...
    I�m trying to send a WebCam SnapShot to my Midlet running in a PDA via socket..
    The method used to send the Image is:
    BufferedImage img = toBufferedImage( getScreenShot( getFrameBuffer() ) );
              byte[] buf = convertImage( toBufferedImage( img ) );
              BASE64Encoder enc64 = new BASE64Encoder();
              enc64.encode(buf);
              try {
                   out.writeUTF("IMAGEM");
                   out.writeInt( buf.length );
                   out.write( buf );
              } catch (IOException e) {
                   e.printStackTrace();
              }So this code get a snapShot from the webCam and returns a BufferedImage. This BufferedImage is converted to a byte[], and later this byte[] is encoded in Base64 format with BASE64Encoder.
    In the next step the buffer is sent to the client, the server send the message "IMAGEM", in the sequence the size off the byte[] and then the byte[].
    The code that receive the Image byte[]...
    private void receiveImageAction(){
              byte[] buf;
              try {
                   buf = new byte[ in.readInt() ];
                   in.read(buf);
                   Image img = Image.createImage( buf, 0 , buf.length );
                   viewForm.setMsg("Image created");
                   viewForm.setImageView(img);
              } catch (IOException e) {
                   viewForm.setMsg( "" + e.toString() );
              }catch(Exception e){
                   viewForm.setMsg( "" + e.toString() );
         }When the connection manager receives a message "IMAGEM" the function receiveImageAction is called.
    It receives the size off the byte[] and then receive the array.
    When I try to create the image using Image.createImage( byte[], int, int ) the exception IllegalArgumentException is throwed...
    The exception doesnt have a message...
    What is wrong ?
    Is the format off my image sent ?
    Is my buffer been encoded correctly by the BASE64Encoder class ?

    Will u try with replacing this line
    Image img = Image.createImage( buf, 0 , buf.length );with this line
    Image img = Image.createImage( buf, 0 , buf.length-1 );

  • 10.5.2 - cannot print with Samsung CLP-510 connected via Airport

    After 10.5.2 Leopard upgrade, the printer Samsung CLP-510 prints only if it's connected directly to my MacBook (or my PowerBook), not if it's connected via Airport (Extreme): the printers become soon busy and give the message "Device busy, please retry...", and after some time the printer print an error page with "timeout" error.
    No luck resetting the Airport.
    Any workaround, please?
    Thanks in advance
    Salvo

    These steps may help:
    1. Open System Preferences and click on the "Print & Fax" icon
    2. Click on the "+" button to add a printer
    3. Click on the "IP" button in the toolbar
    4. Choose "HP Jetdirect - Socket" from the "Protocol" option menu
    5. Enter the hostname or IP of the Airport base station in the "Address" field - typically 10.0.0.1 or your base station name with ".local" on the end
    6. Leave the "Queue" field blank
    7. Replace the auto-generated name with something meaningful to you in the "Name" field
    8. Choose "Select a driver to use" from the "Print Using" option menu, and then type in the model number for your printer to locate the corresponding printer driver
    9. Click "Add" to add the printer, then try printing
    If you report back with your results, it would be appreciated.

  • Powerbook G4 can't connect via ethernet but connects via airport

    We have a small office network connected to an Efficient Networks DSL router that's managed by our isp. The router has 4 ports and a linksys 8 port switch is connected to one of those ports. Another D-Link wireless router/switch is connected to another port.
    2 i-macs connect without problem via ethernet cable. They are set to DHCP and get 192.xx private addresses. Both run 10.4.5. Another older imac running 9.2.2. also has no problems.
    I recently purchased a powerbook G4 and it will not connect via ethernet to the Efficient networks router. At first it was connected to the linksys, so decided to connect it direct to the Efficient Networks router. With DHCP, it acquires a 169. internet address which is self generated (i.e. no real connection). I tried to give it a static private address (talking to the isp provider). They could see the powerbook but saw all zero's (presumable mac address). By the way the Powerbook works perfectly at home connected via ethernet cable to a D-Link router connected to a cable modem so it's not a physical problem. I even checked the ethernet cable I used in the office with another computer - no problem.
    When I switch to airport in the office, the powerbook connects to the network and the internet. I get some strange warning messages showing the server's and the router's private ip addresses. I click ok, and the powerbook finds an unassigned private ip address. It's the only way it will work, but it causes problems, because I can't connect to one of the network printers. Speed also isn't great.
    Can anyone give me advise how to proceed. I am no expert on this stuff so keep it as simple as possible.
    Tks

    Tim,
    Thanks for your help. Here's what I've done before reading your e-mail. The D-Link DI-524 wireless router is connected to the Effiicent Neworks DSL router as you mentioned. One ethernet port of the EFF.Net. router is connected to the WAN port of the DI-514.
    Because I have a D-Link router at home which works flawlessly with my powerbook, I decided to connect the ethernet cable of the powerbook to the D-Link which has 4 ethernet ports. Lo and behold, the powerbook acquired a private ip address and connected to the LAN and internet!
    When I connected the powerbook direct to the Efficient Networks router, it could not communicate. I believe that there must be some software incompatibility between the powerbook and the Efficient Networks router. By connecting to the D-Link, the D-Link assigned an ip address to the powerbook, and it could connect to the server, lan, etc..
    Only problem is that I have a Brother network printer that cannot connect to the powerbook. My powerbook cannot find it on the network. Because there is a linksys switch connected to the efficient networks router's third ethernet port, maybe as you said, going through the D-Link via DHCP (when the Linksys is also acting as a DHCP server, might cause this type of problem. What do you think?
    As a final note, other imac G5's connected to the linksys switch (which then connects to the Efficient Network's router) have no problem connecting to the lan or internet and have no problem connecting to any of the printers. When I put the powerbook on that switch, I could not connect to the internet - i.e. whether connecting via the lynksys switch or direct with the efficient networks router - same results: no internet connection whether manually or via DHCP.
    So the imac G5 has no problem with the efficient networks router but the powerbook G4 hits a brick wall. The G4 likes the D-Link router. I am concerned (and I will have to check this) that if I turn off the dhcp server feature from the D-Link, that whatever software issue crops up between the powerbook and the Efficient Networks router, will rise up again, because the D-Link will act like a simple switch (just like my linksys switch), and we'll be back to square zero. In any case, no harm in trying. This may be the cause of the Powerbook not seeing that Brother printer (even though it sees another printer and other macs).
    Having spent hours reading about network problems, I think it's safe to say that macs have problems with certain routers. Why a G5 works and a powerbook G4 doesn't is beyond me, but clearly software must play a role.

  • When iPhone 5s is connected via USB no audio is heard

    Hi There -
    I've seen older threads on this issue but I don't think I've really come across any solutions. My issue started yesterday; now before reading further I have to ask that you please keep in mind that I did perform the latest upgrade on my iPhone a bit earlier in the day.
    When I connect my iPhone to my vehicle sync system and announce that I'd like to connect via USB, the voice recognition repeats my request and then the music on my iPhone shows to be playing on the display in my vehicle. The problem is that though the music appears to be playing and the minutes played are being displayed there is no audio coming through. When I switch to the Bluetooth Audio option all sound comes through.
    Now, as a 2nd test, we connected my sons iPhone 5s via USB (he has not taken the latest update on his iPhone) and the same issue happens with his. Voice recognition changes to the USB format as requested, music appears to be playing but no audio is heard. When we change his phone to Bluetooth Audio the audio comes through nice and clear.
    I'm not entirely convinced the update caused the issue so I wanted to put this out there to see if anyone has run into this and were able to actually resolve the issue.
    I know the USB cable is working fine because when I do plug it into either phone the phone makes the little connection sound and pops up a brief battery percentage box. I also know the cable is working because when we announce USB as our audio of choice the system recognize USB via the iPhone.
    One other thing I tried looking for was the option on the phone to switch from Docked to Synch - I know on my iPhone 4 I was able to switch back and forth through iTunes and would also have the option if I tried to watch anything via You Tube when connected to the dock; I cannot find this anywhere on the 5s when connected via USB.
    Help is greatly appreciated!!!

    I have had similar troubles with wifi.. some improvement removing BlackBerry desktop software & drivers & reinstalling after reboot... I used the same installer I had previously, but a fresh downloaded installer couldn't hurt...
    10.3.1 SW .1779 OS .2726 WLAN .1.1 Radio .2727

  • The iTune Remote App has stopped finding my iTunes library when connected to wifi from my main router, but works fine when connected via second wifi router on the same network (different SSID)

    I'm running iTunes Remote App from a couple of iPhone 5's and a first generation iPod Touch. iTunes is running on a PC - Windows 7. My home network runs two Wifi Routers, each with a different SSID. I've had no problems with the Remote app running this set up for the last 8 months but recently the App can only find my iTunes library when the iPhone/iPod is connected via one specific router, when connected to the network via the other router, no iTunes library is found. I'm also running an Apple TV and it's the same as the iTunes Library, only visible via the one SSID.
    Everything else seems to work fine when connected via either router, eg Internet on the iPhones (definitely via wifi)
    I've tried renewing the lease on the iPhone wifi connection, restarting everything.....several times.....
    It used to work fine, this only seems to have been a problem in recent weeks
    Any help or advice would be much appreciated
    Thanks
    Ian

    It turned out to be the firewall settings on our router. Her machine was sending traffic that our router interpreted as a DoS attack and blacklisted her Airport's MAC address. That's why it would work fine if she switched to Ethernet.

  • My Canon MX 922 does not scan. My printer is connected via cable. Wireless doesn't work either.

    My Canon MX 922 does not scan. My printer is connected via cable. Wireless doesn't work either.  I get an error message with multiple suggestions but none of them apply to my situation.
    I am so dissatisfied with this printer.  I'm sorry I got it from Amazon because now it is a hassle to return it.  I will never buy another Canon.
    The printer menus are confusing.  I hate using it.  I loved my previous Canon which finally stopped working after many years, that's why I purchased a newer Canon model.  Never again.  Stick with cameras.
    Marcy Hotz

    This note won't be as angry and frustrated as the last one...
    Because I still had my old printer drivers and other applications on my hard drive, I think the application was trying to connect with the old printer.  I deleted all the old stuff.
    I also had several scanning applications on my drive which just confused me.
    When I used the actual Canon MX922 application, I was able to scan but could only save as JPG, TIF or BMP (and one more, I forget which).  So I did some research on the Canon site and found out how to save documents as PDF files using the Canon IJ Scan Utility.
    It works now.  So I'm satisfied, will keep this maching.  I just had to take some time, sit down and focus on the problem.

  • Internet connection via Airport Extreme/router thats not working, why?

    I have been having problems with the internet connection via Airport Extreme which I find it a bit unusual and its still driving me nuts! This is what happened:
    I have lost my internet connection last Sunday evening upon my return from a weekend away from home. The last time I have used the internet connection on my macbook was the previous Friday morning. Prior to the apparent disconnection on Sunday, I have always used my internet connection wirelessly through Airport Extreme (that is connected via ethernet cable to the NETGEAR DG834v2 ADSL modem which had worked beautifully until the problem arose on my return). This wireless internet connection allowed me to surf the internet anywhere in my home.
    However, upon the successful re-connection to the internet via the modem router, I have discovered several new problems. I have tried to set up the internet connection wirelessly again but instead the following happened:
    1. Router (Netgear) drops ADSL connection and cannot reconnect when connected to airport via Ethernet. (which is the case when using airport wireless).
    2. Router connects to ADSL fine when computer is connected to it via Ethernet. (However, router disconnects when magsafe power adapter is taken out for some inexplicable reason!)
    3. Router connects to ADSL fine when nothing is connected to the router (ie. No Ethernet connections)
    4. Router connects to ADSL fine when connected to airport via Ethernet and computer is connected to airport via Ethernet.
    So from the above, I cannot connect to the internet properly whether wirelessly or not so I suspect it could be faulty router or could it be airport extreme? I have asked my ISP for an explanation and all they have said is that it cannot be the mis-configuration but could be to do with the power adaptors or the way plugs are set up and suggested I take out all the power plugs (and power surge protector) out to switch everything off, the macbook, router, printer and airport extreme. However, when I have re-plugged them all back in, the problems I have described above still persists!
    Would appreciate any help if anyone here recognises why this is the case and what seems to be the cause of this. If so, what should I do? Though I have written back to my ISP again yesterday for more help so im waiting to hear from them...
    Thanks
    u2dougal

    I have been having problems with the internet connection via Airport Extreme which I find it a bit unusual and its still driving me nuts! This is what happened:
    I have lost my internet connection last Sunday evening upon my return from a weekend away from home. The last time I have used the internet connection on my macbook was the previous Friday morning. Prior to the apparent disconnection on Sunday, I have always used my internet connection wirelessly through Airport Extreme (that is connected via ethernet cable to the NETGEAR DG834v2 ADSL modem which had worked beautifully until the problem arose on my return). This wireless internet connection allowed me to surf the internet anywhere in my home.
    However, upon the successful re-connection to the internet via the modem router, I have discovered several new problems. I have tried to set up the internet connection wirelessly again but instead the following happened:
    1. Router (Netgear) drops ADSL connection and cannot reconnect when connected to airport via Ethernet. (which is the case when using airport wireless).
    2. Router connects to ADSL fine when computer is connected to it via Ethernet. (However, router disconnects when magsafe power adapter is taken out for some inexplicable reason!)
    3. Router connects to ADSL fine when nothing is connected to the router (ie. No Ethernet connections)
    4. Router connects to ADSL fine when connected to airport via Ethernet and computer is connected to airport via Ethernet.
    So from the above, I cannot connect to the internet properly whether wirelessly or not so I suspect it could be faulty router or could it be airport extreme? I have asked my ISP for an explanation and all they have said is that it cannot be the mis-configuration but could be to do with the power adaptors or the way plugs are set up and suggested I take out all the power plugs (and power surge protector) out to switch everything off, the macbook, router, printer and airport extreme. However, when I have re-plugged them all back in, the problems I have described above still persists!
    Would appreciate any help if anyone here recognises why this is the case and what seems to be the cause of this. If so, what should I do? Though I have written back to my ISP again yesterday for more help so im waiting to hear from them...
    Thanks
    u2dougal

  • Question regarding ONT connection via Ethernet and Cable cards

    Hi,
    We recently upgraded to Fios Quation 150Mbps/65  plan. We are not getting the advertised speeds (we only get like 5mbps upload) so verizon is sending a tech to switch the ONT connection from coax to ethernet.
    I have 2 questions regarding this new setup:
    1. If the ONT communicates with the Fios Actiontect router via ethernet instead of coax from now on, How will the set top boxes and Tivo-esque cable card powered device I currently have connected to coax, talk to the verizon system from now on, if coax is taken out of the equation? Will fios signal still flow through the internal coax wiring of the house? And moreover, I was under the impression that coax was the way set top boxes communicated and derived independent ip addresses from the Fios router, for on deman purposes and what not. How will this work from now on?
    Quiestion 2.
    Right next to the wall where the ONT sits, theres's a basement office where we have a PC that connects to the Fios system  via an Actiontect MoCa adapter (ECB2500C) which I assume derives it internet connection from the Fios Actiontec router which sits upstairs in the living room. 
    Again, with the Coax about to be disabled next Friday in favor of ethernet connection from the ONT, I assume this PC will be left without internet because of the lack of internet signal in the coax? Is this correct? 
    Question 2.5 If my above assumption is correct, since this office is right on the other side of the wall where the ONT sits outside the house, would it be possible to run an ethernet wire through the wall that connects straight from the ONT to an ethernet switch inside the office, from which I would derive a connection for this basement PC (properly firewalled of course) and then, from said switch, continue running the ethernet wire that would ultimately reach the Actiontec Fios router upstairs from which the rest of the house derives it's internet?  and would this setup affect in any way the propper functioning of the cable boxes in the house?
    I'd appreciate your input and any help you can provide so I can have a ballpark idea of what to tell the Fios guy to do when he comes on Friday.
    Cheers.
    Solved!
    Go to Solution.

    It's not valid to have two devices connected to the ONT, PC and VZ Router.  Must be a single device. The ONT locks onto the MAC Address of the first device it sees. Since you have TV you should have the VZ router as the internet facing router.
    Other options:
    1.  Have the VZ Router located next to the PC in the basement and then use Wireless for all other PC's.
    2.  Have the VZ Router located next to the PC in the basement but run one wire upstairs and connect a switch where other PCs and devices can connect via a wire.
    Hope that helps.

Maybe you are looking for