- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- ifconfig error ( subnet error )
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-22-2001 09:10 PM
тАО11-22-2001 09:10 PM
I tried to configure IP with netmask 255.255.255.224 but failed
# ifconfig lan0:1 202.93.38.4 netmask 255.255.255.224
ifconfig: ioctl (SIOCSIFNETMASK): bad value
but when I used 255.255.255.0 ,..it worked.
I already tried to edit the file /etc/rc.config.d/netconf and restart the machine and still failed.
Any idea would be apriciated
Regards
Daniel
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-22-2001 09:52 PM
тАО11-22-2001 09:52 PM
Re: ifconfig error ( subnet error )
this has been discussed on the forum before. Do a search on network and zero or ifconfig and bad value. You'll find other threads regarding this.
I do beleive in the other threads there will be mentioned a work around for this also.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-22-2001 10:02 PM
тАО11-22-2001 10:02 PM
SolutionThe last octet of your netmask is 224 (11100000) while the last octet of your IP address is 4 (00000100). At the bits where the netmask is 1, the bits in your IP are 0's. These are thus reserved bits which resulted in the error you got.
To allow setting of 224 as the last octet of your netmask, you will have to use ndd to set ip_check_subnet_addr to 0.
# ndd -set /dev/ip ip_check_subnet_addr 0
Hope this helps. Regards.
Steven Sim Kok Leong
Brainbench MVP for Unix Admin
http://www.brainbench.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-22-2001 11:41 PM
тАО11-22-2001 11:41 PM
Re: ifconfig error ( subnet error )
If you use a mask of 255.255.255.224 then your network is subnetted to the following...
202.93.38.0-202.93.38.31 first subnet
202.93.38.32-202.93.38.63
202.93.38.64-202.93.38.95
.......
202.93.38.224-202.93.38.255 last subnet
According to subnet RFC (RFC 917 and others) The first subnet and the last subnet cannot be used. The usable IP starts with
202.93.38.33 with 202.93.38.32 as network address and 202.93.38.63 as the broadcast address. I think this will solve your problem...
Manoj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-23-2001 02:32 AM
тАО11-23-2001 02:32 AM
Re: ifconfig error ( subnet error )
try to make changes as follow for network tunable parameters read in by the networking startup script.
/etc/rc.config.d/nddconf
TRANSPORT_NAME[0]=ip
NDD_NAME[0]=ip_check_subnet_addr
NDD_VALUE[0]=0
activate it with "ndd -c"
I hope it works
Regards
Lutz
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-25-2003 09:56 AM
тАО04-25-2003 09:56 AM
Re: ifconfig error ( subnet error )
error lan0 ifconfig: ioctl (SIOCSIFNETMASK): Bad value
This could indicate that the netmask that was used for this address was not valid for the RFC1122 (3.2.1.3).
The RFC states what the network part and the host part of an IP-address should look like.
The ip_check_subnet_addr option could be used to disable this check for the validity of the address.
To explain what the RFC states look at this host-IP and the network mask:
10.1.0.32 netmask 255.255.255.0
This indicates that the network part should be 10.1.0.X and the host part should be X.X.X.32
The problem now is that if we follow RFC1122 (3.2.1.3) this above mention IP results in network part of 10.1.X.X and a host part of X.X.0.32
If the ip_check_subnet_addr value is set the above example would result in an error.
Unsetting the value with ndd, would not check for the RFC and this would give no error.
You could do so by executing:
ndd -set /dev/ip ip_check_subnet_addr 0
OS ver --Min --Max --Default
11.0 0 1 1
11i 0 1 0
Why should this be used?
-----------------------
The RFC1122 (3.2.1.3) decreases the number of usable IP-addresses, so unsetting this value frees some more IPs.
Usable commands:
---------------
Check the current value:
ndd -get /dev/ip ip_check_subnet_addr
Disable the subnet address check:
ndd -set /dev/ip ip_check_subnet_addr 0
Enable the subnet address check:
ndd -set /dev/ip ip_check_subnet_addr 1