Back to Blog

Tag: commands

Linux commands tips – Part 3

Multiple Gateways to Server nano /etc/network/interfaces auto lo iface lo inet loopbackauto eth0 iface eth0 inet static address 10.0.0.52 netmask 255.255.255.0 gateway 10.0.0.1auto eth1 iface eth1 inet static address 10.0.1.52 netmask 255.255.255.0 post-up route add 10.0.1.52 via 10.0.1.1 dev eth1 auto eth2 iface eth2 inet static address 10.0.2.52 netmask 255.255.255.0 post-up route add 10.0.2.52 via 10.0.2.1 dev eth2   Restrict…
Continue Reading

Linux commands tips – Part 2

Start / Stop / Restart OpenSSH (Ubuntu) START Service sudo /etc/init.d/ssh start OR sudo service ssh start STOP Service sudo /etc/init.d/ssh stop OR sudo service ssh stop RESTART Service sudo /etc/init.d/ssh restart OR sudo service ssh restart STATUS sudo /etc/init.d/ssh status OR sudo service ssh status   Restart network (Ubuntu) sudo service network-manager restart OR sudo ifconfig eth0 down &&…
Continue Reading
DNS, Linux, Network, NIC, Uncategorized

Linux commands tips – Part 1

Limit ssh access by IP address nano /etc/hosts.allow sshd : localhost : allow sshd : 192.168.0. : allow sshd : 99.151.250.7 : allow sshd : mydomain.net : allow sshd : ALL : deny   Enable SSH root login (Ubuntu) nano /etc/ssh/sshd_config Change line: FROM: PermitRootLogin prohibit-password TO: PermitRootLogin yes sudo systemctl restart sshd   Restrict SSH to one interface nano…
Continue Reading