AIX

AIX

Connect with fellow AIX users and experts to gain knowledge, share insights, and solve problems.


#Power
 View Only
Expand all | Collapse all

Can not remove static route from AIX 5.3

  • 1.  Can not remove static route from AIX 5.3

    Posted Tue September 15, 2009 05:56 AM

    Originally posted by: SystemAdmin


    Dear all,

    I Try to remove a static route with smitty, but recieve this error:

    Method error (/usr/lib/methods/chginet):
    0514-009 Cannot delete an object from the device
    configuration database.
    0821-216 chginet: Cannot delete route (net,192.168.30.101,192.168.30.1) from CuAt.

    My routing table looks like this (the route I want to remove is marked red):

    biete 11:40:48 root:/u01# netstat -rn
    Routing tables
    Destination Gateway Flags Refs Use If Exp Groups

    Route Tree for Protocol Family 2 (Internet):
    default 10.180.1.1 UG 102 35179371 en2 - -
    10.180.0.0 10.180.1.81 UHSb 0 0 en2 - - =>
    10.180/21 10.180.1.81 U 131 321332968 en2 - -
    10.180.1.81 127.0.0.1 UGHS 4 3786348 lo0 - -
    10.180.7.255 10.180.1.81 UHSb 0 5 en2 - -
    127/8 127.0.0.1 U 15 2409 lo0 - -
    192.168.20.10 192.168.30.1 UGHS 5 15967231 en3 - -
    192.168.30.0 192.168.30.121 UHSb 0 0 en3 - - =>
    192.168.30/24 192.168.30.121 U 2 272 en3 - -
    192.168.30.101/32 192.168.30.1 UGS 0 54 en3 - -
    192.168.30.121 127.0.0.1 UGHS 0 145 lo0 - -
    192.168.30.255 192.168.30.121 UHSb 0 5 en3 - -

    The command with smitty looks like this:

    Destination TYPE host
    (dotted decimal or symbolic name)

    I also tried Destination TYPE net, but error the same.

    I tried to delete route with command line, but got some errors:

    biete 11:46:02 root:/u01# route delete 192.168.30.101 gw 192.168.30.1
    0821-287 gw: bad value
    biete 11:46:20 root:/u01# route delete 192.168.30.101
    0821-279 writing to routing socket: The process does not exist.
    biete 11:46:24 root:/u01#

    Can anyone please help me with some tips how to delete unwanted route?
    #AIX-Forum


  • 2.  Re: Can not remove static route from AIX 5.3

    Posted Tue September 15, 2009 06:45 AM

    Originally posted by: SystemAdmin


    Cannot see the route in red.
    Confirm the route using:
    lsattr -El inet0 -a route
    ...

    Then, delete it using chdev

    $ chdev -l inet0 -a delroute .... ..
    #AIX-Forum


  • 3.  Re: Can not remove static route from AIX 5.3

    Posted Tue September 15, 2009 06:57 AM

    Originally posted by: SystemAdmin


    Route I want to delete is:

    netstat -rn
    192.168.30.101/32 192.168.30.1 UGS 0 54 en3 - -

    Output of:
    biete 13:55:40 root:/u01# lsattr -El inet0 -a route
    route net,-hopcount,0,,0,10.180.1.1 Route True
    route host,-hopcount,0,,,,,,-static,192.168.20.10,192.168.30.1 Route True
    biete 13:57:10 root:/u01#

    Could you please write full command of chdev? Note that I want only to delete static route above!
    #AIX-Forum


  • 4.  Re: Can not remove static route from AIX 5.3

    Posted Tue September 15, 2009 02:34 PM

    Originally posted by: ostost


    Issue a lsattr -El inet0 to display to static routes defined in the ODM. Then run a chdev -l inet0 -a delroute="<route>" where route is the string that was displayed in the lsattr command.

    For example to delete the default route defined in the example below:

    1. lsattr -El inet0
    authm 65536 Authentication Methods True
    bootup_option no Use BSD-style Network Configuration True
    gateway Gateway True
    hostname sotchax10 Host Name True
    rout6 IPv6 Route True
    route net,-hopcount,0,,,,,,-static,0,10.176.240.1 Route True

    Issue the following command:

    chdev -l inet0 -a delroute="net,-hopcount,0,,,,,,-static,0,10.176.240.1"
    #AIX-Forum


  • 5.  Re: Can not remove static route from AIX 5.3

    Posted Wed September 16, 2009 02:15 AM

    Originally posted by: SystemAdmin


    Hi!

    I have to remove route 192.168.30.101/32 192.168.30.1

    biete 09:12:29 root:/u01# netstat -rn
    Routing tables
    Destination Gateway Flags Refs Use If Exp Groups

    Route Tree for Protocol Family 2 (Internet):
    default 10.180.1.1 UG 61 35988829 en2 - -
    10.180.0.0 10.180.1.81 UHSb 0 0 en2 - - =>
    10.180/21 10.180.1.81 U 128 328179753 en2 - -
    10.180.1.81 127.0.0.1 UGHS 5 3836686 lo0 - -
    10.180.7.255 10.180.1.81 UHSb 0 5 en2 - -
    127/8 127.0.0.1 U 15 2476 lo0 - -
    192.168.20.10 192.168.30.1 UGHS 5 16290676 en3 - -
    192.168.30.0 192.168.30.121 UHSb 0 0 en3 - - =>
    192.168.30/24 192.168.30.121 U 2 272 en3 - -
    192.168.30.101/32 192.168.30.1 UGS 0 54 en3 - -
    192.168.30.121 127.0.0.1 UGHS 0 145 lo0 - -
    192.168.30.255 192.168.30.121 UHSb 0 5 en3 - -

    But lsattr -El inet0 | grep route shows only two routes, that I need and do not want to delete (one default one static to specific host)!

    biete 09:13:20 root:/u01# lsattr -El inet0 | grep route
    route host,-hopcount,0,,,,,,-static,192.168.20.10,192.168.30.1 Route True
    route net,-hopcount,0,,0,10.180.1.1 Route True

    How can I remove route 192.168.30.101/32 192.168.30.1 (please see netstat -rn output above)!?
    #AIX-Forum


  • 6.  Re: Can not remove static route from AIX 5.3

    Posted Wed September 16, 2009 02:40 AM

    Originally posted by: ostost


    Try route delete 192.168.30.101/32 192.168.30.1
    #AIX-Forum


  • 7.  Re: Can not remove static route from AIX 5.3

    Posted Wed September 16, 2009 02:54 AM

    Originally posted by: SystemAdmin


    I tried his already several times

    biete 09:14:29 root:/u01# route delete 192.168.30.101/32 192.168.30.1
    0821-279 writing to routing socket: The process does not exist.

    But the route remains as it is
    #AIX-Forum


  • 8.  Re: Can not remove static route from AIX 5.3

    Posted Wed September 16, 2009 07:21 AM

    Originally posted by: ostost


    Might be caused by the problem described in APAR IZ36917.

    http://www-01.ibm.com/support/docview.wss?uid=isg1IZ36917
    #AIX-Forum


  • 9.  Re: Can not remove static route from AIX 5.3

    Posted Wed September 16, 2009 11:00 AM

    Originally posted by: SystemAdmin


    Hi ostost!

    biete 16:50:58 root:/u01# oslevel -r
    5300-05

    As you can see I am using AIX 5.3 with maintenance level 05

    Does that mean that I should install 08 09 or 10 and apply an APAR?
    #AIX-Forum


  • 10.  Re: Can not remove static route from AIX 5.3

    Posted Thu September 17, 2009 01:00 AM

    Originally posted by: kappa


    although it is a host route,
    try to delete it with an explicit mask of 255.255.255.0.

    you must treat it like a net route.
    #AIX-Forum


  • 11.  Re: Can not remove static route from AIX 5.3

    Posted Thu September 17, 2009 07:17 AM

    Originally posted by: SystemAdmin


    Hi!

    I allready tryed to delete like host, but result the same :(
    #AIX-Forum


  • 12.  Re: Can not remove static route from AIX 5.3

    Posted Thu September 17, 2009 01:45 PM

    Originally posted by: kappa


    sorry , you have not posted the failing route command and newest netstat -rn,
    i cannot help!

    did you use the netmask?
    #AIX-Forum


  • 13.  Re: Can not remove static route from AIX 5.3

    Posted Fri September 18, 2009 02:19 AM

    Originally posted by: SystemAdmin


    Sorry for that kappa

    biete 09:10:42 root:/# netstat -rn
    Routing tables
    Destination Gateway Flags Refs Use If Exp Groups

    Route Tree for Protocol Family 2 (Internet):
    default 10.180.1.1 UG 44 38119655 en2 - -
    10.180.0.0 10.180.1.81 UHSb 0 0 en2 - - =>
    10.180/21 10.180.1.81 U 128 345154398 en2 - -
    10.180.1.81 127.0.0.1 UGHS 5 3949434 lo0 - -
    10.180.7.255 10.180.1.81 UHSb 0 5 en2 - -
    127/8 127.0.0.1 U 15 2548 lo0 - -
    192.168.20.10 192.168.30.1 UGHS 2 16989817 en3 - -
    192.168.30.0 192.168.30.121 UHSb 0 0 en3 - - =>
    192.168.30/24 192.168.30.121 U 2 272 en3 - -
    192.168.30.101/32 192.168.30.1 UGS 0 54 en3 - -
    192.168.30.121 127.0.0.1 UGHS 0 145 lo0 - -
    192.168.30.255 192.168.30.121 UHSb 0 5 en3 - -

    Route Tree for Protocol Family 24 (Internet v6):
    ::1

    I try to delete route with

    biete 09:10:47 root:/# route delete 192.168.30.101 netmask 255.255.255.0 gw 192.168.30.1
    0821-287 netmask: bad value

    But get error you see (might be syntax is incorrect)

    And with smitty

    Destination TYPE net +
    (dotted decimal or symbolic name)
    (dotted decimal or symbolic name)
    Network MASK (hexadecimal or dotted decimal) http://255.255.255.0

    I go an error:

    Method error (/usr/lib/methods/chginet):
    0514-009 Cannot delete an object from the device
    configuration database.
    0821-216 chginet: Cannot delete route (net,192.168.30.101,192.168.30.1) from CuAt.
    #AIX-Forum