469,648 Members | 1,585 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,648 developers. It's quick & easy.

Matching IP Address to subnets.

Hi ya all.

I am creating a small solution to keep statistics about IP Address
accessing a certain system at my workplace. The idea is to be able to
group the IP address to a certain subnet so we can see which class of
users is accessing the system the most.

During development of the collection process I've been using Postgres,
Postgres has this a special datatype called CIDR. I can insert an IP
Address into a table using this field and then with a simple where
clause I can match the IP address against up with my reference table
(containing a list of roughly 40 subnets) to group the connections.

this would be very easy if I only had to group by C-Class net's but
...... life isn't so easy ;)

I can only hope that someone has already done this or can give me ideas
on how to solve this using DB2. Currently my best idea is to use
Postgres for the collection process and subnet maching and then export
the data into DB2. I don't like that idea as it gives more complicity
to the system and I have to run and manage two database systems.

I haven't given finalized the table design because of this. So I am
open to any ideas even if I have to redesign the table design.

Hope to see some juicy ideas!

thanks and best regards,
Arni Snorri Eggertsson
arnie - at - gormur.com

Nov 12 '05 #1
0 1083

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

17 posts views Thread by Andrew McLean | last post: by
3 posts views Thread by danpres2k | last post: by
7 posts views Thread by Bill Cohagan | last post: by
1 post views Thread by Jerry Negrelli | last post: by
reply views Thread by Shri | last post: by
5 posts views Thread by wright.brandt | last post: by
1 post views Thread by centexas66 | last post: by
8 posts views Thread by axlq | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.