199 Lotus blogs updated hourly. Who will post next? Home | Blogs | Search | About 
 
Latest 7 Posts
IBM API Connect - Adding IBM DataPower Gateway into the mix - SOMA import failed
Thu, Aug 17th 2017 18
What's the opposite of "cat" ? Another in the "I did not know that" series
Wed, Aug 16th 2017 104
Getting my head around REST APIs
Tue, Aug 15th 2017 100
IBM DataPower Gateway - SSH now working
Tue, Aug 15th 2017 33
IBM DataPower Gateway on Docker - So far, now (mostly) so good
Tue, Aug 15th 2017 28
IBM DataPower Gateway on Docker - Remember the memory
Tue, Aug 15th 2017 36
And more IBM DataPower Gateway - SSH this time around
Tue, Aug 15th 2017 18
Top 10
What's the opposite of "cat" ? Another in the "I did not know that" series
Wed, Aug 16th 2017 104
Getting my head around REST APIs
Tue, Aug 15th 2017 100
IBM API Connect - still learning how to say "Doh!"
Mon, Aug 14th 2017 57
Transport Layer Security (TLS) 1.2 and SoapUI
Fri, Jun 12th 2015 43
Securing the Database - IBM DB2 10.5 and Transport Layer Security 1.2
Wed, Jun 3rd 2015 40
Executing external Python/Jython scripts from within WebSphere Application Server's wsadmin tool
Thu, Feb 27th 2014 37
IBM DataPower Gateway on Docker - Remember the memory
Tue, Aug 15th 2017 36
IBM DataPower Gateway - SSH now working
Tue, Aug 15th 2017 33
Hmmm, macOS Sierra and XQuartz and X11
Thu, Oct 27th 2016 32
WAS - How to clear the WebSphere class caches
Mon, Feb 10th 2014 31


Red Hat Enterprise Linux 7 - Driving Network Manager via Command-Line
Twitter Google+ Facebook LinkedIn Addthis Email Gmail Flipboard Reddit Tumblr WhatsApp StumbleUpon Yammer Evernote Delicious
   

This is definitely a WIP, and results from my experiences with Red Hat Enterprise Linux 7.3, which does networking subtly differently to older versions of RHEL.

Having restored a VM from an OVA export ( using VMware Fusion on macOS ), I realised that I no longer had any network connectivity, even though the VM configuration hadn't changed.

I saw this from the VM console, whilst logged in as a root.

Firstly I checked the IP stack with ifconfig : -

ifconfig -a

ens33: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether 00:50:56:38:a3:ca  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0  KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0


lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1  (Local Loopback)
        RX packets 4  bytes 340 (340.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 4  bytes 340 (340.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0


So I've got an Ethernet interface - ens33 - which has no IP address.

Using Network Manager CLI, I checked the connection: -

nmcli connection

NAME         UUID                                  TYPE            DEVICE 
eno16777736  13756690-ac77-b776-4fc1-f5535cee6f16  802-3-ethernet  

which showed that the internal connection ( eno16777736 ) wasn't mapped to the ens33 interface.

This is easily resolved: -

nmcli connection modify eno16777736 connection.interface-name ens33

where I join the connection to the interface.

Now ifconfig shows a pukka IP address: -

ens33: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.153.130  netmask 255.255.255.0  broadcast 192.168.153.255
        inet6 fe80::20c:29ff:fefe:a16a  prefixlen 64  scopeid 0x20<link>
        ether 00:0c:29:fe:a1:6a  txqueuelen 1000  (Ethernet)
        RX packets 127  bytes 15722 (15.3 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 84  bytes 11401 (11.1 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1  (Local Loopback)
        RX packets 4  bytes 340 (340.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 4  bytes 340 (340.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0


The actual IP configuration is, as before, handled via a script: -

/etc/sysconfig/network-scripts/ifcfg-eno16777736

TYPE="Ethernet"
BOOTPROTO="dhcp"
DEFROUTE="yes"
IPV4_FAILURE_FATAL="no"
IPV6INIT="yes"
IPV6_AUTOCONF="yes"
IPV6_DEFROUTE="yes"
IPV6_FAILURE_FATAL="no"
NAME="eno16777736"
UUID="28ca0f72-3f90-41d1-a2f7-5ec6ea5fffbc"
DEVICE=ens33
ONBOOT="yes"
PEERDNS=yes
PEERROUTES=yes
IPV6_PEERDNS=yes
IPV6_PEERROUTES=yes


which shows that the connection is using DHCP.

If I wanted to allocate a static IP address, I'd change the file as follows: -

TYPE="Ethernet"
BOOTPROTO="static"
IPADDR=192.168.153.133
NETMASK=255.255.255.0
GATEWAY=192.168.153.2

DEFROUTE="yes"
IPV4_FAILURE_FATAL="no"
IPV6INIT="yes"
IPV6_AUTOCONF="yes"
IPV6_DEFROUTE="yes"
IPV6_FAILURE_FATAL="no"
NAME="eno16777736"
UUID="28ca0f72-3f90-41d1-a2f7-5ec6ea5fffbc"
DEVICE=ens33
ONBOOT="yes"
PEERDNS=yes
PEERROUTES=yes
IPV6_PEERDNS=yes
IPV6_PEERROUTES=yes


and restart the network service: -

service network restart

Restarting network (via systemctl):                        [  OK  ]

we now have this: -

ifconfig ens33

ens33: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.153.133  netmask 255.255.255.0  broadcast 192.168.153.255
        inet6 fe80::20c:29ff:fefe:a16a  prefixlen 64  scopeid 0x20<link>
        ether 00:0c:29:fe:a1:6a  txqueuelen 1000  (Ethernet)
        RX packets 961  bytes 88811 (86.7 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 539  bytes 75366 (73.5 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

So, to conclude, we have an interface - ens33 - and a Network Manager connection - eno16777736 - and NMCLI can show the join: -

nmcli connection

NAME         UUID                                  TYPE            DEVICE 
eno16777736  28ca0f72-3f90-41d1-a2f7-5ec6ea5fffbc  802-3-ethernet  ens33  

Thanks to this: -


and this: -


for inspiration.

For the record, at some point, I also had to do this: -

Map physical connection to interface

nmcli connection add type ethernet con-name ens33 ifname eth0

but I can't recall precisely how/why I got there, so we'll bank that for now :-)


---------------------
http://portal2portal.blogspot.com/2017/02/red-hat-enterprise-linux-7-driving.html
Feb 08, 2017
4 hits



Recent Blog Posts
18
IBM API Connect - Adding IBM DataPower Gateway into the mix - SOMA import failed
Thu, Aug 17th 2017 1:39p   Dave Hay
I've been tinkering with an IBM API Connect 5.0.7.2 implementation on my Mac, running all three VMs; the API Manager, the Developer Portal AND the DataPower Gateway on the same box.However, I saw this: -when attempting to integrate APIC and IDG.I dumped out the APIC CMC logs: -debug postmortem export sftp 10.10.2.3 user fred file /tmp/foobar.tar.gzand, on the Mac, exploded the resulting tarball, giving me this: -log/cmc.out:2017-08-17 13:19:30.076 SEVERE [T-83] [com.ibm.datapower.gwapi.impl.Gat
104
What's the opposite of "cat" ? Another in the "I did not know that" series
Wed, Aug 16th 2017 9:33a   Dave Hay
Thanks to a friend, Paul Smith, for sharing this.He had a requirement - to take a list of items ( a text file ) and invert the list.Initially I thought he meant that he wanted to sort the list, which seemed simple.Here's a list: -cat list.txt CatRabbitDogGerbilHamsterHorseRhinoHippoAlosaurso here's the sorted list: -sort list.txt AlosaurCatDogGerbilHamsterHippoHorseRabbitRhinoand here's the reverse sort: -sort -r list.txt RhinoRabbitHorseHippoHamsterGerbilDogCatAlosaurbut NO, I didn't unders
100
Getting my head around REST APIs
Tue, Aug 15th 2017 4:50p   Dave Hay
Almost every product with which I've worked recently, including: -IBM Business Process ManagerIBM Operational Decision Manager (Rules)IBM API ConnectIBM WebSphere Liberty Profile (Collectives)IBM DataPower Gatewayleverages Representational State Transfer (REST) APIs, so I've got no excuse but to L-E-A-R-N.Whilst working through the DataPower tutorial here: -IBM DataPower Gateways - Getting Started - Your first configurationI needed to get a handle on how to drive REST, both in the context of t
33
IBM DataPower Gateway - SSH now working
Tue, Aug 15th 2017 2:53p   Dave Hay
Today has been a day for DataPower: -IBM DataPower Gateway on Docker - Remember the memoryAnd more IBM DataPower Gateway - SSH this time aroundIBM DataPower Gateway on Docker - So far, now (mostly) so goodSo I'm not yet sure why this works, but I was struggling to get SSH to work against an IBM DataPower Gateway Docker image/container.Whilst the configuration looked OK: -https://localhost:9090/configure/SSHServicethe service would refuse to become active, instead frustratingly staying as disabl
28
IBM DataPower Gateway on Docker - So far, now (mostly) so good
Tue, Aug 15th 2017 12:59p   Dave Hay
So this is how I pulled the image: -docker pull ibmcom/datapowerresulting in this: -docker imagesREPOSITORY TAG IMAGE ID CREATED SIZEibmcom/datapower latest 5d04824ab687 2 weeks ago 758MBand this is how I started the container for the first time: -docker run -it -v $PWD/config:/drouter/config -v $PWD/local:/drouter/local -e DATAPOWER_ACCEPT_LICENSE=true -e DATAPOWER_INTERACTIVE=true -p 9090:9090 -p 9
36
IBM DataPower Gateway on Docker - Remember the memory
Tue, Aug 15th 2017 11:56a   Dave Hay
I've been seeing a few interesting exceptions with an IBM DataPower Gateway Docker image, including: -20170815T101929.233Z [0x81000029][system][error] : tid(8175): Execution of webgui:///clixform.xsl stopped: file:///drouter/webgui/clixform.xsl:3530: Stack overflow20170815T101929.233Z [0x8100000f][system][critic] : tid(8175): Failed to save configuration to 'config:///auto-startup.cfg'20170815T101929.234Z [0x8100003c][mgmt][critic] domain(default): tid(8175): Domain configuration not saved.20
18
And more IBM DataPower Gateway - SSH this time around
Tue, Aug 15th 2017 11:15a   Dave Hay
Following this tutorial: -Getting Started - Command Line InterfaceI did this: -configure terminal:ssh 0.0.0.0 22write memorybut saw this: -20170815T105924.939Z [0x81000243][cli][error] : required property host is missing20170815T105924.939Z [][cli][error] : (startup-config:601): exitin the startup logs, and this: -20170815T110105.223Z [0x00b30004][mgmt][error] ssh(SSH Service): tid(111): Invalid local address20170815T110105.224Z [0x8100003f][mgmt][notice] domain(default): tid(111): Domain config
57
IBM API Connect - still learning how to say "Doh!"
Mon, Aug 14th 2017 4:23p   Dave Hay
I saw this: -when testing my API, using the local API Connect Toolkit ( apic edit ), even though the same API worked happily on IBM Bluemix.The suggested URL: -https://localhost:4001/DecisionService/rest/HelloWorldProject/1.0/HelloWorlddidn't work, and there was nothing listening on port 4001 on my Mac.Then I noticed this: -I clicked on the Play icon, which gave me this: -further validated thusly: -netstat -an | grep LISTENtcp46 0 0 *.4001 *.* LISTE
10
IBM BPM - Why won't my Coach Views show up in my Coach ?
Thu, Aug 3rd 2017 1:35p   Dave Hay
As stated previously: -IBM BPM - Consuming RESTful Services using Swagger and YAML - Learning lessonsIBM BPM and IBM ODM Rules - I continue to learn ...I'm tinkering with IBM BPM, learning more about the new Responsive Coach Framework in IBM BPM 8.5.7, and the Client-SIde Human Service capabilities.Having created an External Service and a Service Flow, I then want to create a UI to allow the user to enter their name, and get back a response.So I've created a Coach View, and marked it as a Temp
12
IBM BPM and IBM ODM Rules - I continue to learn ...
Thu, Aug 3rd 2017 11:26a   Dave Hay
Following my earlier post: -IBM BPM - Consuming RESTful Services using Swagger and YAML - Learning lessonsI'm continuing to tinker with IBM BPM, specifically using the web-based Process Designer, to integrate with a very simple Decision Service, called, of course, Hello World.For the record, I'm using IBM BPM on Cloud ( a SaaS offering ) against ODM Rules on Bluemix ( a PaaS offering ).Having created an External Service, using the YAML that I exported from the Decision Server ( as per the prev




Created and Maintained by Yancy Lent - About - Planet Lotus Blog - Advertising - Mobile Edition