AIX: Configuring a network interface

AIX: Configuring a network interface

# Tested on AIX 6.1

# Given following interface (no matter if it is already configured or not):

ifconfig en3
   en3: flags=1e080822,480<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST,GROUPRT,64BIT,CHECKSUM_OFFLOAD(ACTIVE),CHAIN>

# or

ifconfig en3
   en3: flags=1e084863,480<UP,BROADCAST,NOTRAILERS,RUNNING,SIMPLEX,MULTICAST,GROUPRT,64BIT,CHECKSUM_OFFLOAD(ACTIVE),CHAIN>
           inet 192.165.32.181 netmask 0xfffffffc broadcast 192.165.33.255
           tcp_sendspace 262144 tcp_recvspace 262144 rfc1323 1


# I'd like to set its address IP to 192.168.32.181, netmask 255.255.255.252, for instance


# Either I use 'smitty' interface:

smitty mktcpip

   1.- Select network interface to modify

       ┌──────────────────────────────────────────────────────────────────────────┐
       │                       Available Network Interfaces                       │
       │                                                                          │
       │ Move cursor to desired item and press Enter.                             │
       │                                                                          │
       │   en0      Standard Ethernet Network Interface                           │
       │   en1      Standard Ethernet Network Interface                           │
       │   en2      Standard Ethernet Network Interface                           │
   ==> │   en3      Standard Ethernet Network Interface                           │
       │   et0      IEEE 802.3 Ethernet Network Interface                         │
       │   et1      IEEE 802.3 Ethernet Network Interface                         │
       │   et2      IEEE 802.3 Ethernet Network Interface                         │
       │   et3      IEEE 802.3 Ethernet Network Interface                         │
       │                                                                          │
       │ F1=Help                 F2=Refresh              F3=Cancel                │
       │ F8=Image                F10=Exit                Enter=Do                 │
       │ /=Find                  n=Find Next                                      │
       └──────────────────────────────────────────────────────────────────────────┘


   2.- Note that default values for DNS server, domain and gateway, if globally set, are already
       set in following screen. They are set or not, we may change them, as well as the
       rest of parameters:

   Type or select values in entry fields.
   Press Enter AFTER making all desired changes.

                                                        [Entry Fields]
   * HOSTNAME                                           [myhostname]
   * Internet ADDRESS (dotted decimal)                  [192.168.32.181]         <----
     Network MASK (dotted decimal)                      [255.255.255.252]        <----
   * Network INTERFACE                                   en3
     NAMESERVER
              Internet ADDRESS (dotted decimal)         [10.11.16.382]           <---- opt.
              DOMAIN Name                               [mydomain.mycompany.es]  <---- opt.
     Default Gateway
          Address (dotted decimal or symbolic name)     [10.148.656.267]         <---- opt.
          Cost                                          [0]
          Do Active Dead Gateway Detection?              no
     Your CABLE Type                                     N/A
     START TCP/IP daemons Now                            no


   3.- Press enter to confirm changes

   Command: OK            stdout: yes           stderr: no

   Before command completion, additional instructions may appear below.

   en3
   x64lmwbikr5
   inet0 changed
   en3 changed
   inet0 changed




# or I run following command:

mktcpip -h x64lmwbikr5 -a 192.165.32.181 -m 255.255.255.252 -i en3

# Optionally, I could have used '-n', '-d' or '-g' to modify DNS server, domain or gateway if needed:

mktcpip -h myhostname -a 192.168.32.181 -m 255.255.255.252 -i en3 -n 10.11.16.382 -d mydomain.mycompany.es -g 10.148.656.267


# Check:

ifconfig en3
en3: flags=1e084863,480<UP,BROADCAST,NOTRAILERS,RUNNING,SIMPLEX,MULTICAST,GROUPRT,64BIT,CHECKSUM_OFFLOAD(ACTIVE),CHAIN>
        inet 192.165.32.181 netmask 0xfffffffc broadcast 192.165.32.183
         tcp_sendspace 262144 tcp_recvspace 262144 rfc1323 1
0 (0)
Article Rating (No Votes)
Rate this article
Attachments
There are no attachments for this article.
Comments
There are no comments for this article. Be the first to post a comment.
Full Name
Email Address
Security Code Security Code
Related Articles RSS Feed
Trick to Purge/Clean Swap Usage on AIX
Viewed 8172 times since Thu, Nov 29, 2018
To do a quick check on the number of path present (does not mean all are Enabled] using for loop
Viewed 3948 times since Fri, Jun 8, 2018
Changing Ethernet Media Speed for AIX
Viewed 3472 times since Tue, Apr 16, 2019
AIX, Storage, System Admin Allocating shared storage to VIOS clients
Viewed 2401 times since Fri, Apr 19, 2019
Problems with NFS on an AIX Reboot? Then Go Single
Viewed 7439 times since Wed, May 30, 2018
IBM V7000f Performance Test with Vdbench Tool on IBM AIX
Viewed 16191 times since Thu, Jan 23, 2020
AIX Errpt - Diag - Alog
Viewed 3771 times since Wed, Mar 20, 2019
Using Kerberos security with Server for NFS
Viewed 9725 times since Wed, Jun 27, 2018
AIX, Red Hat, Security, System Admin↑ System-wide separated shell history files for each user and session
Viewed 2326 times since Fri, Apr 19, 2019
Ethernet tunning for VIOS and AIX for 10 Gib/sec environtement.
Viewed 10613 times since Thu, Feb 21, 2019