voipmeister.com voip stuff matters and more

Articles in the Linux category

Use iptables on CentOS 7 instead of firewalld

  • log in to your CentOS 7 installation
  • disable firewalld
systemctl stop firewalld
systemctl mask firewalld
  • install the iptables-services package
yum install iptables-services
  • enable the services at boot-time
systemctl enable iptables
systemctl enable ip6tables
  • start the services
systemctl start iptables
systemctl start ip6tables
  • save the iptables configuration
service iptables save
service ip6tables save
  • the configuration can now be found in the file /etc/sysconfig/iptables

Ubuntu 10.04 with ‘old’ theme

I just installed Ubuntu 10.04 on my laptop. Works a treat, but that new theme… I don’t like it much and preferred the old theme (call me crazy but I do). So I headed for ‘Appearance’ and was about to select the old theme.. except… it is no longer part of the default installation.

If you have a machine with, say, Ubuntu 9.10 around, fixing this is fairly simple. Just plugin a USB stick on the old Ubuntu machine and go ahead:

cd /usr/share/themes
cp -R Human* /media/USBSTICK

Then remove the USB stick and insert into the 10.04 machine and continue:

sudo cp -R /media/USBSTICK/Human* /usr/share/themes
sudo chmod -R 755 /usr/share/themes/Human*

Then, go to System > Preferences > Appearance and select the Human-Clearlooks theme.

E-mail an attachment from linux cli

Here’s something I occasionally use on linux PBX’s:

cat body.txt | mutt user{a}example.com -a example.txt -s “Yoursubject”

Where:

  • body.txt contains the message body
  • user{a}example.com is the recipient e-mail address
  • example.txt is file to attach
  • Yoursubject is the subject of the message

It requires mutt to be installed, but this is often the case, even on servers with a minimal install.