ABOUT THE FOLLOWING COMMAND: you can use findreplace command just to find a pattern in files located in a directory. for example, here we are looking for the word 'Infiniband' in the current directory ./ or we could have followed -dir by . or ../etc or /tmp/etc all specifying the same target directory

bash:1 19:30:29 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern Infiniband FIND IN DIRECTORY ./ GOT: sysconfig/raid-check sysconfig/libvirtd sysconfig/xinetd sysconfig/autofs sysconfig/rsyslog sysconfig/opensm sysconfig/readonly-root sysconfig/sshd sysconfig/rdisc sysconfig/iptables-config~2 sysconfig/fcoe sysconfig/sysstat.ioconf sysconfig/rsyncd sysconfig/cgred sysconfig/radvd sysconfig/network-scripts/ifup-TeamPort sysconfig/network-scripts/ifcfg-br0 sysconfig/network-scripts/ifcfg-eno1~~ sysconfig/network-scripts/ifup-routes sysconfig/network-scripts/ifup-sit sysconfig/network-scripts/__ifcfg-enp2s0__ sysconfig/network-scripts/ifup-aliases sysconfig/network-scripts/ifup-wireless sysconfig/network-scripts/ifdown-ppp sysconfig/network-scripts/ifdown-ippp sysconfig/network-scripts/ifdown-ipv6 sysconfig/network-scripts/ifup-Team sysconfig/network-scripts/ifup-plip sysconfig/network-scripts/ifup-eth sysconfig/network-scripts/ifcfg-mic0 sysconfig/network-scripts/ifcfg-lo sysconfig/network-scripts/ifup-ib sysconfig/network-scripts/ifdown-tunnel sysconfig/network-scripts/ifup-bnep sysconfig/network-scripts/ifup-plusb sysconfig/network-scripts/network-functions-ipv6 sysconfig/network-scripts/ifdown-sit sysconfig/network-scripts/ifup-post sysconfig/network-scripts/ifcfg-eno1 sysconfig/network-scripts/ifcfg-ib0.8002 sysconfig/network-scripts/ifdown-eth sysconfig/network-scripts/ifup-ipv6 sysconfig/network-scripts/ifup-ippp sysconfig/network-scripts/ifdown-TeamPort sysconfig/network-scripts/__foo3 sysconfig/network-scripts/ifcfg-ib0 sysconfig/network-scripts/ifcfg-Wired_connection_1 sysconfig/network-scripts/ifdown-bnep sysconfig/network-scripts/ifdown-Team sysconfig/network-scripts/ifcfg-eno1~ sysconfig/network-scripts/ifdown-ib sysconfig/network-scripts/ifdown-routes sysconfig/network-scripts/ifcfg-enp5s0f1 sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE sysconfig/network-scripts/network-functions sysconfig/network-scripts/ifup-tunnel sysconfig/network-scripts/__1__ifcfg-ib0 sysconfig/network-scripts/__ifcfg-ql40g_ib0__ sysconfig/network-scripts/ifdown-post sysconfig/network-scripts/ifcfg-br0~~ sysconfig/network-scripts/init.ipv6-global sysconfig/network-scripts/ifup-ppp sysconfig/cbq/cbq-0000.example sysconfig/cbq/avpkt sysconfig/samba sysconfig/ntpd sysconfig/qemu-ga sysconfig/modules/mic.modules sysconfig/wpa_supplicant sysconfig/nfs sysconfig/irqbalance sysconfig/kdump sysconfig/network sysconfig/lm_sensors sysconfig/authconfig sysconfig/sysstat sysconfig/crond sysconfig/chronyd sysconfig/run-parts sysconfig/init sysconfig/atd sysconfig/smartmontools sysconfig/man-db sysconfig/cpupower sysconfig/kernel sysconfig/rpc-rquotad sysconfig/virtlockd sysconfig/firewalld sysconfig/ntpdate sysconfig/svnserve sysconfig/opensm.rpmsave sysconfig/saslauthd sysconfig/ebtables-config sysconfig/iptables-config sysconfig/netconsole sysconfig/virtlogd sysconfig/rpcbind sysconfig/ip6tables-config dbus-1/session.conf dbus-1/system.d/oddjob-mkhomedir.conf dbus-1/system.d/org.freedesktop.UPower.conf dbus-1/system.d/org.freedesktop.bolt.conf dbus-1/system.d/org.freedesktop.timedate1.conf dbus-1/system.d/org.kde.auth.conf dbus-1/system.d/org.kde.kcontrol.kcmremotewidgets.conf dbus-1/system.d/pulseaudio-system.conf dbus-1/system.d/org.freedesktop.UDisks2.conf dbus-1/system.d/wpa_supplicant.conf dbus-1/system.d/org.freedesktop.RealtimeKit1.conf dbus-1/system.d/org.freedesktop.systemd1.conf dbus-1/system.d/teamd.conf dbus-1/system.d/certmonger.conf dbus-1/system.d/org.selinux.conf dbus-1/system.d/org.freedesktop.locale1.conf dbus-1/system.d/org.fedoraproject.Setroubleshootd.conf dbus-1/system.d/org.gnome.GConf.Defaults.conf dbus-1/system.d/FirewallD.conf dbus-1/system.d/org.kde.kcontrol.kcmclock.conf dbus-1/system.d/org.freedesktop.GeoClue2.conf dbus-1/system.d/org.freedesktop.ModemManager1.conf dbus-1/system.d/org.kde.ksysguard.processlisthelper.conf dbus-1/system.d/org.freedesktop.login1.conf dbus-1/system.d/org.freedesktop.PolicyKit1.conf dbus-1/system.d/org.opensuse.CupsPkHelper.Mechanism.conf dbus-1/system.d/org.freedesktop.Flatpak.SystemHelper.conf dbus-1/system.d/org.freedesktop.NetworkManager.conf dbus-1/system.d/dnsmasq.conf dbus-1/system.d/org.freedesktop.import1.conf dbus-1/system.d/org.freedesktop.hostname1.conf dbus-1/system.d/org.freedesktop.ColorManager.conf dbus-1/system.d/com.redhat.PrinterDriversInstaller.conf dbus-1/system.d/org.freedesktop.machine1.conf dbus-1/system.d/oddjob.conf dbus-1/system.d/bluetooth.conf dbus-1/system.d/nm-ifcfg-rh.conf dbus-1/system.d/org.fedoraproject.SetroubleshootFixit.conf dbus-1/system.d/com.redhat.tuned.conf dbus-1/system.d/org.freedesktop.realmd.conf dbus-1/system.d/org.kde.kalarmrtcwake.conf dbus-1/system.d/org.freedesktop.Accounts.conf dbus-1/system.d/org.freedesktop.GeoClue2.Agent.conf dbus-1/system.d/gdm.conf dbus-1/system.d/nm-dispatcher.conf dbus-1/system.d/org.kde.powerdevil.backlighthelper.conf dbus-1/system.d/org.kde.fontinst.conf dbus-1/system.d/net.reactivated.Fprint.conf dbus-1/system.d/com.redhat.NewPrinterNotification.conf dbus-1/system.d/cups.conf dbus-1/system.d/dbus-abrt.conf dbus-1/system.conf dnsmasq.conf libvirt/libvirt.conf libvirt/libvirt-admin.conf libvirt/qemu.conf libvirt/libvirtd.conf libvirt/qemu-lockd.conf libvirt/virtlockd.conf libvirt/virtlogd.conf 1 2019-03-14_06:17:47 2024-06-20_18:15:02 2024-06-20_18:14:27 838 /tmp/etc/dbus-1/session.conf 2 2019-03-14_06:17:47 2024-06-20_18:15:02 2024-06-20_18:14:27 833 /tmp/etc/dbus-1/system.conf 3 2018-10-30_18:46:59 2024-06-20_18:15:02 2024-06-20_18:14:27 1084 /tmp/etc/dbus-1/system.d/FirewallD.conf 4 2017-09-12_10:43:58 2024-06-20_18:15:02 2024-06-20_18:14:27 1489 /tmp/etc/dbus-1/system.d/bluetooth.conf 5 2018-10-30_19:03:22 2024-06-20_18:15:02 2024-06-20_18:14:27 1069 /tmp/etc/dbus-1/system.d/certmonger.conf 6 2018-04-11_01:38:25 2024-06-20_18:15:02 2024-06-20_18:14:27 1007 /tmp/etc/dbus-1/system.d/com.redhat.NewPrinterNotification.conf 7 2018-04-11_01:38:25 2024-06-20_18:15:02 2024-06-20_18:14:27 1016 /tmp/etc/dbus-1/system.d/com.redhat.PrinterDriversInstaller.conf 8 2018-07-04_15:23:21 2024-06-20_18:15:02 2024-06-20_18:14:27 587 /tmp/etc/dbus-1/system.d/com.redhat.tuned.conf 9 2018-04-11_01:03:47 2024-06-20_18:15:02 2024-06-20_18:14:27 460 /tmp/etc/dbus-1/system.d/cups.conf 10 2018-11-13_11:00:10 2024-06-20_18:15:02 2024-06-20_18:14:27 1117 /tmp/etc/dbus-1/system.d/dbus-abrt.conf 11 2018-10-30_13:05:19 2024-06-20_18:15:02 2024-06-20_18:14:27 475 /tmp/etc/dbus-1/system.d/dnsmasq.conf 12 2019-03-14_06:18:16 2024-06-20_18:15:02 2024-06-20_18:14:27 3883 /tmp/etc/dbus-1/system.d/gdm.conf 13 2018-10-30_20:31:46 2024-06-20_18:15:02 2024-06-20_18:14:27 544 /tmp/etc/dbus-1/system.d/net.reactivated.Fprint.conf 14 2019-03-14_06:19:00 2024-06-20_18:15:02 2024-06-20_18:14:27 465 /tmp/etc/dbus-1/system.d/nm-dispatcher.conf 15 2019-03-14_06:19:00 2024-06-20_18:15:02 2024-06-20_18:14:27 387 /tmp/etc/dbus-1/system.d/nm-ifcfg-rh.conf 16 2013-07-30_17:22:23 2024-06-20_18:15:02 2024-06-20_18:14:27 1892 /tmp/etc/dbus-1/system.d/oddjob-mkhomedir.conf 17 2015-03-05_23:33:02 2024-06-20_18:15:02 2024-06-20_18:14:27 2480 /tmp/etc/dbus-1/system.d/oddjob.conf 18 2018-11-02_12:12:07 2024-06-20_18:15:02 2024-06-20_18:14:27 771 /tmp/etc/dbus-1/system.d/org.fedoraproject.SetroubleshootFixit.conf 19 2018-11-02_12:12:07 2024-06-20_18:15:02 2024-06-20_18:14:27 2079 /tmp/etc/dbus-1/system.d/org.fedoraproject.Setroubleshootd.conf 20 2018-10-30_16:48:39 2024-06-20_18:15:02 2024-06-20_18:14:27 917 /tmp/etc/dbus-1/system.d/org.freedesktop.Accounts.conf 21 2017-08-06_01:01:43 2024-06-20_18:15:02 2024-06-20_18:14:27 1569 /tmp/etc/dbus-1/system.d/org.freedesktop.ColorManager.conf 22 2019-02-19_12:39:08 2024-06-20_18:15:02 2024-06-20_18:14:27 971 /tmp/etc/dbus-1/system.d/org.freedesktop.Flatpak.SystemHelper.conf 23 2018-10-30_13:49:59 2024-06-20_18:15:02 2024-06-20_18:14:27 711 /tmp/etc/dbus-1/system.d/org.freedesktop.GeoClue2.Agent.conf 24 2018-10-30_13:49:59 2024-06-20_18:15:02 2024-06-20_18:14:27 1231 /tmp/etc/dbus-1/system.d/org.freedesktop.GeoClue2.conf 25 2018-04-10_22:39:22 2024-06-20_18:15:02 2024-06-20_18:14:27 422 /tmp/etc/dbus-1/system.d/org.freedesktop.ModemManager1.conf 26 2019-03-14_06:19:00 2024-06-20_18:15:02 2024-06-20_18:14:27 9421 /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf 27 2019-03-08_09:27:06 2024-06-20_18:15:02 2024-06-20_18:14:27 638 /tmp/etc/dbus-1/system.d/org.freedesktop.PolicyKit1.conf 28 2015-03-06_00:27:16 2024-06-20_18:15:02 2024-06-20_18:14:27 1075 /tmp/etc/dbus-1/system.d/org.freedesktop.RealtimeKit1.conf 29 2018-11-02_16:49:05 2024-06-20_18:15:02 2024-06-20_18:14:27 525 /tmp/etc/dbus-1/system.d/org.freedesktop.UDisks2.conf 30 2018-10-30_14:12:15 2024-06-20_18:15:02 2024-06-20_18:14:27 1555 /tmp/etc/dbus-1/system.d/org.freedesktop.UPower.conf 31 2018-05-28_08:10:53 2024-06-20_18:15:02 2024-06-20_18:14:27 899 /tmp/etc/dbus-1/system.d/org.freedesktop.bolt.conf 32 2019-07-31_04:15:18 2024-06-20_18:15:02 2024-06-20_18:14:27 947 /tmp/etc/dbus-1/system.d/org.freedesktop.hostname1.conf 33 2019-07-31_04:15:18 2024-06-20_18:15:02 2024-06-20_18:14:27 2527 /tmp/etc/dbus-1/system.d/org.freedesktop.import1.conf 34 2019-07-31_04:15:18 2024-06-20_18:15:02 2024-06-20_18:14:27 937 /tmp/etc/dbus-1/system.d/org.freedesktop.locale1.conf 35 2019-07-31_04:15:18 2024-06-20_18:15:02 2024-06-20_18:14:27 8534 /tmp/etc/dbus-1/system.d/org.freedesktop.login1.conf 36 2019-07-31_04:15:18 2024-06-20_18:15:02 2024-06-20_18:14:27 3726 /tmp/etc/dbus-1/system.d/org.freedesktop.machine1.conf 37 2018-10-30_18:52:13 2024-06-20_18:15:02 2024-06-20_18:14:27 404 /tmp/etc/dbus-1/system.d/org.freedesktop.realmd.conf 38 2019-07-31_04:15:18 2024-06-20_18:15:02 2024-06-20_18:14:27 10118 /tmp/etc/dbus-1/system.d/org.freedesktop.systemd1.conf 39 2019-07-31_04:15:18 2024-06-20_18:15:02 2024-06-20_18:14:27 947 /tmp/etc/dbus-1/system.d/org.freedesktop.timedate1.conf 40 2014-06-10_02:48:30 2024-06-20_18:15:02 2024-06-20_18:14:27 570 /tmp/etc/dbus-1/system.d/org.gnome.GConf.Defaults.conf 41 2015-05-07_13:19:13 2024-06-20_18:15:02 2024-06-20_18:14:27 434 /tmp/etc/dbus-1/system.d/org.kde.auth.conf 42 2018-04-10_21:49:14 2024-06-20_18:15:02 2024-06-20_18:14:27 295 /tmp/etc/dbus-1/system.d/org.kde.fontinst.conf 43 2018-04-10_19:59:52 2024-06-20_18:15:02 2024-06-20_18:14:27 300 /tmp/etc/dbus-1/system.d/org.kde.kalarmrtcwake.conf 44 2018-04-10_21:49:14 2024-06-20_18:15:02 2024-06-20_18:14:27 304 /tmp/etc/dbus-1/system.d/org.kde.kcontrol.kcmclock.conf 45 2018-04-19_18:15:57 2024-06-20_18:15:02 2024-06-20_18:14:27 312 /tmp/etc/dbus-1/system.d/org.kde.kcontrol.kcmremotewidgets.conf 46 2018-04-10_21:49:12 2024-06-20_18:15:02 2024-06-20_18:14:27 314 /tmp/etc/dbus-1/system.d/org.kde.ksysguard.processlisthelper.conf 47 2018-04-10_21:49:13 2024-06-20_18:15:02 2024-06-20_18:14:27 313 /tmp/etc/dbus-1/system.d/org.kde.powerdevil.backlighthelper.conf 48 2017-08-05_17:09:43 2024-06-20_18:15:02 2024-06-20_18:14:27 535 /tmp/etc/dbus-1/system.d/org.opensuse.CupsPkHelper.Mechanism.conf 49 2019-01-29_12:46:22 2024-06-20_18:15:02 2024-06-20_18:14:27 535 /tmp/etc/dbus-1/system.d/org.selinux.conf 50 2018-04-12_14:46:37 2024-06-20_18:15:02 2024-06-20_18:14:27 1084 /tmp/etc/dbus-1/system.d/pulseaudio-system.conf 51 2017-03-17_13:41:23 2024-06-20_18:15:02 2024-06-20_18:14:27 409 /tmp/etc/dbus-1/system.d/teamd.conf 52 2018-10-30_19:03:42 2024-06-20_18:15:02 2024-06-20_18:14:27 1096 /tmp/etc/dbus-1/system.d/wpa_supplicant.conf 53 2018-10-30_13:05:19 2024-06-20_18:15:02 2024-06-20_18:14:41 26832 /tmp/etc/dnsmasq.conf 54 2019-06-20_11:04:19 2024-06-20_18:15:02 2024-06-20_18:14:53 450 /tmp/etc/libvirt/libvirt-admin.conf 55 2019-06-20_11:04:19 2024-06-20_18:15:02 2024-06-20_18:14:53 547 /tmp/etc/libvirt/libvirt.conf 56 2019-06-20_11:04:19 2024-06-20_18:15:02 2024-06-20_18:14:53 16529 /tmp/etc/libvirt/libvirtd.conf 57 2019-06-20_11:04:19 2024-06-20_18:15:02 2024-06-20_18:14:53 2169 /tmp/etc/libvirt/qemu-lockd.conf 58 2019-06-20_11:04:19 2024-06-20_18:15:02 2024-06-20_18:14:53 30306 /tmp/etc/libvirt/qemu.conf 59 2019-06-20_11:04:19 2024-06-20_18:15:02 2024-06-20_18:14:53 3202 /tmp/etc/libvirt/virtlockd.conf 60 2019-06-20_11:04:19 2024-06-20_18:15:02 2024-06-20_18:14:53 3247 /tmp/etc/libvirt/virtlogd.conf 61 2018-10-30_13:10:18 2024-06-20_18:11:41 2024-06-20_18:11:28 403 /tmp/etc/sysconfig/atd 62 2019-04-11_04:04:46 2024-06-20_18:11:41 2024-06-20_18:11:28 430 /tmp/etc/sysconfig/authconfig 63 2018-10-30_20:17:07 2024-06-20_18:11:41 2024-06-20_18:11:28 339 /tmp/etc/sysconfig/autofs 64 2018-04-11_04:08:33 2024-06-20_18:11:41 2024-06-20_18:11:28 11 /tmp/etc/sysconfig/cbq/avpkt 65 2018-04-11_04:08:33 2024-06-20_18:11:41 2024-06-20_18:11:28 79 /tmp/etc/sysconfig/cbq/cbq-0000.example 66 2018-10-30_19:26:46 2024-06-20_18:11:41 2024-06-20_18:11:28 105 /tmp/etc/sysconfig/cgred 67 2018-04-12_13:37:56 2024-06-20_18:11:41 2024-06-20_18:11:28 46 /tmp/etc/sysconfig/chronyd 68 2017-08-22_17:43:23 2024-06-20_18:11:41 2024-06-20_18:11:28 150 /tmp/etc/sysconfig/cpupower 69 2018-11-20_09:22:40 2024-06-20_18:11:41 2024-06-20_18:11:28 110 /tmp/etc/sysconfig/crond 70 2018-04-10_22:44:54 2024-06-20_18:11:41 2024-06-20_18:11:28 1390 /tmp/etc/sysconfig/ebtables-config 71 2019-03-14_06:18:05 2024-06-20_18:11:41 2024-06-20_18:11:28 169 /tmp/etc/sysconfig/fcoe 72 2018-10-30_18:46:59 2024-06-20_18:11:41 2024-06-20_18:11:28 73 /tmp/etc/sysconfig/firewalld 73 2018-10-30_18:57:05 2024-06-20_18:11:41 2024-06-20_18:11:28 798 /tmp/etc/sysconfig/init 74 2018-11-04_12:03:01 2024-06-20_18:11:41 2024-06-20_18:11:28 2393 /tmp/etc/sysconfig/ip6tables-config 75 2018-11-04_12:03:01 2024-06-20_18:11:41 2024-06-20_18:11:28 2374 /tmp/etc/sysconfig/iptables-config 76 2022-08-31_15:01:59 2024-06-20_18:11:41 2024-06-20_18:11:28 1057 /tmp/etc/sysconfig/iptables-config~2 77 2018-04-10_16:31:59 2024-06-20_18:11:41 2024-06-20_18:11:28 903 /tmp/etc/sysconfig/irqbalance 78 2018-11-04_12:10:01 2024-06-20_18:11:41 2024-06-20_18:11:28 1722 /tmp/etc/sysconfig/kdump 79 2019-04-11_04:04:33 2024-06-20_18:11:41 2024-06-20_18:11:28 180 /tmp/etc/sysconfig/kernel 80 2019-06-20_11:04:19 2024-06-20_18:11:41 2024-06-20_18:11:28 1136 /tmp/etc/sysconfig/libvirtd 81 2018-10-30_10:42:18 2024-06-20_18:11:41 2024-06-20_18:11:28 134 /tmp/etc/sysconfig/lm_sensors 82 2018-10-30_10:55:19 2024-06-20_18:11:41 2024-06-20_18:11:28 200 /tmp/etc/sysconfig/man-db 83 2022-08-30_22:09:53 2024-06-20_18:11:41 2024-06-20_18:11:28 88 /tmp/etc/sysconfig/modules/mic.modules 84 2018-10-30_18:57:05 2024-06-20_18:11:41 2024-06-20_18:11:28 634 /tmp/etc/sysconfig/netconsole 85 2022-09-01_01:11:47 2024-06-20_18:11:41 2024-06-20_18:11:28 22 /tmp/etc/sysconfig/network 86 2022-09-09_09:42:32 2024-06-20_18:11:41 2024-06-20_18:11:28 398 /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 87 2022-09-12_23:04:10 2024-06-20_18:11:41 2024-06-20_18:11:28 276 /tmp/etc/sysconfig/network-scripts/__foo3 88 2022-09-09_09:42:33 2024-06-20_18:11:41 2024-06-20_18:11:28 94 /tmp/etc/sysconfig/network-scripts/__ifcfg-enp2s0__ 89 2022-09-12_23:00:52 2024-06-20_18:11:41 2024-06-20_18:11:28 381 /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE 90 2022-09-09_09:42:33 2024-06-20_18:11:41 2024-06-20_18:11:28 410 /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ 91 2022-09-09_09:42:33 2024-06-20_18:11:41 2024-06-20_18:11:28 323 /tmp/etc/sysconfig/network-scripts/ifcfg-Wired_connection_1 92 2022-09-09_09:42:32 2024-06-20_18:11:41 2024-06-20_18:11:28 169 /tmp/etc/sysconfig/network-scripts/ifcfg-br0 93 2022-09-09_09:42:32 2024-06-20_18:11:41 2024-06-20_18:11:28 131 /tmp/etc/sysconfig/network-scripts/ifcfg-br0~~ 94 2022-09-09_09:42:32 2024-06-20_18:11:41 2024-06-20_18:11:28 90 /tmp/etc/sysconfig/network-scripts/ifcfg-eno1 95 2022-09-09_09:42:32 2024-06-20_18:11:41 2024-06-20_18:11:28 90 /tmp/etc/sysconfig/network-scripts/ifcfg-eno1~ 96 2022-09-09_09:42:32 2024-06-20_18:11:41 2024-06-20_18:11:28 75 /tmp/etc/sysconfig/network-scripts/ifcfg-eno1~~ 97 2022-09-09_09:42:33 2024-06-20_18:11:41 2024-06-20_18:11:28 98 /tmp/etc/sysconfig/network-scripts/ifcfg-enp5s0f1 98 2022-09-14_20:27:57 2024-06-20_18:11:41 2024-06-20_18:11:28 592 /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 99 2022-09-14_20:28:08 2024-06-20_18:11:41 2024-06-20_18:11:28 448 /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 100 2022-09-09_09:42:33 2024-06-20_18:11:41 2024-06-20_18:11:28 254 /tmp/etc/sysconfig/network-scripts/ifcfg-lo 101 2022-09-09_09:42:33 2024-06-20_18:11:41 2024-06-20_18:11:28 89 /tmp/etc/sysconfig/network-scripts/ifcfg-mic0 102 2017-03-17_13:41:23 2024-06-20_18:11:41 2024-06-20_18:11:28 1621 /tmp/etc/sysconfig/network-scripts/ifdown-Team 103 2017-03-17_13:41:23 2024-06-20_18:11:41 2024-06-20_18:11:28 1556 /tmp/etc/sysconfig/network-scripts/ifdown-TeamPort 104 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 654 /tmp/etc/sysconfig/network-scripts/ifdown-bnep 105 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 6532 /tmp/etc/sysconfig/network-scripts/ifdown-eth 106 2018-10-30_16:10:18 2024-06-20_18:11:41 2024-06-20_18:11:28 6190 /tmp/etc/sysconfig/network-scripts/ifdown-ib 107 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 781 /tmp/etc/sysconfig/network-scripts/ifdown-ippp 108 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 4540 /tmp/etc/sysconfig/network-scripts/ifdown-ipv6 109 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 2130 /tmp/etc/sysconfig/network-scripts/ifdown-post 110 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 1068 /tmp/etc/sysconfig/network-scripts/ifdown-ppp 111 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 870 /tmp/etc/sysconfig/network-scripts/ifdown-routes 112 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 1456 /tmp/etc/sysconfig/network-scripts/ifdown-sit 113 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 1462 /tmp/etc/sysconfig/network-scripts/ifdown-tunnel 114 2017-03-17_13:41:23 2024-06-20_18:11:41 2024-06-20_18:11:28 1755 /tmp/etc/sysconfig/network-scripts/ifup-Team 115 2017-03-17_13:41:23 2024-06-20_18:11:41 2024-06-20_18:11:28 1876 /tmp/etc/sysconfig/network-scripts/ifup-TeamPort 116 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 12415 /tmp/etc/sysconfig/network-scripts/ifup-aliases 117 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 910 /tmp/etc/sysconfig/network-scripts/ifup-bnep 118 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 13475 /tmp/etc/sysconfig/network-scripts/ifup-eth 119 2018-10-30_16:10:18 2024-06-20_18:11:41 2024-06-20_18:11:28 10114 /tmp/etc/sysconfig/network-scripts/ifup-ib 120 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 12075 /tmp/etc/sysconfig/network-scripts/ifup-ippp 121 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 11893 /tmp/etc/sysconfig/network-scripts/ifup-ipv6 122 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 650 /tmp/etc/sysconfig/network-scripts/ifup-plip 123 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 1064 /tmp/etc/sysconfig/network-scripts/ifup-plusb 124 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 4997 /tmp/etc/sysconfig/network-scripts/ifup-post 125 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 4154 /tmp/etc/sysconfig/network-scripts/ifup-ppp 126 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 2001 /tmp/etc/sysconfig/network-scripts/ifup-routes 127 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 3303 /tmp/etc/sysconfig/network-scripts/ifup-sit 128 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 2711 /tmp/etc/sysconfig/network-scripts/ifup-tunnel 129 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 1836 /tmp/etc/sysconfig/network-scripts/ifup-wireless 130 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 5419 /tmp/etc/sysconfig/network-scripts/init.ipv6-global 131 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 20671 /tmp/etc/sysconfig/network-scripts/network-functions 132 2018-08-24_06:23:27 2024-06-20_18:11:41 2024-06-20_18:11:28 31027 /tmp/etc/sysconfig/network-scripts/network-functions-ipv6 133 2018-11-07_11:56:34 2024-06-20_18:11:41 2024-06-20_18:11:28 1679 /tmp/etc/sysconfig/nfs 134 2018-04-10_16:29:08 2024-06-20_18:11:41 2024-06-20_18:11:28 45 /tmp/etc/sysconfig/ntpd 135 2018-04-10_16:29:08 2024-06-20_18:11:41 2024-06-20_18:11:28 111 /tmp/etc/sysconfig/ntpdate 136 2018-10-30_15:25:51 2024-06-20_18:11:41 2024-06-20_18:11:28 3848 /tmp/etc/sysconfig/opensm 137 2022-08-31_11:43:57 2024-06-20_18:11:41 2024-06-20_18:11:28 3905 /tmp/etc/sysconfig/opensm.rpmsave 138 2018-10-30_10:53:44 2024-06-20_18:11:41 2024-06-20_18:11:28 911 /tmp/etc/sysconfig/qemu-ga 139 2018-10-30_13:54:11 2024-06-20_18:11:41 2024-06-20_18:11:28 186 /tmp/etc/sysconfig/radvd 140 2018-10-30_10:55:05 2024-06-20_18:11:41 2024-06-20_18:11:28 2915 /tmp/etc/sysconfig/raid-check 141 2017-08-04_04:01:03 2024-06-20_18:11:41 2024-06-20_18:11:28 15 /tmp/etc/sysconfig/rdisc 142 2018-10-30_18:57:05 2024-06-20_18:11:41 2024-06-20_18:11:28 905 /tmp/etc/sysconfig/readonly-root 143 2018-04-10_16:29:40 2024-06-20_18:11:41 2024-06-20_18:11:28 395 /tmp/etc/sysconfig/rpc-rquotad 144 2018-10-30_19:00:54 2024-06-20_18:11:41 2024-06-20_18:11:28 73 /tmp/etc/sysconfig/rpcbind 145 2018-04-10_22:00:01 2024-06-20_18:11:41 2024-06-20_18:11:28 12 /tmp/etc/sysconfig/rsyncd 146 2018-10-30_10:49:15 2024-06-20_18:11:41 2024-06-20_18:11:28 196 /tmp/etc/sysconfig/rsyslog 147 2014-06-09_18:14:31 2024-06-20_18:11:41 2024-06-20_18:11:28 0 /tmp/etc/sysconfig/run-parts 148 2018-10-30_18:32:50 2024-06-20_18:11:41 2024-06-20_18:11:28 428 /tmp/etc/sysconfig/samba 149 2018-04-10_16:21:10 2024-06-20_18:11:41 2024-06-20_18:11:28 429 /tmp/etc/sysconfig/saslauthd 150 2018-04-10_16:42:03 2024-06-20_18:11:41 2024-06-20_18:11:28 125 /tmp/etc/sysconfig/smartmontools 151 2018-04-11_00:21:29 2024-06-20_18:11:41 2024-06-20_18:11:28 506 /tmp/etc/sysconfig/sshd 152 2018-04-10_16:36:55 2024-06-20_18:11:41 2024-06-20_18:11:28 138 /tmp/etc/sysconfig/svnserve 153 2019-07-29_13:35:32 2024-06-20_18:11:41 2024-06-20_18:11:28 474 /tmp/etc/sysconfig/sysstat 154 2019-07-29_13:35:32 2024-06-20_18:11:41 2024-06-20_18:11:28 6228 /tmp/etc/sysconfig/sysstat.ioconf 155 2019-06-20_11:04:19 2024-06-20_18:11:41 2024-06-20_18:11:28 55 /tmp/etc/sysconfig/virtlockd 156 2019-06-20_11:04:19 2024-06-20_18:11:41 2024-06-20_18:11:28 53 /tmp/etc/sysconfig/virtlogd 157 2018-10-30_19:03:42 2024-06-20_18:11:41 2024-06-20_18:11:28 610 /tmp/etc/sysconfig/wpa_supplicant 158 2016-11-05_11:25:05 2024-06-20_18:11:41 2024-06-20_18:11:28 376 /tmp/etc/sysconfig/xinetd *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.Infiniband"/> FOUND // pattern Infiniband in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the Infiniband interface with hardware address FOUND // pattern Infiniband in file /tmp/etc/dnsmasq.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=Infiniband match 2/2 TYPE=Infiniband FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=Infiniband match 2/2 TYPE=Infiniband FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: the option -quiet is to suppress the printing of all the files that are found by findreplace. we will add it in the following command to shorten the output.

bash:2 19:30:41 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern Infiniband -quiet FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.Infiniband"/> FOUND // pattern Infiniband in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the Infiniband interface with hardware address FOUND // pattern Infiniband in file /tmp/etc/dnsmasq.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=Infiniband match 2/2 TYPE=Infiniband FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=Infiniband match 2/2 TYPE=Infiniband FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: the option -nopatcase tell findreplace to ignore the case of the pattern being searched.

bash:3 19:30:51 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern Infiniband -quiet -nopatcase FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.Infiniband"/> FOUND // pattern Infiniband in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the Infiniband interface with hardware address FOUND // pattern Infiniband in file /tmp/etc/dnsmasq.conf *** 6 MATCHED IN FILE [/tmp/etc/libvirt/qemu.conf] match 1/6 # "/dev/infiniband/rdma_cm", match 2/6 # "/dev/infiniband/issm0", match 3/6 # "/dev/infiniband/issm1", match 4/6 # "/dev/infiniband/umad0", match 5/6 # "/dev/infiniband/umad1", match 6/6 # "/dev/infiniband/uverbs0" FOUND // pattern Infiniband in file /tmp/etc/libvirt/qemu.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=Infiniband match 2/2 TYPE=Infiniband FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__foo3] match 1/1 TYPE=InfiniBand FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__foo3 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE] match 1/1 TYPE=InfiniBand FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=Infiniband match 2/2 TYPE=Infiniband FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0] match 1/1 TYPE=InfiniBand FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002] match 1/1 TYPE=InfiniBand FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifdown-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/ifdown-ib *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifup-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/ifup-ib *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/network-functions] match 1/1 InfiniBand | InfiniBand) FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: to replace the pattern with a new pattern we use the options: -pattern and -newpattern. here findreplace search for the pattern Infiniband to replace with the pattern INFINITYBAND. this command will show what is found and what will be replaced with what, but it does not commit any change.

bash:4 19:30:59 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern Infiniband -quiet -nopatcase -newpattern INFINITYBAND FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.Infiniband"/> send_interface="org.freedesktop.NetworkManager.Device.INFINITYBAND"/> REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the Infiniband interface with hardware address # Always give the INFINITYBAND interface with hardware address REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/dnsmasq.conf *** 6 MATCHED IN FILE [/tmp/etc/libvirt/qemu.conf] match 1/6 # "/dev/infiniband/rdma_cm", # "/dev/INFINITYBAND/rdma_cm", match 2/6 # "/dev/infiniband/issm0", # "/dev/INFINITYBAND/issm0", match 3/6 # "/dev/infiniband/issm1", # "/dev/INFINITYBAND/issm1", match 4/6 # "/dev/infiniband/umad0", # "/dev/INFINITYBAND/umad0", match 5/6 # "/dev/infiniband/umad1", # "/dev/INFINITYBAND/umad1", match 6/6 # "/dev/infiniband/uverbs0" # "/dev/INFINITYBAND/uverbs0" REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/libvirt/qemu.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=Infiniband #TYPE=INFINITYBAND match 2/2 TYPE=Infiniband TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__foo3] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__foo3 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=Infiniband #TYPE=INFINITYBAND match 2/2 TYPE=Infiniband TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifdown-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifdown-ib *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifup-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifup-ib *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/network-functions] match 1/1 InfiniBand | InfiniBand) INFINITYBAND | INFINITYBAND) REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: here we added -nopatcase option telling findreplace to ignore the case of the pattern. you can see more files are found to contain the word Infiniband (disregarding the case).

bash:5 19:31:15 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern Infiniband -quiet -nopatcase FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.Infiniband"/> FOUND // pattern Infiniband in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the Infiniband interface with hardware address FOUND // pattern Infiniband in file /tmp/etc/dnsmasq.conf *** 6 MATCHED IN FILE [/tmp/etc/libvirt/qemu.conf] match 1/6 # "/dev/infiniband/rdma_cm", match 2/6 # "/dev/infiniband/issm0", match 3/6 # "/dev/infiniband/issm1", match 4/6 # "/dev/infiniband/umad0", match 5/6 # "/dev/infiniband/umad1", match 6/6 # "/dev/infiniband/uverbs0" FOUND // pattern Infiniband in file /tmp/etc/libvirt/qemu.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=Infiniband match 2/2 TYPE=Infiniband FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__foo3] match 1/1 TYPE=InfiniBand FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__foo3 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE] match 1/1 TYPE=InfiniBand FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=Infiniband match 2/2 TYPE=Infiniband FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0] match 1/1 TYPE=InfiniBand FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002] match 1/1 TYPE=InfiniBand FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifdown-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/ifdown-ib *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifup-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/ifup-ib *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/network-functions] match 1/1 InfiniBand | InfiniBand) FOUND // pattern Infiniband in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: here the option -silent is to silence the replacement-processor and just show that a pattern is found rather then printing what is found and what will be replaced. do not confuse -quiet with -silent. below we repeat the command without the -silent option. also note that no real replacement is taking place yet, that is the command shows you only what will be replaced with what without committing the changes.

bash:6 19:31:54 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern Infiniband -quiet -nopatcase -newpattern INFINITYBAND -silent FIND GOT 158 FILES IN DIRECTORY ./ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/dnsmasq.conf REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/libvirt/qemu.conf REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__foo3 REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifdown-ib REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifup-ib REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: we repeat the previous command without the -silent option. note how findreplace prints what is being being replaced with what. the -silent option is usually used when doing batch processing replacement.

bash:7 19:32:26 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern Infiniband -quiet -nopatcase -newpattern INFINITYBAND FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.Infiniband"/> send_interface="org.freedesktop.NetworkManager.Device.INFINITYBAND"/> REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the Infiniband interface with hardware address # Always give the INFINITYBAND interface with hardware address REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/dnsmasq.conf *** 6 MATCHED IN FILE [/tmp/etc/libvirt/qemu.conf] match 1/6 # "/dev/infiniband/rdma_cm", # "/dev/INFINITYBAND/rdma_cm", match 2/6 # "/dev/infiniband/issm0", # "/dev/INFINITYBAND/issm0", match 3/6 # "/dev/infiniband/issm1", # "/dev/INFINITYBAND/issm1", match 4/6 # "/dev/infiniband/umad0", # "/dev/INFINITYBAND/umad0", match 5/6 # "/dev/infiniband/umad1", # "/dev/INFINITYBAND/umad1", match 6/6 # "/dev/infiniband/uverbs0" # "/dev/INFINITYBAND/uverbs0" REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/libvirt/qemu.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=Infiniband #TYPE=INFINITYBAND match 2/2 TYPE=Infiniband TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__foo3] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__foo3 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=Infiniband #TYPE=INFINITYBAND match 2/2 TYPE=Infiniband TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifdown-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifdown-ib *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifup-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifup-ib *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/network-functions] match 1/1 InfiniBand | InfiniBand) INFINITYBAND | INFINITYBAND) REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: here we will really replace the pattern Infiniband with the new pattern INFINITYBAND as the option -commit will commit the changes.

bash:8 19:34:2 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern Infiniband -quiet -nopatcase -newpattern INFINITYBAND -commit FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.Infiniband"/> send_interface="org.freedesktop.NetworkManager.Device.INFINITYBAND"/> @@@ CHANGING FILE /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the Infiniband interface with hardware address # Always give the INFINITYBAND interface with hardware address @@@ CHANGING FILE /tmp/etc/dnsmasq.conf WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/dnsmasq.conf *** 6 MATCHED IN FILE [/tmp/etc/libvirt/qemu.conf] match 1/6 # "/dev/infiniband/rdma_cm", # "/dev/INFINITYBAND/rdma_cm", match 2/6 # "/dev/infiniband/issm0", # "/dev/INFINITYBAND/issm0", match 3/6 # "/dev/infiniband/issm1", # "/dev/INFINITYBAND/issm1", match 4/6 # "/dev/infiniband/umad0", # "/dev/INFINITYBAND/umad0", match 5/6 # "/dev/infiniband/umad1", # "/dev/INFINITYBAND/umad1", match 6/6 # "/dev/infiniband/uverbs0" # "/dev/INFINITYBAND/uverbs0" @@@ CHANGING FILE /tmp/etc/libvirt/qemu.conf WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/libvirt/qemu.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=Infiniband #TYPE=INFINITYBAND match 2/2 TYPE=Infiniband TYPE=INFINITYBAND @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__foo3] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/__foo3 WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__foo3 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=Infiniband #TYPE=INFINITYBAND match 2/2 TYPE=Infiniband TYPE=INFINITYBAND @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002] match 1/1 TYPE=InfiniBand TYPE=INFINITYBAND @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifdown-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/ifdown-ib WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifdown-ib *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifup-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/ifup-ib WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifup-ib *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/network-functions] match 1/1 InfiniBand | InfiniBand) INFINITYBAND | INFINITYBAND) @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/network-functions WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern Infiniband with INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: since the changes have been commited there is no more pattern Infiniband as shown in this command.

bash:9 19:34:20 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern Infiniband -quiet -nopatcase -newpattern INFINITYBAND FIND GOT 158 FILES IN DIRECTORY ./ Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: but we can look for the pattern INFINITYBAND and locate them in the files.

bash:10 19:35:32 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern INFINITYBAND -quiet FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.INFINITYBAND"/> FOUND // pattern INFINITYBAND in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the INFINITYBAND interface with hardware address FOUND // pattern INFINITYBAND in file /tmp/etc/dnsmasq.conf *** 6 MATCHED IN FILE [/tmp/etc/libvirt/qemu.conf] match 1/6 # "/dev/INFINITYBAND/rdma_cm", match 2/6 # "/dev/INFINITYBAND/issm0", match 3/6 # "/dev/INFINITYBAND/issm1", match 4/6 # "/dev/INFINITYBAND/umad0", match 5/6 # "/dev/INFINITYBAND/umad1", match 6/6 # "/dev/INFINITYBAND/uverbs0" FOUND // pattern INFINITYBAND in file /tmp/etc/libvirt/qemu.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=INFINITYBAND match 2/2 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__foo3] match 1/1 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__foo3 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE] match 1/1 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=INFINITYBAND match 2/2 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0] match 1/1 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002] match 1/1 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifdown-ib] match 1/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifdown-ib *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifup-ib] match 1/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifup-ib *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/network-functions] match 1/1 INFINITYBAND | INFINITYBAND) FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: let's undo the replacement of Infiniband with INFINITYBAND, so we will look for the pattern INFINITYBAND and replace it with InfiniBand; however, we do not commit the change.

bash:11 19:35:46 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern INFINITYBAND -quiet -nopatcase -newpattern InfiniBand FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.INFINITYBAND"/> send_interface="org.freedesktop.NetworkManager.Device.InfiniBand"/> REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the INFINITYBAND interface with hardware address # Always give the InfiniBand interface with hardware address REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/dnsmasq.conf *** 6 MATCHED IN FILE [/tmp/etc/libvirt/qemu.conf] match 1/6 # "/dev/INFINITYBAND/rdma_cm", # "/dev/InfiniBand/rdma_cm", match 2/6 # "/dev/INFINITYBAND/issm0", # "/dev/InfiniBand/issm0", match 3/6 # "/dev/INFINITYBAND/issm1", # "/dev/InfiniBand/issm1", match 4/6 # "/dev/INFINITYBAND/umad0", # "/dev/InfiniBand/umad0", match 5/6 # "/dev/INFINITYBAND/umad1", # "/dev/InfiniBand/umad1", match 6/6 # "/dev/INFINITYBAND/uverbs0" # "/dev/InfiniBand/uverbs0" REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/libvirt/qemu.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=INFINITYBAND #TYPE=InfiniBand match 2/2 TYPE=INFINITYBAND TYPE=InfiniBand REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__foo3] match 1/1 TYPE=INFINITYBAND TYPE=InfiniBand REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/__foo3 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE] match 1/1 TYPE=INFINITYBAND TYPE=InfiniBand REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=INFINITYBAND #TYPE=InfiniBand match 2/2 TYPE=INFINITYBAND TYPE=InfiniBand REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0] match 1/1 TYPE=INFINITYBAND TYPE=InfiniBand REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002] match 1/1 TYPE=INFINITYBAND TYPE=InfiniBand REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifdown-ib] match 1/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifdown-ib *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifup-ib] match 1/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifup-ib *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/network-functions] match 1/1 INFINITYBAND | INFINITYBAND) InfiniBand | InfiniBand) REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: since the change is not commited previously, then the pattern INFINITYBAND still exist.

bash:12 19:36:4 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern INFINITYBAND -quiet FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.INFINITYBAND"/> FOUND // pattern INFINITYBAND in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the INFINITYBAND interface with hardware address FOUND // pattern INFINITYBAND in file /tmp/etc/dnsmasq.conf *** 6 MATCHED IN FILE [/tmp/etc/libvirt/qemu.conf] match 1/6 # "/dev/INFINITYBAND/rdma_cm", match 2/6 # "/dev/INFINITYBAND/issm0", match 3/6 # "/dev/INFINITYBAND/issm1", match 4/6 # "/dev/INFINITYBAND/umad0", match 5/6 # "/dev/INFINITYBAND/umad1", match 6/6 # "/dev/INFINITYBAND/uverbs0" FOUND // pattern INFINITYBAND in file /tmp/etc/libvirt/qemu.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=INFINITYBAND match 2/2 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__foo3] match 1/1 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__foo3 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE] match 1/1 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=INFINITYBAND match 2/2 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0] match 1/1 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002] match 1/1 TYPE=INFINITYBAND FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifdown-ib] match 1/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifdown-ib *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifup-ib] match 1/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/ifup-ib *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/network-functions] match 1/1 INFINITYBAND | INFINITYBAND) FOUND // pattern INFINITYBAND in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: here we will redo the change and commit the operation.

bash:13 19:38:16 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern INFINITYBAND -quiet -nopatcase -newpattern InfiniBand -commit FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.INFINITYBAND"/> send_interface="org.freedesktop.NetworkManager.Device.InfiniBand"/> @@@ CHANGING FILE /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the INFINITYBAND interface with hardware address # Always give the InfiniBand interface with hardware address @@@ CHANGING FILE /tmp/etc/dnsmasq.conf WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/dnsmasq.conf *** 6 MATCHED IN FILE [/tmp/etc/libvirt/qemu.conf] match 1/6 # "/dev/INFINITYBAND/rdma_cm", # "/dev/InfiniBand/rdma_cm", match 2/6 # "/dev/INFINITYBAND/issm0", # "/dev/InfiniBand/issm0", match 3/6 # "/dev/INFINITYBAND/issm1", # "/dev/InfiniBand/issm1", match 4/6 # "/dev/INFINITYBAND/umad0", # "/dev/InfiniBand/umad0", match 5/6 # "/dev/INFINITYBAND/umad1", # "/dev/InfiniBand/umad1", match 6/6 # "/dev/INFINITYBAND/uverbs0" # "/dev/InfiniBand/uverbs0" @@@ CHANGING FILE /tmp/etc/libvirt/qemu.conf WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/libvirt/qemu.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=INFINITYBAND #TYPE=InfiniBand match 2/2 TYPE=INFINITYBAND TYPE=InfiniBand @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__foo3] match 1/1 TYPE=INFINITYBAND TYPE=InfiniBand @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/__foo3 WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/__foo3 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE] match 1/1 TYPE=INFINITYBAND TYPE=InfiniBand @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=INFINITYBAND #TYPE=InfiniBand match 2/2 TYPE=INFINITYBAND TYPE=InfiniBand @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0] match 1/1 TYPE=INFINITYBAND TYPE=InfiniBand @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002] match 1/1 TYPE=INFINITYBAND TYPE=InfiniBand @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifdown-ib] match 1/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/ifdown-ib WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifdown-ib *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifup-ib] match 1/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PKEY_ID" net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"INFINITYBAND IPoIB device: PKEY=yes requires a PHYSDEV" net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/ifup-ib WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifup-ib *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/network-functions] match 1/1 INFINITYBAND | INFINITYBAND) InfiniBand | InfiniBand) @@@ CHANGING FILE /tmp/etc/sysconfig/network-scripts/network-functions WITH NEW PATTERN REPLACEMENT @@@ REPLACED // pattern INFINITYBAND with InfiniBand in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: since the change is commited, now we can locate the pattern InfiniBand that we started with.

bash:14 19:38:37 root@HPMC7 /tmp/etc # findreplace -dir ./ -pattern InfiniBand -quiet FIND GOT 158 FILES IN DIRECTORY ./ *** 1 MATCHED IN FILE [/tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf] match 1/1 send_interface="org.freedesktop.NetworkManager.Device.InfiniBand"/> FOUND // pattern InfiniBand in file /tmp/etc/dbus-1/system.d/org.freedesktop.NetworkManager.conf *** 1 MATCHED IN FILE [/tmp/etc/dnsmasq.conf] match 1/1 # Always give the InfiniBand interface with hardware address FOUND // pattern InfiniBand in file /tmp/etc/dnsmasq.conf *** 6 MATCHED IN FILE [/tmp/etc/libvirt/qemu.conf] match 1/6 # "/dev/InfiniBand/rdma_cm", match 2/6 # "/dev/InfiniBand/issm0", match 3/6 # "/dev/InfiniBand/issm1", match 4/6 # "/dev/InfiniBand/umad0", match 5/6 # "/dev/InfiniBand/umad1", match 6/6 # "/dev/InfiniBand/uverbs0" FOUND // pattern InfiniBand in file /tmp/etc/libvirt/qemu.conf *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0] match 1/2 #TYPE=InfiniBand match 2/2 TYPE=InfiniBand FOUND // pattern InfiniBand in file /tmp/etc/sysconfig/network-scripts/__1__ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__foo3] match 1/1 TYPE=InfiniBand FOUND // pattern InfiniBand in file /tmp/etc/sysconfig/network-scripts/__foo3 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE] match 1/1 TYPE=InfiniBand FOUND // pattern InfiniBand in file /tmp/etc/sysconfig/network-scripts/__ifcfg-mlx4_ib0_example-DELETE *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__] match 1/2 #TYPE=InfiniBand match 2/2 TYPE=InfiniBand FOUND // pattern InfiniBand in file /tmp/etc/sysconfig/network-scripts/__ifcfg-ql40g_ib0__ *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0] match 1/1 TYPE=InfiniBand FOUND // pattern InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0 *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002] match 1/1 TYPE=InfiniBand FOUND // pattern InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifcfg-ib0.8002 *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifdown-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" FOUND // pattern InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifdown-ib *** 2 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/ifup-ib] match 1/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PKEY_ID" match 2/2 net_log $"InfiniBand IPoIB device: PKEY=yes requires a PHYSDEV" FOUND // pattern InfiniBand in file /tmp/etc/sysconfig/network-scripts/ifup-ib *** 1 MATCHED IN FILE [/tmp/etc/sysconfig/network-scripts/network-functions] match 1/1 InfiniBand | InfiniBand) FOUND // pattern InfiniBand in file /tmp/etc/sysconfig/network-scripts/network-functions Bye FileManagement::FileFinder!

ABOUT THE FOLLOWING COMMAND: sweet!

bash:15 19:38:54 root@HPMC7 /tmp/etc #