Last login: Mon Feb 13 10:09:35 on ttys000 odd-2% ls 1f88.ent dynamics.ppt 2008_02_19_irina_collab.pdf eclipse Applications error.txt CV_NIH_2008_02_19.pdf groel-c7.mrc DVDTemp groel.12A.mrc Desktop groel.12A.pub.mrc Documents groel.published.12.mrc Downloads groel.xray.12A.mrc Dropbox installed DumpLog 11-06-12 17:56 lib DumpLog 11-06-19 22:42 mail DumpLog 11-06-19 22:46 me.jpg DumpLog 11-06-19 22:54 me.psd DumpLog 11-06-19 22:59 mmcpn.py DumpLog 11-06-19 23:01 mmcpn.side.gif DumpLog 11-06-19 23:07 mmcpn.top.gif EMAN p1.txt EMAN2 p2.txt EMAN2.odp pro EMAN2.old proc3d.filt EMAN2.ppt proc3d.raddist EMAN2DB r_07_04.hdf Image Data Converter SR r_09_04.hdf ImageMagick-6.4.0 r_16_02.hdf Library r_16_02.jpg Movies r_16_02f.hdf Music r_35_02.hdf Pictures refine Public refine.log QtSDK result.txt Reference2.pdf s2 Sites scripps.pdf StrucFact.sm session9.txt UCLA.pdf share VirtualBox VMs snapshot1.png aacmsched.pdf speed.hed aacmsched2.pdf speed.img abstract.doc std.ics bin test.html burn test.mov cam.html test.py cd test1.mp4 chimera_movie.mov test2.py chimera_movie.mp4 test2.pyc chimera_movie2.mp4 tmp classes.png tomotrackbox.py ctf.fg1d.ps tst.hdf ctfparm.txt tst.txt d video.mpg data wp dot.hdf x.py dot2.hdf odd-2% cd odd-2% cd wp/lecture/2012_01_Intro_Programming/lec11 odd-2% ls 000AcPiano.mid 3.mid 6.mid a.mid pmid.py 1.mid 4.mid 7.mid client.py server.py 2.mid 5.mid CannonDance.mid example_seq.txt synth.py odd-2% vi x.py zsh: suspended vi x.py odd-2% fg [1] + continued vi x.py odd-2% python server.py Command> Server started, with address 192.168.1.101 Connection 0 from ('192.168.1.102', 52973) Connection 1 from ('192.168.1.105', 56539) Connection 2 from ('192.168.1.104', 57013) Connection 3 from ('192.168.1.106', 50534) Connection 4 from ('192.168.1.109', 49472) liConnection 5 from ('192.168.1.107', 64197) st 0. ('192.168.1.102', 52973) 1. ('192.168.1.105', 56539) 2. ('192.168.1.104', 57013) 3. ('192.168.1.106', 50534) 4. ('192.168.1.109', 49472) 5. ('192.168.1.107', 64197) Command> Connection 6 from ('192.168.1.110', 62045) test Failed on ('192.168.1.104', 57013) Command> Connection 7 from ('192.168.1.106', 50535) Connection 8 from ('192.168.1.111', 52584) Connection 9 from ('192.168.1.104', 57021) Command unknown Command> test Failed on ('192.168.1.104', 57013) Failed on ('192.168.1.106', 50534) Command> ^[[A Command unknown Command> test Failed on ('192.168.1.104', 57013) Failed on ('192.168.1.106', 50534) Command> Connection 10 from ('192.168.1.103', 59092) test Failed on ('192.168.1.104', 57013) Failed on ('192.168.1.106', 50534) Command> list 0. ('192.168.1.102', 52973) 1. ('192.168.1.105', 56539) 2. ('192.168.1.104', 57013) 3. ('192.168.1.106', 50534) 4. ('192.168.1.109', 49472) 5. ('192.168.1.107', 64197) 6. ('192.168.1.110', 62045) 7. ('192.168.1.106', 50535) 8. ('192.168.1.111', 52584) 9. ('192.168.1.104', 57021) 10. ('192.168.1.103', 59092) Command> play Command> stop Command> Connection 11 from ('192.168.1.108', 50689) Connection 12 from ('192.168.1.110', 62061) play Command> stop Command> Connection 13 from ('192.168.1.112', 1474) play Command> stop Command> quit Waiting for listener to exit ^C^Z zsh: suspended python server.py odd-2% kill %1 odd-2% [1] + terminated python server.py odd-2% python server.py Command> Server started, with address 192.168.1.101 Connection 0 from ('192.168.1.110', 62073) Connection 1 from ('192.168.1.107', 64229) Connection 2 from ('192.168.1.112', 1483) Connection 3 from ('192.168.1.111', 52606) Connection 4 from ('192.168.1.108', 50694) Connection 5 from ('192.168.1.106', 50538) Connection 6 from ('192.168.1.102', 52988) test Command> play Command> Connection 7 from ('192.168.1.104', 57025) stop Command> Connection 8 from ('192.168.1.108', 50697) Traceback (most recent call last): File "server.py", line 53, in com=raw_input("Command> ").lower() EOFError ^C^Z zsh: suspended python server.py odd-2% kill %1 odd-2% [1] + terminated python server.py odd-2% odd-2% host www.google.com www.google.com is an alias for www.l.google.com. www.l.google.com has address 74.125.227.19 www.l.google.com has address 74.125.227.20 www.l.google.com has address 74.125.227.16 www.l.google.com has address 74.125.227.17 www.l.google.com has address 74.125.227.18 odd-2% dig ; <<>> DiG 9.7.3-P3 <<>> ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 11750 ;; flags: qr rd ra; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 0 ;; QUESTION SECTION: ;. IN NS ;; ANSWER SECTION: . 168705 IN NS j.root-servers.net. . 168705 IN NS k.root-servers.net. . 168705 IN NS f.root-servers.net. . 168705 IN NS g.root-servers.net. . 168705 IN NS i.root-servers.net. . 168705 IN NS c.root-servers.net. . 168705 IN NS d.root-servers.net. . 168705 IN NS b.root-servers.net. . 168705 IN NS m.root-servers.net. . 168705 IN NS h.root-servers.net. . 168705 IN NS e.root-servers.net. . 168705 IN NS l.root-servers.net. . 168705 IN NS a.root-servers.net. ;; Query time: 5 msec ;; SERVER: 128.249.38.101#53(128.249.38.101) ;; WHEN: Mon Feb 13 11:18:25 2012 ;; MSG SIZE rcvd: 228 odd-2% dig www.google.com ; <<>> DiG 9.7.3-P3 <<>> www.google.com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 24943 ;; flags: qr rd ra; QUERY: 1, ANSWER: 6, AUTHORITY: 0, ADDITIONAL: 0 ;; QUESTION SECTION: ;www.google.com. IN A ;; ANSWER SECTION: www.google.com. 341341 IN CNAME www.l.google.com. www.l.google.com. 153 IN A 74.125.227.20 www.l.google.com. 153 IN A 74.125.227.16 www.l.google.com. 153 IN A 74.125.227.17 www.l.google.com. 153 IN A 74.125.227.18 www.l.google.com. 153 IN A 74.125.227.19 ;; Query time: 6 msec ;; SERVER: 128.249.38.101#53(128.249.38.101) ;; WHEN: Mon Feb 13 11:18:31 2012 ;; MSG SIZE rcvd: 132 odd-2% more /etc/services # # Network services, Internet style # # Note that it is presently the policy of IANA to assign a single well-known # port number for both TCP and UDP; hence, most entries here have two entries # even if the protocol doesn't support UDP operations. # # The latest IANA port assignments can be gotten from # # http://www.iana.org/assignments/port-numbers # # The Well Known Ports are those from 0 through 1023. # The Registered Ports are those from 1024 through 49151 # The Dynamic and/or Private Ports are those from 49152 through 65535 # # $FreeBSD: src/etc/services,v 1.89 2002/12/17 23:59:10 eric Exp $ # From: @(#)services 5.8 (Berkeley) 5/9/91 # # WELL KNOWN PORT NUMBERS # rtmp 1/ddp #Routing Table Maintenance Protocol tcpmux 1/udp # TCP Port Service Multiplexer tcpmux 1/tcp # TCP Port Service Multiplexer # Mark Lottor nbp 2/ddp #Name Binding Protocol compressnet 2/udp # Management Utility compressnet 2/tcp # Management Utility compressnet 3/udp # Compression Process compressnet 3/tcp # Compression Process # Bernie Volz echo 4/ddp #AppleTalk Echo Protocol # 4/tcp Unassigned # 4/udp Unassigned rje 5/udp # Remote Job Entry rje 5/tcp # Remote Job Entry # Jon Postel zip 6/ddp #Zone Information Protocol # 6/tcp Unassigned # 6/udp Unassigned echo 7/udp # Echo echo 7/tcp # Echo # Jon Postel # 8/tcp Unassigned # 8/udp Unassigned discard 9/udp # Discard discard 9/tcp # Discard # Jon Postel # 10/tcp Unassigned # 10/udp Unassigned systat 11/udp # Active Users systat 11/tcp # Active Users # Jon Postel # 12/tcp Unassigned # 12/udp Unassigned daytime 13/udp # Daytime (RFC 867) daytime 13/tcp # Daytime (RFC 867) # Jon Postel # 14/tcp Unassigned # 14/udp Unassigned # 15/tcp Unassigned [was netstat] # 15/udp Unassigned # 16/tcp Unassigned # 16/udp Unassigned qotd 17/udp # Quote of the Day qotd 17/tcp # Quote of the Day # Jon Postel msp 18/udp # Message Send Protocol msp 18/tcp # Message Send Protocol # Rina Nethaniel <---none---> chargen 19/udp # Character Generator chargen 19/tcp # Character Generator ftp-data 20/udp # File Transfer [Default Data] ftp-data 20/tcp # File Transfer [Default Data] ftp 21/udp # File Transfer [Control] ftp 21/tcp # File Transfer [Control] # Jon Postel ssh 22/udp # SSH Remote Login Protocol ssh 22/tcp # SSH Remote Login Protocol # Tatu Ylonen telnet 23/udp # Telnet telnet 23/tcp # Telnet # Jon Postel 24/udp # any private mail system 24/tcp # any private mail system # Rick Adams smtp 25/udp # Simple Mail Transfer smtp 25/tcp # Simple Mail Transfer # Jon Postel # 26/tcp Unassigned # 26/udp Unassigned nsw-fe 27/udp # NSW User System FE nsw-fe 27/tcp # NSW User System FE # Robert Thomas # 28/tcp Unassigned # 28/udp Unassigned msg-icp 29/udp # MSG ICP msg-icp 29/tcp # MSG ICP # Robert Thomas # 30/tcp Unassigned # 30/udp Unassigned msg-auth 31/udp # MSG Authentication msg-auth 31/tcp # MSG Authentication # Robert Thomas # 32/tcp Unassigned # 32/udp Unassigned dsp 33/udp # Display Support Protocol dsp 33/tcp # Display Support Protocol # Ed Cain # 34/tcp Unassigned # 34/udp Unassigned 35/udp # any private printer server 35/tcp # any private printer server # Jon Postel # 36/tcp Unassigned # 36/udp Unassigned time 37/udp # Time time 37/tcp # Time # Jon Postel rap 38/udp # Route Access Protocol rap 38/tcp # Route Access Protocol # Robert Ullmann rlp 39/udp # Resource Location Protocol rlp 39/tcp # Resource Location Protocol # Mike Accetta # 40/tcp Unassigned # 40/udp Unassigned graphics 41/udp # Graphics graphics 41/tcp # Graphics name 42/udp nameserver # Host Name Server name 42/tcp nameserver # Host Name Server nicname 43/tcp whois nicname 43/udp whois mpm-flags 44/udp # MPM FLAGS Protocol mpm-flags 44/tcp # MPM FLAGS Protocol mpm 45/udp # Message Processing Module [recv] mpm 45/tcp # Message Processing Module [recv] mpm-snd 46/udp # MPM [default send] mpm-snd 46/tcp # MPM [default send] # Jon Postel ni-ftp 47/udp # NI FTP ni-ftp 47/tcp # NI FTP # Steve Kille auditd 48/udp # Digital Audit Daemon auditd 48/tcp # Digital Audit Daemon # Larry Scott tacacs 49/udp # Login Host Protocol (TACACS) tacacs 49/tcp # Login Host Protocol (TACACS) # Pieter Ditmars re-mail-ck 50/udp # Remote Mail Checking Protocol re-mail-ck 50/tcp # Remote Mail Checking Protocol # Steve Dorner la-maint 51/udp # IMP Logical Address Maintenance la-maint 51/tcp # IMP Logical Address Maintenance # Andy Malis xns-time 52/udp # XNS Time Protocol xns-time 52/tcp # XNS Time Protocol # Susie Armstrong domain 53/udp # Domain Name Server domain 53/tcp # Domain Name Server # Paul Mockapetris xns-ch 54/udp # XNS Clearinghouse xns-ch 54/tcp # XNS Clearinghouse # Susie Armstrong isi-gl 55/udp # ISI Graphics Language isi-gl 55/tcp # ISI Graphics Language xns-auth 56/udp # XNS Authentication xns-auth 56/tcp # XNS Authentication # Susie Armstrong 57/udp # any private terminal access 57/tcp # any private terminal access # Jon Postel xns-mail 58/udp # XNS Mail xns-mail 58/tcp # XNS Mail # Susie Armstrong 59/udp # any private file service 59/tcp # any private file service # Jon Postel 60/udp # Unassigned 60/tcp # Unassigned ni-mail 61/udp # NI MAIL ni-mail 61/tcp # NI MAIL # Steve Kille acas 62/udp # ACA Services acas 62/tcp # ACA Services # E. Wald whois++ 63/udp # whois++ whois++ 63/tcp # whois++ # Rickard Schoultz covia 64/udp # Communications Integrator (CI) covia 64/tcp # Communications Integrator (CI) # Dan Smith tacacs-ds 65/udp # TACACS-Database Service tacacs-ds 65/tcp # TACACS-Database Service # Kathy Huber sql*net 66/udp # Oracle SQL*NET sql*net 66/tcp # Oracle SQL*NET # Jack Haverty bootps 67/udp # Bootstrap Protocol Server bootps 67/tcp # Bootstrap Protocol Server bootpc 68/udp # Bootstrap Protocol Client bootpc 68/tcp # Bootstrap Protocol Client # Bill Croft tftp 69/udp # Trivial File Transfer tftp 69/tcp # Trivial File Transfer # David Clark gopher 70/udp # Gopher gopher 70/tcp # Gopher # Mark McCahill netrjs-1 71/udp # Remote Job Service netrjs-1 71/tcp # Remote Job Service netrjs-2 72/udp # Remote Job Service netrjs-2 72/tcp # Remote Job Service netrjs-3 73/udp # Remote Job Service netrjs-3 73/tcp # Remote Job Service netrjs-4 74/udp # Remote Job Service netrjs-4 74/tcp # Remote Job Service # Bob Braden 75/udp # any private dial out service 75/tcp # any private dial out service # Jon Postel deos 76/udp # Distributed External Object Store deos 76/tcp # Distributed External Object Store # Robert Ullmann 77/udp # any private RJE service 77/tcp # any private RJE service # Jon Postel vettcp 78/udp # vettcp vettcp 78/tcp # vettcp # Christopher Leong finger 79/udp # Finger finger 79/tcp # Finger # David Zimmerman http 80/udp www www-http # World Wide Web HTTP http 80/tcp www www-http # World Wide Web HTTP # Tim Berners-Lee hosts2-ns 81/udp # HOSTS2 Name Server hosts2-ns 81/tcp # HOSTS2 Name Server # Earl Killian xfer 82/udp # XFER Utility xfer 82/tcp # XFER Utility # Thomas M. Smith mit-ml-dev 83/udp # MIT ML Device mit-ml-dev 83/tcp # MIT ML Device # David Reed <--none---> ctf 84/udp # Common Trace Facility ctf 84/tcp # Common Trace Facility # Hugh Thomas mit-ml-dev 85/udp # MIT ML Device mit-ml-dev 85/tcp # MIT ML Device # David Reed <--none---> mfcobol 86/udp # Micro Focus Cobol mfcobol 86/tcp # Micro Focus Cobol # Simon Edwards <--none---> odd-2% python Python 2.7.1 (r271:86832, Jun 16 2011, 16:59:05) [GCC 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2335.15.00)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> #sender ... s=socket.socket(socket.AF_INET,socket.SOCK_DGRAM) Traceback (most recent call last): File "", line 2, in NameError: name 'socket' is not defined >>> s.bind((“”,40000)) File "", line 1 s.bind((“”,40000)) ^ SyntaxError: invalid syntax >>> s.setsockopt(socket.SOL_SOCKET, socket.SO_BROADCAST, 1) Traceback (most recent call last): File "", line 1, in NameError: name 's' is not defined >>> s=socket.socket(socket.AF_INET,socket.SOCK_DGRAM) Traceback (most recent call last): File "", line 1, in NameError: name 'socket' is not defined >>> s.bind(("",40000)) Traceback (most recent call last): File "", line 1, in NameError: name 's' is not defined >>> s.setsockopt(socket.SOL_SOCKET, socket.SO_BROADCAST, 1) Traceback (most recent call last): File "", line 1, in NameError: name 's' is not defined >>> import socket >>> s=socket.socket(socket.AF_INET,socket.SOCK_DGRAM) >>> s.bind(("",40000)) >>> s.setsockopt(socket.SOL_SOCKET, socket.SO_BROADCAST, 1) >>> s.sendto("Hello there",("",40000)) 11 >>> socket.gethostbyname(socket.hostname()) Traceback (most recent call last): File "", line 1, in AttributeError: 'module' object has no attribute 'hostname' >>> socket.gethostbyname(socket.gethostname()) '192.168.1.101' >>> s=socket.socket(socket.AF_INET,socket.SOCK_DGRAM) >>> s.bind(("192.168.1.101",40000)) >>> s.setsockopt(socket.SOL_SOCKET, socket.SO_BROADCAST, 1) >>> s.sendto("a"*256,("",40000)) 256 >>> s.sendto("a"*256,("",40000)) 256 >>> s.sendto("a"*256,("",40000)) 256 >>> s.sendto("a"*256,("",40000)) 256 >>> from threading import * >>> def f(): ... File "", line 2 ^ IndentationError: expected an indented block >>> import time >>> def f(): ... for i in range(50): ... time.sleep(5) ... print i ... >>> t=Thread(f) Traceback (most recent call last): File "", line 1, in File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 428, in __init__ assert group is None, "group argument must be None for now" AssertionError: group argument must be None for now >>> t=Thread(target=f) >>> t.start() >>> >>> 0 >>> 1 >>> t2=Threa2 d(target=f) >>> 3 t2.start()4 >>> 5 0 6 1 7 2 8 3 9 4 10 5 11 6 12 7 13 8 14 9 15 10 16 11 ^C^C^Z zsh: suspended python odd-2% kill %1 odd-2% [1] + terminated python odd-2% odd-2% ls 000AcPiano.mid 4.mid CannonDance.mid pmid.py 1.mid 5.mid a.mid server.py 2.mid 6.mid client.py synth.py 3.mid 7.mid example_seq.txt x.py odd-2% vi server.py odd-2% vi client.py odd-2% vi server.py odd-2% python server.py Command> Server started, with address 192.168.1.101 Connection 0 from ('192.168.1.102', 53371) Connection 1 from ('192.168.1.106', 50989) Connection 2 from ('192.168.1.105', 56928) Connection 3 from ('192.168.1.107', 64633) test Command> Connection 4 from ('192.168.1.112', 1885) Connection 5 from ('192.168.1.103', 61414) Connection 6 from ('192.168.1.114', 53539) Connection 7 from ('192.168.1.111', 49556) play Command> Connection 8 from ('192.168.1.108', 51892) Connection 9 from ('192.168.1.102', 53377) stop Command> play Command> stop Command> Connection 10 from ('192.168.1.104', 57491) quit Waiting for listener to exit ^Z zsh: suspended python server.py odd-2% kill %1 odd-2% [1] + terminated python server.py odd-2%