473,401 Members | 2,146 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,401 software developers and data experts.

python and LAN

Hello, All!

I wish to write a programs for LAN, but I don't know where to begin.

For example I have to get a hostlist of my network:
....
192.168.1.35 acca
192.168.3.38 alligator
192.168.1.1 alpha
192.168.2.31 andp-duha
192.168.5.76 angel
192.168.2.49 anny
192.168.3.26 antracit
192.168.3.35 array
192.168.5.39 arsen
192.168.4.64 asperansa
192.168.2.44 assasin
192.168.5.17 asterix
192.168.4.53 baggins
192.168.2.38 bars
192.168.4.24 basilio
192.168.4.28 batchhq
192.168.5.46 bazuka
192.168.2.27 benladen
192.168.2.48 bigmag
192.168.4.39 bilya
....

How can I do it with python?

With best regards, Egor Bolonev. E-mail: eb******@rin.ru
Jul 18 '05 #1
2 1534
Am Sat, 03 Jan 2004 20:16:09 +1000 schrieb Egor Bolonev:
Hello, All!

I wish to write a programs for LAN, but I don't know where to begin.

For example I have to get a hostlist of my network:
...
192.168.1.35 acca
192.168.3.38 alligator


What operating system do you use?

Some systems answer ping to the
broadcast address, but not all

ping 255.255.255.255

If you network is not switched, you
can listen to the wire by setting
the ethernet card to promiscuous mode.
Google for tcpdump.

But this has nothing to do with python.

thomas

Jul 18 '05 #2
Hello, Thomas!
You wrote on Mon, 05 Jan 2004 16:09:42 +0100:

TG> What operating system do you use?

winXP, LAN consists of ~300 pc's, 5 segment, Iam not admin

TG> Some systems answer ping to the
TG> broadcast address, but not all

Is there any modules for LAN in python? How to get list of pc's now working?
....
f=open('\\\\DELTA\\upload\\sobaka.swf','rb')
s=f.read()
print s CWSнЊ import glob
glob.glob('\\\\delta\\upload\\*')

['\\\\delta\\upload\\RAdmin', '\\\\delta\\upload\\Norton AntiVirus 2002',
'\\\\delta\\upload\\htm', '\\\\delta\\upload\\K&M',
'\\\\delta\\upload\\AVP', '\\\\delta\\upload\\From DemoN',
'\\\\delta\\upload\\From Merkava_Mk4 \xec\xf3\xeb\xfc\xf2\xfb',
'\\\\delta\\upload\\Max Payne 2 Bonus', '\\\\delta\\upload\\Demoscene',
'\\\\delta\\upload\\3DAnalyze',
....

With best regards, Egor Bolonev. E-mail: eb******@rin.ru

Jul 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.