Description of problem: According to ipcalc manpage it should work with IPv6 or IPv4. However, only IPv4 works. $ ipcalc -nmp 192.168.1.1/24 NETMASK=255.255.255.0 PREFIX=24 NETWORK=192.168.1.0 $ ipcalc -6 -p fd91:6d87:7341:db6a:0:52:190c:be01/64 ipcalc: unable to show setting for IPv6 Expected results: It should work with IPv6, or should be documented not to.
Hmm it looks that -6 only work in combintaion with -c and -h . I will probably just document that other option does not work, but patches are highly appreciated.
I need a tool that outputs something like http://jodies.de/ipcalc for IPv6 as well. I've put my "patch" to github: https://github.com/nmav/ipcalc
I've made it backwards compatible, and print detailed information by default as well. Consider using that version for initscripts. $ ./ipcalc -i fd0b:a336:4e7d::/48 Full Address: fd0b:a336:4e7d:0000:0000:0000:0000:0000 Address: fd0b:a336:4e7d:: Full Network: fd0b:a336:4e7d:0000:0000:0000:0000:0000 Network: fd0b:a336:4e7d::/48 Address space: Unique Local Unicast Netmask: ffff:ffff:ffff:: = 48 HostMin: fd0b:a336:4e7d:: HostMax: fd0b:a336:4e7d:ffff:ffff:ffff:ffff:ffff Hosts/Net: 2^(80) $ ./ipcalc -bmnp --minaddr --maxaddr --addrspace fd0b:a336:4e7d::/48 NETMASK=ffff:ffff:ffff:: PREFIX=48 NETWORK=fd0b:a336:4e7d:: MINADDR=fd0b:a336:4e7d:: MAXADDR=fd0b:a336:4e7d:ffff:ffff:ffff:ffff:ffff ADDRSPACE="Unique Local Unicast" $ ./ipcalc -c fd0b:a336:4e7d::/48 $ ./ipcalc -4 -c fd0b:a336:4e7d::/48 ipcalc: bad prefix: 48
Thanks! Looks good. I will try to review it and merge those patches in upstream. Not sure if I will make it this week, unfortunately I am a little bit busy with rhel, but I have add it to my todo, so I will not forget.
(In reply to Lukáš Nykrýn from comment #4) > Thanks! Looks good. I will try to review it and merge those patches in > upstream. > Not sure if I will make it this week, unfortunately I am a little bit busy > with rhel, but I have add it to my todo, so I will not forget. Wouldn't it make sense to make the github version the upstream one, and simply include it in initscripts? It could allow easier merging of fixes and updated. I could give you access to github repo if you want.
I am trying to slowly destroy the initscripts package, so maybe would you be interested in the possibility of creating a new fedora package with your ipcalc? Then I could drop it from initscripts completely and be one more step closer to its elimination.
(In reply to Lukáš Nykrýn from comment #6) > I am trying to slowly destroy the initscripts package, so maybe would you be > interested in the possibility of creating a new fedora package with your > ipcalc? If I do it, would you review the new package?
> If I do it, would you review the new package? Yep.
https://bugzilla.redhat.com/show_bug.cgi?id=1222423
Fix scheduled for f23.