Difference between revisions of "Centos7-RHEL9"
m |
m |
||
Line 54: | Line 54: | ||
Show windows/terminals <code> screen -ls </code> Re-attach <code>screen -r [number or sesssion_name]</code> | Show windows/terminals <code> screen -ls </code> Re-attach <code>screen -r [number or sesssion_name]</code> | ||
+ | |||
+ | Scrollback start with <code>-h [numlines]</code> | ||
+ | to access ctrl-A, Esacpe , [then up/down], Escape to return. | ||
= Locale Problems = | = Locale Problems = |
Revision as of 23:53, 7 January 2020
Contents
Development
To make life super easy for the first cut of something
Disable firewall
service firewalld stop systemctl disable firewalld
Disable SELinux
/etc/selinux/config SELINUX=enforcing --> permissive Reboot
Interfaces
vi /etc/sysconfig/network-scripts/ifcfg-eth0
VM interfaces
VMWare interfaces are created in the following order
- ens192
- ens224
- ens256
- ens161
Static Routes
Temporary ip route add 172.16.5.0/24 via 10.0.0.101 dev eth0
ip route delete 192.168.0.0/16 dev ens256 scope link metric 1005
/etc/sysconfig/network-scripts/route-eth0
172.16.5.0/24 via 10.0.0.101 dev eth0
Remember to bounce the interface after
ifdown eth0 ifup eth0
Dummy Interface
$ cat /etc/modules-load.d/dummy.conf # Load dummy.ko at boot dummy $ cat /etc/modprobe.d/dummy.conf install dummy /sbin/modprobe --ignore-install dummy; /sbin/ip link set name ethdummy1 dev dummy0 $ cat /etc/sysconfig/network-scripts/ifcfg-ethdummy1 NAME=ethdummy1 DEVICE=ethdummy1 MACADDR=00:22:22:ff:ff:ff IPADDR=10.10.10.1 NETMASK=255.255.255.0 ONBOOT=yes TYPE=Ethernet NM_CONTROLLED=no
Screen
Terminal multiplexer. https://linuxize.com/post/how-to-use-linux-screen/
Start a 'window' screen
or to give the session a name screen -S 'hello_world'
To exit exit [enter]
To detach from the session ctrl + a , d)
Show windows/terminals screen -ls
Re-attach screen -r [number or sesssion_name]
Scrollback start with -h [numlines]
to access ctrl-A, Esacpe , [then up/down], Escape to return.
Locale Problems
This is an issue with Mobaxterm/WSL/Ubuntu not centos which sets the locale as C.UTF-8
, but here is a work around - add the following to your .bashrc file (seriously, there is something wrong with mobaxterm and this was the only fix (read: crude workaround)
export LANGUAGE=en_US.UTF-8 export LANG=en_US.UTF-8 export LC_ALL=en_US.UTF-8 export LC_CTYPE=en_US.UTF-8
Appears mobaxterm is built from cygwin sources which defaults to C.UTF-8 (which is an extended char set of en_US.UTF-8) - however some centos boxes do not know about the C variant so complain.
Normal fix (that Mobaxterm seems to ignore and set to C.UTF.8)
sudo locale-gen en_US.UTF-8 sudo update-locale LANG=en_US.UTF-8